home | O'Reilly's CD bookshelfs | FreeBSD | Linux | Cisco | Cisco Exam    

Book Home Perl for System AdministrationSearch this book

Preface

Perl is a powerful programming language that grew out of the traditional system administration toolbox. Over the years it has adapted and expanded to meet the challenges of new operating systems and new tasks. Until now, however, no book has recognized this deep history by concentrating solely on using Perl for system administration.

If you know a little Perl, and you need to perform system administration tasks, this is the right book for you. Readers with varying levels of both Perl programming experience and system administration experience will all find something of use within these pages.

0.1. How This Book Is Structured

Each chapter in this book addresses a different system administration domain and ends with a list of the Perl modules used in that chapter and references to facilitate deeper exploration of the information presented. The chapters are as follows:

Chapter 1, "Introduction"

The introduction describes the material covered by the book in more detail, how it will serve you, and what you need to get the most from it. The material in this book is powerful and meant to be used by powerful people (e.g., Unix superusers and NT/2000 administrators). The introduction provides some important guidelines to help you write more secure Perl programs.

Chapter 2, "Filesystems"

This chapter is about keeping multiplatform filesystems tidy and properly used. We start by looking at the salient differences between the native filesystems for each operating system. We then explore the process of walking or traversing filesystems from Perl and how that can be useful. Finally, we look at manipulating disk quotas from Perl.

Chapter 3, "User Accounts"

This chapter discusses how these user accounts manifest themselves on two different operating systems. The crux of this chapter is a rudimentary account system written in Perl. In the process of building this system, we examine the mechanisms necessary for recording accounts in a simple XML-based database, creating these accounts, and deleting them.

Chapter 4, "User Activity"

Chapter 4, "User Activity" explores different process control mechanisms for all three operating systems. These range from the simple (e.g., MacOS processes) to the more complex (e.g., WinNT/2000 Windows Management Instrumentation). We put these mechanisms to work with administration helper scripts. Finally, we look at how to track file and network operations from Perl.

Chapter 5, "TCP/IP Name Services"

Name services allow hosts on a TCP/IP network to communicate with each other amicably. This chapter takes a historical perspective by starting with host files, moving to Network Information Service, and finally to the glue of the Internet, Domain Name Service. Each step of the way we show how Perl can make professional management of these services easier.

Chapter 6, "Directory Services"

As the complexity of the information we deal with increases over time, so does the importance of the directory services we use to access this information. System administrators are increasingly being called upon to not only use these services, but to build tools for their management. This chapter discusses some of the more popular directory service frameworks such as LDAP and ADSI, and shows you how to work with them from Perl.

Chapter 7, "SQL Database Administration"

Over time, more uses for relational databases are being found in the system administration realm. As a result, system administrators need to become familiar with SQL database administration. This chapter explains two SQL database frameworks, DBI and ODBC, and provides examples of them in action.

Chapter 8, "Electronic Mail"

This chapter demonstrates how Perl can make better use of email as a system administration tool. After discussing the basics of sending and parsing email via Perl, we look at several interesting applications, including Unsolicited Commercial Email (a.k.a. spam) analysis and managing tech support email.

Chapter 9, "Log Files"

System administrators are often awash in a sea of log files. Every machine, operating system, and program can (and often does) log information. This chapter looks at the logging systems offered by Unix and NT/2000. We discuss approaches for analyzing all of this information so it can work for you.

Chapter 10, "Security and Network Monitoring"

The final chapter heads right into the maelstrom called "security." We demonstrate how Perl can make hosts and networks more secure. In addition, we discuss several network monitoring techniques, including use of the Simple Network Management Protocol (SNMP) and network sniffing.

Appendixes

Some of the chapters assume some basic knowledge about a topic that you may not already have. For those who are new to these topics, this book includes several mini-tutorials to bring you up to speed quickly. These include introductions to the Revision Control System (RCS), Lightweight Directory Access Protocol (LDAP), Structured Query Language (SQL), eXstensible Markup Language (XML), and the Simple Network Management Protocol (SNMP).



Library Navigation Links

Copyright © 2001 O'Reilly & Associates. All rights reserved.











??????????????@Mail.ru