• No results found

linux

N/A
N/A
Protected

Academic year: 2021

Share "linux"

Copied!
168
0
0

Loading.... (view fulltext now)

Full text

(1)

Linux Administration – Introducttion Page 1 of 167

1. Linux Introduction

Linux is a modern, flexible, and mature operating system. Although it started life on the Intel platform, it has since been ported to many other platforms such as Amiga, DEC Alpha, Apple Power PC, Sun workstations, and others. Linux boasts many other features:

Multitasking - Linux is a true preemptive multitasking operating system. All processes run independently of

each other and leave processor management to the kernel.

Networking - Linux supports a multitude of networking protocols.

Interoperability - Linux can interoperate with Windows 9x/NT/NT 2000, Novell, Mac, and most other versions

of UNIX.

Multi-user - Linux can handle multiple users simultaneously logged on to one machine.

Advanced memory management Traditional UNIX systems used swapping to manage memory, where the entire memory structure of a program was written to disk when the system began running low on memory. Linux uses paging, a method that intelligently allocates memory, when system memory is running low, by prioritizing memory tasks. Linux currently supports up to 64GB of RAM.

POSIX support POSIX defines a minimum interface for UNIX-type operating systems. Linux currently supports POSIX 1003.1. This ensures that POSIX-compliant UNIX programs will port easily to Linux.

Multiple file systems Linux must be installed on Extended 2 Linux-formatted partitions, but if certain other OS file systems already exist on the same host, Linux will support several of these file system formats as well, including DOS/Windows, OS/2, and Novell. This is just another interoperability feature provided by Linux.

1.1. Open Source and Free Software

All Linux distributions are based on the same idea: Take the Linux kernel and surround it with freely available software to create a usable operating system. Red Hat Linux 7.0 used Linux kernel 2.2, while version 9 uses kernel 2.4. Red Hat Software continuously evolves their distribution by using the most current, stable kernel as well as the latest available software for each of its distributions.

1.1.1. History

Although Linux came into being in 1991, it can trace its lineage back much further. In 1969, a Bell Labs programmer named Ken Thompson invented the UNIX operating system. Around the same time, another programmer, Dennis Ritchie, was working on a new computer language called C. By 1974, the two had rewritten UNIX in the C language, and ported it to several different machines. It is this combination of UNIX and C that Linux owes much of its heritage to.

UNIX and C are at the heart of Linux and the Open Source movement. While languages such as Purl, Python, Java, and others make the headlines today, far more lines of open source code have been written than any other single language.

Though many of these programs have been ported to other operating systems, such as Windows NT, UNIX and UNIX-like operating systems have benefited from Open Source software the most.

Linux

In 1991, a student at Helsinki University in Finland posted this message to the Usenet group comp.os.minix:

From: [email protected] (Linus Benedict Torvalds) Newsgroups: comp.os.minix

Subject: Gcc-1.40 and a posix-question

Message-ID: <[email protected]> Date: 3 Jul 91 10:00:50 GMT

Hello netlanders,

Due to a project I'm working on (in minix), I'm interested in the posix standard definition. Could somebody please point me to a (preferably) machine-readable format of the latest posix rules? Ftp-sites would be nice.

(2)

Linux Administration – Introducttion Page 2 of 167

www.wilshiresoft.com Wilshire Software Technologies Rev Dt: 15-Oct-08

From: [email protected] (Linus Benedict Torvalds) Newsgroups: comp.os.minix

Subject: What would you like to see most in minix? Summary: small poll for my new operating system

Message-ID: <[email protected]> Date: 25 Aug 91 20:57:08 GMT

Organization: University of Helsinki

The student, of course, was Linus Torvalds. Linus had just purchased a (then) state-of-the-art 386 PC, and wanted, among other things, to learn how it worked. The MS-DOS operating system was too limiting, and immediately discounted. At the time, he had been using another UNIX-like operating system called Minix, a microkernel-based teaching operating system. Minix had many limitations, however, so Linus set about writing a new operating system that did not suffer the limitations of MS-DOS and Minix.

Linus was by no means the first person to come up with the idea of a free UNIX-like operating system. Several years earlier The Free Software Foundation, headed by Richard M. Stallman, announced a kernel called The HURD. Unfortunately, efforts on this new kernel faltered, and it wasn't until 1996 that a stable version of The HURD was available. William and Lynne Jolitz in 1991 were also busy porting Berkeley UNIX, BSD, to the Intel platform.

But Linux was quickly propelled to the front of the pack by the large army of programmers from all across the world, who all pitched in their expertise for the Linux kernel. Instead of the project becoming chaotic and unmanageable, Linux actually benefited from the large number of coders and testers, and nearly instant feedback every time a new kernel was released, which was often? At times, several versions of Linux were released in a single day. A few years after development had begun on Linux, it was a full-featured, stable operating system. Today, the Linux kernel is developed the same as it was in the beginning. Programmers across the globe collaborate on discussion groups and e-mail lists to work on the Linux kernel. Most are not paid for their efforts, doing it instead from a sense of community that binds Linux developers.

1.2. GPL and Open Source Licenses

The terms “Free” and “Open Source” software are commonly used to mean the same thing. While the differences are subtle, they are very important.

Free Software

Free software is the term typically used to refer to software that has been released under the GNU Public License, or GPL. The GPL (also called Copyleft) was designed with the philosophy that all software should be free. Not free as in zero prices, but free as in open. As the Free Software Foundation's Richard Stallman puts it in his essay “The GNU Operating System and the Free Software Movement.”

The term "Free software" is sometimes misunderstood-it has nothing to do with price. It is about freedom. To clear up some of the confusion, the following is the definition of Free software. A program is Free software for users if:

 You have the freedom to run the program, for any purpose.

 You have the freedom to modify the program to suit your needs. (To make this freedom effective in practice, you must have access to the source code, since making changes in a program without having the source code is exceedingly difficult.)

You have the freedom to redistribute copies, either gratis or for a fee.

You have the freedom to distribute modified versions of the program, so the community can benefit from your improvements.

Since "free" refers to freedom, not to price, there is no contradiction between selling copies and Free software. In fact, the freedom to sell copies is crucial: collections of Free software sold on CD-ROMs are important for the community, and selling them is an important way to raise funds for Free software development. Therefore, a program that people are not free to include on these collections is not Free software

1.3. About Linux

You hear people talking about Linux all the time. But you also probably hear about the "Red Hat" Linux distribution, and names like SuSE, Caldera, Debian, Slackware, and others. Are they all Linux?

(3)

Linux Administration – Introducttion Page 3 of 167 Recall that Linux is the operating system kernel. That is, Linux is the very heart of the operating system. However, like all operating systems, to be useful, Linux has to have utilities and programs to do the actual work. This is where distributions come in.

All of the Linux distributions run the Linux kernel. But after that, the distributions vary from each other to some degree. For example, the Slackware distribution looks and feels much like Berkeley UNIX, whereas the SuSE distribution is much more System V'ish. Red Hat Linux tends to fall somewhere in between but is leaning toward System V more and more with each new release.

1.4. Current Support for Networking Services

Linux was built from the start to be a network operating system. This may seem obvious now, but consider that in 1991 nobody knew how important networking and the Internet would be to modern-day computing. This gives Linux a big edge in terms of network stability and integration.

Today, Linux supports the networking protocols

 Protocol  Description

TCP/IP This is the protocol used by the Internet, and on most local networks

IP Version 6 This is the protocol that will eventually replace IP version 4 on the Internet.

AppleTalk The protocol used for Apple computers to communicate with each other.

CCITT X.25 Packet Layer The X.25 networking protocol.

Acorn Econet/AUN An older protocol, used by Acorn computers to access file and print servers.

IPX The Novell networking protocol, used to access Novell file and print servers.

1.5. Flexibility of Open Source Software

Much ado has been made about Free and Open Source software, but what do you really get that you can't get from closed operating systems such as Microsoft Windows?

StabilityWhen a version of an open source program is released on the Internet, there is a large peer review of the source code. With so many people looking at the code, there's a much better chance somebody will see a bug, and even offer a correction. This type of peer review just isn't possible in the closed source world.

ModificationsIn a closed source environment, you're at the mercy of the vendor. If you want or need a feature, you can submit a request for features, and only hope the vendor will agree with you. If not, you're stuck. With open source, you have the source code, and you can add the features yourself, if need be. Or, you can hire a programmer to make the changes for you. Many times, you can post a message to the appropriate Usenet newsgroup saying "Gee, it sure would be nice if program Foo could do this." Sometimes somebody will have a patch written within a couple days that does just what you want.

SupportThere are literally thousands of open source advocates out there on newsgroups and e-mail lists who can answer your questions when you need help. Best of all, it's free. Contrast this with the big money you throw to the closed source vendors, who may or may not be able to help you. And if you really feel the need to pay for support, there are several companies out there now providing 24/7 technical support for Linux.

(4)

Linux Administration - Distribution Comparision Page 4 of 167

www.wilshiresoft.com Wilshire Software Technologies Rev Dt: 15-Oct-08

2. The Linux Distribution Comparison

Linux is started taking the world of computers by storm. Corporate greed, insane legal licensing and constant Windows vulnerabilities are starting to take its toll on the general computing population, and many are looking for an alternative. For some Linux is the answer.

The Linux Operating System is very different than proprietary Operating Systems. Linux has a community based development model where many people, organizations and businesses jointly develop the software. With this style of development, there is no one entity that controls everything, but because of this, it is quite difficult to build a coherent system that will run on personal computers. This is where distributions come in.

Distributions are complete Linux Systems that are built by companies or organizations to aid in the support and installation of the Linux Operating System. Distributions take care of all of the rudimentary tasks of building the system, such as building and testing the software, providing technical support and to provide security updates and bug fixes, etc.

There are all types of distributions available, from ones that are very user friendly to advanced ones that allow you to build your system from the source code. We will cover the most popular intermediate Linux distributions available today, RedHat Linux Fedora Linux, RedHat Enterprise Linux, Mandrake Linux, Suse Linux, Debian GNU/Linux, Slackware Linux and Caldera OpenLinux. Intermediate distributions give the user plenty of control and choice over their system, yet provide easy to use tools to administer and maintain their system.

There is no one distribution that will perfectly fit into everyone’s needs. Each one has its own strengths and weaknesses which will vary from person to person. This article covers all the major advantages (and disadvantages) each of these distributions have to offer and hopefully give you enough information to help you correctly choose which Linux Distribution is right for your computer.

2.1 Red Hat Linux

For many, the name Red Hat www.redhat.com epitomises Linux, as it is probably the best-known Linux company in the world. Founded in 1994, Red Hat, Inc. has only recently started showing signs of profitability, due to services rather than the distribution itself. Yet, Red Hat Linux is a first choice for many professionals and is likely to be a major player for a long time. They wisely resisted any rapid expansion plans during the dot-com boom times in 1998 - 1999, concentrating on their core business. This type of prudent management, if continued, is likely to guarantee stability and dependability.

What is so special about Red Hat Linux? It is a curious mix of conservative and leading-edge packages put together on top of many knowledge-intensive utilities developed in-house. The packages are not the most up-to-date; once a new beta version is announced, the package versions are frozen, except for security updates. The result is a well-tested and stable distribution, the beta program and a bug reporting facility are open to public and there is a great spirit on the public mailing lists. Many mission-critical servers around the world run Red Hat Linux. One other reason for Red Hat's success is the variety of popular services the company offers. The software packages are easy to update via Red Hat Network, a free repository of software and valuable information. A vast range of support services is available through the company and, while not always cheap, you are virtually assured of an excellent support by highly skilled support personnel. The company has even developed a certification program to further popularize its distribution - the RHCE (Red Hat Certified Engineer) training and examination are now available in most parts of the world. All these factors have contributed to the fact that Red Hat is now a recognized brand name in the IT industry.

2.1.1 Fedora Linux

Fedora Linux was started by Redhat Linux in September 2003 as a community based open development Operating System based on the Redhat Linux distribution. The Redhat distribution was first released in October 1994 and has progressed to one of the most popular Linux Distributions available today.

2.1.2 RedHat Enterprise Linux

Red Hat Enterprise Linux creates a reliable, secure, high-performance platform designed for today’s commercial environments—with capabilities that match or surpass those of proprietary operating systems. Sold in a family of four products that span client systems to the largest servers, Red Hat Enterprise Linux delivers a consistent application, management, and user environment.

(5)

Linux Administration - Distribution Comparision Page 5 of 167 Red Hat Enterprise Linux is the corporate Linux standard, already at work running some of the world’s largest commercial, government, and academic institutions. For any deployment—from the desktop to the datacenter— Red Hat Enterprise Linux delivers unmatched performance and cost savings, and the freedom of open source technology. Following is a figure describes RedHat’s Network:

Figure: RedHat Network

Server Solutions:

Red Hat Enterprise Linux AS (Advanced Server):

Red Hat Enterprise Linux AS is the top-of-the-line server operating system solution. Supporting the largest servers, it is the ultimate solution for large departmental and datacenter server deployments.

Red Hat Enterprise Linux ES (Enterprise Server):

Red Hat Enterprise Linux ES is the perfect server operating system solution for the majority of today's business computing needs – suitable for systems ranging from the edge-of-network to medium-scale departmental deployments.

Client Solutions:

Red Hat Enterprise Linux WS (Work Station) and Desktop:

Red Hat Enterprise Linux WS is the desktop/client partner for Enterprise Linux AS and Enterprise Linux ES. Red Hat Enterprise Linux WS is ideal for all desktop deployments, including office productivity applications, S/W development environments, and targeted ISV client applications. When configured as a headless workstation, Enterprise Linux WS is also ideally suited for use as a compute node in a High Performance Computing (HPC) environment.

Red Hat Enterprise Linux products are based on the same core kernel, libraries, and utilities, and also share the same major package sets. However, because Red Hat Enterprise Linux WS and Red Hat Desktop are not designed for use in server environments, there are some differences between family members in terms of their server package sets.

(6)

Linux Administration - Distribution Comparision Page 6 of 167

www.wilshiresoft.com Wilshire Software Technologies Rev Dt: 15-Oct-08

product: Linux AS Linux ES Linux WS

Common usages Databases, ERP,

CRM, applications

Small-medium web, file, and print configurations

Technical, virtualization, trading, power user

Personal productivity: mail, document processing, browsing, instant messaging; software development Includes desktop applications

Yes Yes Yes Yes

Supported by leading ISV applications

Yes Yes Yes Yes

 Certified on leading

OEM hardware

Yes Yes Yes Yes

Includes dedicated server packages

Yes Yes No No

Web and phone-based

comprehensive support 24x7 - 1 year Red Hat Network

Yes No No No

Supports X86 systems (Intel Pentium Pro, AMD Athlon, or

compatible), Intel EM64T, and AMD64 systems

Yes Yes Yes Yes

Supports Itanium systems

Yes Yes Yes No

Supports IBM zSeries, POWER series, and S/390 series systems

Yes No No No

2.1.3 Red Hat Enterprise Linux system configuration limits

The following table lists some Red Hat Enterprise Linux 3 supported system and software limits. This table will be updated as additional qualification and testing is completed.

These minimum and maximum system configuration limits identify the technical capabilities of the Red Hat Enterprise Linux technology.

Note: Following chart doesn’t apply to Red Hat Enterprise Linux WS and Desktop

Minimum Maximum Comments

Memory: 256MB 64GB Maximum varies with chosen kernel; Red Hat Enterprise

Linux ES supports up to 8GB X86

CPUs: 1 (300MHz,

i686)

16 16 physical CPUs or 8 Hyperthreaded CPUs; AMD K6

(i586) is not supported, Red Hat Enterprise Linux WS and ES support up to 2 physical CPUs (4 Hyperthreaded) CPUs per system

(7)

Linux Administration - Distribution Comparision Page 7 of 167

Memory: 512MB 96GB 96Gb applies to HP Integrity systems. Maxmimum memory

for Intel Tiger-based systems is 32GB Itanium2 *

CPUs: 1 8 Red Hat Enterprise Linux WS for Itanium supports up to 2

CPUs per system

Memory: 512MB 16GB

AMD64

CPUs: 1 4 Red Hat Enterprise Linux WS for AMD64 supports up to 2

CPUs per system

File system size 800MB 1TB Quoted minimum is for a custom installation. Sparse files

can be up to 4TB

2.2. Mandrake Linux

Mandrake Linux was first started in 1998 as a custom built Redhat Linux distribution. The company that releases Mandrake Linux, Mandrakesoft, is a publicly traded company in France. More recently Mandrakesoft has just gotten out of bankruptcy and looks to continue to be a very strong Linux Distribution contender

Mandrake Linux was created with the goal of making Linux easier to use for everyone. At that time, Linux was already well-known as a powerful and stable operating system that demanded strong technical knowledge and extensive use of the "command line"; Mandrake saw this as an opportunity to integrate the best graphical desktop environments and contribute its own graphical configuration utilities and quickly became famous for setting the standard in ease-of-use and functionality.

With this innovative approach, Mandrake offers all the power and stability of Linux to both individuals and professional users in an easy-to-use and pleasant environment. Thousands of new users are discovering Linux each and every day and finding it a complete replacement for their previous operating system. Linux as a server or workstation has no reason to be jealous of any other more established operating systems.

The GPL license (General Public License) governs the development and redistribution of Mandrake Linux. This license provides everyone the right to copy, distribute, examine, modify and improve the system as long as the results of these modifications are returned to the community. It is this development model that allows Mandrakelinux Linux to collect the best ideas from developers & users from across the globe to result in a rich variety of techniques and solutions.

2.3 SuSE Linux

Suse Linux was started in 1992, and was the first "real" commercial Linux vendor to appear. Suse is a very strong Linux Distributor, especially in Germany and other European countries. In January of 2004, Novell acquired Suse, and another Linux company, Ximian. Suse Linux Professional 9.1, which was released in May 2004, is the first release since Novell acquired Suse Linux.

SuSE www.suse.com is another company with the desktop focus, not very different from Mandrake in this respect. The distribution has received positive reviews for its installer and configuration tools, called Yast, developed by SuSE's own developers. The documentation, which comes with the boxed product, has repeatedly been labeled as the most complete, thorough and usable by far. Linux Journal has recently awarded SuSE Linux 7.3 the "Product of the Year" title. The distribution has achieved a dominant market share in German speaking and some Eastern European countries.

However, SuSE has been suffering from lack of profitability, having been forced to close down their offices in the USA and reduce staff - due to high cost of development in Germany. Also, SuSE's development takes place completely behind closed doors and no public betas are provided for testing. The release cycle is more frequent (SuSE released three versions in 2001) and they have a policy of not making the software available for download long after the boxed versions are in stores. Even so, SuSE does not provide ISO images of their distribution, relying on packaged software for the vast majority of their user base.

2.4 Debian GNU/Linux

Debian GNU/Linux www.debian.org is a completely non-commercial project; perhaps the purest form of the ideals that started the free software movement. Hundreds of volunteer developers from all over the world contribute to the project, which is well managed and strict, assuring a quality distribution known as Debian.

(8)

Linux Administration - Distribution Comparision Page 8 of 167

www.wilshiresoft.com Wilshire Software Technologies Rev Dt: 15-Oct-08 At any time during the development process, there are three branches in the main directory tree - "stable", "testing" and "unstable", the last of which is often referred to as "sid". When a new version of a package appears, it is placed in the unstable branch for first testing. If it passes, the package moves to the testing branch, which undergoes rigorous testing lasting many months. This branch is only declared stable after a very thorough testing. As a result of this, the distribution is possibly the most stable and reliable, albeit not the most up-to-date, suitable for deployment on servers.

Debian's other main claim to fame is the reputation for being hard to install, unless the user has intimate knowledge about the computer's hardware. Compensating this failing is "apt-get", a convenient installer for Debian packages. Many Debian users joke that their installer is so bad, because they only need it once - as soon as Debian is up and running, all future updates of any scale can be accomplished via the apt-get utility. Take it from a person who has tried many distributions - once you have experienced the dependency headaches while installing software on any RPM-based distribution, you will stare in absolute disbelief at the painless and convenient process of installing and upgrading your Debian packages. You might even think that you have just entered paradise...

2.5 Slackware Linux

Slackware www.slackware.com is one of the oldest distributions around and it is very popular among experienced Linux users. It offers no bells and whistles, sticking with a text-based installer and no graphical configuration tools. Where other distributions tried hard to develop easy-to-use front ends for many common utilities, Slackware offers no hand-holding and everything is still done through configuration files. Because of this, Slackware is not recommended to novice users.

Nevertheless, Slackware has a magic appeal to many users. It is extremely stable and secure - very suitable for server deployment. Experienced Linux administrators find that the distribution is less buggy as it uses most packages in their pristine forms and without too many in-house enhancement which have a potential to introduce new bugs. Releases are infrequent although up-to-date packages are always available for download after the official release. Slackware is a fine distribution for those who are interested in deeper knowledge of Linux internals.

Perhaps the best characteristic of this distribution I have heard is this: If you need help with your Linux box, find a Slackware user. He is more likely to fix the problem than a user familiar with any other distribution.

2.6 Caldera OpenLinux

Caldera www.caldera.com has been through bad times in the last few months, suffering from severe drops in share prices and being forced to reduce staff. They have released a version of OpenLinux in July 2001, surrounded in enormous controversy. The company has introduced "per-seat licensing" for business users, requiring users to purchase a separate license for every workstation or server installed. This unprecedented move drew lots of criticism and prompted many users to switch to another distribution.

Caldera OpenLinux 3.1 is still available for non-commercial use as a free download. The reviews have been positive, branding the distribution as easy-to-install and very stable, suitable for heavy development work. It lacks the Gnome desktop environment and associated libraries, which means that some excellent GTK+ based applications, such as Galeon or Gnumeric, are not available.

Note: Linux is actually only the kernel of a complete system. Many contributors like to call a complete Linux

system a GNU/Linux system. The GNU stands for GNU's Not Unix (a recursive acronym) and is the system first started by Richard Stallman, then later developed with the coordination of the Free Software Foundation. The whole name idea is to get the point of freedom across when you discuss the operating system.

2.7. Top 6 Distributions

This is difficult to determine, since Linux distributions are often unable to determine their own sales figures due to the multiple installation models, and lack of strict 'per-seat' licensing. However, the popular www.distrowatch.com site lists features of 90 major Linux distributions, with 'interest counts' (based on page requests for each of the distributions).

We also took the 20 most popular distributions according to Distrowatch, and using the 'link:' feature of Google, determined the number of in-pointing links to each distribution's web site (i.e. number of sites that link to each distribution's homepage). This helped to validate the findings of Distrowatch.

(9)

Linux Administration - Distribution Comparision Page 9 of 167

Distribution Rank from Distrowatch Rank from Google Combined Ranking

Mandrake 1 3 =1 Redhat 2 2 =1 Debian 3 1 =1 SuSE 4 6 =4 Slackware 5 5 =4 Caldera/SCO 6 4 5

2.7.1 Evaluation Criteria and Description

Evaluation of these distributions according to the following categories, We do not give a 'good', 'bad' rating, we merely list the qualities of each distribution.

Criterion Reason

Organization structure / description of company structure etc. Any recent or intended major changes.

Funding in the Open Source world is especially difficult following 'dot-com' collapse. Many mergers, some distributions and companies have closed. Mergers, while possibly helping the market in the long-run, could give

Ease of installation process, is it graphically based?

The installation process is the first thing the end-user will normally see. The feel of this process gives a good clue to what the distribution things of their target market. Some are graphical and need only a few mouse clicks, some require the skills of a system administrator.

Is the entire distribution itself open source?

If parts are non-open source, few developers outside the company itself (if corporate) would be willing to fix / enhance. For totally open source distributions, there will always be a migration path – if the company producing a excellent product goes under, someone else will take up that product.

Any insistence of 'per seat' licensing?

Per seat licensing means that the vendor of the distribution tries to insist on a payment for every seat using that distribution (similar to the current Microsoft licensing model).

Target market of distribution Different distributions have widely differing target markets – the Linux world is extremely diverse.

Support for adding bug fixes and extra hardware support.

Users need the ability to upgrade for security fixes and new hardware. Whether this is free, and how easy to do, varies widely.

License fee. If a license fee is required or recommended for the distribution, what is the fee, and what are the benefits.

2.7.2 Organizational Structure

Mandrake A large public company, based in France. Some minor reports of financial

problems, reasonable levels of sales growth. No indications of any likely merger activity.

Redhat A large US based limited company. Over $US100M in the bank, most secure of all

Linux distributions.

Debian Not a for-profit company, a collection of developers, expenses paid by donations.

Some suspicions in the community that Debian is becoming less popular.

SuSE Commercial company, based in Germany. Some changes in that they are merging

some development to become part of UnitedLinux.

Slackware Another non-commercial distribution, centered around a few dedicated individuals, with a variety of other contributors.

(10)

Linux Administration - Distribution Comparision Page 10 of 167

www.wilshiresoft.com Wilshire Software Technologies Rev Dt: 15-Oct-08 Caldera/SCO Relatively large public US based company, involved in Linux as well as other

non-Linux software. Some changes in that they are merging some development to become part of UnitedLinux. May 2003 update : Caldera/SCO now neither distribute nor support Linux

2.7.3 Ease of Installation Process

Distribution Comments

Mandrake Very well respected installer, graphical, questions are mainly non-technically worded.

Redhat Graphical installer, easy to use.

Debian Text based installer, lots of options.

SuSE Graphical, easy to use.

Slackware Text based, said to have steep learning curve.

Caldera/SCO Easy to use, but text based.

2.7.4 Commitment to Open Source

Distribution Comments

Mandrake Yes, they are committed to open source and donate time to popular applications.

Redhat Same as Mandrake.

Debian Committed to keeping everything open source:

SuSE Everything except 'YAST', the system setup tool. This has caused some

controversy. Now part of UnitedLinux : see Caldera.

Slackware Everything is open source.

Caldera/SCO Some open source community concerns that binaries under UnitedLinux binaries

may not be freely distributable, only sources will be. UnitedLinux keen to play down any concerns they are not fully open source. Many in the industry believe Caldera treads a fine line on the edge of breaking the spirit of the GPL licensing agreement.

2.7.5 Per Seat Licensing

Distribution Comments

Mandrake Possible to get security updates, online support etc without per-seat license. License just makes support faster.

Redhat No per seat licensing requirement.

Debian Cost-free (donations suggested).

SuSE Maintenance utility requires a per seat license, but SuSE keen to deny reports that

their entire product could change to per-seat licensing now that they are part of UnitedLinux.

Slackware Cost-free.

(11)

Linux Administration - Distribution Comparision Page 11 of 167

2.7.6 Target Market

Distribution Comments

Mandrake Said to be one of the easier to use Linux distributions for desktop users, however, default KDE (desktop) requires some relearning for previous Windows users.

Redhat Traditionally Redhat concentrated on the server market, but now they are also

promoting the desktop market. Same comments about KDE as for Mandrake.

Debian Debian is said to be hard to learn, more suited for experienced Linux users.

SuSE Quite similar to Mandrake – easy, but not optimized to be like Windows.

Slackware Same as Debian.

Caldera/SCO The cheapest 'workstation' product targets software developers not 'normal' users.

2.7.7 Software Upgrades / Support

Distribution Comments

Mandrake Even non-registered users have access to security upgrades, dedicated site.

Redhat Automatic update agent.

Debian Software support is okay, but installation method is text-only.

SuSE Automatic update facility (this is the non-GPL part of SuSE).

Slackware No automated update, users are expected to manually select their own updates

from a website.

Caldera/SCO Automatic update facility.

2.7.8 License Fee

Distribution Comments

Mandrake $US25 - if you want support.

Redhat Desktop and WS RH Enterprise: AS RH Enterprise: ES

$US40.

$ US 1499 (for Standard Edn) and $ US 2499 (Premium Edn) $ US 400 (for Standard Edn) and $ US 500 (Premium Edn)

Debian Cost-free (donations suggested).

SuSE $US40 or US$80 (some users say $US40 product does not have some commonly

required features).

Slackware Cost-free (donations suggested).

Caldera/SCO $US99 per user.

Conclusion

The Linux world has surprising variety. There are distributions made to look like Windows, distributions that only a system administrator could install, and everything in between. There are business models everywhere between ‘it’s all free, please donated' And that's just the top 6 distributions. Take a look at www.distrowatch.com, check out some of the smaller distributions, and you'll find an even more diverse world.

(12)

Linux Administration – Installation Page 12 of 167

www.wilshiresoft.com Wilshire Software Technologies Rev Dt: 15-Oct-08

3. Linux Installation

3.1 Hardware Requirements

The following information represents the minimum hardware requirements necessary to successfully install Red Hat Linux 9:

- Minimum: Pentium-class

- Recommended for text-mode: 200 MHz Pentium-class or better - Recommended for graphical: 400 MHz Pentium II or better

Hard Disk Space (NOTE: Additional space will be required for user data):

Personal Desktop

A personal desktop installation, including a graphical desktop environment, requires at least 1.7GB of free space. Choosing both the GNOME and KDE desktop environments requires at least 1.8GB of free disk space.

Workstation

A workstation installation, including a graphical desktop environment and software development tools, requires at least 2.1GB of free space. Choosing both the GNOME and KDE desktop environments requires at least 2.2GB of free disk space.

Server

A server installation requires 850MB for a minimal installation without X (the graphical environment), at least 1.5GB of free space if all package groups other than X are installed, and at least 5.0GB to install all packages including the GNOME and KDE desktop environments.

Custom

A Custom installation requires 475MB for a minimal installation and at least 5.0GB of free space if every package is selected.

Memory: -

 Minimum for text-mode: 64MB  Minimum for graphical: 128MB  Recommended for graphical: 192MB

Note that the compatibility/availability of other hardware components (such as video and network cards) may be required for specific installation modes and/or post-installation usage. For more information about hardware compatibility, see the Red Hat Linux Hardware Compatibility List at http://hardware.redhat.com/hcl/ Before you begin a Red Hat Linux installation, you need to know what the purpose of the machine will be. Will it be a development workstation? An FTP? A Web server? Or will it be a database server? Each of these examples requires a different configuration.

3.2 Planning the Installation

Before any software can be installed, the computer has to be able to recognize the hardware it will be using. The installation process will ask you about your hardware, so have this data ready before you start.

You should know the make and model number for each of the following pieces of hardware, if you have them:  SCSI controllers

 Network interface cards (NIC)  Video cards

 Sound cards

(13)

Linux Administration – Installation Page 13 of 167 Red Hat Linux comes conveniently bundled with an array of pre-configured software packages. Most likely, you will not need to install all of these packages, and for security reasons (or office policy) it is a good idea not to. Your boss might not appreciate the office network being used to serve personal Web pages from each employee's installation of an Apache Web server. Also, every computer on your network doesn't need to run the innd network news service.

Limit the packages you install to only the ones you need. If other packages are required later, they can be installed easily enough with the rpm tool.

Partitioning the Drive

It is recommended that you make several partitions when preparing your hard drive to install Linux. This is a good idea for various reasons. First, Red Hat Linux runs two filesystems: a Linux native filesystem, and a Linux swap space. Second, if you want to install Red Hat Linux and another operating system on the same computer, you will have to create separate partitions for each.

Stability and Security

The Linux native filesystem is usually divided among many hard drive partitions. The recommended configuration is a separate partition for each of these directories: /, /usr, /tmp, /var, and /home as well as separate partitions for corporate data, database services, and even the Web and FTP sites if they are expected to be large.

Partitioning the hard drive in this manner keeps system, application, and user files isolated from each other. This aids in protecting the file space that the Linux kernel and the rest of your applications use. Files cannot grow across partitions. Therefore, an application that uses huge amounts of disk space, such as a newsgroup server, will not be able to use up all of the disk space needed by the Linux kernel. Another advantage is that if a bad spot develops on the hard drive, it will be easier to restore a single partition than the entire system. Stability is improved.

Security, also, is improved. Multiple partitions give you the ability to mount some filesystems as read-only. For example, if there is no reason for any user (even root) to write to the /usr directory, mounting that partition as read-only will help protect those files from being tampered with.

While there are many incentives to partitioning your disk space, it might not be desirable for you. For single-user systems, or where disk space is scarce, a simpler filesystem layout would be called for. For example, if the /var directory is on its own partition of 300MB, only 100MB might be used. That makes 200MB of wasted disk space. As of RH 7.x, both the web and ftp document roots have been added to /var. These may add additional disk space requirements for /var.

Currently, there is no easy way to resize Linux partitions. Therefore, a lot of careful consideration should be put into whether you want to partition your disk space, and how to do it.

3.3 How Much Space Is Required?

You should size your Linux partitions according to your needs and the function of the computer. For example, a mail server will require more space for the /var directory because the mail spool resides in /var/spool/mail. You may even want to create a separate partition just to accommodate /var/spool/mail.

Example: File Server

If the Linux system you are installing is to be a file server, then your filesystem could look something like the following:

Filesystem Size (MB) Mounted on

/dev/sda1 400 /

/dev/sda5 2000 /var

/dev/sda6 300 /usr

/dev/sda7 60 Swap space

(14)

Linux Administration – Installation Page 14 of 167

www.wilshiresoft.com Wilshire Software Technologies Rev Dt: 15-Oct-08

/dev/sda9 3000 /home/shared

Linux Swap Space

Normally, Linux can use a maximum 4GB of swap space. This 4GB can be spread over a maximum of eight partitions. Note that each swap partition is restricted to a maximum of 2GB.

There is no authoritative formula for deciding how much swap space should be made, but you can make an estimate based on the typical UNIX rule of thumb, swap space should be two to three times the amount of RAM. Disk space is very cheap compared to RAM.

BIOS Limits

Be aware that some computers, built before 1998, may have a BIOS (Basic Input/Output System) that, at bootup (under DOS), limits access to hard disks beyond their 1024 cylinder. A common effect of this problem is your computer's inability to see any partitions past the first 512MB of disk space at boot time. If this limitation affects your computer, do not place any bootable partitions after this barrier or the BIOS will not be able to access them and your Linux operating system will not be able to load.

3.4 Partitioning Naming Conventions

UNIX is notorious for creating weird file names for hardware, and no one standard has been used by all the UNIX versions. Linux, meanwhile, has been using a simple standard for disk drives: disk device names have three letters, then a number. The first letter identifies the controller type (h is for IDE/EIDE, s is for SCSI). The second letter is d for disk, the third letter is for the sequential disk controller starting with “a.” This means the first IDE drive would be hda, the next would be hdb, then hdc and hdd. The partitions are numbered starting from 1, but due to the DOS world, they may not be sequential, depending on how they were created. Under this rule, the partitions would be /dev/hda1, /dev/hda2, /dev/hda3, .../dev/hda16 for the first IDE drive, then /dev/hdb1.../dev/hda16 for the second drive, and so one

For SCSI drives, the name is sda for the first disk on the first controller. The partitions are /dev/sda1, /dev/sda2... /dev/sda15 (only 15 maximum partitions with SCSI, whereas IDE can have 16). The second disk on the same SCSI controller would be sdaa {1, 2, 15}, and so on. The second controller would have sdb{1-15} for the first disk, then sdba{1-15} for the second disk on the second controller, and so on. In RH 7.x, there are 2048 configured SCSI devices. The number of disks and partitions already configured depends on the version and distribution of Linux.

3.5 Install Options

The Red Hat Linux installation program has the ability to test the integrity of the installation media. It works with the CD, DVD, hard drive ISO, and NFS ISO installation methods. Red Hat recommends that you test all installation media before starting the installation process, and before reporting any installation-related bugs (many of the bugs reported are actually due to improperly-burned CDs). To use this test, type linux mediacheck at the boot: prompt.

While most present-day computers are able to start the installation process by booting directly from the first Red Hat Linux distribution CD, some hardware configurations require the use of a boot diskette. If your hardware requires a boot diskette, you should be aware of the following change.

Red Hat Linux 9 uses a different boot diskette layout than previous releases of Red Hat Linux. There is now a single boot diskette image file (bootdisk.img) that is used to boot all systems requiring a boot diskette.

If you are performing anything other than an installation from an IDE or USB device, you will be asked to insert a driver diskette created from one of the following image files:

- drvnet.img - For network installations - drvblock.img - For SCSI installations - pcmciadd.img - For PCMCIA installations

As with previous releases of Red Hat Linux, these image files can be found in the images directory on the first installation CD.

(15)

Linux Administration – Installation Page 15 of 167 Also in the images/ directory is the boot.iso file. This file is an ISO image that can be used to boot the Red Hat Linux installation program. It is a handy way to start network-based installations without having to use multiple diskettes. To use boot.iso, your computer must be able to boot from its CD-ROM drive, and its BIOS settings must be configured to do so. You must then burn boot.iso onto a recordable/rewriteable CD-ROM.

The rescue mode environment (accessed by booting with the "linux rescue" boot-time command) has been enhanced. Numerous requested utilities have been added, and there is now support for activating network interfaces. Commands needed for SCSI tape support are also available. Please test this environment and send us your feedback.

The Red Hat Linux installation program now detects existing Red Hat products on your system, and will prompt you to select the product you would like to upgrade. You will also have the option of performing a complete re-installation of the system instead of upgrading. Please report any problems you may experience with this new feature.

If the contents of your /etc/redhat-release file have been changed from the default, your Red Hat Linux installation may not be found when attempting an upgrade to Red Hat Linux 9.

You can relax some of the checks against this file by entering the following at the boot: prompt:

boot: linux upgradeany

Use the upgradeany option only if your existing Red Hat Linux installation was not detected.

isolinux is now used for booting the Red Hat Linux installation CD. If you have problems booting from the CD, you can write the images/bootdisk.img image to a diskette

During a graphical installation, you can now press SHIFT-Print Screen and a screenshot of the current installation screen will be taken. These are stored in the following directory:

/root/anaconda-screenshots/

The screenshots can be accessed once the newly-installed system is rebooted. The parted disk partition manipulation program has been upgraded to version 1.6.

Users of Red Hat Linux 6.2 that want to upgrade their system to Red Hat Linux 9 must first have all errata updates applied before starting the upgrade process. The most straightforward way to accomplish this is to use Red Hat Network. A Red Hat Linux 6.2 system that is not completely up-to-date will not upgrade successfully to Red Hat Linux 9.

Text mode installations using a serial terminal work best when the terminal supports UTF-8. Under UNIX and Linux, Kermit supports UTF-8. For Windows, Kermit '95 works well. Non-UTF-8 capable terminals will work as long as only English is used during installation. An enhanced serial display can be used by passing "utf8" as a boot-time option to the installation program. For example:

(16)

Linux Administration - Boot Loaders Page 16 of 167

www.wilshiresoft.com Wilshire Software Technologies Rev Dt: 15-Oct-08

4. Boot Loaders

Before Red Hat Linux can run, it must be loaded into memory by a special program called a boot loader. A boot loader usually exists on the system's primary hard drive (or other media device) and has the sole responsibility of loading the Linux kernel with its required files or (in some cases) other operating systems into memory.

4.1 Boot Loaders and System Architecture

Each architecture capable of running Red Hat Linux uses a different boot loader. For example, the Alpha architecture uses the aboot boot loader, while the Itanium architecture uses the ELILO boot loader.

GRUB

GNU Grand Unified Boot loader or GRUB is a program which enables the user to select which installed operating system or kernel to load at system boot time. It also allows the user to pass arguments to the kernel.

GRUB and the x86 Boot Process

This section discusses in more detail the specific role GRUB plays when booting an x86 system. For an look at the overall boot process.

GRUB loads itself into memory in the following stages:

The Stage 1 or primary boot loader is read into memory by the BIOS from the MBR. The primary boot loader exists on less than 512 bytes of disk space within the MBR and is capable of loading either the Stage 1.5 or Stage 2 boot loader.

The Stage 1.5 boot loader is read into memory by the Stage 1 boot loader, if necessary. Some hardware requires an intermediate step to get to the Stage 2 boot loader. This is sometimes true when the /boot partition is above the 1024 cylinder head of the hard drive or when using LBA mode. The Stage 1.5 boot loader is found either on the /boot partition or on a small part of the MBR and the /boot partition.

The Stage 2 or secondary boot loader is read into memory. The secondary boot loader displays the GRUB menu and command environment. This interface allows you to select which operating system or Linux kernel to boot, pass arguments to the kernel, or look at system parameters, such as available RAM. The secondary boot loader reads the operating system or kernel and initrd into memory. Once GRUB determines which operating system to start, it loads it into memory and transfers control of the machine to that operating system.

The boot method used to boot Red Hat Linux is called the direct loading method because the boot loader loads the operating system directly. There is no intermediary between the boot loader and the kernel.

The boot process used by other operating systems may differ. For example, Microsoft's DOS and Windows operating systems, as well as various other proprietary operating systems, are loaded using a chain loading boot method. Under this method, the MBR points to the first sector of the partition holding the operating system. There it finds the files necessary to actually boot that operating system. GRUB supports both direct and chain-loading boot methods, allowing it to boot almost any operating system.

Warning: During installation, the Microsoft's DOS and Windows installation program completely overwrites the

MBR, destroying any existing boot loader. If creating a dual-boot system, it is best to install the Microsoft operating system first.

4.1.1 Features of GRUB

GRUB contains a number of features that make it preferable to other boot loaders available for the x86 architecture. Below is a partial list of some of the more important features:

GRUB provides a true command-based, pre-OS environment on x86 machines. This affords the user maximum flexibility in loading operating systems with certain options or gathering information about the system. For years, many non-x86 architectures have employed pre-OS environments that allow system booting

(17)

Linux Administration - Boot Loaders Page 17 of 167 from a command line. While some command features are available with LILO and other x86 boot loaders, GRUB is more feature rich.

Important: GRUB supports Logical Block Addressing (LBA) mode. LBA places the addressing

conversion used to find files in the hard drive's firmware, and is used on many IDE and all SCSI hard devices. Before LBA, boot loaders could encounter the 1024-cylinder BIOS limitation, where the BIOS could not find a file after that cylinder head of the disk. LBA support allows GRUB to boot operating systems from partitions beyond the 1024-cylinder limit, so long as the system BIOS supports LBA mode. Most modern BIOS revisions support LBA mode.

GRUB can read ext2 partitions. This functionality allows GRUB to access its configuration file, /boot/grub/grub.conf, every time the system boots, eliminating the need for the user to write a new version of the first stage boot loader to MBR when configuration changes are made. The only time a user would need to reinstall GRUB on the MBR is if the physical location of the /boot partition is moved on the disk.

Installing GRUB

If GRUB was not installed during the Red Hat Linux installation process it can be installed afterward. Once installed, it automatically becomes the default boot loader. Before installing GRUB, make sure to use the latest GRUB package available or use the GRUB package from the Red Hat Linux installation CD-ROMs. For instructions on installing packages, see the chapter titled Package Management with RPM in the Red Hat

Linux Customization Guide.

Once the GRUB package is installed, open a root shell prompt and run the command /sbin/grubinstall < location>, where < location> is the location that the GRUB Stage 1 boot loader should be installed.

The following command installs GRUB to the MBR of the master IDE device on the primary IDE

bus: /sbin/grub-install /dev/had The next time the system boots, the GRUB graphical boot loader menu will appear before the kernel loads into memory.

GRUB Terminology

One of the most important things to understand before using GRUB is how the program refers to devices, such as hard drives and partitions. This information is particularly important when configuring GRUB to boot multiple operating systems.

Device Names

Suppose a system has more than one hard drive. The first hard drive of the system is called (hd0) by GRUB. The first partition on that drive is called (hd0,0), and the fifth partition on the second hard drive is called (hd1,4). In general, the naming convention for file systems when using GRUB breaks down in this way:

(<type-of-device><bios-device-number>, <partition-number>)

The parentheses and comma are very important to the device naming conventions. The

<type-of-device> refers to whether a hard disk (hd) or floppy disk (fd) is being specified. The <bios-device-number> is the number of the device according to the system's BIOS, starting

with 0. The primary IDE hard drive is numbered 0, while the secondary IDE hard drive is numbered 1. The ordering is roughly equivalent to the way the Linux kernel arranges the devices by letters, where the a in hda relates to 0, the b in hdb relates to 1, and so on.

Note: GRUB's numbering system for devices starts with 0, not 1. Failing to make this distinction is one of the

most common mistakes made by new GRUB users.

The <partition-number> relates to the number of a specific partition on a disk device. Like the

<bios-device-number>, the partition numbering starts at 0. While most partitions are specified by numbers, if a system uses BSD partitions, they are signified by letters, such as a or c.

GRUB uses the following rules when naming devices and partitions:

(18)

Linux Administration - Boot Loaders Page 18 of 167

www.wilshiresoft.com Wilshire Software Technologies Rev Dt: 15-Oct-08 To specify an entire device without respect to its partitions, leave off the comma and the partition number. This is important when telling GRUB to configure the MBR for a particular disk. For example, (hd0) specifies the MBR on the first device and (hd3) specifies the MBR on the fourth device.

If a system has multiple drive devices, it is very important to know the drive boot order set in the BIOS. This is rather simple to do if a system has only IDE or SCSI drives, but if there is a mix of devices, it can become confusing.

4.1.2 File Names and Blocklists

When typing commands to GRUB involving a file, such as a menu list to use when allowing the booting of multiple operating systems, it is necessary to include the file immediately after specifying the device and partition.

A sample file specification to an absolute file name is organized as follows:

(<type-of-device><bios-device-number>,<partition-number>) /path/to/file

Most of the time, a user will specify files by the directory path on that partition, plus the file name. It is also possible to specify files to GRUB that do not actually appear in the file system, such as a chain loader that appears in the first few blocks of a partition. To specify these files, you must provide a blocklist, which tells GRUB, block by block, where the file is located in the partition, since a file can be comprised of several different sets of blocks, there is a specific way to write blocklists. Each file's section location is described by an offset number of blocks and then a number of blocks from that offset point, and the sections are put together in a comma-delimited order.

The following is a sample blocklist:

0+50,100+25,200+1

This blocklist tells GRUB to use a file that starts at the first block on the partition and uses blocks 0 through 49,

99 through 124, and 199.

Knowing how to write blocklists is useful when using GRUB to load operating systems that use chain loading, such as Microsoft Windows. It is possible to leave off the offset number of blocks if starting at block 0. As an example, the chain loading file in the first partition of the first hard drive would have the following name:

(hd0,0)+1

The following shows the chainloader command with a similar blocklist designation at the GRUB command line after setting the correct device and partition as root:

chainloader +1

4.1.3 GRUB's Root File System

Some users are confused by the use of the term "root file system" with GRUB. It is important to remember that GRUB's root file system has nothing to do with the Linux root file system. The GRUB root file system is the root partition for a particular device. GRUB uses this information to mount the device and load files from it.

With Red Hat Linux, once GRUB has loaded its root partition (which equates to the /boot partition and contains the Linux kernel), the kernel command can be executed with the location of the kernel file as an option. Once the Linux kernel boots, it sets the root file system Linux users are familiar with. The original GRUB root file system and its mounts are forgotten; they only existed to boot the kernel file.

GRUB Interfaces

GRUB features three interfaces, which provide different levels of functionality. Each of these interfaces allows users to boot the Linux kernel or other operating systems.

The interfaces are as follows:

(19)

Linux Administration - Boot Loaders Page 19 of 167 If GRUB was automatically configured by the Red Hat Linux installation program, this is the interface shown by default. A menu of operating systems or kernels preconfigured with their own boot commands are displayed as a list, ordered by name. Use the arrow keys to select an option other than the default selection and press the [Enter] key to boot it. Alternatively, a timeout period is set, so that GRUB will start loading the default option. Press the [e] key to enter the entry editor interface or the [c] key to load a command line interface.

Menu Entry Editor Interface

To access the menu entry editor, press the [e] key from the boot loader menu. The GRUB commands for that entry are displayed here, and users may alter these command lines before booting the operating system by adding a command line ([o] inserts a new line after the current line and [O] inserts a new line before it), editing one ([e]), or deleting one ([d]).

After all changes are made, the [b] key executes the commands and boots the operating system. The [Esc] key discards any changes and reloads the standard menu interface. The [c] key loads the command line interface.

Command Line Interface

The command line interface is the most basic of the GRUB interfaces, but it is also the one that grants the most control. The command line makes it possible to type any relevant GRUB commands followed by the [Enter] key to execute them. This interface features some advanced shell-like features, including [Tab] key completion, based on context, and [Ctrl] key combinations when typing commands, such as [Ctrl]-[a] to move to the beginning of a line, and [Ctrl]-[e] to move to the end of a line. In addition, the arrow, [Home], [End], and [Delete] keys work as they do in the bash shell.

Order of the Interfaces

When GRUB loads its second stage boot loader, it first searches for its configuration file. Once found, it builds a menu list and displays the menu interface.

If the configuration file cannot be found, or if the configuration file is unreadable, GRUB loads the command line interface, allowing the user to type commands to complete the boot process.

If the configuration file is not valid, GRUB prints out the error and asks for input. This helps the user see precisely where the problem occurred. Pressing any key reloads the menu interface, where it is then possible to edit the menu option and correct the problem based on the error reported by GRUB. If the correction fails, GRUB reports an error and reloads the menu interface.

4.1.4 GRUB Commands

GRUB allows a number of useful commands in its command line interface. Some of the commands accept options after their name; these options should be separated from the command and other options on that line by space characters.

The following is a list useful commands:

boot - Boots the operating system or chain loader that has been previously specified and loaded.

chainloader <file-name> - Loads the specified file as a chain loader. To grab the file at the first sector of the specified partition, use +1 as the file's name.

displaymem - Displays the current use of memory, based on information from the BIOS. This is useful to determine how much RAM a system has prior to booting it.

initrd <file-name> - Enables users to specify an initial RAM disk to use when booting. An initrd is necessary when the kernel needs certain modules in order to boot properly, such as when the root partition is formatted with the ext3 file system.

install <stage-1> <install-disk> <stage-2> p <config-file> - Installs GRUB to the system MBR.

(20)

Linux Administration - Boot Loaders Page 20 of 167

www.wilshiresoft.com Wilshire Software Technologies Rev Dt: 15-Oct-08

<stage-1> - Signifies a device, partition, and file where the first boot loader image can be found, such as (hd0,0)/grub/stage1.

<install-disk> - Specifies the disk where the stage 1 boot loader should be installed, such as (hd0).

<stage-2> -Passes to the stage 1 boot loader the location of the stage 2 boot loader is located, such as (hd0,0)/grub/stage2.

p <config-file> - This option tells the install command to look for the menu configuration file specified by <config-file>. An example of a valid path to the configuration file is

(hd0,0)/grub/grub.conf.

Warning: The install command will overwrite any other information in the MBR. If executed, any information

(other than GRUB information) that is used to boot other operating systems, will be lost.

kernel <kernel-file-name> <option-1> <option-N> - Specifies the kernel file to load from GRUB's root file system when using direct loading to boot the operating system. Options can follow the kernel command and will be passed to the kernel when it is loaded.

For Red Hat Linux, an example kernel command looks like the following:

kernel /vmlinuz root=/dev/hda5

This line specifies that the vmlinuz file is loaded from GRUB's root file system, such as (hd0,0). An option is also passed to the kernel specifying that when loading the root file system for the Linux kernel, it should be on hda5, the fifth partition on the first IDE hard drive. Multiple options may be placed after this option, if needed.

root <device-and-partition> - Configures GRUB's root partition to be a specific device and partition, such as (hd0,0), and mounts the partition so that files can be read.

rootnoverify <device-and-partition> - Performs the same functions as the root command but does not mount the partition.

Commands other than these are available. Type info grub for a full list of commands.

4.1.5 GRUB Menu Configuration File

The configuration file (/boot/grub/grub.conf), which is used to create the list of operating systems to boot in GRUB's menu interface, essentially allows the user to select a pre-set group of commands to execute.

Special Configuration File Commands

The following commands can only be used in the GRUB menu configuration file:

color <normal-color> <selected-color> - Allows specific colors to be used in the menu, where two colors are configured as the foreground and background. Use simple color names, such as red/black. For example:

color red/black green/blue

default <title-name> - The default entry title name that will be loaded if the menu interface times out.

fallback <title-name> - If used, the entry title name to try if first attempt fails.

hiddenmenu - If used, prevents the GRUB menu interface from being displayed, loading the default entry when the timeout period expires. The user can see the standard GRUB menu by pressing the [Esc] key.

password <password> - If used, prevents a user who does not know the password from editing the entries for this menu option.

Optionally, it is possible to specify an alternate menu configuration file after the password <password> command. In this case, GRUB will restart the second stage boot loader and use the specified alternate configuration file to build the menu. If an alternate menu configuration file is left out of the command, then a user who knows the password is allowed to edit the current configuration file.

timeout - If used, sets the interval, in seconds, before GRUB loads the entry designated by the default command.

References

Related documents

Enable Boot Devices UEFI Hard Drive - Allows the user to select Enable boot devices detected by the system.. UEFI

All their customers numbered in the scaling of class c subnet address tells how is cidr also to as which hosts need this range of?. Kiselev VY, Kirschner K, Schaub MT, Andrews T, Yiu

The panel dismissed Covidien’s petitions because it determined that “Pa- tent Owner UFRF, as an arm of the State of Florida, [was] entitled to a sover- eign immunity defense to

Around the age of 50 when people develop presbyopia, difficulty reading at close distances, Horizon Laser Vision Center can offer the KAMRA VisionTM procedure to correct their

This specification identifies the requirements and standards for the development and production of Maintenance Requirement Cards (MRCs), Maintenance Index Pages (MIPs), and other

The 128MB NAND Flash memory of M-506 contains Boot loader (uBoot), Linux Kernel, Root File System and user disk (\home).. The file system and disk space are shown as follow

The respondents reported being able to make direct referral’s to a wide range of disciplines, Typically, (as far as children under 16 years are concerned), PHNs can

Patients were excluded if they: were of childbearing potential (unless practicing acceptable birth control methods); had a history of life-threatening asthma within the last 5