Moving Cacti from a 32-bit to a 64-bit system

I recently had to move our Cacti install from a 32-bit to a 64-bit Linux system, and ran into the following RRD error:

ERROR: This RRD was created on another architecture

This is because the RRD file format is architecture-dependent, as described here. To convert all your Cacti RRD files, run the following on the 32-bit machine in your Cacti rra/ directory:

for i in `ls *. rrd`; do rrdtool dump $i > $i.xml; done

Next, transfer all the resulting .xml files to the new Cacti location’s rra/ directory on the 64-bit server, and run the following in the rra/ directory:

for i in `ls *.xml`; do rrdtool restore $i `echo $i |sed s/.xml//g`; done

This will regenerate all .rrd files using the data from the .xml files.

Dovecot and the “Too many open files” error

EDIT: This method is not sufficient. See below for update!

I recently switched our mailserver from Gentoo and Courier-IMAP to CentOS 5.6 and Dovecot, which all went pretty smooth, until this weekend :) Dovecot wasn’t accepting logins anymore, and a quick look at the logs revealed the following:

May 30 09:06:17 mx1 dovecot: pipe() failed: Too many open files
May 30 09:06:17 mx1 dovecot: Temporary failure in creating login processes, slowing down for now

This is due to the standard max. open files limit of 1024, and was solved rather quickly by adding the following to /etc/security/limits.conf:

*                soft    nofile          8192
*                hard    nofile          63536

This increases the system-wide maximum of open files to a soft limit of 8192 files, and a hard limit of 63536 files. Restart Dovecot and verify the new limit is in effect with the following command:

cat /proc/`pidof dovecot`/limits |grep files

It should give the following output:

Max open files 8192 63536 files


It seems this method does not work as well as i thought it would. I found a better and much quicker/easier way to fix this. Just edit /etc/sysconfig/dovecot and change it to:

# Here you can specify your dovecot command line options.

# Increase max open files for dovecot process
ulimit -n 4096

Restart dovecot and you’re all set. Don’t forget to revert the changes to /etc/security/limits.conf if you altered this file.

New PHP4 RPMs for CentOS

Since there still seems to be people interested in PHP4 for CentOS, I thought i’d share my recently compiled RPM’s for PHP-4.4.7. They were build on a CentOS 5.0 system, for i386 and x86_64 architecture.

This time the source RPM is included as well.

You can find them here

Issues regarding HA-NFS with Heartbeat and DRBD on Slackware 12.0

Our NFS server setup at our datacenter consists of two SuperMicro SC933 chassis, each with dual Intel Xeon 3 Ghz, 2GB memory, and 15 200GB SATA disks connected to a Areca ARC-1160 16-ports SATA RAID controller. High Availability by redundancy and fail-over is taken care of by Heartbeat and DRBD. This setup is responsible for serving up document roots for our web cluster through NFS, and it obviously is very important that it always works :)

These systems run Slackware Linux, which has historically been my distro of choice for critical systems. When deploying Heartbeat on Slackware i ran into some issues which i’d like to share here. I won’t go into basic stuff like actually compiling and installing DRBD and Heartbeat, since that is pretty well documented in various other places, for starters the Linux-HA site (home of Heartbeat).
Read more »

CentOS 64 bit (x86_64) and VMWare Server

Recently i had to install VMWare Server on a CentOS 4.4 x86_64 box for one of our clients. I ran a clean install of CentOS 4.4 from the server CD. The RPM install of VMWare Server went fine but during the step i ran into some trouble related to missing libraries.

After some searching on Google i found an excellent post on the weblog of a CentOS developer named Karanbir Singh. To make everything work, you need to poison your 64-bit system with some 32-bit libraries :)

I had to install the following packages to make things work (some are sucked in by dependancies):

  • xorg-x11-libs.i386
  • expat.i386 (dep. of xorg-x11-libs)
  • fontconfig.i386 (dep. of xorg-x11-libs)
  • freetype.i386 (dep. of xorg-x11-libs)
  • xorg-x11-Mesa-libGL.i386 (dep. of xorg-x11-libs)
  • zlib.i386 (dep. of xorg-x11-libs)
  • glibc.i686
  • gcc.x86_64

After this ran flawlessly and VMWare Server is up and running!

Flickr GeoTagging

Following the great stick-everything-on-a-map rage i have just “GeoTagged” all my Flickr photo’s. Now you can find out exactly where every shot was taken :)

See the result at

New PHP-4.4.4 RPM’s for CentOS

I’ve built a bunch of new CentOS RPM’s from the recently released php-4.4.4. Just like last time, they’re available for both 32- and 64-bit Intel architectures, and although i’ve tested and use them myself, they come with absolutely no guarantee :)

You can get them here

PHP-4.4.2 RPMs for CentOS 4.3

Been a while since my last post ;) But anyway:

At the moment, we mostly run Slackware and Gentoo based servers at my workplace. Since the number of servers is steadily growing (currently 30-something servers), so is the maintenance. This is why i’ve been doing some research on more maintenance-friendly distros, one of which is CentOS, the community release of Red Hat Enterprise Linux.

So far i am really impressed by CentOS, and i’m getting more into the whole RPM buzz. I have always been a ‘compile-it-yourself’ person, and never really been a fan of RPM, but i’m starting to see the benefits now :)

The only thing i was a bit bummed about, was the relatively old version of php that came with CentOS 4.3. Since we run the latest version of PHP4 on most of our servers, i’ve been looking into rolling my own RPMs. After a bit of research on rpmbuild and related tools, the result is a bunch of PHP-4.4.2 RPMs for both 64-bit (x86_64) and 32-bit (i386) servers. And since CentOS is the community version of RHEL4, i thought i’d share these with the world.

You can find them here. Ofcourse the usual disclaimers apply ;)

Op IR missie in Haarlem

Ik ben vorig weekend samen met Jasper op pad geweest om wat te experimenteren met IR fotografie. Hierbij een van de eindresultaten. Even snel gepost, eigenlijk meer als smerig excuus om de integratie van Flickr met WordPress eens te checken :)

*tap tap tap* Is this thing on?

Daar gaat ie dan, de eerste post op mn blogje! Misschien wordt het nog wat, als ik de discipline op kan brengen :)

Moet nog wel ff een nieuwe (eigen) look en een fatsoenlijke naam tegenaan in ieder geval!