(M)  s i s t e m a   o p e r a c i o n a l   m a g n u x   l i n u x ~/ · documentação · suporte · sobre

  Next Previous Contents

4. Red Hat 4.2 installation

With anything computer related, something 3 months old is considered obsolete and is in need of upgrading. Since I'm not always going to have the time to update this document with every update, I'll try my best to at least update it every other version. As for the other distributions, unless the authors wish to send updates, they well remain as they are.

4.1 Personal setup

For my installation, I have and used:

  • Kernel 2.0.30
  • Iomega ppa disk drive
  • Red Hat 4.2

4.2 Package installation

When I first decided to attempt to install Red Hat on a ZIP disk, I figured it would be much easier to just use a Red Hat boot disk. Then I woke up. I came very close to actually getting a boot disk created, even got help from various folks at Red Hat via e-mail but ultimately I began to give up on the whole project when I discovered the --root option with rpm.

What packages to get

I found what packages to install by browsing a file I had found on one of Red Hat's mirrors. This file can be found on any mirror at:

  redhat/redhat-4.2/i386/RedHat/base/comps

For this installation, I wanted to include network support but due to Red Hat's X network configuration, I'm going to have to manually configure, or rather manually attempt to configure, the network setup scripts found in /etc/sysconfig/ (see section 4.3.3.)

I decided against installing any development packages as the ZIP drive, at least an unpatched kernel version, is rather slow to get anything to compile. I also choose not to install X mainly for disk space issues. Later on, I may attempt to mount my hard drive and create a symlink with /usr to see if I can get X to work.

Following is a list of what packages I installed, listed in order of installation. Those marked with a * have updates from Red Hat's errata. In parentheses is the updated package number;

e.g. NetKit-B-0.09-6 was updated to NetKit-B-0.09-8 so the entry
    would be: *91) NetKit-B-0.09-6 (-8)


      (List created by the command rpm --root /iomega -qa)

       1) setup-1.7-2                   2) pamconfig-0.51-2
       3) filesystem-1.3-1              4) MAKEDEV-2.2-9
       5) adduser-1.7-1                 6) libc-5.3.12-18
       7) SysVinit-2.64-8               8) ash-0.2-8
       9) at-2.9b-2                    10) libtermcap-2.0.8-4
      11) bash-1.14.7-1                12) bc-1.03-6
      13) bdflush-1.5-5                14) cpio-2.4.2-4
      15) cracklib-dicts-2.5-1         16) tmpwatch-1.2-1
      17) crontabs-1.5-1              *18) db-1.85-10 (-11)
      19) dev-2.5.1-1                  20) diffutils-2.7-5
      21) etcskel-1.3-1                22) file-3.22-5
      23) fileutils-3.16-1             24) findutils-4.1-11
      25) grep-2.0-5                   26) groff-1.10-8
     *27) ld.so-1.7.14-4 (-5)          28) getty_ps-2.0.7h-4
      29) gzip-1.2.4-7                 30) mingetty-0.9.4-3
     *31) initscripts-2.92-1 (93-1)    32) ed-0.2-5
      33) info-3.9-1                   34) ncurses-1.9.9e-4
      35) libg++-2.7.1.4-5            *36) pwdb-0.54-3 (-4)
      37) rootfiles-1.5-1             *38) pam-0.57-2 (-4)
      39) redhat-release-4.2-1         40) less-321-3
      41) mount-2.5l-2                 42) zlib-1.0.4-1
      43) rpm-2.3.11-1                 44) e2fsprogs-1.10-0
      45) sysklogd-1.3-15              46) tar-1.11.8-11
      47) passwd-0.50-7                48) gawk-3.0.2-1
      49) gdbm-1.7.3-8                 50) gpm-1.10-8
      51) hdparm-3.1-2                 52) kbd-0.91-9
      53) slang-0.99.37-2              54) newt-0.8-1
      55) kbdconfig-1.4-1              56) ncompress-4.2.4-7
     *57) sh-utils-1.16-4 (-5)         58) procinfo-0.9-1
     *59) logrotate-2.3-3 (4-1)        60) lilo-0.19-1
      61) losetup-2.5l-2               62) linuxthreads-0.5-1
     *63) mkinitrd-1.6-1 (7-1)         64) mailcap-1.0-3
     *65) man-1.4h-5 (j-1)             66) mt-st-0.4-2
      67) modules-2.0.0-5              68) mailx-5.5.kw-6
      69) net-tools-1.32.alpha-2       70) procmail-3.10-10
      71) procps-1.01-11               72) psmisc-11-4
      73) quota-1.55-4                 74) readline-2.0-10
      75) sed-2.05-6                   76) setconsole-1.0-1
      77) sendmail-8.8.5-4             78) shadow-utils-960530-6
      79) stat-1.5-5                   80) tcsh-6.06-10
      81) termcap-9.12.6-5             82) textutils-1.22-1
      83) time-1.7-1                   84) timeconfig-1.8-1
      85) util-linux-2.5-38            86) vim-4.5-2
      87) vixie-cron-3.0.1-14          88) which-1.0-5
      89) zoneinfo-96i-4               90) tcp_wrappers-7.5-1
     *91) NetKit-B-0.09-6 (-8)        *92) lpr-0.18-1 (19-1)
     *93) bind-4.9.5p1-2 (9.6-1)      *94) bind-utils-4.9.5p1-2 (9.6-1)
     *95) wu-ftpd-2.4.2b12-6 (b15-1)   96) anonftp-2.3-3
      97) zip-2.1-1                    98) unzip-5.12-5
      99) statserial-1.1-7            100) minicom-1.75-2
     101) lrzsz-0.12.14-1             102) dip-3.3.7o-9
     103) ppp-2.2.0f-3                104) portmap-4.0-3
     105) perl-5.003-8               *106) traceroute-1.0.4.4bsd-2 (1.4a5-1)
    *107) elm-2.4.25-7 (-8)           108) lynx-2.6-2 
     109) ncftp-2.3.0-5               110) pine-3.95-2
     111) rdate-0.960923-1            112) apache-1.1.3-3
    *113) nfs-server-2.2beta16-7     *114) nfs-server-clients-2.2beta16-7
          (2.2beta16-8)                    (2.2beta16-8)

And with all the above installed, I still have 32MB left!

Updates; errata

As many, I hope, Red Hat users know, some packages may be found to have some security flaws or anything else which may cause issues to arise. For this reason, Red Hat releases updates for such packages. I have updated what packages I had which had updates and are marked in the above list. Please refer to Red Hat's web page concerning the updated packages at:

http://www.redhat.com/support/docs/rhl/rh42-errata-general.html


   NOTE: Before you can update the packages, you'll have to
         run the ldconfig as described in section 3.3.1.1.

How to install packages with rpm; without glint

With rpm, use the --root option to specify the mounted directory as the root for installation. I had discovered that many packages were failing to install becuase of preinstall or postinstall scripts that weren't executing correctly due to the different root directory, thus, use the --noscripts option:

==> rpm --root /iomega -i --noscripts PACKAGE.i386.rpm

As I'm sure many will notice, you should get an error message like:


  failed to open /iomega/var/lib/rpm/packages.rpm

  error: cannot open /iomega/var/lib/rpm/packages.rpm

So, just create the var/lib/rpm directory :)

==> mkdir /iomega/var; mkdir /iomega/var/lib; mkdir /iomega/var/lib/rpm

Which came first, pamconfig or pam?

If anyone's tried to install pamconfig, it'll complain about a failed dependency of pam; and when you go try to install pam, pam complains about a failed dependency of pamconfig! This, being the chicken or the egg issue, puzzled me for a while, but thanks to the --nodeps flag, we can force pamconfig to install; besides pam has more failed dependencies than just pamconfig.

==> rpm --root /iomega -i --nodeps --noscripts pamconfig-0.51-2

4.3 Problems after installation of packages

Once everything is all nicely installed, unfortunately, the disk is not fully functionable, if that's a word. What I mean to say is, if you try to boot now with the floppy, you won't get very far. As soon as init tries to start up, you'll get two lovely errors; both of which complain about some files not being found that would have been made had the scripts been run.

The case of the missing /etc/ld.so.cache and libc.so.5

If you tried booting, you'd get two error messages, the first will be the abscence of /etc/ld.so.cache file. The second complains about a missing libc.so.5.

/etc/ld.so.cache

As mentioned by many readers, my previous instructions didn't quite work as stated. In order to get this file created, you'll have to run ldconfig while the ZIP disk is still mounted:

==> chroot /iomega /sbin/ldconfig

Thanks to Javier Rodriguez for this solution.

libc.so.5

To solve the missing lib case, you'll have to create a symlink which would have been created by the installation scripts.

==> cd /iomega/lib; ln -s libc.so.5.3.12 libc.so.5

Thanks to Darcy Boese for this solution.

Setting root password

Just as ldconfig was ran in 4.3.1.1, you might as well change/create a root password for this new system:

==> chroot /iomega passwd root

What the install program created


       NOTE: This is just a very brief setup, one which I haven't
             been able to test to see if it works.  In theory it
             should, but please do not send me complaints saying
             that this didn't work.

While exploring my Red Had 4.2 CD-ROM, I came across something rather interesting; the source code for the install program. I found it under /misc/src/install and one thing which I found of some use was the net.c file. In this, I found what other files that would be created had the install program been run. Most of these just give network support (hince the name net.c) but even if you don't have a network card, you can still use localhost for networking (plus apache will complain about not being able to determine a hostname.) These files include:

      /etc/hosts
      /etc/HOSTNAME
      /etc/resolv.conf
      /etc/sysconfig/network
      /etc/sysconfig/network-scripts/ifcfg-eth0
      (or any other network device you may have.)

Networking setup

For this document, I wanted network support for my 3Com 3c595 fast-ethernet card (which for the last several months has been used in another machine.)

First I needed a name, and since I'm running my own name server (which is another long story) I gave myself the name: dash-dot.wig.org (I just liked the sound of it.) Having a name without an IP is kind of pointless, so I used a reserved non-internet usable network of 192.168.10.0 which my name server also uses. Even though the hostname is typically stored in /etc/HOSTNAME, Red Hat checks for /etc/sysconfig/network for this name; so let's start there. Sample of my /etc/sysconfig/network:


  NETWORKING=yes
  HOSTNAME=dash-dot
  DOMAINNAME=wig.org
  GATEWAY=
  GATEWAYDEV=eth0
  NS1=192.168.10.7

Next, bascially duplicate the same info here for /etc/HOSTNAME, /etc/resolv.conf, and /etc/hosts:

/etc/HOSTNAME:


dash-dot.wig.org

/etc/resolv.conf:


search wig.org
nameserver ns.wig.org

/etc/hosts:


127.0.0.1 localhost
192.168.10.99 dash-dot.wig.org dash-dot
192.168.10.7  ns.wig.org ns

Red Hat configures all network devices from scripts found in /etc/sysconfig/network-scripts. The configuration of any network device is usually first created via the install program so I had to create these config files manually. They all begin with ifcfg-XXX where XXX is the network interface which ifconfig brings up; e.g. ppp0, eth0, etc. For this example, I had to create a file called ifcfg-eth0 which contains the following:

  DEVICE=eth0
  ONBOOT=yes
  BOOTPROTO=none
  BROADCAST=192.168.10.255
  NETWORK=192.168.10.0
  NETMASK=255.255.255.0
  IPADDR=192.168.10.99

And last but not least, in order to get this going right now, while in the /etc/sysconfig/network-scripts directory, just run:

==> ./ifup ifcfg-eth0 boot

This will start the script which configures the network interface if that interface was set to start at 'boot' time.

For further information, please refer to the NET-3-HOWTO document.


Next Previous Contents