Transcript CIS 191
CIS 191 – Lesson 1 CIS 191AB Textbook • UNIX and Linux System Administration Handbook 4th Edition • Authors: – Evi Nemeth – Garth Snyder – Trent Hein – Ben Whaley • Used for CIS191 and CIS192 • Last year’s book may also be used. CIS 191 – Lesson 1 Opus Linux Server opus.cabrillo.edu Remote shell access via SSH. SCP access for turning in lab assignments Each student gets an account on Opus CIS 191 – Lesson 1 Online Help Forum for Students • Post questions and answers • Share Linux information • Post class notes for classmates who miss class • Only your real names please! Note: Posts count towards class participation. CIS 191 – Lesson 1 Remote Access Lab • Remote Desktop access to cislab.cabrillo.edu • Student accounts • Access to your own virtual machine • 24/7 access • Labs may be done remotely. • Do installations with a variety of distros. CIS 191 – Lesson 1 vCenter Server CIS 191 – Lesson 1 Virtual Machines CIS 191 – Lesson 1 Classroom Network Internet 172.30.1.0/24 nopar .1 172.30.5.0/24 172.30.4.0/24 .101 .5 .101 station-01 .100 cislab .102 .102 .10 instructor station-02 .103 .10 .103 station-03 . . . snickers (DHCP) . . . .110 netlab .2 nosmo Lab Machines ESXi Servers CIS 191 – Lesson 1 CIS Lab Can do arranged hours in CTC 1404 In the former recording studio: • VMware Workstation. • Multiple ISOs for installation practice. •Trouble VM for trouble-shooting practice for CIS 191. •Can boot from USB to test custom distros on pen drives. •Putty access to Opus. •CIS Lab Network is 172.30.4.0/24 http://webhawks.org/~cislab/ CIS 191 – Lesson 1 Class Exercise Opus, Website and Forum Access Opus: 1. Open Putty on Windows desktop 2. Enter opus.cabrillo.edu as hostname 3. Click Open 4. Logon with your login name or guest191 and password on the board. 5. Change your PATH variable to include: /home/cis191/bin CIS 191 – Lesson 1 Class Exercise (continued) Opus, Website and Forum Access forum: 1. Click on Forum link in top panel of website 2. Click on CIS191 forum 3. Click on first post 4. Register yourself using your first and last name for your username* *Note, this forum is for CIS students only and not for spammers . Only usernames with that contain actual first and last names of registered students will be approved by the moderator. All other usernames will be rejected. CIS 191 – Lesson 1 Operating Systems Various UNIX Products SCO UNIX AIX HP-UX Solaris Mac OS X CIS 191 – Lesson 1 Operating Systems Various Linux Distributions Red Hat 9 OpenSUSE Fedora Debian Ubuntu CentOS Knoppix CIS 191 – Lesson 1 Linux Distributions compare and contrast • Similarities: – – – – kernel from kernel.org system commands bash shell X Windows • Differences: – – – – Installation programs Graphical utilities 3rd party software Package management CIS 191 – Lesson 1 Basic role of a multi-user multi-tasking operating system users programs Operating System hardware CIS 191 – Lesson 1 GNU/Linux Operating System Architecture Users (multi-user) Programs (multi-tasking) Shell User Space Applications Commands & Utilities X / Desktops GNU C Library (glibc) Kernel1 Richard Stallman started the GNU project in 1983 to create a free UNIXlike OS. He Founded the Free Software Foundation in 1985. In 1989 he wrote the first version of the GNU General Public License System Call Interface Process Management Kernel Space Memory Management Architecture Dependent Kernel Code Virtual File System Network Stack Device Drivers Hardware 1See “Anatomy of the Linux kernel” by M. Tim Jones at http://www-128.ibm.com/developerworks/linux/library/l-linux-kernel/ Linus Torvalds, as a student, initially conceived and assembled the Linux kernel in 1991. The kernel was later relicensed under the GNU General Public License in 1992. CIS 191 – Lesson 1 User Space Components • Shell (in /bin) • Command interpreter and programming language (scripting) • Commands and utilities (in /bin, /sbin, /usr) • cat, ping, ls, fdisk, chmod, man, ifconfig, ... 100’s more • X / Desktops (in /usr) • X window managers, gnome, kde, etc. • GNU C Library (in /lib) • Math, string, input, output, logging, kernel system calls, etc. • Applications (in /usr, /opt) • Browsers, word processing, spreadsheets, software development, administration, databases, web servers, etc. Design • Programs restricted to the privileges of the user running them • Unlike Windows, the GUI does not run in the kernel • Unlike Windows, multiple graphical desktops available CIS 191 – Lesson 1 The Linux Kernel (in /boot) Major Subsystems: • System Call Interface • mechanism for user space programs to request kernel services. • Process Management • handles fork, exec, exit, kill, signals, CPU scheduling, etc. • Memory Management • allocation, usage tracking, paging, etc. • Virtual File System • open, close, read, write, caching, etc. • Architecture Dependent Kernel Code • Drivers (dynamically loadable drivers are in /lib/modules) Design • Linux kernel is “monolithic”, not a “microkernel” • Dynamic – can load and unload modules on the fly • Over time has become efficient, stable and portable CIS 191 – Lesson 1 UNIX/Linux User Interfaces CLI – Command Line Interface GUI - Graphical User Interface TUI - Text User Interface (uses curses library) CIS 191 – Lesson 1 Types of Installations • • • • • • CD, DVD, or ISO image Live CD/DVD Attended vs. Unattended Local vs. Network Imaging software (Ghost, ImageCast) Build from scratch CIS 191 – Lesson 1 Three steps to an installation 1. Prepare the storage device Partition the disk Format the filesystems Select mount points for those filesystems 2. Copy the selected packages Package groups, packages, files 3. Write out the boot loader MBR or boot sector (GRUB, LILO, SYSLinux) Everything else is configuration