Archive for the ‘Linux’ Category

More VMWare problems in Fedora

Oh another Kernel update another VMWare problem, great. When you upgrade to 2.6.19, you get the following error
/tmp/vmware-config2/vmnet-only/userif.c: In function ‘VNetCopyDatagramToUser’:
/tmp/vmware-config2/vmnet-only/userif.c:629: error: ‘CHECKSUM_HW’ undeclared (first use in this function)
/tmp/vmware-config2/vmnet-only/userif.c:629: error: (Each undeclared identifier is reported only once
/tmp/vmware-config2/vmnet-only/userif.c:629: error: for each function it appears in.)
make[2]: *** [/tmp/vmware-config2/vmnet-only/userif.o] Error 1
make[1]: *** [_module_/tmp/vmware-config2/vmnet-only] Error 2
make[1]: Leaving directory `/usr/src/kernels/2.6.19-1.2895.fc6-i686'
make: *** [vmnet.ko] Error 2
make: Leaving directory `/tmp/vmware-config2/vmnet-only'
Unable to build the vmnet module.
After a bit of hunting on LWN, I found that CHECKSUM_HW has been remove from 2.6.19 and replaced with CHECKSUM_PARTIAL. Fortunately, Robin Kearney at usefulthings.org.uk has provided a patch.

It’s a little more complicated than the usual fixes, at the patched files are within a tarball, but you should be able to cut and paste from below.

As root:

cd /tmp
wget http://usefulthings.org.uk/wp-content/uploads/vmnet-only-2.6.19.patch
cd /usr/lib/vmware/modules/source/
cp vmnet.tar vmnet.tar.orig
tar xf vmnet.tar
patch -p0 < /tmp/vmnet-only-2.6.19.patch
tar cf vmnet.tar vmnet-only
vmware-config.pl -d

Flash player finally out of beta!

Flash playerWahoo! Flash player 9 for Linux is finally out of beta.

There’s even a nice RPM version. So ignore my previous instructions and go install now!

Switching off the internal speaker in FC6

Fedora Core 6 enables the internal crappy speaker by default. I don’t like this, it makes my sexy machine sound old and cheap. To disable it run the following as root:

modprobe -r pcspkr ; echo "install pcspkr :" >>/etc/modprobe.conf

FC6 choses i585 rather than i686

You might remember I had a bit of a nightmare getting vmware to work on a dual core Intel. In the end it turned out that Fedora had chosen the wrong kernel arch (i586 rather than i686). This morning I was having a poke around the FC6 Common bug list (http://fedoraproject.org/wiki/Bugs/FC6Common) and found the problem. Apparently it’s bug in Anaconda, the Fedora installer. Here’s what they say:

Anaconda installing the wrong architecture kernel in some systems. cpuspeed is not working for the same reason. This does not affect out of box functionality much but if you are compiling third party kernel drivers you might run into this on x86 architecture. x86_64 and PPC systems are not affected. https://bugzilla.redhat.com/bugzilla/show_bug.cgi?id=211941. You can bypass this bug in a new installation by specifying “linux i686″ in the installation boot prompt.

An updates.img is available for this issue http://people.redhat.com/pnasrat/211941-updates.img. Please follow the instructions here: Anaconda/Updates.

To check which kernel package architectures are currently installed:

rpm -qa --queryformat "%{NAME}-%{VERSION}-%{RELEASE}.%{ARCH}\n"|grep kernel|sortIf the installed kernel architecture is i586, but your machine is i686 capable (Pentium II or K6II or higher), use the following simple workaround:

  1. Install yumdownloader. yumdownloader is part of yum-utils in Fedora Extras. You can also manually download the kernel.su -c "yum install yum-utils"
  2. Get the current i686 kernel:yumdownloader kernel.i686
  3. If the version of the kernel downloaded is larger than currently installed:su -c "rpm -ivh kernel-2*.i686.rpm"
    • Alternatively, if the version of the kernel downloaded is the same as that currently installed:su -c "rpm -ivh --replacefiles --replacepkgs kernel-2*.i686.rpm"
  4. Restart the machine.reboot

Creating shadows with Imagemagick

I needed to create drop shadows on around 200 images. I didn’t really like the idea of doing it with Gimp as that would have taken hours! It is really simple to do it using Imagemagick

convert
\( +clone -background black -shadow 80x3+5+5 \) +swap -background white -mosaic

I needed to convert a whole directory, so it’s just a simple case of wrapping it around a loop

for a in *.jpg
do
echo $a
convert "$a" \( +clone -background black -shadow 80x3+5+5 \) +swap -background white -mosaic "shadows/$a"
done

Return top