TAMU-1.0D Linux BINARY SET Installation Instructions MINIMUM HARDWARE REQUIREMENTS: 80386 CPU 4MB or more of RAM, 60MB of disk space (base) RECOMMENDED HARDWARE: 80486 CPU 8MB RAM 100MB disk ------------------------------------------------------------------------ BEFORE INSTALLATION: 1. Retrieve the appropriate files from net.tamu.edu: boot bin.* Note: the boot diskette must be used in your drive A: but you may use any floppy drive for the install disk set. So if you have a 5.25 a: and 3.5 drive b:, the boot diskette must be 5.25, but the install set may be either 5.25 or 3.5. 2. Transfer the images to diskettes with either dd (unix) or rawrite (dos). (Rawrite and uncompress for DOS are available from net.tamu.edu in util/dos-utils). By the way, dd runs MUCH faster to floppies on a Sun if the blocking is set up correctly. For 3.5 inch floppies on a Sun sparcstation: dd bs=18k conv=sync if=boot of=/dev/rfd0 NOTE:!!! The bin.* files are diskette *IMAGES*. That is, they exactly fill a raw diskette, and cannot be copied as files to diskettes as a DOS file. If you try under DOS to do "copy bin.01 a:" the file will not fit. You must use some tool like rawrite to write the image to diskette. The rawrite steps can be combined/simplified with the use of the new "rawfd" dos device driver, available in the dos_utils directory on net.tamu.edu:pub/linux. This raw floppy device driver (which can be loaded in config.sys, or from the dos command prompt) allows one to ftp *directly* to the raw floppy disk, as if it were a regular destination file. For example, the ftp command "get boot rawfda" would ftp the boot disk image, and write it directly to the raw floppy in drive a:. In addition, rawfd will also format the floppy as it writes out the data, thus saving another step. 3. Determine necessary information about your configuration: With the new automated installation, the only required information you need is (and you need this ONLY if you are networked): hostname ip address netmask local nameserver address local default route address This package uses the standard linux naming scheme: fd0H1440 3.5 inch HD floppy (a:) fd0h1200 5.25 inch HD floppy (a:) fd1H1440 3.5 inch HD floppy (b:) fd1h1200 5.25 inch HD floppy (b:) hda entire ide/mfm first *drive* hda1 .. hda4 first thru fourth *partition* on hda hdb entire ide/mfm second *drive* hdb1 .. hdb4 first thru fourth *partition* on hdb sda entire scsi first *drive* sda1 .. sda4 first thru fourth *partition* on sda ------------------------------------------------------------------------ INSTALLATION: If your disk will be sharing space with other operating systems, such as DOS, INSTALL THE OTHER SYSTEMS FIRST. My preferred layout is OS/2 on partition 1 using HPFS, DOS/WIN3.1 on partition 2 using FAT, an extended partition on partition 3 with a FAT filesystem (so it appears as drive d: to both OS/2 and DOS), and linux in partition 4. If you install them in this order, and in these locations, then TAMU linux's bootactv can be used for boot time selection, and OS/2's Boot Mangler is not needed. (REALLY!) There are two installation methods: a simple menu driven installation script for most configurations (single linux root partition), or manual installation for experienced users with more complex needs. AUTOMATED INSTALLATION: 1. Boot the "boot" diskette. IMPORTANT INFORMATION ABOUT AVAILABLE BOOT KERNELS: The boot diskette has two tiny kernels: one for scsi or ide disk systems, and one just for ide based systems. Both tiny kernels have all unnecessary drivers, such as networking, CDROM, and special serial/mouse drivers removed, as these sometimes conflict with a given hardware configuration. By default, lilo will boot the combined scsi/ide kernel in ramdisk mode. If you have an ide only system, and the scsi probing code conflicts with your hardware, you can try the ide only kernel. If you press at the lilo boot prompt, you will see a list of available boot modes: ramdisk (scsi/ide kernel) floppy (scsi/ide kernel) harddisk (scsi/ide kernel) ide_ramdisk (ide only kernel) ide_floppy (ide only kernel) ide_harddisk (ide only kernel) The automatic install requires that you boot in the ramdisk mode. If you have insufficient memory for this, you can do a manual install from a floppy mode boot. The harddisk mode boot is useful as a backup way to boot a linux hard disk partition, if you have problems with the normal lilo boot. The installed linux system has a full "generic" linux kernel (/vmlinuz) with ide, scsi, drivers, along with all possible network and mouse drivers. If the boot diskette works, but the installed hard disk kernel has problems booting due to driver conflicts with your hardware configuration, you will have to boot the hard disk using the boot diskette (selecting either the "harddisk" or "ide_hardisk" modes, and then configure and build a kernel tailored for your hardware (as discussed in "Rebuilding the kernel:" later in this document). The lilo boot program will prompt for "Boot" device -- press a shift key to see a help screen listing boot choices, and then simply press enter. (If you have a value point or other non-standard hardware, you may need to enter some lilo boot parameters here - see the examples on the boot information screen, or the latest FAQ for details.) As the kernel boots, you will be asked for video mode desired -- either select one of the choices, or let the prompt time out. You will finally see a menu: Linux Maintenance Diskette 1 - Install a full distribution set 2 - Exit to linux shell press '1' and enter, to start the automated installation program. If you want to do a manual install, or other maintenance, press 2. 2. Running the automated installation program: The program will first ask a series of questions to determine the desired installation configuration. In every case, a default answer will be provided, and this default answer will be displayed in parentheses (default) at the end of the question. To accept the default answer, simply press enter. The questions asked are: - What floppy drive will be used for installation? simply pick (1-4) from the menu (A list of available partitions (including any free partitions) are then presented.) - Do you need to run fdisk now? (n) you need to run fdisk only if none of the displayed partitions (including any free space) are suitable. - Which partition will be used for linux? (/dev/hda1) The default partition is chosen to be the largest linux or empty partition found. Non linux partitions will not be automatically selected as default partitions, but they are displayed on the list, and can be chosen. - Setup swapping (for 4MB ram or less)? (y) Swapping to a 4MB swap file will be configured by default unless there is insufficient space in the selected partition. Swapping must be selected if you have 4MB of ram or less, or subsequent steps may run out of memory. - Install all files? (y/n) The default is to install all files in the distribution set. If you would like to selectively install packages from the set, enter 'n'. The installation program will then ask you to remove the boot diskette, and insert the first data diskette, so that it can read the Table Of Contents (TOC). once it has read the TOC, it will for each package list the package name and size in bytes, and ask if you want it installed. The TAMU-1.0D TOC list contains: Package Name Size (bytes) Diskette # base 3508234 1 extra 4830318 1,2,3 network 1084081 3 development 11282586 3,4,5 kernel_src 5081820 5,6 man_pages 7048497 6,7 emacs 15305892 7,8,9 ghostscript 1022020 9,10 groff 1964556 10,11 libc-lite 619524 11 X_libX11 478272 12 X_base 25698219 12,13,14,15,16,17 X_server_8514 848900 X_server_Mach32 885764 X_server_Mach8 869380 X_server_Mono 771076 X_server_S3 947204 X_server_SVGA 947204 X_server_VGA16 791556 X_man_pages 4237255 X_server_kit 3501751 21 The base package is the only required package. It contains the kernel, /bin, /sbin, /boot, /lib, and some /usr/bin files necessary for booting a basic linux system. The X_libX11 package is separate from the rest of X_base, as it must be included if you load the emacs package. You need at least one of the X_server pakcages, based on your your graphics hardware. The X_server_kit is optional. - Do you want BOOTACTV (boot time partition selector) installed? (y) bootactv is a simple MBR (master boot record) boot partition selector. You want this if you have multiple partitions on the first drive. You don't want it if you need to boot linux on a second drive partition, as in this case, LILO needs to be put in the first drive MBR. (see next question) - Where do you want lilo installed? (/dev/hda1): If you asked for bootactv, the lilo bootstrap will default to the selected linux partition. If not, lilo will default to the MBR. - What is this machine's hostname? (tamu) Simply enter the machine's desired hostname (default "tamu") - Do you want networking configured? (y): simply enter 'n' if you don't want networking enabled. If you asked for networking, you will get the following added questions: - What domain is the machine in (tamu.edu) simply enter your IP domain name - What is this host's IP address (192.9.200.1) enter your host's IP address - What is the netmask (default) The presented default is correct for standard class A, B, or C networks. If your net is subnetted, you will need to override default with your local netmask. For example, tamu.edu has a class B network (128.194), so the default presented is 255.255.0.0, but we actually are subnetted with mask of 255.255.255.0 - What is the network's address (default) The network address is (your IP address & NETMASK), ie a host part of all zeros. The default should be correct unless your subnet mask is not on a byte boundary, in which case you may need to override the presented value. - what is the broadcast address (default) The broadcast address is (your IP address | !NETMASK) ie a host part of all ones. The default should be correct unless your subnet mask is not on a byte boundary, in which case you may need to override the presented value. - What is the default gateway (default) The calculated default is host 254 on your network. You will probably want to change this. - What is the nameserver address (default) The calculated default is host 254 on your network. You will probably want to change this. Once these questions are answered, the program will display the selected partition, and ask for confirmation to proceed. The default on this question is 'n' -- you HAVE to enter 'y' to proceed. The rest of the installation is automatic - it will tell you to take out the boot diskette, and enter the bin.* diskettes one at a time. Note that the new installation program is very forgiving of errors; if you insert the wrong diskette, it will tell you which disk you inserted, and ask for the correct one again. When the installation is finished, it will remind you to remove the last data diskette, and reboot (use ctrl-alt-del). The first time you reboot, fsck may check the root partition. In all subsequent reboots, as long as you use halt or reboot, the filesystems should be clean, and fsck will skip the time consuming checks. RUNNING FDISK: If you do want to run fdisk manually: If you want to run fdisk during the automated installation, simply enter 'y' at the appropriate question. You will be asked which disk device to partition, such as hda, hdb, sda, sdb as discussed above. Fdisk has command help available with the "m" command. "fdisk" should be able to determine your disk's geometry. If not, you will need to tell it the number of cylinders, heads, and sectors of your hard disk. Use the "x" command to switch to expert menu. Then use the "c" command to specify the cylinders, "h" command to specify heads, and "s" command to specify the sectors of your disk. Now use the "r" command to return to the starting menu. The instructions here are a little less clear since your partitioning preferences may be different. I will give an example of 3 partitions, one for DOS, one for swap and the other for the root filesystem. I have a 90M drive that I want to partition into 10M for DOS, 10M linux swap and 70M linux root file system. First I use the "p" command to print the partition table. I see that my disk has 1024 cylinders, and that partition 1 (DOS) covers cylinders 1 through 114. Then I use the "d" command to delete any partitions other than DOS (partition 1). I then use the "n" command to create new partitions. "fdisk" will ask me if I want a primary of extended partition: use primary. Next it will ask me where to start the partition: I use cylinder 115. I want my first partition to be a swap partitoin of size 10M. The computer asks me how big to make the partition: I enter 114 cylinders. I create a second primary partition starting at cylinder 229 and make it 796 cylinders in size. By default, all partitions are created as Linux/MINIX partitions. Since we want to use partition 2 for swap, we need to change its type, or "system id". Use the "t" command to change the type: choose partition 2 and choose type 82 "Linux swap". Similarly, partition 3 needs to be changed to type 83 (extfs). A complete list of supported partition types can be obtained using the "l" command. Before we go, use the "p" command to print the partition table and note down the number of blocks for each partition. We will need this in the next step. We are now done with this. Use the "w" command to write the information to disk and exit "fdisk". When you exit fdisk, you will be reminded to reboot, which you must do now, if you changed any partition information with fdisk. To reboot, press -- keys together. If you did not make any changes, simply press return to continue installation. ------------------------------------------------------------------------ MANUAL INSTALLATION: 1. Boot your computer with disk "boot". At the maintenance menu, select (2.) to exit to a command shell. 2. Run the "fdisk" command. Partitions the disk as desired and note down the number of blocks allocated to each partition. (see the earlier description of this.) [ /sbin/fdisk /dev/hda ] 3. Reboot your machine. (Ctrl-Alt-Del or push reset button). 4. Run "mkefs" to create the file system on all non-swap partitions. [ /sbin/mke2fs -c /dev/hda2 72345 ] (I pulled 72345 out of air for this example, but you should used the number of blocks fdisk reported in the previous step.) 5. do the actual installation: [ mount -t ext2 /dev/hda2 /mnt ] [ cd /mnt ] [ label -u -i /dev/fd0H1440 |gzip -d|tar xBpf - ] (change hda2 fd0H1440 and 1440 as appropriate) 6. configure the new root files: [ cd /mnt/etc ] [ /mnt/usr/bin/vi system_config ] this file contains definitions for the system configuration. edit the example values appropriately. [ ../sbin/doconfig ] 7. If you have more than one operating system (eg DOS and Linux) and want to have boot time selection of which operating system to run, install bootactv on your boot drive: [ cd /mnt/boot; /mnt/bin/cp bootactv.bin /dev/hda ] ( substitute your drive name for "/dev/hda") 8. prepare for reboot: [ cd / ] [ umount /mnt ] [ sync ] ------------------------------------------------------------------------ FURTHER CONFIGURATION: 1. remove all floppies, and reboot the machine: [ control-alt-delete ] 2. Log in as root by typing "root" at the login prompt. [ root ] set a password for root: [ passwd ] 3. You are now mostly done. You may still need to configure /etc/mtools, /etc/fstab (if necessary for cdrom ...), and /usr/X386/lib/X11/Xconfig.hostname. You may also want to rebuild the kernel for your configuration (the default kernel has only necessary devices in it, and assumes you have only a 80386 processor). Hints for the last two follow later. 4. If you need to change any of the configuration values entered during installation (such as ip address ...), you need to change the respective entry in /etc/system_config. If you are turning networking on for the first time, you will then need to run doconfig, which creates some networking config files based on the system_config information. NOTE that this will update /etc/fstab, so if you have customized it, save a copy and restore it afterwards. FINAL TIPS: 1. use "useradd -m user_name" to build a regular user account, (the -m switch uses the /etc/skel files for the user home skeleton). You will need to set a password for them ("passwd user_name"). 2. root and the user skeleton is now configured to use fvwm. Fvwm is configured to popup window tools on the left mouse button, utilities on the right button, and games on the middle button. (If your mouse has only two buttons, the middle button is emulated by pressing both buttons simultaneously.) 3. For a fun demo of ghostscript, use xfm to cd into /usr/lib/ghostscript/examples, and drag/drop any of the examples onto the xfm application "ghostscript". 4. if you rebuild the kernel, be sure to run "ps -U" to update /etc/psdatabase. Do this before doing a "make clean" in the /usr/src/linux directory, as the system file in /usr/src/linux/tools is needed by "ps -U". 5. if you are new to Linux, be sure to try the four virtual terminals, available with -F1 thru -F4. Under X-windows, the virtual terminals are reached with --F1 thru F4, and you return to X with -F5. 6. You can use the boot disk for maintenance (in case of filesystem problems, the disk has e2fsck), or for reinstallation from your own backup set. NOTE - the maintenance disk does not have 'ls' so you can't look around. /sbin has most system commands (mount, umount, fsck, mkfs...), and /bin has most /bin commands. 7. to make a backup compatible with the installation disk: [cd /] [tar cf - .|gzip|label -o /dev/fd0H1440 ] (or as appropriate for your floppy) questions/comments to: dave safford dave.safford@net.tamu.edu ---------------------------------------------------------------------------- Rebuilding the kernel: 1. cd /usr/src/linux 2. run "make config" This will ask which optional devices you want in the kernel. 3. run "make dep" 4. run "make clean" 5. run "make" 6. install the kernel: cp zImage /vmlinuz lilo That's it! ---------------------------------------------------------------------------- XFree86-2.1 Configuration: Getting the new XFree86-2.1 running involves three major steps: 1. point /usr/X386/bin/X to the appropriate server for you adapter. 2. Create the config file /usr/X386/lib/X11/Xconfig. 3. Edit the config file for your mouse. 1. Choosing the server: cd /usr/X386/bin rm X ln -s XF86_ X where is one of "SVGA", "8514", "Mach8" "Mach32", "S3", "MONO", or "VGA_16" 2. Creating the Xconfig file: There are several configuration options for XFree86-2.1: A. Sample configuration files B. Simplified scanning Xconfig.1m C. The "right" (pain in the rear end) way A. Sample Config files: The directory /usr/X386/lib/X11/Xconfig.Samples has a number of preconfigured Xconfig files for common adapters/monitors. Check the index file to see if one is available. If one is, simply copy it to /usr/X386/lib/X11/Xconfig.. B. SIMPLIFIED X Window Configuration In /usr/lib/X11 there are several Xconfig templates: Xconfig.hostname - *DEFAULT* - working copy of Xconfig.1M Xconfig.1M - the install version for 1MB vga cards Xconfig - working copy of Xconfig.master Xconfig.master - standard X11 release version (manual install) Xconfig.drs - this is my tailored copy of Xconfig.1M By default, when you run "startx", the server will use Xconfig.tamu, as the hostname is "tamu". This file is a working copy of the .1M easy installation version for 1MB vga cards. If your vga card has only 512K bytes of memory, it can not run in the 1024x768 resolution modes, so you need to delete these modes from the Xconfig file. If you are running on a notebook, you probably can use only the 640 x 480 modes. Then, in Xconfig.tamu: 1. check the mouse definitions, and if necessary, comment out the default (microsoft mouse on ttyS0, aka com1:) and uncomment the line corresponding to your mouse type and port. If your mouse has 3 buttons, comment out the "Emulate3Buttons" line. 2. run "xinit" There will be 48 available "modes" that are essentially all possible combinations of clocks and resolutions. You can cycle through all of these modes by pressing control-alt-keypad+. (If your vga card has 512K, there will be only 32 modes). The modes are named "1" through "48" and appear in that order. Most of these modes will show garbage on your screen. Jot down the number (ie 1 - 48) of any mode that presents a reasonable display (minor size or x/y offset errors can be trimmed out later.) Hopefully you will find at least one good mode for each of 1024x768, 800x600, and 640x480 display resolutions. Exit X using control-alt-backspace, and then edit Xconfig.tamu, to delete the "bad" mode numbers out of the "Modes" line, leaving just the few good ones you jotted down. (You can look at my final version in Xconfig.drs, which left just three modes on the "Modes" line.) That should be it! No puzzling over the vga database, frequencies, clocks, or dot calculations! This has been tested on several machines with Tseng, trident, and paradise cards. On my own tseng clone, in 1 minute I discovered two very nice modes that I had missed in hours of testing using other methods! (2.1 If necessary, you may need to tweak the dot values in the corresponding mode entries in the ModeDB section, if the display is a little off center. Each mode line in the ModeDB section has 4 numbers for horizontal dots, and four numbers for vertical dots. If the display is a little off in the horizontal or vertical position, try adjusting the MIDDLE two numbers in the respective horizontal or vertical set by 10 or 20 dots. This needs to be done by trial and error, but at least you have a good starting point. ) C. The "right" way: Read /usr/X386/lib/X11/etc/?????? adn follow the instructions. 3. Setting the mouse: asfasdf asdf asdf