Product Cover Image

UNIX and Linux System Administration Handbook, CourseSmart eTextbook, 4th Edition

By Evi Nemeth, Garth Snyder, Trent R. Hein, Ben Whaley

Published by Prentice Hall

Published Date: Jul 14, 2010

Description

The twentieth anniversary edition of the world’s best-selling UNIX system administration book has been made even more invaluable by adding coverage of the leading Linux distributions: Ubuntu, RHEL, and openSUSE. This book approaches system administration in a practical way and is an invaluable reference for both new administrators and experienced professionals. It details best practices for every facet of system administration, including storage management, network design and administration, email, web hosting, scripting, software configuration management, performance analysis, Windows interoperability, virtualization, DNS, security, management of IT service organizations, and much more. UNIX® and Linux® System Administration Handbook, Fourth Edition, reflects the current versions of these operating systems: Ubuntu® Linux, openSUSE® Linux, Red Hat® Enterprise Linux®, Oracle America® Solaris™ (formerly Sun Solaris), HP HP-UX®, and IBM AIX®.

Table of Contents

Foreword xlii

Preface xliv

Acknowledgments xlvi

 

Section One: Basic Administration

 

Chapter 1: Where to Start 3

Essential duties of the system administrator 4

Suggested background 6

Friction between UNIX and Linux 7

Linux distributions 9

Example systems used in this book 10

System-specific administration tools 13

Notation and typographical conventions 13

Units 14

Man pages and other on-line documentation 16

Other authoritative documentation 18

Other sources of information 20

Ways to find and install software 21

System administration under duress 26

Recommended reading 27

Exercises 28

 

Chapter 2: Scripting and the Shell 29

Shell basics 30

bash scripting  37

Regular expressions 48

Perl programming 54

Python scripting 66

Scripting best practices 73

Recommended reading 74

Exercises 76

 

Chapter 3: Booting and Shutting Down 77

Bootstrapping 78

Booting PCs 82

GRUB: The GRand Unified Boot loader 83

Booting to single-user mode 86

Working with startup scripts 87

Booting Solaris 97

Rebooting and shutting down 100

Exercises 102

 

Chapter 4: Access Control and Rootly Powers 103

Traditional UNIX access control 104

Modern access control 106

Real-world access control 110

Pseudo-users other than root 118

Exercises 119

 

Chapter 5: Controlling Processes 120

Components of a process 120

The life cycle of a process 123

Signals 124

kill: send signals 127

Process states 128

nice and renice: influence scheduling priority 129

ps: monitor processes 130

Dynamic monitoring with top, prstat, and topas  133

The /proc filesystem 135

strace, truss, and tusc: trace signals and system calls 136

Runaway processes 138

Recommended reading 139

Exercises 139

 

Chapter 6: The Filesystem 140

Pathnames 142

Filesystem mounting and unmounting 143

The organization of the file tree 145

File types 147

File attributes 152

Access control lists 159

Exercises 173

 

Chapter 7: Adding New Users 174

The /etc/passwd file 176

The /etc/shadow and /etc/security/passwd files 183

The /etc/group file 186

Adding users: the basic steps 187

Adding users with useradd 191

Adding users in bulk with newusers (Linux) 197

Removing users 198

Disabling logins 200

Managing users with system-specific tools 201

Reducing risk with PAM 201

Centralizing account management 201

Recommended reading 204

Exercises 205

 

Chapter 8: Storage 206

I just want to add a disk! 207

Storage hardware 209

Storage hardware interfaces 213

Peeling the onion: the software side of storage 220

Attachment and low-level management of drives 223

Disk partitioning 231

RAID: redundant arrays of inexpensive disks 237

Logical volume management 246

Filesystems 254

ZFS: all your storage problems solved 264

Storage area networking 274

Exercises 281

 

Chapter 9: Periodic Processes 283

cron: schedule commands 283

The format of crontab files 284

Crontab management 286

Linux and Vixie-cron extensions 287

Some common uses for cron 288

Exercises 291

 

Chapter 10: Backups 292

Motherhood and apple pie 293

Backup devices and media 299

Saving space and time with incremental backups 305

Setting up a backup regime with dump 307

Dumping and restoring for upgrades 314

Using other archiving programs 315

Using multiple files on a single tape 317

Bacula 318

Commercial backup products 335

Recommended reading 337

Exercises 337

 

Chapter 11: Syslog and Log Files 340

Finding log files 341

Syslog: the system event logger 344

AIX logging and error handling 353

logrotate: manage log files 356

Condensing log files to useful information 358

Logging policies 359

Exercises 361

 

Chapter 12: Software Installation and Management 362

Installing Linux and OpenSolaris 363

Installing Solaris 370

Installing HP-UX 377

Installing AIX with the Network Installation Manager 380

Managing packages 381

Managing Linux packages 382

Using high-level Linux package management systems 384

Managing packages for UNIX 393

Revision control 397

Software localization and configuration 404

Using configuration management tools 408

Sharing software over NFS 411

Recommended reading 413

Exercises 414

 

Chapter 13: Drivers and the Kernel 415

Kernel adaptation 416

Drivers and device files 417

Linux kernel configuration 421

Solaris kernel configuration 427

HP-UX kernel configuration 431

Management of the AIX kernel 432

Loadable kernel modules 434

Linux udev for fun and profit 437

Recommended reading 443

Exercises 444

 

Section Two: Networking

 

Chapter 14: TCP/IP Networking 447

TCP/IP and its relationship to the Internet 447

Networking road map 450

Packet addressing 454

IP addresses: the gory details 457

Routing 465

ARP: the Address Resolution Protocol 468

DHCP: the Dynamic Host Configuration Protocol 469

Security issues 472

PPP: the Point-to-Point Protocol 476

Basic network configuration 476

System-specific network configuration 484

Linux networking 484

Solaris networking 494

HP-UX networking 501

AIX networking 506

Recommended reading 508

Exercises 509

 

Chapter 15: Routing 511

Packet forwarding: a closer look 512

Routing daemons and routing protocols 515

Protocols on parade 518

Routing strategy selection criteria 521

Routing daemons 522

Cisco routers 525

Recommended reading 528

Exercises 530

 

Chapter 16: Network Hardware 531

Ethernet: the Swiss Army knife of networking 532

Wireless: ethernet for nomads 541

DSL and cable modems: the last mile 543

Network testing and debugging 544

Building wiring 545

Network design issues 547

Management issues 549

Recommended vendors 550

Recommended reading 550

Exercises 551

 

Chapter 17: DNS: The Domain Name System 552

Who needs DNS? 554

How DNS works 555

DNS for the impatient 558

Name servers 563

The DNS namespace 566

Designing your DNS environment 568

What’s new in DNS 572

The DNS database 574

The BIND software 597

BIND configuration examples 618

The NSD/Unbound software 625

Updating zone files 638

Security issues 642

Microsoft and DNS 667

Testing and debugging 667

Vendor specifics 681

Recommended reading 686

Exercises 688

 

Chapter 18: The Network File System 690

Introduction to network file services 690

The NFS approach 692

Server-side NFS 698

Client-side NFS 706

Identity mapping for NFS version 4 709

nfsstat: dump NFS statistics 710

Dedicated NFS file servers 711

Automatic mounting 711

Recommended reading 717

Exercises 718

 

Chapter 19: Sharing System Files 719

What to share 720

Copying files around 721

LDAP: the Lightweight Directory Access Protocol 728

NIS: the Network Information Service 736

Prioritizing sources of administrative information 739

Recommended reading 741

Exercises 741

 

Chapter 20: Electronic Mail 742

Mail systems 744

The anatomy of a mail message 748

The SMTP protocol 750

Mail system design 753

Mail aliases 756

Content scanning: spam and malware 761

Email configuration 774

sendmail 775

sendmail configuration 778

sendmail configuration primitives  782

Security and sendmail 795

sendmail performance 802

sendmail testing and debugging 805

Exim 807

Postfix 828

DKIM Configuration 845

Integrated email solutions 853

Recommended reading 854

Exercises 855

 

Chapter 21: Network Management and Debugging 859

Network troubleshooting 860

ping: check to see if a host is alive 861

SmokePing: gather ping statistics over time 864

traceroute: trace IP packets 865

netstat: get network statistics 868

Inspection of live interface activity 873

Packet sniffers 874

The ICSI Netalyzr 878

Network management protocols 879

SNMP: the Simple Network Management Protocol 880

The NET-SNMP agent 883

Network management applications 884

NetFlow: connection-oriented monitoring 890

Recommended reading 893

Exercises 894

 

Chapter 22: Security 896

Is UNIX secure? 897

How security is compromised 898

Security tips and philosophy 901

Passwords and user accounts 906

PAM: cooking spray or authentication wonder? 908

Setuid programs 912

Effective use of chroot 913

Security power tools 914

Mandatory Access Control (MAC) 922

Cryptographic security tools 924

Firewalls 932

Linux firewall features 935

IPFilter for UNIX systems 939

Virtual private networks (VPNs) 942

Certifications and standards 944

Sources of security information 947

What to do when your site has been attacked 950

Recommended reading 952

Exercises 954

 

Chapter 23: Web Hosting 956

Web hosting basics 957

HTTP server installation 963

Virtual interfaces 967

The Secure Sockets Layer (SSL) 971

Caching and proxy servers 974

Scaling beyond your limits 977

Exercises 979

 

Section Three: Bunch O’ Stuff

Chapter 24: Virtualization 983

Virtual vernacular 984

Benefits of virtualization 988

A practical approach 989

Virtualization with Linux 991

Solaris zones and containers 997

AIX workload partitions 1001

Integrity Virtual Machines in HP-UX 1003

VMware: an operating system in its own right 1005

Amazon Web Services 1005

Recommended reading 1010

Exercises 1010

 

Chapter 25: The X Window System 1011

The display manager 1013

Process for running an X application 1014

X server configuration 1019

X server troubleshooting and debugging 1026

A brief note on desktop environments 1028

Recommended reading 1030

Exercises 1031

 

Chapter 26: Printing 1032

Printing-system architecture 1033

CUPS printing 1034

Printing from desktop environments 1043

System V printing 1045

BSD and AIX printing 1054

What a long, strange trip it’s been 1065

Common printing software 1067

Printer languages 1068

PPD files 1072

Paper sizes 1073

Printer practicalities 1075

Troubleshooting tips 1081

Recommended reading 1083

Exercises 1084

 

Chapter 27: Data Center Basics 1085

Data center reliability tiers 1086

Cooling 1087

Power 1091

Racks 1094

Tools 1095

Recommended reading 1095

Exercises 1096

 

Chapter 28: Green IT 1097

Green IT initiation 1098

The green IT eco-pyramid 1099

Green IT strategies: data center 1100

Green IT strategies: user workspace 1108

Green IT friends 1110

Exercises 1111

 

Chapter 29: Performance Analysis 1112

What you can do to improve performance 1114

Factors that affect performance 1115

How to analyze performance problems 1117

System performance checkup 1118

Help! My system just got really slow! 1131

Recommended reading 1133

Exercises 1134

 

Chapter 30: Cooperating with Windows 1135

Logging in to a UNIX system from Windows 1135

Accessing remote desktops 1136

Running Windows and Windows-like applications 1139

Using command-line tools with Windows 1140

Windows compliance with email and web standards 1141

Sharing files with Samba and CIFS 1142

Sharing printers with Samba 1149

Debugging Samba 1152

Active Directory authentication 1154

Recommended reading 1160

Exercises 1161

 

Chapter 31: Serial Devices and Terminals 1162

The RS-232C standard 1163

Alternative connectors 1165

Hard and soft carrier 1167

Hardware flow control 1168

Serial device files 1168

setserial: set serial port parameters under Linux 1169

Pseudo-terminals 1170

Configuration of terminals 1171

Special characters and the terminal driver 1177

stty: set terminal options 1178

tset: set options automatically 1178

Terminal unwedging 1179

Debugging a serial line 1180

Connecting to serial device consoles 1180

Exercises 1182

 

Chapter 32: Management, Policy, and Politics 1183

The purpose of IT 1184

The structure of an IT organization 1190

The help desk 1196

The enterprise architects 1197

The operations group 1199

Management 1206

Policies and procedures 1215

Disaster recovery 1217

Compliance: regulations and standards 1222

Legal issues 1226

Organizations, conferences, and other resources 1229

Recommended Reading 1231

Exercises 1231

 

Index 1233

A Brief History of System Administration 1264

In Defense of AIX 1274

Colophon 1277

About the Contributors 1278

About the Authors 1279

Purchase Info ?

With CourseSmart eTextbooks and eResources, you save up to 60% off the price of new print textbooks, and can switch between studying online or offline to suit your needs.

Once you have purchased your eTextbooks and added them to your CourseSmart bookshelf, you can access them anytime, anywhere.

Buy Access

UNIX and Linux System Administration Handbook, CourseSmart eTextbook, 4th Edition
Format: Safari Book

$37.49 | ISBN-13: 978-0-13-336640-2