Archive for July, 2011

openVZ: Automatic VETH Bridging Script

When you use openVZ you will sooner or later need virtual ethernet interfaces in VEs you’re going to bridge to an interface on your host node – for example to put your container into some special VLAN. Though openVZ included the optional “bridge” parameter to their configuration specification, they do not provide an automatic way of dealing with it once you set it up so you’ll have to take care about it yourself.

We wrote a script that allows you to bridge the virtual ethernet interface automatically to the hosts interface you specified within your VEs configuration once you start a virtual entity. All you have to do is saving it to /etc/vz/scripts, making it executable and starting it along with the VE mount event. To do this, insert “/etc/vz/vzbridge.sh $VEID &” into /etc/vz/conf/vps.mount (you might have to create the vps.mount file in first place and make it executeable too.).

You’ll find the script available for download here
http://creo.blackmesa.at/random_stuff.html

 

[creo]

 

 

Differential block-based backup using rdiff-backup

Time has come for us to stop worrying about a safe, reliable and efficient (aka. cheap) backup strategy. After weeks of comparing lots of backup solutions we found the one we’re going to use from now on (for our *x infrastructure).

If you are looking for a solid and easy way to backup your data (from single files to full machines) rdiff-backup may be your weapon of choice. While backing up your data from a given source directory (or set of directories) it preserves all meta-information and in the end provides a full copy of the source directory with extra reverse diffs that are stored in a special subdirectory of that target directory. This way you can recover your files easily by copying them back to their original location with cp, but you may also go back in time and recover files you deleted (or modified) a specified period of time ago. It fully resembles the features of Apples “TimeMachine” while being introduced in mid 2001.

rdiff-backup is available for all major platforms (yes – even Windows) and is licensed under GPL.

For more information, visit the rdiff-backup website.

 

[creo]