SUN4/50 SparcStation IPX "Hacks" -- Linux
IPX and RedHat Linux
A number of people visiting the site have asked me to provide some info on successfully running Red Hat Linux on a limited machine, and yet still provide plenty of usability and performance.
New Material Added to this "section":
- The BogoMips Page - BogoMips are really BOGUS, here's my take.
- Sparc Linux Webserver Tuning Page - Squeeze every last drop of performance out of your obsolete Sparc box!
"yo", my status program
What I really wanted was "Sysinfo", but that doesn't exist for Linux. I wanted something that could easily be run without recompiling and give me standard information about the machine, what it's doing and how things are going. Thus, I came up with a simple shell script called "yo", as in "Yo, wassup?". Also, there's no UNIX command called yo, so I figured I'm safe putting it in my command path without disturbing anything else. Yo is a shell script that you can use as well:
-------- cut here ----------When yo is run (remember to chmod +x yo) when you save the text file, so that it can be executed as a command), it will output the following (your results will vary):
#! /bin/sh # this is the yo command # a kind of status indicator # uname -a date echo " " echo "Hardware Info:" cat /proc/openprom/name cat /proc/cpuinfo | head -2 cat /proc/cpuinfo | grep BogoMips free -ot cat /proc/scsi/scsi | head -3 df echo " " echo Number of Users : `who | wc -l` echo " " echo User Status : w echo " " echo Last 10 connections to this machine: last | head -10 echo $SHELL-------- cut here ----------
Cutting down the number of installed packagesLinux ipc 2.2.5-22 #1 Wed Jun 2 09:00:53 EDT 1999 sparc unknown Mon Oct 2 01:38:50 EDT 2000 Hardware Info: 'SUNW,Sun 4/50' cpu : Fujitsu or Weitek Power-UP fpu : Fujitsu or Weitek on-chip FPU BogoMips : 79.66 total used free shared buffers cached Mem: 63088 61516 1572 23348 3088 48228 Swap: 50956 560 50396 Total: 114044 62076 51968 Attached devices: Host: scsi0 Channel: 00 Id: 03 Lun: 00 Vendor: SEAGATE Model: ST3610N Rev: 8830 Filesystem 1k-blocks Used Available Use% Mounted on /dev/sda1 456439 362619 70244 84% / Number of Users : 1 User Status : 1:38am up 16 days, 8:44, 1 user, load average: 0.00, 0.00, 0.00 USER TTY FROM LOGIN@ IDLE JCPU PCPU WHAT techrat pts/0 cc827852-a.jrsyc 1:35am 1.00s 1.51s 0.28s sh ./yo Last 10 connections to this machine: techrat pts/0 cc827852-a.jrsyc Mon Oct 2 01:35 still logged in techrat pts/0 cc827852-a.jrsyc Sun Oct 1 22:10 - 22:11 (00:01) techrat ftp cc827852-a.jrsyc Sun Oct 1 22:05 - 22:12 (00:06) ftp ftp du205-149.ppp.al Sun Oct 1 20:11 - 20:34 (00:22) techrat ftp station-210.vm.c Sat Sep 30 21:37 - 21:43 (00:05) techrat ftp station-210.vm.c Sat Sep 30 21:36 - 21:36 (00:00) techrat ftp station-210.vm.c Sat Sep 30 21:36 - 21:36 (00:00) techrat ftp station-210.vm.c Sat Sep 30 21:35 - 21:40 (00:04) techrat ftp station-210.vm.c Sat Sep 30 17:23 - 17:26 (00:02) techrat ftp station-210.vm.c Sat Sep 30 17:23 - 17:23 (00:00) /bin/tcshRed Hat Linux has a base install that is almost 250 to 350MB, even when you tell the installer to install the bare minimum. This makes it tough for those of us with small hard drives to get much on there especially when you factor in a 50MB swap partition and then a few luxury items like a web server and a website that contains few photos!
However, there's a way at least, to chop it down after the installer has almost filled your HD. RHL contains a "package manager" known as "rpm" (do a "man rpm" sometime and see what magic it performs).
The first thing you want to do is determine what you currently have installed. This can easily be done by sending a command to rpm to query all packages and then redirect the output to a text file.
This command will Query All Information on your installed packages, and redirect the output to a text files named rpms.txt. Don't be surprised if you're waiting a few minutes for it to complete this task, and don't be surprised by the size of the text file generated -- it can be as much as 400 to 500 kilobytes. If you have access to a printer with lots of paper, print it out and start reading. Not only will you find out things about your Linux machine you never knew before, but you'll start seeing packages that you don't really need for what you want to use your machine for -- although, this will vary, depending upon WHAT you want to use your machine for.rpm -qai > rpms.txt
When you find packages you don't want on your machine, rpm can "uninstall" them for you. It will warn you if you're going to delete something critical, and it will warn you if other programs depend upon what it is you're about to delete.
This command will delete the package. Once you do this on enough unwanted, unused, un-needed packages, you'll clear up a signifigant amount of hard drive space.rpm -e (package name)
For those of you wondering what packages I have left on my little IPX with a tiny 500MB Hard drive, I've included a copy of my current RPM list. If you're trying to clear up room on your machine, this might help you see that there's plenty that can be discarded.