Notation: I use '----' to mark the beginning and end of
bits of text that go in files.
Installation
Linux distributions are available from
many sources.
For Fedora Core 2 it is most convenient to get it on a single DVD.
I was installing FC2 because my T23 hard drive had failed, so it was
a clean install, onto a brand-new empty hard drive.
I wanted to have a FAT32 partition at the start of the disk, for the
hibernation file, and for a possible future re-install of Windows.
However, I had problems with Disk Druid: it kept moving my FAT32 partition
to other places on the disk. In the end, I used parted
to create the FAT32 and the root ext3 partitions,
then started the FC2 install process and
used Disk Druid to make the remaining partitions.
The procedure was:
- Boot off a parted 2-floppy set. Create the FAT32
primary partition and the linux root (/) partition. I had an old set of
parted floppies, so it could not make an ext3 filesystem. I used
mkpartfs to make the FAT32, and mkpart to make the linux root partition:
> mkpartfs primary fat32 0 5000 # for Windows
> mkpart extended 5000 38154.375 # 38154.375 was the end of my disk
> mkpart logical 5000 17000 # root (/)
> mkpart logical 17000 21000 # /home
> mkpart logical 21000 29000 # /usr/local
I made the remaining Linux partitions at install time with Disk Druid.
- Boot off the
IBM Hibernation utility diskette.
Select the "make file" option. It created a hibernation file on the
FAT32 partition.
- Boot off the Fedora Core 2 DVD. Follow the usual installation procedure.
A few small points:
- There was a warning message about the disk geometry: I ignored it.
- The monitor is Generic LCD, 1024x768
- It is a good idea to have separate /home
and /usr/local partitions,
so in the future you can re-install a new version of the operating system,
without trashing your home directory, or
any non-RPM software that you installed. I also have a /storage
partition for large data sets.
- No need to worry about cylinder 1024 limitations for linux, we will use
GRUB which is above such things. So no separate /boot partition
is needed.
- System clock should be on UTC, to allow automatic
implementation of daylight saving time.
Fine tuning
- I set up my /etc/fstab as follows. This allows anyone to write
files on the FAT32 partition /win, and allows anyone to
mount /mnt/cdrom and /mnt/floppy
and anyone to unmount them again.
----
LABEL=/ / ext3 defaults 1 1
none /dev/pts devpts gid=5,mode=620 0 0
/dev/hda1 /win msdos users,uid=99,gid=99,umask=000 0 0
LABEL=/home /home ext3 defaults 1 2
none /proc proc defaults 0 0
none /dev/shm tmpfs defaults 0 0
LABEL=/storage /storage ext3 defaults 1 2
LABEL=/usr/local /usr/local ext3 defaults 1 2
/dev/hda9 swap swap defaults 0 0
/dev/hdc /mnt/cdrom iso9660 noauto,users,kudzu,ro 0 0
/dev/fd0 /mnt/floppy auto noauto,users 0 0
----
To stop the fstab from being overwritten by system utilities that think
they know what I need better than I do,
> chkconfig kudzu off
- Some extras (RPM packages or tarballs) that I like:
- xfig is still my
favorite diagramming program. Luckily the
xfig and transfig packages are part of FC2.
- The fvwm window manager.
(Needs the libstroke package too.) Fvwm is simple,
it starts up instantaneously
and you can configure any keystrokes and mouse clicks you like.
I use asapm as a battery monitor: you have to install the
rpm file with --nodeps under FC2.
- Secure delete.
Good for deleting old versions of files where you keep
sensitive info (e.g. all those passwords for web sites).
- Acroread, downloadable from Adobe.
The best way to view PDF files if you want to see all the hyperlinks and other
special features. (Otherwise use gv, which deals with PDF
as well as PostScript).
- ElectricFence-2.2.2-16, also part of FC2,
is great for finding memory mismanagement bugs in C++.
- If you want to install tarballs in /usr/local, you
should add /usr/local/lib to the library load path, since
some of them may install their libraries in /usr/local/lib.
Create file local.conf in /etc/ld.so.conf.d, containing
----
/usr/local/lib
----
(note that this is automatically included by /etc/ld.so.conf)
Windows 2000
I left a 5G FAT32 partition for Windows on the hard drive. Here is
the installation procedure:
- Ensure that we will be able to recreate the grub master boot record.
Make a grub floppy:
> grub-install '(fd0)'
Check that you can boot Linux from it.
- Boot off the Win2k CD-ROM.
It identifies hda1 as the only DOS/Win partition, as we hoped,
and labels it "C". Allow Win2k to format drive C: as FAT32.
If you don't there are weird errors on the first reboot: "NTLDR not found".
- When the system finally reboots with Win2k installed,
it goes straight to Win2k: it has obliterated GRUB from the
hda master boot record. Now we must restore it.
Boot linux from the grub floppy.
Edit /etc/grub/grub.conf to boot Linux or Win2k.
Here is an example, which
assumes Linux is on hda5, ie (hd0,4),
and Win2k is on hda1, ie (hd0,0):
----
default=0
timeout=10
splashimage=(hd0,4)/boot/grub/splash.xpm.gz
title Fedora Core (2.6.5-1.358)
root (hd0,4)
kernel /boot/vmlinuz-2.6.5-1.358 ro root=LABEL=/ rhgb quiet acpi=off
initrd /boot/initrd-2.6.5-1.358.img
title Windows2000
rootnoverify (hd0,0)
chainloader +1
----
Recreate the MBR on the hard drive:
> grub-install /dev/hda.
Re-make the grub install floppy:
> grub-install '(fd0)'
You should now be able to boot Linux or Win2k from the hard drive, or
from the floppy.
To my surprise, Win2k failed to detect the onboard ethernet card.
There was no LAN icon in the "Dialup and network connections" folder.
I had to download a driver (after rebooting to Linux to
get an internet connection!) from
this IBM website.
Then the ethernet card worked, and I could connect to the internet under Win2k.
The driver is 26MB, so I am not sure how someone with only Win2k could get it.
Power management and hibernation
Neither suspend nor hibernate works
out of the box under Fedora Core 2.0. You must turn off acpi and
revert to apm:
In /boot/grub/grub.conf, add "acpi=off" to the "kernel" line:
----
kernel /boot/vmlinuz-2.6.5-1.358 ro root=LABEL=/ rhgb quiet acpi=off
----
Even then, it only works if there is a hibernation file on a FAT16
or FAT32 primary partition. I make this the first partition on the
drive: I don't know whether this is an absolute requirement. If you have an
appropriate partition (eg the Win2k FAT32 partition described
above) then it is easy to create a hibernation file:
- Create the "IBM hibernation utility diskette II". To do this,
download the self-unpacking file stndalhd.exe
from
this IBM website.
[If you have trouble downloading it,
here is the version I used, but it may not
be the most recent version.]
- Run the executable under windows on any machine,
and let it create the utility diskette.
- Boot off this floppy, and select the "make file" option.
It creates a hibernation file on the
FAT partition. Hibernation should then work.
Keeping packages up to date
I use yum. With FC2 it is properly configured on installation.
Just type yum update and you are in business. For more info
see
this excellent Linux Gazette guide
Networking: DHCP
I have not yet managed to get system-config-network to work.
I set up the devices under different profiles, but DHCP won't work
when invoked from the ifcfg-ethX files created by
system-config-network.
To configure networking by hand, just edit
/etc/sysconfig/network-scripts/ifcfg-eth0. Eg:
----
DEVICE=eth0
USERCTL=yes
ONBOOT=no
BOOTPROTO=dhcp # For static addresses, leave out this line
IPADDR=123.456.789.10 # leave blank for DHCP
NETMASK=255.255.255.0 # leave blank for DHCP
GATEWAY=123.456.789.254 # leave blank for DHCP
DNS1=123.456.789.1 # leave out this line for DHCP
DNS2=123.456.789.4 # leave out this line for DHCP
----
Then the command ifup eth0 will start the
connection and ifdown eth0 will stop it.
Dell Truemobile 1150 wireless PCMCIA card
This card works out of the box.
Configuring a wireless connection by hand is also easy. You create
/etc/sysconfig/network-scripts/ifcfg-eth1:
----
DEVICE=eth1
USERCTL=yes
ONBOOT=no
BOOTPROTO=dhcp
NETMASK=
IPADDR=
BROADCAST=
NETWORK=
TYPE=Wireless
DHCP_HOSTNAME=
ESSID= # supply ESSID here if you know it
CHANNEL=6
MODE=Auto
RATE=Auto
----
If you have a WEP-encrypted wireless network, put the key in
/etc/sysconfig/network-scripts/keys-eth1:
----
KEY=12345F678
----
Then the command ifup eth1 will start the
wireless connection and ifdown eth1 will stop it.
Sound
Sound worked immediately on installation, however it always stopped working
after hibernation. This is fixed by reloading the sound module on resume.
In principle this should be accomplished by setting
RESTORESOUND="yes" in etc/sysconfig/apmd, but
this does not work, because of miscoding
in etc/sysconfig/apm-scripts/apmscript.
So we are forced to
do it manually. Create an executable script
/etc/sysconfig/apm-scripts/apmcontinue:
----
#!/bin/sh
# script to ensure that sound module is reloaded on resume.
# apmscript doesn't do this correctly.
case "$1" in
suspend) ;;
resume)
modprobe -r snd-intel8x0; modprobe snd-intel8x0 ;;
esac
----
Pine
Fedora Core 2 does not include the pine email program. This is
unfortunate. I followed the same procedure as under
FC1, downloading the rpm file from
this FTP URL.