Tuesday, November 8, 2011

Lotus Notes fixpack in .deb traditionally produces this error:
dpkg -i ibm_lotus_notes_fixpack-8.5.2.i586.deb
dpkg: error processing ibm_lotus_notes_fixpack-8.5.2.i586.deb (--install):
 parsing file '/var/lib/dpkg/tmp.ci/control' near line 2 package 'ibm-lotus-notes-fixpack':
 error in Version string '8.5.2-20110323.0837_FP2': invalid character in revision number
To circumvent this error, unpack the .deb archive with:
  1. dpkg-deb --extract which extracts the files in the package.
  2. dpkg-deb --control which extracts the meta-data.
Edit this metadata (/DEBIAN/controls) and remove the underscore from "_FP2". Then, rebuild the package with  dpkg --build .


Monday, November 7, 2011

Encrypted Ubuntu filesystem on a logical volume (without alternate install)

Ubuntu with LVM and an encrypted filesystem does not require the Alternative installation media. It can be done via the official one.

My setup is what is usually called full-encryption (although I would not call it full, because the /boot partition is not encrypted and thus it can be backdoored by someone who has physical access to the machine). The root filesystem is located on a logical volume and encrypted (unlike in other setups and how-tos where the whole LVM is encrypted). The boot partition is on the /dev/sda3 partition; it can boot other systems where I do not want to install LVM support.

If a newly installed system does not boot after a reboot and drops out into a busybox shell, it can be because the initramfs is unable to find root partition to mount and boot the rest of the system. This is what I have done to finalize the installation:

1. Boot another system (e.g. Ubuntu from the installation media)

2. Open the new (encrypted) target Ubuntu root filesystem
(cryptsetup luksOpen /dev/vg/new cryptroot)
Of course you have not given your volume group a name like "vg" and your logical volume the name "new". (If yes... Do you like that all volume groups on your and your friend's USB drives have the same name "vg"? And do you want to have a logical volume that is old for many years but it is called "new", because you do not want to rename it?)

3. Mount it
(mount /dev/mapper/cryptroot /mnt)
4. Mount the /boot partition.
(mount /dev/sda3 /mnt/boot)
 Change the device number accordingly. This is the unencrypted boot partition. Kernel image and initramfs (initrd) boot files are located here.

5. Chroot to it
(chroot /mnt)
6. Install LVM and cryptsetup
(apt-get install lvm2 cryptsetup)
Once you install these packages, they will update the initramfs automagically. That is why it is important to have the boot partition mounted.

7. Edit the file /etc/default/grub and add kernel command line options

(GRUB_CMDLINE_LINUX="root=/dev/mapper/cryptroot cryptopts=source=/dev/vg/new")

so that after propagating the changes (update-grub) the generated grub configuration file (/mnt/boot/grub.cfg) has the line

(linux..... root=/dev/mapper/cryptroot cryptopts=source=/dev/vg/new)

You can omit the first option if root= option gets added automatically. You could omit the latter one (until 12/2011 in Ubuntu 11.10), but if the boot drops you to a" busybox initramfs shell" with an error that it cannot find /dev/mapper/cryptroot, this might be the useful.

8. Edit /etc/fstab

(/dev/mapper/cryptroot  /      ext3    errors=remount-ro 0       1)
9. Enjoy!

You can comment and ask, maybe I forgot some steps that were also needed. Consider also encrypting swap.

Monday, June 20, 2011

Skype does not ring in Ubuntu

Skype does not ring... More precisely, all events that display notifications fail to play sounds, but the others work fine (e.g. testing the event of "Ringing out" plays the sound).

Solution: System -> Preferences -> Sound

Pull up the Alert volume like above.

Thanks goes to http://ubuntuforums.org/showpost.php?p=10084372&postcount=4

Tuesday, May 31, 2011

OpenVAS says 'login failed'

This solution was found at


"openvas-adduser" probably created the user directory in a different location (e.g. /usr/local/var/lib/openvas/) than the server is looking for it. It needs to moved to /var/lib/openvas.

Saturday, April 16, 2011

VirtualBox: Could not find an open hard disk with UUID

My VirtualBox sometimes shows a dialog box that says:

"One or more virtual hard disks, CD/DVD or floppy media are not currently accessible."

My virtual machine becomes inaccessible. Details show this error:

Could not find an open hard disk with UUID {5bad2863-64d0-40a2-a394-7442e3a6adc7}.
Result Code: VBOX_E_OBJECT_NOT_FOUND (0x80BB0001)

This happens when a snapshot is removed, then another snapshot is made and the host computer crashes (e.g. freezes during hibernation). After this, there is a reference to a non-existing HardDisk in the configuration file "~/.VirtualBox/VirtualBox.xml". This needs to be updated with the real value. The last working situation can be found in the log file (e.g. "~/.VirtualBox/Machines/<...>/Logs/VBox.log")

00:00:01.330 [/Devices/piix3ide/0/LUN#0/AttachedDriver/Config/] (level 6)
00:00:01.330   Format   = "VDI" (cb=4)
00:00:01.330   Path     = "/data/vmware/winvm/{5bad2863-64d0-40a2-a394-7442e3a6adc7}.vdi" (cb=62)
00:00:01.330   Type     = "HardDisk" (cb=9)
00:00:01.330 [/Devices/piix3ide/0/LUN#0/AttachedDriver/Config/Parent/] (level 7)
00:00:01.330   Format   = "VDI" (cb=4)
00:00:01.330   Path     = "/data/vmware/winvm/{cd71486f-ab71-4b03-9e2e-690d7ef76b9d}.vdi" (cb=62)
00:00:01.330 [/Devices/piix3ide/0/LUN#0/AttachedDriver/Config/Parent/Parent/] (level 8)
00:00:01.330   Format   = "VDI" (cb=4)
00:00:01.330   Path     = "/data/vmware/winvm/Windows XP flexible disk.vdi" (cb=48)

This shows reliably the structure (the snapshot and its parents are listed), so it can be reconstructed by editing the XML file accordingly.

Tuesday, January 18, 2011

asm/io.h: No such file or directory

The issue is caused by an include:

#include "asm/io.h"

Solution: Make a symlink asm -> asm-i386

Thursday, January 6, 2011

Fwd: firewire_core: Unsolicited response (external HDD drive & firewire)

MyBook connected through FireWire gets offline or has problems immediately after connecting: