munin 2 would’t start after server crash

Yesterday my home server crashed, and munin2′s cron wouldn’t execute.

The error message was :

Magic number checking on storable file failed at 
/usr/local/lib/perl5/site_perl/5.14.2/mach/Storable.pm line 398, at 
/usr/local/lib/perl5/site_perl/5.14.2/Munin/Master/Utils.pm line 362

Solution was to find the file munin/limits.storable and remove it.

Encrypt a file using SSL certificate.

You can use traditionnal ssl certificate to encrypt files :

http://stackoverflow.com/questions/7143514/how-to-encrypt-a-large-file-in-openssl-using-public-key

openssl smime -encrypt -binary -aes256 -in /etc/fstab -out fstab.enc -outform DER /etc/ssl/certs/dannielou.com.pem
openssl smime -decrypt -binary -in fstab.enc -inform DER -out fstab -inkey /etc/ssl/certs/dannielou.com.key

Ever wondered how to sort /etc/group by gid

Just a quick post about reordering /etc/group using sort. As time goes, /etc/group is often unsorted as some groups were added and some others removed. The sort command has the ability to use alternative separator and to sort using arbitrary field :

sort -t":" -nk 3 /etc/group