Best of Technical Support

by Various
Partitioning

I am installing and have a 3GB hard drive. I am not sure of the best way to partition it. Any suggestions? —Jes, jes2@mindspring.com

You do not say what you plan to do with the disk, or what the host machine is (server? workstation?). Personally, I usually partition as such:

/       (about 50Meg)
/safe   (same size)
/var    (half the space left)
/usr    (the other half)

I then link /home to /var/home and /tmp to /var/tmp/tmp. /safe is a copy of my root partition so that I can boot on it with LILO if my boot partition becomes badly damaged, and it also gives me a copy of my configuration files in /etc.

Adding more partitions can be nice, but the more you add, the more chances you have to run out of space in one of them. For instance, I think making /tmp a separate partition instead of linking it to /var is a stupid idea, unless you're willing to give it several hundred megabytes, or even a gigabyte, because some programs can create huge temporary files and may fail in bizarre ways if your /tmp partition is too small.

/usr is also meant to be read-only, which works very well on Debian and works mostly on Red Hat (they have incorporated most of my bug reports). In both cases, you'll still have to remount the partition as read/write before installing a package, however. —Marc Merlin, merlin@varesearch.com

Networking Oddities

I have tried to install Red Hat 6.0 twice now from the CD included in Sams' Red Hat Linux 6 Unleashed, and both times have run into the same problem. Installation goes fine, and when done, I can log in at the console with no problems, I can telnet out, ping, etc., and I can ping it from other machines on my internal network. When I use telnet to log in to the machine, I get “telnet: unable to connect to remote host: Connection Refused”. When I try to do the finger command, I get the same error. When I use FTP to get to the machine from a 95 workstation, I get “Refused”. When I try to do the finger command, I get the same error. When I use FTP to get to the machine from a 95 workstation, I get “ftp:connect :10061”, and of course, it does not connect. On this machine, the IP address is 189.0.1.50, and the subnet address is 255.255.0.0. Interestingly though, Apache does work, and I was able to connect the Samba client to the Samba server, so TCP/IP seems to be working, but only some services.

My inetd.conf file has the lines

ftp stream tcp nowait root /usr/sbin/tcpd in.ftpd\
   -l -a
telnet stream tcp nowait root /usr/sbin/tcpd\
   in.telnetd

Further down, I also uncommented the line

finger stream tcp nowait root /usr/sbin/tcpd\
   in.fingerd

I have used Red Hat and other Linux flavors for over two years, and have never had a problem like this before. —Charles Almond, charles@ovis.net

I answered a similar question for a local user who had exactly the same problem just last week. Make sure your inetd daemon is actually running. All the file changes in the world do nothing if the daemon isn't present to read it. You can do a ps ax and scroll through the list of running processes to make sure it is present. —Chad Robinson, chadr@brt.com

There is another possible reason: the connections are being denied by tcpwrappers. Check /etc/hosts.allow, /etc/hosts.deny and /var/log/syslog. —Marc Merlin, merlin@varesearch.com

PPP Locked by Process

I'm trying to connect to my service provider. I got them to tell me how to set it up according to all their specifications through linuxconf, and according to them, the setup is right. When I run ifup ppp0, I get the following message:

pppd 2.3.7 started by root uid0 device is locked by pid438 exit.

How do I unlock ttyS1? —Kirk, webmaster@dcas.net

Looks like there is or was another previous process (438) running, which has or had the /dev/ttyS1 device locked. I think this is the port where your modem is connected. Log in as root, check if the 438 process is still running with ps aux|grep 438; if so, kill or terminate it with kill -HUP 438 and check on the /var/lock directory for any file with a name like “LCK..ttyS1” which is the actual lock file. Remove it and try again. —Felipe E. Barousse, fbarousse@piensa.com

There is also the possibility that two programs are trying to lock the device when you try to dial out. If that appears to be happening (which is most likely the case if there is no lock file but pppd always dies), try removing any lines that say “lock” in /etc/ppp/options. —Steven Pritchard, steve@silug.org

RPMs, Downloading

I am an end user with a Caldera 2.2 Linux system. My question regards the installation of new software in the RPM format and the dreaded failed dependences with respect to a missing or wrong version of a library. I generally use the KDE kpackage program but have had the same problem with the command line rpm. Let me give a real example:

Download program.rpm
Run kpackage—reports: Unsatisfied dependencies
libgdk-1.2.so.0
libgtk-1.2.so.0

But, the Caldera 2.2 system has

libgdk.so.1.0.5
libgtk.so.1.0.5

Obviously, I need to install an update to GTK+ library. So, I downloaded gtk+1.2.3 which provides:

libgdk-1.2.so.0
libgtk-1.2.so.0

Next, I download the package and use kpackage to install. Guess what: Unsatisfied dependencies appears for this package:

libc.so.6 (glibc2.1)
libc.so.6 (glibc2.0)

How can two versions of this library be required?

libm.so.6 (glibc2.1)

Caldera 2.2 has GLIBC 2.1-3 which provides

libc.so.6
libm.so.6

How do you resolve this issue which is general and not specific to this one program? More importantly, is there a HOWTO or FAQ or whatever that details working with these libraries—lic5, libc6 (2.0 and 2.1), lisbstdc++ and egcs? Unless this information is readily available to newbies so that new software can be added to their Linux system, they will be dependent on the software provided by their distribution. I would appreciate your solution to this problem. —Don, dollberg@worldnet.att.net

It seems that you have the libraries you need, but that Caldera and the package you're trying to install (probably built on Red Hat) don't agree on dependency names. You can try to force the install with

rpm -i --nodeps package.rpm

Another option is to download package.src.rpm and rebuild it:

rpm --rebuild package.src.rpm

This will generate an rpm that will install on your system. —Marc Merlin, merlin@varesearch.com

Ejecting a CD-ROM

I have Red Hat 5.1, 5.2 and 6 and I can't get my CD-ROM to eject. I have tried umount, then eject on the CD-ROM. I've tried umount, then eject on the cdplayer window. I've also tried it mounted; nothing works. My system is a Compaq Deskpro 4000 pII CPU, 3.2GB hard drive, 32MB RAM, IDE CD-ROM. —Uriah Seagraves, useagraves@excite.com

When the CD-ROM is mounted, the operating system will issue a lock command that prevents the eject function from operating. I suspect your CD-ROM is not actually being unmounted. Execute the command

cat /proc/mounts

to view what the kernel thinks is actually mounted to be sure the drive isn't in the list. —Chad Robinson, chadr@brt.com

The eject command uses the cdrom argument as default, check on your /dev directory if you have a symbolic link from “cdrom” to the actual device that handles your CD-ROM drive. In my case, also on a Red Hat 6.0 system, it is:

$ ls -l cdrom
lrwxrwxrwx   1 root     root   3 Aug  9 13:47 cdrom -> hdd

If there is no such link, create it by typing

$ ln -s hdd cdrom

It should work then. Actually, you can give any name to the CD-ROM unit by creating links on the /dev directory such as

ln -s hdd compactdisc

and later on use eject compactdisc. Since you do not mention the specific brand of your CD-ROM unit and it seems you have tested it under several Linux versions, bear in mind that the physical CD-ROM unit must support the eject command. Also, type man eject on your system and read more about the options of the eject command. —Felipe E. Barousse, fbarousse@piensa.com

Boot Process Question

How do I change the order of items in the boot process? I am running Red Hat on a laptop and I want to load the PCMCIA services before the initialization of the network interfaces. Right now, the interfaces are initialized and eth0 fails because the PCMCIA services don't load until later in the boot process. —Jeff Blaha, jeffery.f.blaha@us.arthurandersen.com

If you look at the /etc/rc.d/rc2.d directory and type ls -la, you will see a list of files (possibly among others) starting with a capital S exactly in the order they are executed by the boot process, and a list of files starting with capital K in the order they are executed by the shutdown or system going down processes. The order is alphanumeric and determined by the numbers that follow the Ss or the Ks. If you rename, say, S45pcmcia to S07pcmcia (i.e., to some number lower than the one belonging to the network startup), the PCMCIA services will start before the network services. This applies to all startup and shutdown script files on the rc1.d, rc2.d and rc3.d directories under /etc/rc.d/. Modifying startup and shutdown order of these files may damage your system behavior and/or some of its services, so be careful. —Felipe E. Barousse, fbarousse@piensa.com

This is how it's supposed to work: the Ethernet interface gets configured when pcmcia gets loaded, so there is nothing wrong with the message you see. However, should you need to start PCMCIA sooner, you can edit /etc/rc.d/init.d/pcmcia and lower the second digit on the chkconfig line. For instance, change chkconfig: 2345 45 96 into chkconfig: 2345 9 96. Then type:

chkconfig  --del pcmcia;  chkconfig --add
pcmcia

The links in /etc/rc.d/rc?.d/ will be regenerated. This will change the order in which PCMCIA is started. —Marc Merlin, merlin@varesearch.com

Load Disqus comments