COMMENTS ON INSTALLING RED HAT FROM A FAT-32 PARTITION

FAT-32 installation has changed substantially from Red Hat 5.1 to Red Hat 5.2, doing a complete bug replacement in the process. Red Hat 5.0 installers should read the section on Red Hat 5.0 issues and follow the 5.1-related section, below.


Red Hat 5.1

Fortunately, there's not a lot to add about installing Red Hat 5.1 from FAT-32. The main thing you must do is to change the partition type of the FAT-32 partition on which your Red Hat installation files reside to that of a FAT type other than FAT-32, such as 06 ("DOS 16-bit >=32M"). On my test installation with FAT-32, the FAT-32 partition was of type 0b, and Red Hat's installation routines refused to let me point to such a partition for the source files. Fortunately, the actual FAT-32 code doesn't rely upon the partition type matching the contents of the partition, so this isn't a problem for Linux; however, I strongly recommend that you return the partition type to its original value after installation! If you fail to do this, DOS, Windows, or other OSes might become confused and trash the partition (or at least fail to boot)! Unfortunately, using type 83 (Linux native) doesn't work; you must use a FAT partition type.

So how do you do this? During the Red Hat installation, you'll be asked if you wish to partition your disk with Disk Druid or Linux's fdisk. Choose the latter. This will start up fdisk, which has a relatively klunky interface. Type "p" and hit < Enter > to see the partitions that are defined on your disk. Change the FAT-32 partition type to 06 by selecting the "t" option. You'll be asked for a partition number and a partition type. The type, as mentioned above, should be 06. If you need to create partition(s) for Linux (you probably do, though you might have done this with a tool such as PowerQuest's Partition Magic), you should do that here, too. If you've created Linux partitions in another utility, you should change their types to type 83 ("Linux native") or type 82 ("Linux swap"), as appropriate. When you've done all this, hit "w" and then < Enter > to exit. The install program may insist on re-booting. When you're done installing Linux, type "fdisk" when you're logged in as root and reverse the process, changing the partition type of the FAT-32 partition back to what it had been (probably 0b, but possibly 0c or something else, as Microsoft has been proliferating their partition types lately).

Red Hat 5.2

Red Hat 5.2 fixes the bug about not recognizing FAT-32 partitions as valid installation media, but adds new bugs relating to filename handling. So if you're installing Red Hat 5.2, you can ignore the above comments, but you must pay attention to this:

Prior to version 5.2, Red Hat installed from FAT partitions by mounting them as type "msdos," which means that only DOS-style "8.3" filenames were available. The install routines took this into account by relaxing the restrictions on filenames that are detailed in Pitfalls #2 and #3 of the basic instructions section. With version 5.2, however, the Red Hat installer mounts the source partition as type "vfat," which means full long filenames are available. The problem with this is that filenames that Windows treats as being entirely uppercase, Linux treats as being entirely lowercase. As Linux is case-sensitive in its filename handling, this causes problems for one highly important directory name: RPMS. The result is that, if you downloaded the Linux directory tree in Windows, Red Hat will complain that it can't open a directory after you've told it where to look for the install files.

If you have Linux installed and merely want to upgrade, the simplest fix is to boot your existing Linux setup and change the filename from there. Look for the rpms directory in the RedHat directory, and use the "mv" command to change it to some intermediate value, then change that intermediate value to "RPMS". (You can't change the filename directly because, although Linux is case-sensitive, FAT is not.) Note that if you downloaded the Red Hat install files from Linux, the RPMS directory is likely to have the correct case already.

If you don't have Linux installed already, you can do the same thing from the Red Hat installation procedure. Here's how:

  1. Download the mv program. This is the Linux equivalent of the DOS RENAME and MOVE commands, rolled into one. The link above is to a zipped version of the program; unzip it with PKZip, InfoZip, or whatever, and put it on the same partition as the rest of your Linux install files. The following assumes it's in the RedHat directory, where the RPMS directory also resides.
  2. Start the install and make note of the Linux device associated with the install partition (e.g., "/dev/hda1" or "/dev/sdb5" or something similar).
  3. Continue with the install and wait until you get the "error opening directory" message. With the error message still on screen, do the following:
  4. Hit < Alt-F2 > to get to a Linux command prompt.
  5. Type "ls /tmp/hdimage"; this should produce a listing of the files on your FAT installation partition. If there are no files listed, something else is wrong, or perhaps you need to try this at some other point in the error process.
  6. Type "umount /tmp/hdimage" to un-mount the partition.
  7. Type "mount -t vfat {devicename} /tmp/hdimage" to re-mount the partition. "{devicename}" should be the device name you noted above, such as /dev/hda1 or /dev/sdb5. These two steps are necessary because the partition was mounted read-only before now, but we need read/write access to change the rpms directory name.
  8. Type "cd /tmp/hdimage/RedHat" (if RedHat is in the root of that partition; you may need to add directories here if it's located more deeply on your hard disk).
  9. Type "ls" to be sure you're in the correct directory; you should see the rpms directory and the mv file, among others.
  10. Type "./mv rpms fred" ("fred" could be anything; it's an arbitrary temporary filename).
  11. Type "./mv fred RPMS". Again, case is significant; that's why we must change this.
  12. Type "cd /"
  13. Type "umount /tmp/hdimage"
  14. Hit < Alt-F1 > to return to the main Red Hat install screen.
  15. Hit the "OK" button and tell it you want to re-try the operation. It should now continue correctly.

One hopeful note: The bug that necessitates this workaround can almost certainly be fixed by modifying the Red Hat install floppies. It's possible that Red Hat will have fixed it by the time you read this, so you might want to check the errata section of their web site for mention of updated install floppy images.

Additional Comments

If you need to re-partition your system so that you can have both Linux and Win95 on it, you may want to check out a couple of programs, both of which can shrink a FAT-32 partition to make room for Linux (or any other OS). The first is the freeware FIPS program. Be sure to get a recent version (which should come with Red Hat 5.2, and at least some versions of 5.1); older versions don't handle FAT-32. The other option is the commercial program Partition Magic, from PowerQuest, which can both shrink and grow FAT-16, FAT-32, OS/2 HPFS, WinNT NTFS, and (with version 4.0) Linux ext2 and swap partitions, as well as converting from some of these formats to some others and installing a Boot Manager program for selecting between multiple OSes. Version 3.0 users can download relatively crude Linux native tools for handling ext2 filesystems from PowerQuest's web site. IMHO, Partition Magic is well worth getting if you do any re-partitioning more than once or twice a year. Other commercial and freeware utilities exist for re-sizing and moving FAT partitions, but Partition Magic's ext2 support makes it the clear favorite for Linux users.


Copyright © 1997, 1998 Rod Smith, rodsmith@rodsbooks.com
Return to the Red Hat Joliet installation page