PrroBooks.com » Study Aids » Debian GNU/Linux: Guide to Installation and Usage by John Goerzen and Ossama Othman (best fiction books of all time TXT) 📕

Book online «Debian GNU/Linux: Guide to Installation and Usage by John Goerzen and Ossama Othman (best fiction books of all time TXT) 📕». Author John Goerzen and Ossama Othman



1 2 3 4 5 6 7 8 9 10 ... 28
class="calibre2">Debian makes it possible to have both Debian GNU/Linux and another operating system installed on the same system. If you plan to use this option, make sure that you have on hand the original CD-ROM or floppies of the other installed operating systems. If you repartition your boot drive, you may find that you have to reinstall your existing operating system’s boot loader2.1 or the entire operating system itself.

 

Information You Will Need

 

If your computer is connected to a network 24 hours a day (i.e., an Ethernet or similar LAN connection - not a PPP connection), you should ask your network’s system administrator for the following information: Your host name (you may be able to decide this on your own) Your domain name

* Your computer’s IP address

* The IP address of your network

* The netmask to use with your network

* The broadcast address to use on your network * The IP address of the default gateway system you should route to, if your network has a gateway

* The system on your network that you should use as a DNS server Whether you connect to the network using Ethernet Whether your Ethernet interface is a PCMCIA card, and if so, the type of PCMCIA controller you have

If your only network connection is a telephone line using PPP or an equivalent dialup connection, you don’t need to worry about getting your network set up until your system is already installed. See section 11.1 on page [*] for information on setting up PPP under Debian.

 

Partitioning Your Hard Drive Before you install Debian on your computer, it is generally a good idea to plan how the contents of your hard drive will be arranged. One part of this process involves partitioning your hard drive.

 

Background

 

Partitioning your disk simply refers to the act of breaking up your disk into sections. Each section is then independent of the others. It’s roughly equivalent to putting up walls in a house; after that, adding furniture to one room doesn’t affect any other room.

 

If you already have an operating system on your system (Windows 95, Windows NT, DOS, etc.) and you want to install Debian GNU/Linux on the same disk, you will probably need to repartition the disk. In general, changing a partition that already has a filesystem on it will destroy any information in that filesystem. Therefore, you should always make backups before doing any repartitioning. Using the analogy of the house, you would probably want to move all the furniture out of the way before moving a wall or you risk destroying your furniture. Luckily, there is an alternative for some users; see section 2.3.6 on page [*] for more information.

 

At a bare minimum, GNU/Linux needs one partition for itself. You can have a single partition containing the entire operating system, applications, and your personal files. Most people choose to give GNU/Linux more than the minimum number of partitions, however. There are two reasons you might want to break up the filesystem into a number of smaller partitions. The first is for safety. If something happens to corrupt the filesystem, generally only one partition is affected. Thus, you only have to replace (from the backups you’ve been carefully keeping) a portion of your system.

At the very least, you should consider creating what is commonly called a “root partition.” This contains the most essential components of the system. If any other partitions get corrupted, you can still boot into GNU/Linux to fix the system. This can save you the trouble of having to reinstall the system from scratch.

 

The second reason is generally more important in a business setting, but it really depends on your use of the machine. Suppose something runs out of control and starts eating disk space. If the process causing the problem happens to have root privileges (the system keeps a percentage of the disk away from users), you could suddenly find yourself out of disk space. This is not good since the operating system needs to use real files (besides swap space) for many things. It may not even be a problem of local origin. For example, unsolicited e-mail (“spam”) can easily fill a partition. By using more partitions, you protect the system from many of these problems. Using e-mail as an example again, by putting the directory varspool/mail on its own partition, the bulk of the system will work even if unsolicited e-mail fills that partition.

 

Another reason applies only if you have a large IDE disk drive and are using neither LBA addressing nor overlay drivers2.2. In this case, you will have to put the root partition into the first 1,024 cylinders of your hard drive, usually around 524 megabytes. See section 2.3.3 on page [*]

for more information on this issue.

 

Most people feel that a swap partition is also a necessity, although this isn’t strictly true. “Swap” is scratch space for an operating system, which allows the system to use disk storage as “virtual memory” in addition to physical memory. Putting swap on a separate partition allows Linux to make much more efficient use of it. It is possible to force Linux to use a regular file as swap, but this is not recommended.

 

The only real drawback to using more partitions is that it is often difficult to know in advance what your needs will be. If you make a partition too small, either you will have to reinstall the system, or you will be constantly moving things around to make room in the undersized partition. On the other hand, if you make the partition too big, you may be wasting space that could be used elsewhere.

 

Planning Use of the System

 

Disk space requirements and your partitioning scheme are influenced by the type of installation you decide to create.

 

For your convenience, Debian offers a number of default “profiles” some of which are listed later in this section. Profiles are simply preselected sets of packages designed to provide certain desired capabilities on your system. Installation is easier since packages that fit your desired profile are automatically marked for installation. Each given profile lists the size of the resulting system after installation is complete.

Even if you don’t use these profiles, this discussion is important for planning, since it will give you a sense of how large your partition or partitions need to be. The following are some of the available profiles and their sizes:

 

Server_std.

This is a small server profile, useful for a stripped-down server, that does not have a lot of niceties for shell users. It basically has an FTP server, a web server, DNS, NIS, and POP. It will take up around 50MB. Of course, this is just the size of the software; any data you serve would be additional.

 

Dialup.

This profile would be good for a standard desktop box, including the X Window system, graphics applications, sound, editors, etc.

The size of the packages will be around 500MB.

 

Work_std.

This profile is suitable for a stripped-down user machine without the X Window system or X applications. It is also suitable for a laptop or mobile computer. The size is around 140MB. It is possible to have a simple laptop setup including X with less than 100MB.

 

Devel_comp.

This is a desktop setup profile with all the popular development packages, such as Perl, C, and C++. It requires around 475MB.

Assuming you are adding X and some additional packages for other uses, you should plan for approximately 800MB of disk space for this type of installation.

 

Remember that these sizes don’t include all the other materials that are normally found, such as user files, mail, and data. It is always best to be generous when considering the space for your own files and data.

Notably, the Debian /var directory contains a lot of state information.

The installed package management files can easily consume 20MB of disk space. In general, you should allocate at least 50MB for the /var directory because system log files are also stored there.

 

PC Disk Limitations

 

A PC BIOS generally adds additional constraints for disk partitioning.

There is a limit to how many “primary” and “logical” partitions a drive can contain. Additionally, there are limits to where on the drive the BIOS looks for boot information. More information can be found in the Linux Partition mini-HOWTO. This section will include a brief overview to help you plan most situations.

 

“Primary” partitions are the original partitioning scheme for PC hard disks. However, there can be only four of them. To get past this limitation, “extended” or “logical” partitions were invented. By setting one of your primary partitions as an extended partition, you can subdivide all the space allocated to that partition into logical partitions. The number of logical partitions you can create is much less limited than the number of primary partitions you can create; however, you can have only one extended partition per drive.

 

Linux limits the number of partitions per drive to 15 partitions for SCSI drives (3 usable primary partitions, 12 logical partitions), and 63

partitions for IDE drives (3 usable primary partitions, 60 logical partitions).

 

The last issue you need to know about a PC BIOS is that your boot partition - that is, the partition containing your kernel image - needs to be contained within the first 1,024 cylinders of the drive. Because the root partition is usually your boot partition, you need to make sure your root partition fits into the first 1,024 cylinders.

 

If you have a large disk, you may have to use cylinder translation techniques, which you can set in your BIOS, such as LBA translation mode.

(More information about large disks can be found in the Large Disk mini-HOWTO.) If you are using a cylinder translation scheme, your boot partition must fit within the translated representation of cylinder 1,024.

 

Device Names in Linux

 

Linux disks and partition names may be different from those in other operating systems. You should know the names that Linux uses when you create and mount partitions. The basic scheme can be found in Table 2.1 on page [*].

 

Table 2.1: Linux Device Names +––––––––––––––––––––––––––+

| Device | Linux Name |

|–––––––––––––––—+––––––––––|

| First floppy drive | devfd0 |

|–––––––––––––––—+––––––––––|

| Second floppy drive | devfd1 |

|–––––––––––––––—+––––––––––|

| First partition on devhda (typically C: in | devhda1 |

| other OSs) | |

|–––––––––––––––—+––––––––––|

| Fifth partition on devhdc | devhdc5 |

|–––––––––––––––—+––––––––––|

| Second partition on devsdb | devsdb2 |

|–––––––––––––––—+––––––––––|

| Entire Primary-Master IDE hard disk or CD-ROM | devhda |

|–––––––––––––––—+––––––––––|

| Entire Primary-Slave IDE hard disk or CD-ROM | devhdb |

|–––––––––––––––—+––––––––––|

| Entire Secondary-Master IDE hard disk or | devhdc |

| CD-ROM | |

|–––––––––––––––—+––––––––––|

| Entire Secondary-Slave IDE hard disk or | devhdd |

| CD-ROM | |

|–––––––––––––––—+––––––––––|

| First SCSI disk | devsda |

|–––––––––––––––—+––––––––––|

| Second and remaining SCSI disks | devsdb and so forth |

|–––––––––––––––—+––––––––––|

| First serial port (COM1 in other OSs) | devttyS0 |

|–––––––––––––––—+––––––––––|

| Second, third, etc. serial ports | devttyS1, devttyS2, etc. |

|–––––––––––––––—+––––––––––|

| SCSI tape units (automatic rewind) | devst0, devst1, etc. |

|–––––––––––––––—+––––––––––|

| SCSI tape units (no automatic rewind) | devnst0, devnst1, etc. |

|–––––––––––––––—+––––––––––|

| SCSI CD-ROMs | devscd0, devscd1, etc. |

+––––––––––––––––––––––––––+

The partitions on each disk are represented by appending a number to the disk name. For example, the names hda1 and hda2 represent the first and second partitions of the first IDE disk drive in your system. Linux represents the primary partitions with the

1 2 3 4 5 6 7 8 9 10 ... 28

Free e-book «Debian GNU/Linux: Guide to Installation and Usage by John Goerzen and Ossama Othman (best fiction books of all time TXT) 📕» - read online now

Similar e-books:

Comments (0)

There are no comments yet. You can be the first!
Add a comment