Introduction to Unix: Ftp://Wks.Uts.Ohio-State.Edu/Unix Course/Unix Book.Ps And
Total Page:16
File Type:pdf, Size:1020Kb
UNIX System Administration Frank G. Fiamingo [email protected] University Technology Services The Ohio State University September 23, 1998 1991-1998 University Technology Services, The Ohio State University, Baker Systems Engineering Building, 1971 Neil Avenue, Columbus, OH 43210. All rights reserved. Redistribution and use, with or without modification, are permitted provided that the following conditions are met: 1. Redistributions must retain the above copyright notice, this list of conditions, and the following disclaimer. 2. Neither the name of the University nor the names of its contributors may be used to endorse or promote products or services derived from this document without specific prior written permission. THIS PUBLICATION IS PROVIDED "AS IS" WITHOUT WARRANTY OF ANY KIND. THIS PUBLICATION MAY INCLUDE TECHNICAL INACCURACIES OR TYPOGRAPHICAL ERRORS. UNIX is a registered trademark of The Open Group. Sun, SunOS, Solaris, SPARC, NFS, NIS, NIS+, JumpStart, OpenWindows, Sunview and SunInstall are trademarks or registered trademarks of Sun Microsystems, Inc. Ultrix, Digital UNIX and DEC are trademarks of Digital Equipment Corporation. HP-UX is a trademark of Hewlett-Packard Co. IRIX is a trademark of Silicon Graphics, Inc. AIX is a trademark of International Business Machines, Inc. AT&T is a trademark of American Telephone and Telegraph, Inc. GNU is a trademark of the Free Software Foundation. X Window System is a trademark of Massachusetts Institute of Technology. Ethernet is a registered trademark of Xerox Corporation. Netscape is a copyright of Netscape Communications Crop. Mosaic is a copyright of the National Center for Supercomputing Applications at the University of Illinois, Urbana-Champaign. All other products mentioned are trademarks of their respective owners. This publication is available via the Internet as: ftp://wks.uts.ohio-state.edu/sysadm_course/sysadm_book.ps and http://wks.uts.ohio-state.edu/sysadm_course/sysadm.html. Also available via the Internet is Introduction to Unix: ftp://wks.uts.ohio-state.edu/unix_course/unix_book.ps and http://wks.uts.ohio-state.edu/unix_course/unix.html. Acknowledgements: The author wishes to thank the following for helpful advice and discussions related to the material presented in this document: Harpal Chohan, Bob DeBula, Bob Manson, Steve Romig, and Bill Yang. 2 © 1998 University Technology Services, The Ohio State University UNIX System Administration Table of Contents PART I Introduction .......................................................9 1 Overview ............................................................................11 1.1 What is UNIX System Administration? ........................11 1.2 Daily Tasks of a System Administrator ........................11 1.3 Startup and Shutdown ....................................................11 1.4 Periodic Processes ...........................................................12 1.5 Managing File Systems ...................................................12 1.6 Responsibilities to the users ...........................................12 1.7 Hardware responsibilities ..............................................12 1.8 Types of SunOS Systems ................................................12 1.9 Resources for System Administrators ...........................13 1.10 UTS Software Support ...................................................15 2 Disk Structure and Partitions ..........................................17 2.1 Disk Structure and Partitions ........................................17 2.2 Disk Partitions .................................................................19 3 Devices ...............................................................................27 3.1 Logical Names .................................................................27 3.2 Disk Partitioning .............................................................28 3.3 Disk Label and Bootblock ..............................................31 3.4 Tapes ................................................................................32 4 The UNIX File System ......................................................33 4.1 File Systems .....................................................................33 4.2 File System Types ............................................................35 4.3 Compatibility ...................................................................38 4.4 Names & contents of important UNIX directories ......40 4.5 File structure of standalone and server machines .......43 4.6 Disk Partitioning .............................................................43 5 File System Management .................................................45 5.1 File System Management ...............................................45 5.2 Fsck ...................................................................................46 5.3 Disk Check Commands ..................................................47 UNIX System Administration © 1998 University Technology Services, The Ohio State University 3 5.4 Swapping and Paging .....................................................48 5.5 Adding swap space ..........................................................49 5.6 Setting up a Cache File System ......................................50 5.7 XFS (IRIX) ......................................................................52 5.8 File System Quotas ..........................................................52 5.9 Miscellaneous useful commands ....................................53 5.10 Log files ............................................................................54 6 Startup and Shutdown .................................................... 55 6.1 Booting .............................................................................55 6.2 Run Levels (SunOS 5.X, IRIX 5.X) ...............................57 6.3 /etc/inittab (SunOS 5.X, IRIX 5.X, Digital UNIX) .......57 6.4 Sun PROM .......................................................................65 6.5 SGI Indy PROM .............................................................67 6.6 Diskless Workstations .....................................................67 6.7 Shutdown .........................................................................69 6.8 Crashes .............................................................................70 7 Operating System Installation ........................................ 71 7.1 Suninstall .........................................................................71 7.2 SunOS 4.1.X .....................................................................71 7.3 SunOS 5.X ........................................................................74 7.4 Post Install Actions ........................................................84 7.5 Sun Patch List .................................................................86 7.6 IRIX 5.X ...........................................................................90 8 Kernel Configuration ...................................................... 91 8.1 SunOS 4.1.X .....................................................................91 8.2 SunOS 5.X ........................................................................92 8.3 IRIX 5.X .........................................................................100 8.4 Digital UNIX ..................................................................101 8.5 Ultrix ..............................................................................101 9 Adding Hardware .......................................................... 103 9.1 SunOS 4.1.X ...................................................................103 9.2 SunOS 5.X ......................................................................110 9.3 IRIX 5.X .........................................................................110 10 Special Files .................................................................... 111 10.1 Special Files ...................................................................111 10.2 SunOS 4.X ......................................................................112 10.3 SunOS 5.X ......................................................................112 10.4 IRIX 5.X .........................................................................113 10.5 Ultrix and Digital UNIX ...............................................114 11 System Directories ......................................................... 115 11.1 System Directories ........................................................115 11.2 / - root ............................................................................115 11.3 /etc - system and network configuration .....................118 4 © 1998 University Technology Services, The Ohio State University UNIX System Administration 11.4 /usr - system programs, libraries, etc. .........................120 12 User accounts ..................................................................123 12.1 User accounts .................................................................123 12.2 Admittance - login procedure ......................................126 12.3 Password Aging, SunOS 4.1.X .....................................126 13 Daily System Administration .........................................127 13.1 User and Group Administration .................................127 13.2 Communicating with system users ..............................129 13.3 Running programs automatically, cron & at .............129 14 Administration Tool & Solstice Adminsuite ................131 14.1 Admintool ......................................................................131