/Tag:Replication

Near Realtime File Replication With Lsyncd

Ever wanted real time backups of  directories on your server? To replicate static media files for a website to a separate box to reduce load? An easy solution lays with lsyncd it allows you to watch a directory structure on your file system, and replicate any changes on a remote system. How It Works: inotify is a Linux subsystem available from the 2.6.13 release of the Linux kernel that monitors changes made to a file system and reports these changes to interested applications. lsyncd is an application written in lua that uses the inotify service to inform it of changes made to monitored directories and then when notified of a change uses rsync to replicate the changes on a remote service. Getting lsyncd The lsyncd sourcecode can be downloaded from Google Code and compiled but depending on the distribution your server is running, the install process be even easier as lsyncd is included in the repositories of many popular Linux distros. Installing On Debian / Ubuntu While lsyncd is included in both the repositories of Debian and Ubuntu but unfortunately its an outdated version so check what version you are going to get beforehand with the command: apt-cache show lsyncd If apt-cache tells you that only one of the 1.x versions are available, I would recommend grabbing one of the 2.x versions from the Debian testing repository instead, the amd64 package can be found here  and one for the i386 architecture here. Then install using the dpkg command i.e cd /root wget wget http://ftp.au.debian.org/debian/pool/main/l/lsyncd/lsyncd_2.0.4-1_amd64.deb apt-get install lua5.1 rsync dpkg -i lsyncd_2.0.4-1_amd64.deb […]

By |July 21st, 2011|Linux|2 Comments

Setting Up PowerDNS With A MySQL Backend On Ubuntu 9.10

Bind9 has treated us well over the years, but its lack of support for database back ends in a default install is very annoying, especially when an application needs to control DNS services dynamically. PowerDNS is a powerful alternative it supports a wide variety of back ends and can also be configured to serve different [...]

By |December 1st, 2009|Linux, Sysadmin|1 Comment