• No results found

Problems after installing Linux

In document Linux (Page 139-148)

2.9 Running into trouble

2.9.4 Problems after installing Linux

You’ve spent an entire afternoon installing Linux. In order to make space for it, you wiped your MS-DOS and OS/2 partitions, and tearfully deleted your copies of SimCity and Wing Commander. You reboot the system, and nothing happens. Or, even worse,

something happens, but it’s not what should happen. What do you do?

On page 113, we cover some of the most common problems that can occur when boot- ing the Linux installation media—many of those problems may apply here. In addition, you may be victim to one of the following maladies.

Problems booting Linux from floppy. If you use a floppy to boot Linux, you may need to specify the location of your Linux root partition at boot time. This is especially true if you are using the original installation floppy itself, and not a custom boot floppy that was created during installation.

While booting the floppy, hold down Shift or Ctrl. This should present you with a boot menu. Press Tab to see a list of available options. For example, many distributions allow you to type

Running into Trouble 123

boot: linux hd=partition

at the boot menu, wherepartition is the name of the Linux root partition, like/dev/hda2. Consult the documentation for your distribution for details.

Problems booting Linux from the hard drive. If you opted to install LILO instead of creating a boot floppy, you should be able to boot Linux from the hard drive. However, the automated LILO installation procedure used by many distributions is not always per- fect. It may make incorrect assumptions about your partition layout, and you will need to re-install LILO to get everything correct. LILO installation is covered in Chapter 4.

 System reports

Drive not bootable---Please insert system disk.” The hard drive’s master boot record is corrupt in some way. In most cases, it’s harmless, and everything else on your drive is still intact. There are several ways around this:

1. While partitioning your drive usingfdisk, you may have deleted the partition that was marked as “active”. MS-DOS and other operating systems attempt to boot the “active” partition at boot time (Linux pays no attention to whether the partition is “active” or not). You may be able to boot MS-DOS from floppy and runFDISK.EXEto set the active flag on your MS-DOS paritition, and all will be well.

Another command to try (with MS-DOS 5.0 and higher) is FDISK /MBR

This command attempts to rebuild the hard drive master boot record for booting MS-DOS, by overwriting LILO. If you no longer have MS-DOS on your hard drive, you need to boot Linux from floppy and attempt to install LILO later. 2. If you created a MS-DOS partition using Linux’s version offdisk, or vice

versa, you may get this error. You should create MS-DOS partitions only us- ing MS-DOS’s version,FDISK.EXE. (This applies to operating systems other than MS-DOS.) The best solution is either to start from scratch and repartition the drive correctly, or to merely delete and re-create the offending partitions with the correct version offdisk.

3. The LILO installation procedure may have failed. In this case, you should either boot from your Linux boot floppy (if you have one), or from the original installation media. Either of these should provide options for specifying the

124 Obtaining and Installing Linux

Linux root partition to use when booting. Hold down Shift or Ctrl at boot time, and press Tab from the boot menu for a list of options.

 When booting the system from the hard drive, MS-DOS (or another operating system) starts instead of Linux. First of all, be sure that you actually installed LILO when installing the Linux software. If not, then the system still boots MS-DOS (or whatever other operating system you may have) when you attempt to boot from the hard drive. In order to boot Linux from the hard drive, you need to install LILO (see Chapter 4).

On the other hand, if you did install LILO, and another operating system boots in- stead of Linux, then you have LILO configured to boot that other operating system by default. While the system is booting, hold down Shift or Ctrl, and press Tab at the boot prompt. This should present you with a list of possible operating systems to boot; select the appropriate option (usually “linux”) to boot Linux. If you wish to select Linux as the default operating system, you must re-install LILO. See Chapter 4.

It may also be possible that you attempted to install LILO, but the installation proce- dure failed in some way. See the previous item.

Problems logging in After booting Linux, you should be presented with alogin

prompt, like

linux login:

At this point, either the distribution’s documentation or the system itself will tell you what to do. For many distributions, you simply log in asroot, with no password. Other possible user names to try areguestortest.

Most newly installed Linux systems should not require a password for the initial log in. However, if you are asked to enter a password, there may be a problem. First, try using a password equivalent to the username; that is, if you are logging in asroot, use “root” as the password.

If you simply can’t log in, there may be a problem. First, consult your distribution’s documentation; the user name and password to use may be buried in there somewhere. The user name and password may have been given to you during the installation procedure, or they may be printed on theloginbanner.

One cause may be a problem with installing the Linuxloginprogram and initializa- tion files. You may need to reinstall (at least parts of) the Linux software, or boot your

Running into Trouble 125

installation media and attempt to fix the problem by hand—see Chapter 4 for hints.

Problems using the system. If logging in is successful, you should be presented with a shell prompt (like “#” or “$”) and can happily roam around your system. However, there are some initial problems with using the system that sometimes creep up.

The most common initial configuration problem is incorrect file or directory permis- sions. This can cause the error message

Shell-init: permission denied

to be printed after logging in (in fact, any time you see the message “permission denied” you can be fairly certain that it is a problem with file permissions).

In many cases, it’s a simple matter of usingchmodto fix the permissions of the appro- priate files or directories. For example, some distributions of Linux once used the (incor- rect) file mode 0644 for the root directory (/). The fix was to issue the command

# chmod 755 /

asroot. However, in order to issue this command, you needed to boot from the installation media and mount your Linux root filesystem by hand—a hairy task for most newcomers.

As you use the system, you may run into places where file and directory permissions are incorrect, or software does not work as configured. Welcome to the world of Linux! While most distributions are quite trouble-free, very few of them are perfect. We don’t want to cover all of those problems here. Instead, throughout the book we help you to solve many of these configuration problems by teaching you how to find them and fix them yourself. In Chapter 1 we discussed this philosophy in some detail. In Chapter 4, we give hints for fixing many of these common configuration problems.

126 Obtaining and Installing Linux

RPM Category Required? Comments

BASE Yes Should not be customized.

C Development Highly Recommend Need the minimal system to compile a kernel. Development Libs Highly Recommend Need the minimal system

to compile a kernel. C++ Development Optional C++ Development.

Networked Workstation Recommend; Required Whether you are on an Ethernet or for other network going to dialup networking, you software need to install this package suite;

You shouldn’t customize this. Anonymous FTP/Gopher Server Optional If your Linux box is going to

serve files via FTP or Gopher. Web Server Optional Useful for Web Developers for local

development, required if you serve Web pages.

Network Management Workstation Optional Has additional tools useful for dialup as well as Ethernet network. Dialup Workstation Recommended Required if you are going to dialup. Game Machine Optional Need I say more? Fortunes are

required for humor.

Multimedia Machine Optional If you have supported hardware. X Window System Optional If you want to run X.

X Multimedia Support Optional If you have supported hardware. TEX Document Formatting Optional Installation of the entire

package is recommended.

emacs Recommended The One True Editing Environment.

emacswith X support Recommended Requires X MS-DOS and Microsoft Windows Connectivity Optional Huh?

Extra Documentation Required Manual pages should always be installed.

Running into Trouble 127

Use of Partition Recommend Size Comments

Swap 2 x Physical RAM If less than 16MB of RAM installed, 16MB of swapis a must. If space is tight, and 16MB RAM installed, 1 x Physical RAM is the minimum recommended. Root system, no X 100 - 200MB Depends on tools, like compilers,

that are needed.

Root system, with X 250-350MB Depends on tools like compilers, that are needed.

/home 5 - Infinite MB Depends on being single or multiple users and needs.

/var 5 - Infinite Depends on news feeds, number of users, etc. /usr/local 25 - 200MB Used for programs not in RPM format

or to be kept separate from the rest of Red Hat.

/usr 350+ MB

128 Obtaining and Installing Linux

File IDE Slackware bootdisks:

aztech.i CD-ROM drives: Aztech CDA268-01A, Orchid CD-3110, Okano/Wearnes

CDD110, Conrad TXC, CyCDROM CR520, CR540.

bare.i IDE support only.

cdu31a.i Sony CDU31/33a CD-ROM.

cdu535.i Sony CDU531/535 CD-ROM.

cm206.i Philips/LMS cm206 CD-ROM with cm260 adapter card.

goldstar.i Goldstar R420 CD-ROM (sometimes sold in a Reveal “Multimedia Kit”).

mcd.i NON-IDE Mitsumi CD-ROM support.

mcdx.i Improved NON-IDE Mitsumi CD-ROM support.

net.i Ethernet support.

optics.i Optics Storage 8000 AT CD-ROM (the “DOLPHIN” drive).

sanyo.i Sanyo CDR-H94A CD-ROM support.

sbpcd.i Matsushita, Kotobuki, Panasonic, CreativeLabs (Sound Blaster),

Longshine and Teac NON-IDE CD-ROM support.

xt.i MFM hard drive support.

Running into Trouble 129

File SCSI/IDE Slackware bootdisks:

7000fast.s Western Digital 7000FASST SCSI support.

Advansys.s AdvanSys SCSI support.

Aha152x.s Adaptec 152x SCSI support.

Aha1542.s Adaptec 1542 SCSI support.

Aha1740.s Adaptec 1740 SCSI support.

Aha2x4x.s Adaptec AIC7xxx SCSI support (For these cards: AHA-274x, AHA-2842,

AHA-2940, AHA-2940W, AHA-2940U, AHA-2940UW, AHA-2944D, AHA-2944WD, AHA-3940, AHA-3940W, AHA-3985, AHA-3985W).

Am53c974.s AMD AM53/79C974 SCSI support.

Aztech.s All supported SCSI controllers, plus CD-ROM support for Aztech CDA268-01A, Orchid CD-3110, Okano/Wearnes CDD110, Conrad TXC, CyCDROM CR520, CR540.

Buslogic.s Buslogic MultiMaster SCSI support.

Cdu31a.s All supported SCSI controllers, plus CD-ROM support for Sony CDU31/33a.

Cdu535.s All supported SCSI controllers, plus CD-ROM support for Sony CDU531/535.

Cm206.s All supported SCSI controllers, plus Philips/LMS cm206 CD-ROM with cm260 adapter card.

Dtc3280.s DTC (Data Technology Corp) 3180/3280 SCSI support.

Eata dma.s DPT EATA-DMA SCSI support. (Boards like PM2011, PM2021, PM2041, PM3021, PM2012B, PM2022, PM2122, PM2322, PM2042, PM3122, PM3222, PM3332, PM2024, PM2124, PM2044, PM2144, PM3224, PM3334.)

Eata isa.s DPT EATA-ISA/EISA SCSI support. (Boards like PM2011B/9X,

PM2021A/9X, PM2012A, PM2012B, PM2022A/9X, PM2122A/9X, PM2322A/9X).

Eata pio.s DPT EATA-PIO SCSI support (PM2001 and PM2012A).

Fdomain.s Future Domain TMC-16x0 SCSI support.

Goldstar.s All supported SCSI controllers, plus Goldstar R420 CD-ROM (sometimes sold in a Reveal “Multimedia Kit”).

In2000.s Always IN2000 SCSI support.

Iomega.s IOMEGA PPA3 parallel port SCSI support (also supports the parallel port version of the ZIP drive).

Mcd.s All supported SCSI controllers, plusstandard non-IDE Mitsumi CD-ROM support.

Mcdx.s All supported SCSI controllers, plus enhanced non-IDE Mitsumi CD-ROM support.

N53c406a.s NCR 53c406a SCSI support.

N 5380.s NCR 5380 and 53c400 SCSI support.

N 53c7xx.s NCR 53c7xx, 53c8xx SCSI support (Most NCR PCI SCSI controllers use this driver).

Optics.s All supported SCSI controllers, plus support for the Optics Storage 8000 AT CDROM (the “DOLPHIN” drive).

Pas16.s Pro Audio Spectrum/Studio 16 SCSI support.

Qlog fas.s ISA/VLB/PCMCIA Qlogic FastSCSI! support (also supports the Control Concepts SCSI cards based on the Qlogic FASXXX chip).

Qlog isp.s Supports all Qlogic PCI SCSI controllers, except the PCI-basic, which the AMD SCSI driver supports.

Sanyo.s All supported SCSI controllers, plus Sanyo CDR-H94A CD-ROM support.

Sbpcd.s All supported SCSI controllers, plus Matsushita, Kotobuki, Panasonic,

CreativeLabs (Sound Blaster), Longshine and Teac NON-IDE CDROM support.

Scsinet.s All supported SCSI controllers, plus full ethernet support.

Seagate.s Seagate ST01/ST02, Future Domain TMC-885/950 SCSI support.

130 Obtaining and Installing Linux

Device I/O address IRQ DMA

ttyS0(COM1) 3f8 4 n/a

ttyS1(COM2) 2f8 3 n/a

ttyS2(COM3) 3e8 4 n/a

ttyS3(COM4) 2e8 3 n/a

lp0(LPT1) 378 - 37f 7 n/a

lp1(LPT2) 278 - 27f 5 n/a

fd0,fd1(floppies 1 and 2) 3f0 - 3f7 6 2

fd2,fd3(floppies 3 and 4) 370 - 377 10 3

Chapter 3

Linux Tutorial

3.1

Introduction.

If you’re new to UNIX and Linux, you may be a bit intimidated by the size and apparent complexity of the system before you. This chapter does not go into great detail or cover advanced topics. Instead, we want you to hit the ground running.

We assume very little here about your background, except perhaps that you have some familiarity with personal computer systems, and MS-DOS. However, even if you’re not an MS-DOS user, you should be able to understand everything here. At first glance, Linux looks a lot like MS-DOS—after all, parts of MS-DOS were modeled on the CP/M operating system, which in turn was modeled on UNIX. However, only the most superficial features of Linux resemble MS-DOS. Even if you’re completely new to the PC world, this tutorial should help.

And, before we begin: Don’t be afraid to experiment. The system won’t bite you. You can’t destroy anything by working on the system. Linux has built-in security features to prevent “normal” users from damaging files that are essential to the system. Even so, the worst thing that can happen is that you may delete some or all of your files and you’ll have to re-install the system. So, at this point, you have nothing to lose.

In document Linux (Page 139-148)