Using autofs to mount your install CDs

Thursday, June 3rd, 2004

Prompted by Kyle’s presentation at NBLUG on autofs; I decided to try my hand at it.

I figured the perfect task for autofs would be to automatically mount my install CDs when I needed them. For instance, when I want to install software; instead of physically loading the CD into the drive I can just hit “install” and magically have the software loaded and installed.

In a previous entry I showed how easy it was to store your install CDs as ISOs on your hard drive. From there all you need to do is edit a few configuration files to get autofs working for you.

First is /etc/auto.master which is the main configuration file for autofs. I altered the file so that there was only a single non-commented line:

/mnt/iso /etc/auto.iso –timeout=60 .

Now to create the file /etc/auto.iso, which I wrote to look like this:

mdkinstall_1 -fstype=iso9660,ro,loop :/iso/Mandrake-10.0-install_1.iso
mdkinstall_2 -fstype=iso9660,ro,loop :/iso/Mandrake-10.0-install_2.iso
mdkinstall_3 -fstype=iso9660,ro,loop :/iso/Mandrake-10.0-install_3.iso

Now whenever you try to navigate to either /mnt/iso/mdkinstall_1 , /mnt/iso/mdkinstall_2 , or /mnt/iso/mdkinstall_3 the images are automatically mounted for you and you can easily browse them.

In order to make this new magic usable by my software installation tool I updated my software sources to point to file://mnt/iso/mdkinstall_1/Mandrake/RPMS/ , file://mnt/iso/mdkinstall_2/Mandrake/RPMS2/ , and file://mnt/iso/mdkinstall_3/Mandrake/RPMS3 for “Installation CD 1″, “installation CD 2″, and “Installation CD 3″ respectively.

Now when I want to install software from the installation CDs I just fire up my install tool, select the software I want and go; no wasting time loading CDs into the tray, or even taking the time to mount the images anymore. Life is good.

Fixing the “Bad Signature” RPM error in Mandrake

Tuesday, June 1st, 2004

I installed my newly downloaded and burned Mandrake 10.0 CDs at work today, and I wanted to update my software to get all the security updates and bug fixes. However when I tried to install the updated software I received the error that the packages I was trying to install had bad signatures.

Package signatures are a way for the users to verify that the software they are about to install has not been changed since the original developers released it. A bad signature on a package can be caused by the package being corrupted, the package being compromised by some evil doer, but the most common reason is that you don’t have the public key required to verify the package signature. In my case I had the wrong keys.

You can see what keys you have available via the command line with:

rpm -qa gpg-pubkey .

The key can be displayed on the command line with:

rpm -qi gpg-pubkey-XXXXXXXX .

Where XXXXXXXX is the key-id.

I found that these keys differed from the ones in /etc/RPM-GPG-KEYS/

After removing the old keys:

rpm -e rpm -e gpg-pubkey-22458a98-3969e7de … .

I imported the new keys:

rpm –import /etc/RPM-GPG-KEYS/*.asc .

And all was well. Now I can install packages from Mandrake and not have to worry about the dreaded bad signatures error.

* Sources: This link helped me get going.

Vmware and the Linux 2.6 Kernel

Thursday, January 8th, 2004

Here is a great how-to for getting vmware working with the 2.6 Linux kernel:

http://kerneltrap.org/node/view/1804

One note though; there seem to be more up to date patches available at:

ftp://platan.vc.cvut.cz/pub/vmware/

This worked for me with VMware version 4.

Storing your install CDs as ISOs on your hard drive.

Wednesday, December 31st, 2003

I was tired of burning copies of Linux distribution CDs only to throw them away when the next revision came around. With copies for home, and copies for work it gets to be pretty wasteful. So I decided to take my latest Mandrake 9.2 CDs and create ISO images from them which I could then store on my hard drive. Once the ISO image is on your hard drive you can mount it like any other file system and use it.
(more…)

Update NVIDIA Drivers on Mandrake 9.1 and 9.2

Tuesday, August 12th, 2003

I updated the kernel on the Mandrake 9.1 workstation at work today, and then I realized I also had to update the NVIDIA drivers to have a display. :P However finding updated NVIDIA packages for Mandrake, and figuring out the correct way to install and configure them took a bit of googling, so I figured I would archive what I did here to help others, and possibly my future self if I have to do it again (and when I forget how to do it…).

  1. Surf to: http://www.ibiblio.org/pub/Linux/distributions/contrib/texstar/mandrake/9.1/rpms/
    and download: NVIDIA_GLX-2.4.21.0.25.2tex-4496.i586.rpm and NVIDIA_kernel-2.4.21.0.25.2tex-4496.i586.rpm
  2. Install NVIDIA_kernel and then NVIDIA_GLX. NVIDIA_GLX gave me some conflicts, but a little –force fixed that right up.
  3. Edit /etc/modules: comment out the “NVdriver” line, and add a line that says “nvidia”. This will cause the NVIDIA driver to load on boot; which is a good thing.

That is all.

UPDATE: 2003-12-31.
I just did this on the new Mandrake 9.2 kernel upgrade that I upgraded and the above links don’t work. I’ll keep them just for historical reference. The way that worked for me with 9.2 was the following:

You’ll need the kernel source for the kernel you want to build the nvidia module for.

Surf to ftp://download.nvidia.com/XFree86/Linux-x86/1.0-4496/
(or which ever version it is you want).

Download NVIDIA-Linux-x86-1.0-4496-pkg2.run or the largest pkg#

Reboot to new kernel.

Exit out of X (if needed) run the *.pkg#.run as root.
This will build the nvidia driver for you using the kernel headers from your running kernel source, and install it in:
/lib/modules/[kernel_version]/kernel/drivers/video/nvidia.o

You’ll still need the nvidia line in /etc/modules to have the driver loaded on start up.

BONUS LINK:
A great How-To for doing this with the 2.6 kernel can be found here:
http://kerneltrap.org/node/view/1804 .
The only things extra that I had to do to get it to work with the pre-compiled 2.6 kernel binaries from Mandrake were:

Use this command to extract the tar-ball from minion.de :

tar xjvf NVIDIA-Linux-x86-1.0-4496-pkg#.tar.bz2.gz

And set an environment variable before running nvidia-installer :

export IGNORE_CC_MISMATCH=1

urpmi

Friday, July 18th, 2003

A brief how-to for using the urpmi utility to update your linux servers/workstations much more easily.

(more…)