note

cacti перестал рисовать графики

какти вдруг перестал рисовать графики.
в логах пишет

05/28/2013 11:35:10 AM - CMDPHP: Poller[0] ERROR: A DB Exec Failed!, Error:'1017', SQL:"insert into poller_output (local_data_id, rrd_name, time, output) values (525, 'traffic_out', '2013-05-28 11:35:10', '493251798791')'
05/28/2013 11:35:10 AM - CMDPHP: Poller[0] ERROR: A DB Exec Failed!, Error:'1017', SQL:"insert into poller_output (local_data_id, rrd_name, time, output) values (525, 'traffic_in', '2013-05-28 11:35:10', '15642269223')'

VIM encrypt text file

Encrypt:
vim -x text.txt

Open:
vim text.txt

Change the password:
vim +X text.txt

Cleaning ‘Failed actions’ message in Pacemaker/Corosync cluster setup

crm_mon -1

Failed actions:
p_drbd_nfs:0_monitor_15000 (node=zeta, call=19, rc=-2, status=Timed Out): unknown exec error

crm_resource -P

Waiting for 1 replies from the CRMd. OK

Скриншоты на mag250

нужна утилита fbdump
скачать можно тут:
https://dl.dropbox.com/u/4651430/fbdump
работает она на версиях прошивки 0.2.16
кидаем её на приставку
выставляем права

chmod a+x fbdump

шлепаем скриншоты
fbdump 1.png

MySQL Performance Tuning: EXPLAIN

EXPLAIN Types

system              The table has only one row 
const               At the most one matching row, treated as a constant 
eq_ref              One row per row from previous tables 
ref                 Several rows with matching index value 
ref_or_null         Like ref, plus NULL values 
index_merge         Several index searches are merged 
unique_subquery     Same as ref for some subqueries 
index_subquery      As above for non-unique indexes 
range               A range index scan 
index               The whole index is scanned 

Compress RAM on linux

sudo apt-get install zram-config

Support for 3TB drives on Adaptec Controllers

Support for 3TB drives is available on the following controllers:

Series 7 (7805, 7805Q, 71605E, 71605, 71605Q, 71685, 72405)
Series 6, 6E, 6Q, and 6T (6405, 6445, 6805, 6405E, 6805E, 6405T, 6805T, 6805Q, 6805TQ)
Series 2 (2405, 2045, 2805): using firmware/BIOS version 5.2.0 Build 17911 (or later)
Series 5 (5405, 5445, 5805, 5085, 51245, 51645, 52445): using firmware/BIOS version 5.2.0 Build 17911 (or later)
Q Series (5805Q, 2405Q): using firmware/BIOS version 5.2.0 Build 17911 (or later)

Обновление портала Stalker

1.Переименовать каталог с предыдущей версией, например, в stalker_portal-old.

cp -R /var/www/stalker_portal /var/www/stalker_portal-old

2.Скачать и распаковать архив с новой версией;
3.Скопировать файл custom.ini из предыдущей версии в новую;
4.Скопировать каталог /var/www/stalker_portal/screenshots/ из предыдущей версии в новую;
5.Cкопировать все файлы каталога stalker_portal/misc/logos/ (кроме dummy.png) из предыдущей версии в новую;
6.Скопировать каталог firmwares из предыдущей версии в новую;

Advanced MySQL Replication Techniques

http://onlamp.com/pub/a/onlamp/2006/04/20/advanced-mysql-replication.htm...

In this broader schema, water is the master of air and slave of earth, which is slave of fire; and this last is in turn slave of air, thus completing the circle. The boxed numbers next to each server indicate the server ID, which must be different for each node; the auto_increment_increment, the same for all the nodes; and the auto_increment_offset, which guarantees the uniqueness of self-generated keys.

Here is the complete setup for all nodes:

# node A - water
[mysqld]

удалить файлы, старше 30 дней

find /var/www/file_exchange/uploads/ -type f -mtime +30 -delete

Найти файлы редактированный за последние сутки

find /var/www/abc_dev/ -type f -mtime -1 -print