Fix for bad write performance with LUKS + RAID5

After setting up a new fileserver with an LUKS encrypted dataset on top of Linux software RAID5 I did some benchmarks and reliability testing before filling it up with “real” data… but it turns out write performance was quite horrible. Only a fraction of what the “raw” RAID5 could do, all while having the CPU mostly idle. So what’s going on?

Apparently only small blocks of data get written to the disks when using LUKS encrypted volumes (mostly default settings) therefore dramatically reducing write performance (figured it out thanks to this) on my RAID 5 volume. Setting the stripe_cache_size from 256 to 8192 increased throughput from roughly 50-70 MB/sec to well above 200 MB/sec.

To permanently set it, so you don’t have to manually adjust it after every reboot, consider setting up a udev rule like this:

CUPS and Canon Pixma: Printer hangs after first page

After updating my Ubuntu desktop to a more recent release (12.04 / Precise Pangolin), my rarely used Canon Pixma MP190 stopped working. Not completely, but in a rather annoying way: Printing a single page works fine, but printing multiple pages / copies causes the printer to hang. Hard. As in, you have to pull the power plug to reset it, as no button will do anything anymore.

Apparently there was a bug introduced with CUPS a while ago, or rather a change in behavior of CUPS which triggers a bug in the printer Firmware. Took me a couple hours to find and had me on the brink of throwing out the whole printer.

And it looks like it affects quite a few other USB printers as well:  Epson NX130, Canon i550, i560, ip4200, ip4300, ip5200, MP180, MP160, MP210, MP450, MP500, MP520, …

To save you from reading through all the comments: Till Kamppeter came up with a workaround that worked perfectly for me and others.

 

After that I was able to print a couple hundred envelopes without a hitch.

 

Fallout New Vegas, Honest Hearts: No more sound using wine-1.3

After installing the Honest Hearts DLC for Fallout New Vegas, all of the sudden the in-game sound stops working the second I load a savegame. Running FalloutNV.exe from the console, I get tons of these as soon as the game goes mute:

As a quick workaround, go into your Wine configuration, create a custom application setting for Fallout if you haven’t already, click the Libraries tab and add an override for quartz.

Native then Builtin did the trick for me.

HP ProLiant management tools for Ubuntu / Debian based server

So you just got yourself a brand new and shiny HP ProLiant server to play with, installed your favorite distribution and life is good. Except… unless your distribution of choice is RHEL or SuSE, there’s no way to monitor or even configure all those nice little gadgets that made you go with a ProLiant server instead of some random white box server.

If you go to the HP support site to download drivers and software, usually all you get is a choice between various versions of Windows, NetWare (anyone still using that?), Solaris, VMware ESX and for Linux: RHEL and SuSE. Sure, you can convert the RPM packages to deb using alien, but it’s kind of a PITA and doesn’t necessarily work reliably. Wouldn’t it be much nicer if there were packages for Ubuntu or Debian?

Guess what? There are packages for Debian based systems. There’s even a repository containing all the versions and architectures you need. But for some reason unbeknown to man, HP decided not to put it in there with the other OSes, but hide it instead.

Just add this to your APT sources (/etc/apt/sources.list or equivalent):

(nothing for Maverick yet, but the packages for Lucid worked just fine for me)

Then run apt-get update and install any of the packages you might need:

Say you want to monitor your servers temperatures using Monitorix or check your fan-status and PSU redudancy:

Or take a look at your internal cciss RAID configuration, see if all disks are still in working condition or change your array setup without having to reboot your server to do it at the BIOS level:

Change your iLO parameters or reboot the management processor if it got stuck for some reason?

Way better than having to unwrap the documentation packages and pop in a CD or having to find and download a RPM, upload it to your server, convert it with alien and hope it kinda works, isn’t it?

Getting Fallout New Vegas to work with Wine

If you can’t wait to play the newest iteration of Fallout, yet don’t want to boot Windows to do it – with a little effort you can get it running under Wine as well.

It doesn’t seem to work out of the box, even with a very recent release (Failed to initialize renderer. Unknown error creating the GamebryoRenderer.)

But if you don’t mind adding a little patch and compiling Wine yourself, you should be able to get Fallout New Vegas up and running in no time.

WineHQ Bug 24831 describes the problem and someone else came up with a fix just a few hours later. But if you’re running Ubuntu 10.10, sadly the patch doesn’t apply right away. To manually fix it, just get the Wine source package and edit the file ‘dlls/d3d9/directx.c’, go to line 477, remove or comment out this part

*device = NULL;

return D3DERR_DRIVERINTERNALERROR;

and substitute it with this:

return IDirect3D9Ex_CreateDevice(iface, adapter, device_type, focus_window, flags, parameters, (void *)device);

Save the file and run ‘dpkg-buildpackage’ and when finished, install the resulting .deb.

(Or just download my modified directx,c and save it to wine1.2-1.2.1/dlls/d3d9/directx.c before compiling)

That’s it. Enjoy your stay in New Vegas. :)