Presentation is loading. Please wait.

Presentation is loading. Please wait.

Chapter 4 Booting and Shutdown

Similar presentations


Presentation on theme: "Chapter 4 Booting and Shutdown"— Presentation transcript:

1 Chapter 4 Booting and Shutdown
CSNB113 SYSTEM ADMINISTRATION College of Information Technology Universiti Tenaga Nasional (UNITEN) SN 2017

2 Objectives Understand the concept of run levels and their role in startup and shutdown operations SN 2014

3 Introduction Startup and shutdown procedures are controlled by automated shell scripts System administrator needs to know that exact sequence of steps the system follows during the two events – able to fix if things do go wrong SN 2017

4 Booting Step 1 Step 2 Step 3 Step 4 PID1: Process-id 1
Machine is powered on Step 1 System looks for all peripherals Step 2 Follow a series of steps  lead to the loading of kernel into memory Step 3 Kernel spawns init (PID1), followed by other processes Step 4 PID1: Process-id 1 SN 2017

5 init init process: second process of the system
Behavioral pattern of init for three vital reasons: Maintains the system at a specific run level (state) and decides which processes to run for each run level Parent of all system daemons (process) that keep running all the time Spawns a getty process at every terminal so that users can log in – parent of all shell SN 2017

6 Run level Indicated by a single digit (0 to 6), or an s or S Run level
Description System shutdown 1 System administration mode (local file system mounted) 2 Multiuser mode (NFS not available) 3 Full multiuser mode 5 The graphical environment mode in Linux 6 Shutdown and reboot mode s or S Single-user mode (file systems mounted) SN 2017

7 init : Run level init state 1 or S init state 2, 3, or 5
Machine is powered on init state 2, 3, or 5 Multiuser mode init state 0 or 6 System is shutdown System administrator has the freedom to use the init command to move the system to any run level. Example: # init 1 SN 2017

8 Display run level who -r surizal@sn010101-scnb113 :~$ who –r
Example: Run level 2: ___________ mode SN 2017

9 Shutdown shutdown command: shut the machine down
Notifies users with wall about the system going down with a directive log out Activities during shutting down (sleeping for one minute): Sends signals to all running process – normally terminate the process Log off and kill remaining processes Unmounts all secondary file systems – unmount command Write all memory-resident data to disk – sync command Notifies users to reboot or switch off SN 2017

10 Shutdown - Ubuntu P option: overrides the default sleeping time of one minute r option: shutdown and restart/reboot # shutdown –P 2 Powers down machine after 2 minutes # shutdown –P 0 Immediate shutdown # shutdown –r 0 Immediate shut down and reboot SN 2017

11 References Das, S. (2012). Your UNIX/LINUX The Ultimate Guide: Third Edition. McGraw-Hill Hahn, H. (2008). Harley Hahn's Guide to Unix and Linux. California: McGraw-Hill Higher Education SN 2014


Download ppt "Chapter 4 Booting and Shutdown"

Similar presentations


Ads by Google