CSE 265: System and Network Administration

Similar documents
CSE 265: System and Network Administration

RHCE BOOT CAMP. The Boot Process. Wednesday, November 28, 12

Chapter 2 Booting Up and Shutting Down

Booting Up and Shutting Down. lctseng / Liang-Chi Tseng

The kernel is not to be confused with the Basic Input/Output System (BIOS).

Using grub to Boot various Operating Systems

Booting Up and Shutting Down

System Administration. Startup Process

CST8177 Linux II. Linux Boot Process

Booting up and Shutting down A primer for troubleshooting

Certification. System Initialization and Services

Recovering GRUB: Dual Boot Problems and Solutions

Chapter 6. Boot time configuration. Chapter 6 Boot time configuration

HOW LINUX BOOTS. As it turns out, there isn t much to the boot process:

PL-I Assignment Broup B-Ass 5 BIOS & UEFI

Linux/Citrix Virtual Environment Documentation

Runlevels, System Shutdown and Reboot

University of Pennsylvania Zachary Goldberg. CIS c. More Kernel Bits. 10/03/09 Slide 1

Linux+ Guide to Linux Certification, Third Edition. Chapter 2 Linux Installation and Usage

grub-md5-crypt --help Usage: grub-md5-crypt [OPTION] Encrypt a password in MD5 format.

Authored by: Brian E. Brzezicki Copyright 2013, Paladin Group LLC Reuse without permission is strictly prohibited

The Linux IPL Procedure

The Early System Start-Up Process. Group Presentation by: Tianyuan Liu, Caiwei He, Krishna Parasuram Srinivasan, Wenbin Xu

Oracle 1Z Enterprise Linux System Administration. Download Full Version :

InDepth Linux Serial Consoles for Servers and Clusters

System control mechanisms

Advanced Unix System Administration

OPERATING SYSTEMS. Božo Krstajić, PhD, University of Montenegro Podgorica.

Advanced Operating Systems and Virtualization. Alessandro Pellegrini A.Y. 2017/2018

Fedora 12 Essentials

MODULE 02. Installation

Chapter 02 Linux Installation and Usage

More on file systems, Booting Todd Kelley CST8177 Todd Kelley 1

The Linux Boot Process

Enabling and Configuring SOL (Serial Over LAN) on an 8832 Blade Server

OPERATING SYSTEMS LINUX

WLM1200-RMTS User s Guide

The LILO Configuration Handbook. Virgil J. Nisly

Installation Tools for Clusters. Rajesh K., Computer Division, BARC

Integrated Lights-Out 3 Virtual Serial Port configuration and operation

LPIC 102. be familiar with standard runlevels in a Linux system

. Fill in the Blank: A directory named mydir has just been... Points:10. Add Question Success: 64 questions added as a copy.

Course 55187B Linux System Administration

Automating Linux App Startup

Please choose the best answer. More than one answer might be true, but choose the one that is best.

This is Lab Worksheet 13 - not an Assignment. Boot Process and GRUB

More on file systems, Booting Todd Kelley CST8177 Todd Kelley 1

Boot Process in details for (X86) Computers

Introduction to Linux start-up. Hao-Ran Liu

Initialization: runlevels

Start Up and Shutdown Procedures (Unix)

CIT 480: Securing Computer Systems

B. The configuration will deny access to /var/web/dirl/private.html, but it will allow access to /var/web/dirl/subdir2/private.html, for example.

CompTIA Linux+ Guide to Linux Certification Fourth Edition. Chapter 2 Linux Installation and Usage

Actual4Test. Actual4test - actual test exam dumps-pass for IT exams

KillTest 䊾 䞣 催 ࢭ ད ᅌ㖦䊛 ᅌ㖦䊛 NZZV ]]] QORRZKYZ TKZ ϔᑈܡ䊏 ᮄ ࢭ

ECE 471 Embedded Systems Lecture 16

NETW 110 Lab 3 Post-Installation Configuration Page 1

minit Felix von Leitner September 2004 minit

ITDUMPS QUESTION & ANSWER. Accurate study guides, High passing rate! IT dumps provides update free of charge in one year!

LPI Linux-Linux Networking Administration. Download Full Version :

LPI EXAM LPI Level 1 Exam 101, Junior Level Linux Certification, Part 1 of 2. Buy Full Product.

RedHat. Rh202. Redhat Certified Technician on Redhat Enterprise Linux 4 (Labs)

If you don't care about how it works but you just would like that it works read here. Other wise jump to the next chapter.

Basic UNIX system administration

Introduction to Linux Init Scripts

Network Drawing. Computer Specs, I ve used. Installing a Network-Based Intrusion Detection

Enabling and Configuring SOL (Serial Over LAN) on an 8832 Blade Server

At course completion. Overview. Audience profile. Course Outline. : 55187B: Linux System Administration. Course Outline :: 55187B::

CIS 191A Final Exam. Fall CIS 191 Final Exam

Exam Questions Demo LPI. Exam Questions Linux Networking Administration.

Fedora Core: Made Simple

Getting Started with Linux. Are Covered in This Chapter: (GRUB: /boot/grub/grub.conf, /boot/grub/menu.lst, grub-install, grub).

Basic Shell Commands. Bok, Jong Soon

Basic Linux Security. Roman Bohuk University of Virginia

How To Configure PowerAlert on Linux with the APC BackUPS Pro 280VA (v2.0, 5Sept2002)

RAP Installation README

Boot. How OS boots

1Z Oracle Linux 6 Implementation Essentials Exam Summary Syllabus Questions

ECE 471 Embedded Systems Lecture 16

"Charting the Course... MOC B: Linux System Administration. Course Summary

RH202. Redhat Certified Technician on Redhat Enterprise Linux 4 (Labs) Exam.

Linux Administration

GL-280: Red Hat Linux 7 Update. Course Description. Course Outline

Instructions: Step 1: Respond to the following: IT131 Linux+

Managing the Linux Boot Process

Vendor: LPI. Exam Code: Exam Name: LPI Level 1 Exam 101, Junior Level Linux Certification, Part 1 of 2. Version: Demo

Linux Howtos. Fedora 9 Install (114) CIS Fall Fedora 9 Install (114) Fedora 9 installation with custom partitions.

Virtual Data Center (vdc) Manual

Operating System Kernel and the boot process

Installation of Fedora 12 with CD

Vendor: RedHat. Exam Code: RH133. Exam Name: Red Hat Linux System Administration. Version: Demo

How to clone a Linux box using netcat

ExpressCluster X LAN V1 for Linux

ECE 471 Embedded Systems Lecture 12

ECE 550D Fundamentals of Computer Systems and Engineering. Fall 2017

Please note that CNE 216 is a brand new course that has never been taught on the George campus; it will be taught for the first time in the fall of

Introduction p. 1 Why Linux? p. 2 Embedded Linux Today p. 3 Open Source and the GPL p. 3 Free Versus Freedom p. 4 Standards and Relevant Bodies p.

Zephyr Kernel Installation & Setup Manual

Embedded System Design

Transcription:

CSE 265: System and Network Administration System startup and shutdown Bootstrapping Booting PCs Boot loaders Booting into single user mode Startup scripts Rebooting and shutting down

Bootstrapping i.e., starting the computer System is particularly vulnerable to errors Steps in boot process Execution of boot code in ROM Loading and initialization of kernel Device detection and configuration Creation of spontaneous system processes Operator intervention (manual boot only) Execution of system startup scripts Multiuser operation

Booting PCs PC starts by executing code in ROM (the BIOS) Usually BIOS has a configuration mode with special keypress during boot Tries to load first 512B of the boot disk the Master Boot Record MBR contains program to specify which partition from which to load the secondary boot program (the boot loader )

Boot loaders Load and start the kernel Could be one of many kernels or OSes! MBR set to load the master boot loader Each disk partition can have its own second stage loader LILO is an older Linux boot loader GRUB is the modern Linux boot loader Supports most OSes, not just Linux

Example multi-boot laptop GRUB # grub.conf generated by anaconda # # Note that you do not have to rerun grub after making changes # to this file # NOTICE: You have a /boot partition. This means that # all kernel and initrd paths are relative to /boot/, eg. # root (hd0,2) # kernel /vmlinuz-version ro root=/dev/hda6 # initrd /initrd-version.img #boot=/dev/hda default=1 timeout=10 splashimage=(hd0,2)/grub/splash.xpm.gz title Red Hat Linux (2.4.20-8) root (hd0,2) kernel /vmlinuz-2.4.20-8 ro root=label=/ initrd /initrd-2.4.20-8.img title Microsoft XP rootnoverify (hd0,1) chainloader +1

Hardware configuration Kernel examines system environment Tries to locate and initialize every device that it is supposed to have Hardware configuration info in kernel is often underspecified Probes buses for devices and asks drivers for info (i.e., which interrupt, which PCI address, etc.) Drivers can sometimes be added later

Operator intervention (manual booting) Kernel tells init if single-user mode is desired Typically requests root password Single-user shell is similar to normal shell Often fewer disk partitions mounted (such as root partition only) Other partitions must be mounted by hand if needed Daemons typically not running Can run fsck if needed to repair filesystems When you exit, system attempts to boot into multiuser mode

Booting into single user mode Need to modify a GRUB entry to include the keyword single, e.g., title Red Hat Linux (2.4.9-21) single user mode root (hd0,0) kernel /vmlinuz-2.4.9-21 ro root=/dev/hda6 single initrd /initrd-2.4.9-21.img Can be done at run-time Better is to set up a single-user mode entry ahead

Startup scripts At the end of single user mode, init executes system startup scripts Typical tasks: Setting name of computer Setting the time zone Checking the disks with fsck Mounting the system disks Removing old files from /tmp Configuring network interfaces Starting daemons and network services

Multiuser operation After initialization scripts run, system is fully operational, except that no one can log in init spawns getty processes that listen on terminals (including console) graphical login such as xdm or gdm if configured init later responsible for moving from one runlevel to the next

Spontaneous system processes Not created via usual fork mechanism init is always process 1 Plus special memory and kernel processes kflushd, kupdate, kpiod, kswapd Not really processes (portions of kernel) Everything else (other processes) are started via init Optionally view such processes with ps -aux more

init and run levels Seven run levels defined 0 is for system shut down 1 or S is single user mode 2-5 are multi-user levels In RH/Fedora, 3 is networked multi-user, 5 is X-windows 6 is the reboot level /etc/inittab specifies what init has to do in each level During booting, system goes from 0 to default run level (in /etc/inittab), and calls /etc/rc.d/rc for each change Optionally view /etc/inittab

init and rc scripts Startup scripts live in /etc/init.d/ (linked to /etc/rc.d/init.d/) Each script starts, stops, restarts some service /etc/rc.d/rc knows to look in /etc/rc.d/ where there is a subdirectory for each runlevel Symbolic links are made to the actual script in /etc/init.d/ within each subdirectory for the services appropriate for that level, e.g. ln -s /etc/init.d/sshd /etc/rc3.d/s99sshd Script names indicate order of Start or Kill

/etc/sysconfig Additional scripts and configuration for Red Hat Stores networking configuration /etc/sysconfig/network-scripts/ifcfg-ethx Scripts can be used to individually start or stop network interfaces /etc/sysconfig/network-scripts/ifdown eth0 /etc/sysconfig/network-scripts/ifup eth0

Rebooting and shutting down Not needed as often as in consumer OSes Needed for Adding or removing hardware Change to boot configuration System really wedged Ways to reboot or shutdown Including new kernel Use the shutdown command Use the halt and reboot commands Use telinit to change init's run level Use poweroff to tell system to turn off (missing from USLAH) Use hardware reset switch or turn off power (last resort!)

Turning off power Turning off power can cause data loss and leave filesystem in an inconsistent state Linux (and other modern OS) filesystems buffer changes in memory, and only sporadically write them back to disk Makes disk I/O faster, but more sensitive to loss Uninterrupted power is important Sometimes it is necessary to remove power Flood, fire, etc.

shutdown shutdown command is safest, considerate, and most thorough to halt, reboot, or change to single user mode shutdown can wait before bringing down system sends warning messages (like wall) to logged-in users should explain why, and when it is coming back Can specify whether to halt, or reboot: shutdown -r +15 Rebooting to fix NFS

Halt; reboot halt called by shutdown -h logs the shutdown kills non-essential processes executes sync waits for filesystem to finish writes puts IDE drives in standby mode (flushing write caches) halts the kernel reboot called by shutdown -r similar to halt, but tells kernel to reboot system

telinint; poweroff telinit Directs init to go to a specific run level telinit 1 takes system to single-user mode poweroff Identical to halt, but adds request to power management system to turn off system's power