Linux System Administration: A User's Guide

Marcel Gagné

  • 出版商: Addison-Wesley Professional
  • 出版日期: 2001-09-28
  • 定價: USD $59.99
  • 售價: $990
  • 語言: 英文
  • 頁數: 560
  • 裝訂: Paperback
  • ISBN: 0201719347
  • ISBN-13: 9780201719345

立即出貨 (庫存 < 4)

買這商品的人也買了...

產品描述

"Gagne is clearly an insider in the Linux community, familiar with both the technical details and the culture, which sets this book apart from others in the field."

--Joseph Sloan, Lead System Administrator, Mirai Consulting

This comprehensive, hands-on guide to Linux system administration provides you with the deeper understanding of the inner workings of Linux and the pragmatic techniques you need to become an outstanding Linux system administrator--whether you are a career administrator in a corporate environment or simply administering your home system.

Written both for those who are new to Linux and those who are already proficient and wish to hone their skills, Linux System Administration starts with the basics and builds up to more sophisticated material.

You will find complete coverage of all major system administration topics:

  • Linux versus UNIX
  • Installation tips and tricks
  • Working effectively with the Linux command line
  • Organizing and working with system users
  • Disks, file systems, backup, and restore
  • The inner workings of X and the graphical desktop
  • Configuring and using scanners, CD-Recordables, and other devices
  • Internet connectivity
  • Finding, building, and installing software
  • Kernel building and renovation
  • Scripting and automation
  • Network administration, electronic mail, and Web services
  • Integrating Windows with Linux
  • System logs and accounting
  • Security and firewalls
  • Performance monitoring and tuning

Using standard Linux tools (PostgreSQL, Apache, Perl, and more) this book will help you deploy a feature-rich corporate intranet featuring online discussion groups, bulletin boards, a company phone directory, and a document center. You will also learn everything you need to know to install a complete electronic mail and Internet gateway solution for your home or office on a single, shared connection. In addition, numerous anecdotes from the trenches, examples of techniques to try, and plenty of experience-based advice bring important concepts to life.

Written with good humor and enthusiasm for the profession of system administration, as well as a deep appreciation for the power and flexibility of Linux, Linux System Administration will teach you the tricks of the trade, guide your efforts, and serve as a definitive and comprehensive reference.

Table of Contents

Acknowledgments.
1. Introduction.

What Is Linux?
Why Linux?

The System Administrator's Job.
About This Book.
The Command Line Rules!
GUIs Rule!
Flexibility.
Is There Anything You Can't Do with Linux?
Regrets, I've Had a Few....
Resources.


2. Linux versus Linux versus UNIX.

The UNIX Question.
The Windows Question
A Question of Distribution.
So Which Linux Distribution Should You Choose?
Red Hat Linux.
SuSE.
Caldera.
Mandrake.
Slackware.
Debian.
Turbolinux.

Getting Linux.
Getting Others to Try Linux.
Sharing Space with Windows.
How about No Disk Space At All?

A Changing Landscape.
Resources.


3. Help (and the Truth) Is Out There.

Documentation and Man Pages
What If You Don't Know the Command Name?
Show Me the PATH, man!
Graphical Man Pages.

info (the Command, That Is).
HOWTOs and Distributed DOCs
The Linux Documentation Project
Linux User Groups.
Usenet News.
Resources.


4. Linux System Installation.

Getting Ready for Your Installation.
Hardware Considerations.
Passing Boot Options
Dual Booting.
The 12 (13, 14, 15...) Steps to Any Installation.
Step 1: Booting.
Step 2: Selecting the Installation Type.
Step 3: Selecting a Language (Parlez-vous Francais?).
Step 4: Choosing a Keyboard Type.
Step 5: Selecting Your Mouse.
Step 6: Selecting a Time Zone.
Step 7: Creating a Partition
Step 8: Formatting the Partitions.
Step 9: To LILO or Not to LILO.
Step 10: Choosing and Installing Software Packages.
Step 11: Configuring the Network.
Step 12: Identifying Yourself.
Step 13: The Dreaded X Window Configuration.
Step 14: The Boot Disk Question.

The (Emergency) Boot Disk.
Starting Linux.
Shutting Down Linux.
Resources.


5. Taking Command of Linux.

Linux Commands: Love at First Sight.
Working with Files.
File Naming Conventions.
Listing Files with Emotion!
File Permissions: A First Look
Making Your Life Easier with alias

Standard Input and Standard Output
Piping
tee: A Very Special Pipe.
STDERR
The Road to Nowhere

Linux Commands: Working with Directories.
There's No Place Like $HOME
More on File Permissions
User and Group Ownership.
Who Can Do What?
Who Was That Masked User?
The setuid Bit

File Attributes
Finding Anything
grep’ping for Dollars (or Anything Else for That Matter) and Piping.
Processes.
Forests and Trees.
Interrupting, Suspending, and Restarting Processes.

Killing Processes.
“I Am vi, the Great and Powerful”
:q, :w, :wq, and ZZ
Recovering a VIM Session
Power vi: Start-up Options.

Pico: A kinder, gentler editor.
Emacs
Resources.


6. Daemons and Runlevels.

Daemons and Other Not-So-Scary Things.
The inittab File.
The rc.local File and Runlevels.
Switching between Runlevels
The chkconfig Command.

Runlevels the Graphical Way.
The (Not) Last Word.
Resources.


7. Users and Groups.

Living in a Multiuser World.
When Not to Use the root User.
Managing Users
Managing Groups
Adding Groups.
Modifying Groups.
Removing Groups.

Adding Users
About Home Directories.
Group Participation.
E-mail-Only Accounts
Yet More User-Creation Controls.

Modifying a User Account.
Deleting a User Account
Checking the Password File
User and Group Administration the GUI Way.
Choosing Good Passwords
How Crackers Crack Your Passwords.
Choosing Better Passwords.

What Next?
I Logged In from Where?
How Not to Be a “Sucker” .
Resources.


8. Disks and File Systems.

Everything Is a File.
Understanding Your File Systems.
The File System Tree.
The Root File System (aka /, or Slash).
The /usr File System.

The /var File System
The /tmp File System
The /proc File System
The /lost+found File System.
fsck: The File System Check and Repair Tool.
Bad Superblock?

How Much Space Have I Got Again?
What's This about Inodes?
Mounting and Unmounting File Systems.
Creating File Systems.
Using the New File System.

Working with Quotas
Getting Ready for Quotas.
Turning Quotas On and Off
Setting Limits.
Back to Grace
Letting the Users Know.

Resources.


9. X and the Graphical Desktop.

It's Just Window Dressing, Right?
Graphical Login Managers
Working without a Graphical Login Manager.

The World beneath the Surface.
The xinitrc File.
The .xserverrc File
The Xresources File
Specifying Resources on the Command Line.

Look, Ma! I Can Run Multiple Desktops!
Backing Up and Restoring the Desktop
Running X Applications Remotely
Choosing a Window Manager
The Tab Window Manager (twm).
Window Maker.
KDE.
GNOME.
Qvwm.
Tweaking X and Dealing with Problems.
Key Mapping.
Tuning Video Modes with xvidtune.
The “Messed Up” X Session.

Screen Captures
Resources


10. Dialing Up to the Internet with PPP.

The Basics.
What You Need from Your ISP.
Where the Information Goes

The Graphical Alternative.
Automagic PPP Connections.
eznet.
wvdial.

Resources.


11. Finding, Building, and Installing Software.

Finding Software and Software Review Sites.
Freshmeat.
TUCOWS Linux.
SourceForge.
Rpmfind
Ibiblio.org.

Installing and Building Software.
Compiling from Source.
Step 1: Unpacking the Archive.
Step 2: Building Your Programs.

Downloading and Installing Perl Modules.
Package Managers.
Updating or Installing Packages on a Debian System.
Great, but Can You Tell Me What Is Already There?
Finding Out a Package's Current Release Level
What Is That Strange File?
Using apt-get to Install or Update Software.
Educating apt-get.
Graphical Alternatives.

Red Hat Package Manager.
Installing an RPM Package.
Upgrading an RPM Package.
Uninstalling an RPM Package.
Everything You Ever Wanted to Know about an RPM Package, but Were Afraid to Ask.
RPM: The Graphical Alternatives.

installpkg: Slackware's Lonely Child.
Resources.


12. Kernel Building and Renovation.

What Is This Kernel, Anyhow?
When Should I Rebuild My Kernel?
Downloading and Building a New Kernel.
Automatic Build and Install
What about the 2.4 Kernel?
Resources.


13. Printers and Printing.

Selecting Printers for Linux (and a Note about “WinPrinters” )
How Printing Works.
Filters.
HP JetDirect Adaptors.
Printer Job Control.
Printing Anything to Any Printer.
Tying It Up: Advanced Filters with Ghostscript.
Why PostScript?
A Few PostScript Tricks.
Alternative Print Systems.
PDQ.
CUPS.
Miscellaneous Tips and Tricks.
Resources.


14. Scripting and Scripting Languages.

Shells As Far As the Eye Can See.
It's Commands All the Way Down.
Passing Parameters.
A First Look at Variables.
More on Variables
Special Characters.
Really Programming the Shell.

Specifying the Shell.
Perl.
Perl in Action: A Script for Monitoring Disk Space.

Other Languages Worthy of Consideration.
Resources.


15. Simplified Administration through Automation.

Constructive Laziness.
cron: Punching Linux's Clock.
Testing Your Job.
Editing the crontab.

Could I See an Example?
Running Jobs with at
A Question of Permissions.
Other Tools for Automation.
Automatic Downloads: ncftp.
Automatic Web Fetch: wget.
Scripting for Interactive Sessions: expect.
Automating Interactive Automation.
Resources.


16. Devices, Devices, and More Devices.

Creating Device Definitions.
Major Minor

SCSI versus IDE
Why Choose One over the Other?

CD-ROMs and CD-RWs
The Graphical Way to Burn

Scanners
Back Ends.
Front Ends.
XSane

Tape Drives.
Other Tape Formats.

Miscellaneous Devices.
Resources.


17. Backups and Restores.

The Need for Backups
Basic Tools in Every Linux System.
Using cpio.
Working with tar
Backing Up Windows Workstations.
Selecting a Backup Medium.
Backing Up with dump
Restoring with (You Guessed It) restore.

Identity Backups.
Backing Up to a CD-RW
Backups the Graphical Way.
Taper: A Text-Based Backup Utility.
Kdat: Graphical and Free

Commercial Solutions.
BRU
Arkeia

Other Considerations.
Final Words
Resources.


18. Network Administration.

The Light-Speed Introduction to TCP/IP (Act 18, Scene 1).
Protocols and Suites.

Services and Ports
IP Addresses, Networks, and Subnets, Oh My!
What Are Domains?
IP Addresses and Networks
Subnets, Netmasks, and Broadcast Addresses.

Intermezzo
Setting Up Your PC Network (Act 18, Scene 2).
Drivers
Setting the IP Address.
Routing
Using netstat

Domain Name Services (Act 18, Scene 3).
The /etc/hosts File

Will the Real DNS Please Stand Up.
Setting Up Your Own Name Server.
Defining Your Domain
The /etc/named.conf File.
Listing of /etc/named.conf.
Zones
Your Own Zone File
And Now the Reverse DNS Zone.
Does It Work?
What's All This about “Lame Servers” ?
Who Gets to See the Information?
DNS Wrap-up

File Sharing Under Linux (Act 18, Scene 4).
Network File System.
How Does NFS Work?
Making a Remote File System Available.
Mounting an NFS Partition
Specifying Mounts with /etc/fstab

Simplifying Network Mounts with Linux autofs.
Network Information Service (Act 18, Scene 5).
Configuring the NIS Master Server.
Configuring the NIS Client.
The /etc/nsswitch.conf File.

Miscellaneous Network Tricks: Time Synchronization.
rdate.
NTP.

Wait! What about the GUIs?
Resources.


19. Tools, Tools, and More Tools.

The Web Browser Angle.
Linuxconf.

Webmin
Graphical Administration Tools.
Tiny but Powerful Tools.
Go-Anywhere Linux
tomsrtbt.
Trinux.

The Tiny Conclusion.
There's No Control Like Remote Control.
Resources.


20. Proof of Concept, Part 1.

Of Web Servers and Intranets
Building Your Own Corporate Portal.
Building Apache from Source.
Basic Apache Configuration.
Common Changes

The Basics of Web-Connected Databases.
An Introduction to PostgreSQL.
Perl DBI and DBD for Database Access.
Downloading and Installing the Modules.

The CGI Back End
The Face of the Intranet
Protecting Certain Pages.

Resources


21. Proof of Concept, Part 2.

The Connected Office, Linux Style
What to Look for in an ISP.
Setting Up Your ISP Dial-up Connection with diald.
Automatic Remote Mail Pickup with fetchmail
IP Forwarding and Masquerading.
DNS Revisited.
Putting It All Together.
Basic Firewall Services.
Setting Up the Mail Server with Linux.
Defining the Network.
The Components

Setting Up the POP3 Server.
Setting Up sendmail.
Stopping and Restarting sendmail.
Your DNS Setup.

Setting Up Users and Aliases.
Setting Up Your Client MUAs.
Let’s Send Some Mail

Not-So-Stupid sendmail Tricks
The Multiple Domain, Similar Address Dilemma.
The Multidrop Domain.

Stop the Spam!
Resources.


22. Integrating Windows with Linux.

An Introduction to Samba.
Getting and Building Samba.
A Note on Passwords.
Configuring the Server.
The PC Side
Printing with Samba
Printing from the Windows Client.

The GUI Way to Administer Samba.
Backing Up Windows Workstations.
Running Windows on Linux.
Wine
VMware
Win4Lin.

Resources.


23. System Logs and Accounting.

Your System Logs.
Looking at Your Log Files.
What the Names Mean
Cleaning Up and What the Numbers Mean.
syslogd: The Master Logger.
Back to the logger Program.
Automating the Log-Checking Process.
Logcheck.
Web Site Log Analysis.
Analog
The Webalizer.

Resources.


24. Secure Computing.

A Brief History of Encryption.
Personal Encryption
An Introduction to the Secure Shell.
What Are Your Options?

OpenSSH.
Secure Sockets Layer.
OpenSSH (Right Back Where You Started).
Secure File Transfers.

PGP and GnuPG.
Graphical Front Ends to GnuPG.

Building Trust Relationships.
Encrypting Electronic Mail.

Building a Secure Web Server.
Building the SSL-Enabled Apache Server.
Resources.


25. Security: The Battle for Your System.

What Is a “Script Kiddie” ?
The Basics: Your TCP Wrappers.
What Your TCP Wrapper Is Telling You.
“Hey, My Logs Have Nothing in Them!”
Detecting the Cracker.
The Cracker's Not-So-Invisible Footsteps.
More Thoughts If You Have Been Cracked.
Port Scanners, Sniffers, and the Cracker's Tools.
Sniffers.
PortSentry: Active Intrusion Detection and Response.
ipchains and Firewalls.
Quick and Easy Firewall Solutions.
Locating the Cracker and Reporting Him or Her.
Keeping Up-to-Date.
Resources.


26. Performance Monitoring and Tuning.

The Search for the Holy Grail.
Monitoring and Analyzing Performance.
The uptime Command.
The top Command

Graphical tops.
The free Command
Working with vmstat
What about Good Ol' ps?

Performance Enhancing Tweaks.
/proc Revisited.
File System Tweaks.
Improving Disk Drive Performance.
Do-It-Yourself Benchmarks.
Resources.


Appendix A: The All-Linux Office?
Appendix B: The GNU General Public License.