Skip to content

Category: Technology

Setting max memory of a Xen Dom0

I've had some issues with Xen crashing when I wanted to create a DomU for which the Dom0 had to shrink (see bug report). Therefore, it's better to force a memory limit on the dom0. That is done with a kernel param. Read More »

Fixing a broken Xen DomU after upgrading to Ubuntu 11.4 (Natty)

My Xen DomU's that I upgraded to 11.4 no longer booted, because the xen-blkfront module is missing from the initramfs. To fix, do this when you get the initramfs prompt: Read More »

Fixing a Xen DomU’s grub config

When you use xen-create-image to bootstrap an ubuntu, it sets up a grub config file menu.lst. However, this boot config is not kept up-to-date with newer ubuntu's because they use grub2 (which uses grub.cfg and not menu.lst). And Xen's pygrub first looks at menu.lst, so if you have a stale file, it will always boot an old kernel. Read More »

CUPS printer driver for my HP4050

My HP4050 has a million different drivers to choose from. Some don't have the maximum DPI, some don't have other options, like selecting paper output. The one that works the best seems to be "HP LaserJet 4050 Series Postscript (recommended) (grayscale, 2-sided printing)". However, I have no idea anymore if that came from hplip, foomatic, gutenprint, or whatever. Read More »

Converting a MySQL database from latin1 to utf8

mysqldump dbname > dbname_bak_before_messing_with_it.sql mysqldump --default-character-set=latin1 --skip-set-charset dbname > dump.sql sed -r 's/latin1/utf8/g' dump.sql > dump_utf.sql mysql --execute="DROP DATABASE dbname; CREATE DATABASE dbname CHARACTER SET utf8 COLLATE utf8_general_ci;" mysql --default-character-set=utf8 dbname < dump_utf.sql Read More »

Setting up a postfix fallback MX

These are some short stepts and pointers to setup a postfix fallback MX. It does not describe postfix basics, nor how to install Mailscanner (a necessisity, because spammers like sending spam to fallback MX's because they're usually not as well protected). Read More »

Postfix queue: sender and recipient address

I always seem to forget this, and the mailq command is not clear, so here it is: when you type mailq on a postfix server, the first address listed is the sender, the second the recipient. Read More »

Adding SPF support to Postfix

(Hmm, this suggests the python version might be better). Read More »

Tracking Xen domU’s with munin

To view statistics of your xen server with Munin (source): Read More »

Getting a better MySQL prompt

When you want to see which user you are and which database you're working with, put this in .my.cnf: prompt=(\\u@\\h) [\\d]>\\_ Read More »