SlideShare une entreprise Scribd logo
1  sur  24
Télécharger pour lire hors ligne
RHCSA
BOOT CAMP
The Boot Process

Monday, July 11, 2011
OVERVIEW
The boot process gets a machine from the useless off state to
the feature rich operating system we all know and love
Requires cooperation between hardware and software to
correctly hand off processing
Akin to the life cycle of a human - birth, newborn, infant,
toddler, teen, adult

Monday, July 11, 2011
BIRTH
Power switch flipped on
Electricity flows from wall, through power supply where it
gets converted to the levels necessary for the computer, and
on to the motherboard, drives, CPU and more
Completely unaware of the world or even what’s attached to
the motherboard.

Monday, July 11, 2011
INFANT
BIOS - Basic Input/Output System - CPU looks for
instructions starting at a specific address, which happens to
be where BIOS resides. BIOS initializes and starts the....
POST - Power On Self Test - A simple set of tests that BIOS
performs to verify basic functioning of attached hardware.
Like an infant, extremely limited understanding of world
Searches for valid MBR, loads the software found there and
transfers control to the...

Monday, July 11, 2011
TODDLER
Boot Loader - Special software installed to the MBR of the
boot partition which selects and loads the kernel.
Can be configured to immediately load the default OS, or
can offer choice to user
Slightly better understanding of world - can read linux
filesystems, sometimes includes powerful debugging and
configuration support.
Main job: select and load kernel, transfer control to kernel

Monday, July 11, 2011
TEENAGER

Dreaded teenager age: knows a lot about the world, but
doesn’t contribute a thing. Still pretty useless.
Kernel loads and initializes. Device drivers are loaded and
initialized. Basic hardware checks performed.
The First Process is created from nothing: init

Monday, July 11, 2011
ADULT
init loads the inittab, specifying what the default runlevel should
be, then additional configuration files specify what software needs
to be started. init starts running all of the specified startup scripts
at this point.
Services are started by init, including network configurations, X
Windows, network services, databases, etc.
At this point, the machine is finally becoming useful: otherwise, an
adult
Eventually, login processes are started and the boot process is
complete!

Monday, July 11, 2011
MORE ON INIT
RHEL 6 marks Red Hat’s departure from the old style SystemV
initialization framework. Time to [mostly] forget about inittab!
RHEL 6 now uses Upstart to handle startup, shutdown and
service management.
http://upstart.ubuntu.com
The only configuration /etc/inittab provides anymore is
what the default runlevel should be, as Upstart supports the
notion of runlevels to ease transition from SysV style
initialization to Upstart.
Monday, July 11, 2011
UPSTART
The configuration files for Upstart are under:
/etc/init
Files in this directory detail configuration for certain global
events, like ctrl-alt-delete, as well as maintaining TTY gettys,
handling runlevels and more.
A runlevel defines what services are running...

Monday, July 11, 2011
RUNLEVELS
Runlevels:
S: System startup
0: OS stopped, machine halted ( usually powers off as well )
1: Single user mode - for maintenance
2: Multiuser, no NFS shares
3: Full multiuser, TUI
4: Unused
5: Full multiuser, GUI
6: Reboot

Monday, July 11, 2011
RUNLEVELS
telinit: Signal the init process to change the current
runlevel
Switching runlevels is fairly uncommon - generally only
used if system maintenance needs to be performed
Runlevels can be used to control what services a machine
provides, and can sometimes be useful to quickly
reconfigure a machine for a new task

Monday, July 11, 2011
UPSTART OVERVIEW
So the basic flow of operation for Upstart is as follows:
At bootup, the kernel starts /sbin/init. After /sbin/
init loads configuration files and is ready, the first event
is emitted: startup
The startup event causes /etc/init/rcS.conf to
fire, which in turn runs the familiar /etc/rc.d/
rc.sysinit. After rc.sysinit finishes, rcS.conf
uses /etc/inittab to determine the default runlevel,
then runs telinit to that runlevel.
Monday, July 11, 2011
UPSTART OVERVIEW
telinit emits the runlevel event, which fires off /etc/
init/rc.conf
rc.conf fires off the familiar /etc/rc.d/rc script with
the appropriate runlevel to fire off all of the startup scripts in
the appropriate /etc/rcX.d directory.
WHEW!
All of this, mainly so that the transition to Upstart is relatively
painless for the system administrators more comfortable with
SysV initialization.
Monday, July 11, 2011
INIT SCRIPTS
What is actually running in a given runlevel is defined by the
init scripts for that level.
That standard location for the init scripts is:
/etc/rcX.d
Where the X corresponds to the runlevel
For example, /etc/rc5.d contains all of the init scripts
that, combined, provide runlevel 5 service

Monday, July 11, 2011
RC DIRECTORIES
The files in the rc directories start with either an S or a K:
S means to start the service, ie run the command with
“start” as an argument
K means to kill the service, ie run the command with
“stop” as an argument
After the S or K, there is a two digit number which is used
for ordering the execution of the scripts

Monday, July 11, 2011
ENTERING A
RUNLEVEL
So when the init process “enters” a runlevel, the steps are:
Run all of the Kill scripts, in order, with “stop” as an
argument
Run all of the Start scripts, in order, with “start” as an
argument

Monday, July 11, 2011
INIT SCRIPTS
If you look closely, you will see that /etc/rcX.d actually
holds a collection of symbolic links
The actual script files are stored in /etc/init.d
The main reason for this is so that there is only one copy of
each init script, reducing the chance that a script change
won’t be reflected in all runlevels.
You can run the scripts directly, or use the service
command to start/stop various components of the OS.

Monday, July 11, 2011
MANAGING INIT
SCRIPTS
You can manage the links to the init scripts manually, or you
can use the chkconfig command to get the job done:
chkconfig --list
List all processes and display their default status in each
run-level.
chkconfig [--level levels] name <on|off|reset>
This command will modify the chkconfig configuration for a
particular service, setting it on/off for the given runlevels.
Monday, July 11, 2011
GRUB
Grand Unified Boot Loader
Recall that GRUB is responsible for the initial kernel load at
boot time.
Using GRUB, an administrator can control what kernel is
loaded, what options are passed to the kernel, as well as
initial ramdisk configurations.

Monday, July 11, 2011
GRUB
CONFIGURATION
GRUB’s configuration file is /boot/grub/grub.conf, which is configured as
follows:
default=0
timeout=10
splashimage=(hd0,0)/grub/splash.xpm.gz
title RedHat Enterprise Linux
!

root (hd0,0)

!

kernel /vmlinuz ro root=LABEL=/

!

initrd /initrd

Monday, July 11, 2011
GRUB SHELL
Command mode – Pressing “c” while the boot menu is displayed will
provide the user with the GRUB shell, where a limited set of commands
can be used to explore the filesystem before booting. A full list of the
commands available can be found by pressing Tab while in command
mode.
Editing mode – Pressing “e” while the boot menu is displayed will provide
the user with the opportunity to edit a line in GRUB’s configuration file.
Append mode – Pressing “a” while the boot menu is displayed will allow
the user to append to the kernel line for the default kernel in GRUB’s
configuration file
Esc – can be pressed at any time to return you to the previous menu

Monday, July 11, 2011
BOOTING TO A GIVEN
RUNLEVEL
Using GRUB, add a number to the end of the kernel
command line to override the default runlevel.
Also, adding the letter “s” or the word “single” to the end
of the command line is very important: this boots into single
user mode, which by default, will not require a password to
obtain a root shell.
Very important!

Monday, July 11, 2011
LAB

1.

Reboot your machine into the single user runlevel and
verify root access without a password.

2. Review a few of the init.d scripts
3. Review the configuration files in /etc/init

Monday, July 11, 2011
slideshow.end();

Monday, July 11, 2011

Contenu connexe

Tendances

Boot process -test
Boot process -testBoot process -test
Boot process -test
Hari Shankar
 
6 stages of linux boot process
6 stages of linux boot process6 stages of linux boot process
6 stages of linux boot process
Teja Bheemanapally
 

Tendances (19)

Project 2 How to modify os161: A Manual
Project 2 How to modify os161: A ManualProject 2 How to modify os161: A Manual
Project 2 How to modify os161: A Manual
 
linux
linuxlinux
linux
 
Boot process -test
Boot process -testBoot process -test
Boot process -test
 
Project 2 how to modify OS/161
Project 2 how to modify OS/161Project 2 how to modify OS/161
Project 2 how to modify OS/161
 
OpenSolaris 2009.06 Workshop
OpenSolaris 2009.06 WorkshopOpenSolaris 2009.06 Workshop
OpenSolaris 2009.06 Workshop
 
Install and Configure Ubuntu for Hadoop Installation for beginners
Install and Configure Ubuntu for Hadoop Installation for beginners Install and Configure Ubuntu for Hadoop Installation for beginners
Install and Configure Ubuntu for Hadoop Installation for beginners
 
BASSET_README
BASSET_READMEBASSET_README
BASSET_README
 
How to install Open Atrium over LAMP stack
How to install Open Atrium over LAMP stackHow to install Open Atrium over LAMP stack
How to install Open Atrium over LAMP stack
 
6 stages of linux boot process
6 stages of linux boot process6 stages of linux boot process
6 stages of linux boot process
 
PE Packers Used in Malicious Software - Part 2
PE Packers Used in Malicious Software - Part 2PE Packers Used in Malicious Software - Part 2
PE Packers Used in Malicious Software - Part 2
 
How to add system calls to OS/161
How to add system calls to OS/161How to add system calls to OS/161
How to add system calls to OS/161
 
Fedora Atomic Workshop handout for Fudcon Pune 2015
Fedora Atomic Workshop handout for Fudcon Pune  2015Fedora Atomic Workshop handout for Fudcon Pune  2015
Fedora Atomic Workshop handout for Fudcon Pune 2015
 
Linux Booting Steps
Linux Booting StepsLinux Booting Steps
Linux Booting Steps
 
Linux booting process - Linux System Administration
Linux booting process - Linux System AdministrationLinux booting process - Linux System Administration
Linux booting process - Linux System Administration
 
Ch06
Ch06Ch06
Ch06
 
HowTo Install openMPI on Ubuntu
HowTo Install openMPI on UbuntuHowTo Install openMPI on Ubuntu
HowTo Install openMPI on Ubuntu
 
Booting
BootingBooting
Booting
 
Understanding The Boot Process
Understanding The Boot ProcessUnderstanding The Boot Process
Understanding The Boot Process
 
2 how to-build_document_management_system
2 how to-build_document_management_system2 how to-build_document_management_system
2 how to-build_document_management_system
 

En vedette (6)

District 428 Final annual report.2012
District 428 Final annual report.2012District 428 Final annual report.2012
District 428 Final annual report.2012
 
Presentation1 - Testing
Presentation1 - TestingPresentation1 - Testing
Presentation1 - Testing
 
Poradenstvo pre smrteľne chorých a pozostalých s použitím krízovej intervenci...
Poradenstvo pre smrteľne chorých a pozostalých s použitím krízovej intervenci...Poradenstvo pre smrteľne chorých a pozostalých s použitím krízovej intervenci...
Poradenstvo pre smrteľne chorých a pozostalých s použitím krízovej intervenci...
 
Parasitology lecture 3
Parasitology lecture 3 Parasitology lecture 3
Parasitology lecture 3
 
Social Media Là Gì?
Social Media Là Gì?Social Media Là Gì?
Social Media Là Gì?
 
Ejercicios
EjerciciosEjercicios
Ejercicios
 

Similaire à 01 boot process

6 stages of linux boot process
6 stages of linux boot process6 stages of linux boot process
6 stages of linux boot process
Hari Shankar
 
101 1.3 runlevels , shutdown, and reboot
101 1.3 runlevels , shutdown, and reboot101 1.3 runlevels , shutdown, and reboot
101 1.3 runlevels , shutdown, and reboot
Acácio Oliveira
 
Bootloader and bootloading
Bootloader and bootloadingBootloader and bootloading
Bootloader and bootloading
Arpita Gupta
 
Your first dive into systemd!
Your first dive into systemd!Your first dive into systemd!
Your first dive into systemd!
Etsuji Nakai
 
Power point on linux commands,appache,php,mysql,html,css,web 2.0
Power point on linux commands,appache,php,mysql,html,css,web 2.0Power point on linux commands,appache,php,mysql,html,css,web 2.0
Power point on linux commands,appache,php,mysql,html,css,web 2.0
venkatakrishnan k
 

Similaire à 01 boot process (20)

Linux startup
Linux startupLinux startup
Linux startup
 
Unix Administration 2
Unix Administration 2Unix Administration 2
Unix Administration 2
 
Linux booting process!!
Linux booting process!!Linux booting process!!
Linux booting process!!
 
Open_suse
Open_suseOpen_suse
Open_suse
 
ch1-1.pptx
ch1-1.pptxch1-1.pptx
ch1-1.pptx
 
6 stages of linux boot process
6 stages of linux boot process6 stages of linux boot process
6 stages of linux boot process
 
Basics of Ansible - Sahil Davawala
Basics of Ansible - Sahil DavawalaBasics of Ansible - Sahil Davawala
Basics of Ansible - Sahil Davawala
 
Ubuntu server guide
Ubuntu server guideUbuntu server guide
Ubuntu server guide
 
Linux basics
Linux basics Linux basics
Linux basics
 
101 1.3 runlevels , shutdown, and reboot
101 1.3 runlevels , shutdown, and reboot101 1.3 runlevels , shutdown, and reboot
101 1.3 runlevels , shutdown, and reboot
 
Bootloader and bootloading
Bootloader and bootloadingBootloader and bootloading
Bootloader and bootloading
 
Your first dive into systemd!
Your first dive into systemd!Your first dive into systemd!
Your first dive into systemd!
 
EasyTest Test Automation Tool Introduction
EasyTest Test Automation Tool IntroductionEasyTest Test Automation Tool Introduction
EasyTest Test Automation Tool Introduction
 
Systemd mlug-20140614
Systemd mlug-20140614Systemd mlug-20140614
Systemd mlug-20140614
 
Linux basics
Linux basics Linux basics
Linux basics
 
CentOS 6 to CentOS 7 Upgrade Procedure
CentOS 6 to CentOS 7 Upgrade ProcedureCentOS 6 to CentOS 7 Upgrade Procedure
CentOS 6 to CentOS 7 Upgrade Procedure
 
Linux
LinuxLinux
Linux
 
Linux System Monitoring
Linux System Monitoring Linux System Monitoring
Linux System Monitoring
 
Introduction to node.js
Introduction to node.jsIntroduction to node.js
Introduction to node.js
 
Power point on linux commands,appache,php,mysql,html,css,web 2.0
Power point on linux commands,appache,php,mysql,html,css,web 2.0Power point on linux commands,appache,php,mysql,html,css,web 2.0
Power point on linux commands,appache,php,mysql,html,css,web 2.0
 

Dernier

Top Rated Call Girls Mira Road : 9920725232 We offer Beautiful and sexy Call ...
Top Rated Call Girls Mira Road : 9920725232 We offer Beautiful and sexy Call ...Top Rated Call Girls Mira Road : 9920725232 We offer Beautiful and sexy Call ...
Top Rated Call Girls Mira Road : 9920725232 We offer Beautiful and sexy Call ...
amitlee9823
 
Rekha Agarkar Escorts Service Kollam ❣️ 7014168258 ❣️ High Cost Unlimited Har...
Rekha Agarkar Escorts Service Kollam ❣️ 7014168258 ❣️ High Cost Unlimited Har...Rekha Agarkar Escorts Service Kollam ❣️ 7014168258 ❣️ High Cost Unlimited Har...
Rekha Agarkar Escorts Service Kollam ❣️ 7014168258 ❣️ High Cost Unlimited Har...
nirzagarg
 
FULL NIGHT — 9999894380 Call Girls In Jagat Puri | Delhi
FULL NIGHT — 9999894380 Call Girls In Jagat Puri | DelhiFULL NIGHT — 9999894380 Call Girls In Jagat Puri | Delhi
FULL NIGHT — 9999894380 Call Girls In Jagat Puri | Delhi
SaketCallGirlsCallUs
 
Vip Mumbai Call Girls Colaba Call On 9920725232 With Body to body massage wit...
Vip Mumbai Call Girls Colaba Call On 9920725232 With Body to body massage wit...Vip Mumbai Call Girls Colaba Call On 9920725232 With Body to body massage wit...
Vip Mumbai Call Girls Colaba Call On 9920725232 With Body to body massage wit...
amitlee9823
 
➥🔝 7737669865 🔝▻ Asansol Call-girls in Women Seeking Men 🔝Asansol🔝 Escorts...
➥🔝 7737669865 🔝▻ Asansol Call-girls in Women Seeking Men  🔝Asansol🔝   Escorts...➥🔝 7737669865 🔝▻ Asansol Call-girls in Women Seeking Men  🔝Asansol🔝   Escorts...
➥🔝 7737669865 🔝▻ Asansol Call-girls in Women Seeking Men 🔝Asansol🔝 Escorts...
amitlee9823
 
Call Girls Bangalore Just Call 👗 7737669865 👗 Top Class Call Girl Service Ban...
Call Girls Bangalore Just Call 👗 7737669865 👗 Top Class Call Girl Service Ban...Call Girls Bangalore Just Call 👗 7737669865 👗 Top Class Call Girl Service Ban...
Call Girls Bangalore Just Call 👗 7737669865 👗 Top Class Call Girl Service Ban...
amitlee9823
 
Call Girls Kadugodi Just Call 👗 7737669865 👗 Top Class Call Girl Service Bang...
Call Girls Kadugodi Just Call 👗 7737669865 👗 Top Class Call Girl Service Bang...Call Girls Kadugodi Just Call 👗 7737669865 👗 Top Class Call Girl Service Bang...
Call Girls Kadugodi Just Call 👗 7737669865 👗 Top Class Call Girl Service Bang...
amitlee9823
 
➥🔝 7737669865 🔝▻ narsinghpur Call-girls in Women Seeking Men 🔝narsinghpur🔝 ...
➥🔝 7737669865 🔝▻ narsinghpur Call-girls in Women Seeking Men  🔝narsinghpur🔝  ...➥🔝 7737669865 🔝▻ narsinghpur Call-girls in Women Seeking Men  🔝narsinghpur🔝  ...
➥🔝 7737669865 🔝▻ narsinghpur Call-girls in Women Seeking Men 🔝narsinghpur🔝 ...
nirzagarg
 
Vip Mumbai Call Girls Mumbai Call On 9920725232 With Body to body massage wit...
Vip Mumbai Call Girls Mumbai Call On 9920725232 With Body to body massage wit...Vip Mumbai Call Girls Mumbai Call On 9920725232 With Body to body massage wit...
Vip Mumbai Call Girls Mumbai Call On 9920725232 With Body to body massage wit...
amitlee9823
 
Call Girls Hongasandra Just Call 👗 7737669865 👗 Top Class Call Girl Service B...
Call Girls Hongasandra Just Call 👗 7737669865 👗 Top Class Call Girl Service B...Call Girls Hongasandra Just Call 👗 7737669865 👗 Top Class Call Girl Service B...
Call Girls Hongasandra Just Call 👗 7737669865 👗 Top Class Call Girl Service B...
amitlee9823
 
➥🔝 7737669865 🔝▻ pathankot Call-girls in Women Seeking Men 🔝pathankot🔝 Esc...
➥🔝 7737669865 🔝▻ pathankot Call-girls in Women Seeking Men  🔝pathankot🔝   Esc...➥🔝 7737669865 🔝▻ pathankot Call-girls in Women Seeking Men  🔝pathankot🔝   Esc...
➥🔝 7737669865 🔝▻ pathankot Call-girls in Women Seeking Men 🔝pathankot🔝 Esc...
nirzagarg
 
Just Call Vip call girls Ankleshwar Escorts ☎️9352988975 Two shot with one gi...
Just Call Vip call girls Ankleshwar Escorts ☎️9352988975 Two shot with one gi...Just Call Vip call girls Ankleshwar Escorts ☎️9352988975 Two shot with one gi...
Just Call Vip call girls Ankleshwar Escorts ☎️9352988975 Two shot with one gi...
gajnagarg
 
Top profile Call Girls In dharamshala [ 7014168258 ] Call Me For Genuine Mode...
Top profile Call Girls In dharamshala [ 7014168258 ] Call Me For Genuine Mode...Top profile Call Girls In dharamshala [ 7014168258 ] Call Me For Genuine Mode...
Top profile Call Girls In dharamshala [ 7014168258 ] Call Me For Genuine Mode...
gajnagarg
 
Top Rated Call Girls South Mumbai : 9920725232 We offer Beautiful and sexy Ca...
Top Rated Call Girls South Mumbai : 9920725232 We offer Beautiful and sexy Ca...Top Rated Call Girls South Mumbai : 9920725232 We offer Beautiful and sexy Ca...
Top Rated Call Girls South Mumbai : 9920725232 We offer Beautiful and sexy Ca...
amitlee9823
 

Dernier (20)

Top Rated Call Girls Mira Road : 9920725232 We offer Beautiful and sexy Call ...
Top Rated Call Girls Mira Road : 9920725232 We offer Beautiful and sexy Call ...Top Rated Call Girls Mira Road : 9920725232 We offer Beautiful and sexy Call ...
Top Rated Call Girls Mira Road : 9920725232 We offer Beautiful and sexy Call ...
 
Connaught Place, Delhi Call girls :8448380779 Model Escorts | 100% verified
Connaught Place, Delhi Call girls :8448380779 Model Escorts | 100% verifiedConnaught Place, Delhi Call girls :8448380779 Model Escorts | 100% verified
Connaught Place, Delhi Call girls :8448380779 Model Escorts | 100% verified
 
Rekha Agarkar Escorts Service Kollam ❣️ 7014168258 ❣️ High Cost Unlimited Har...
Rekha Agarkar Escorts Service Kollam ❣️ 7014168258 ❣️ High Cost Unlimited Har...Rekha Agarkar Escorts Service Kollam ❣️ 7014168258 ❣️ High Cost Unlimited Har...
Rekha Agarkar Escorts Service Kollam ❣️ 7014168258 ❣️ High Cost Unlimited Har...
 
FULL NIGHT — 9999894380 Call Girls In Jagat Puri | Delhi
FULL NIGHT — 9999894380 Call Girls In Jagat Puri | DelhiFULL NIGHT — 9999894380 Call Girls In Jagat Puri | Delhi
FULL NIGHT — 9999894380 Call Girls In Jagat Puri | Delhi
 
Vip Mumbai Call Girls Colaba Call On 9920725232 With Body to body massage wit...
Vip Mumbai Call Girls Colaba Call On 9920725232 With Body to body massage wit...Vip Mumbai Call Girls Colaba Call On 9920725232 With Body to body massage wit...
Vip Mumbai Call Girls Colaba Call On 9920725232 With Body to body massage wit...
 
Is Your Volvo XC90 Displaying Anti-Skid Service Required Alert Here's Why
Is Your Volvo XC90 Displaying Anti-Skid Service Required Alert Here's WhyIs Your Volvo XC90 Displaying Anti-Skid Service Required Alert Here's Why
Is Your Volvo XC90 Displaying Anti-Skid Service Required Alert Here's Why
 
➥🔝 7737669865 🔝▻ Asansol Call-girls in Women Seeking Men 🔝Asansol🔝 Escorts...
➥🔝 7737669865 🔝▻ Asansol Call-girls in Women Seeking Men  🔝Asansol🔝   Escorts...➥🔝 7737669865 🔝▻ Asansol Call-girls in Women Seeking Men  🔝Asansol🔝   Escorts...
➥🔝 7737669865 🔝▻ Asansol Call-girls in Women Seeking Men 🔝Asansol🔝 Escorts...
 
Call Girls Bangalore Just Call 👗 7737669865 👗 Top Class Call Girl Service Ban...
Call Girls Bangalore Just Call 👗 7737669865 👗 Top Class Call Girl Service Ban...Call Girls Bangalore Just Call 👗 7737669865 👗 Top Class Call Girl Service Ban...
Call Girls Bangalore Just Call 👗 7737669865 👗 Top Class Call Girl Service Ban...
 
8377087607, Door Step Call Girls In Majnu Ka Tilla (Delhi) 24/7 Available
8377087607, Door Step Call Girls In Majnu Ka Tilla (Delhi) 24/7 Available8377087607, Door Step Call Girls In Majnu Ka Tilla (Delhi) 24/7 Available
8377087607, Door Step Call Girls In Majnu Ka Tilla (Delhi) 24/7 Available
 
Call Girls Kadugodi Just Call 👗 7737669865 👗 Top Class Call Girl Service Bang...
Call Girls Kadugodi Just Call 👗 7737669865 👗 Top Class Call Girl Service Bang...Call Girls Kadugodi Just Call 👗 7737669865 👗 Top Class Call Girl Service Bang...
Call Girls Kadugodi Just Call 👗 7737669865 👗 Top Class Call Girl Service Bang...
 
Marathi Call Girls Santacruz WhatsApp +91-9930687706, Best Service
Marathi Call Girls Santacruz WhatsApp +91-9930687706, Best ServiceMarathi Call Girls Santacruz WhatsApp +91-9930687706, Best Service
Marathi Call Girls Santacruz WhatsApp +91-9930687706, Best Service
 
➥🔝 7737669865 🔝▻ narsinghpur Call-girls in Women Seeking Men 🔝narsinghpur🔝 ...
➥🔝 7737669865 🔝▻ narsinghpur Call-girls in Women Seeking Men  🔝narsinghpur🔝  ...➥🔝 7737669865 🔝▻ narsinghpur Call-girls in Women Seeking Men  🔝narsinghpur🔝  ...
➥🔝 7737669865 🔝▻ narsinghpur Call-girls in Women Seeking Men 🔝narsinghpur🔝 ...
 
What Does The Engine Malfunction Reduced Power Message Mean For Your BMW X5
What Does The Engine Malfunction Reduced Power Message Mean For Your BMW X5What Does The Engine Malfunction Reduced Power Message Mean For Your BMW X5
What Does The Engine Malfunction Reduced Power Message Mean For Your BMW X5
 
(INDIRA) Call Girl Nashik Call Now 8617697112 Nashik Escorts 24x7
(INDIRA) Call Girl Nashik Call Now 8617697112 Nashik Escorts 24x7(INDIRA) Call Girl Nashik Call Now 8617697112 Nashik Escorts 24x7
(INDIRA) Call Girl Nashik Call Now 8617697112 Nashik Escorts 24x7
 
Vip Mumbai Call Girls Mumbai Call On 9920725232 With Body to body massage wit...
Vip Mumbai Call Girls Mumbai Call On 9920725232 With Body to body massage wit...Vip Mumbai Call Girls Mumbai Call On 9920725232 With Body to body massage wit...
Vip Mumbai Call Girls Mumbai Call On 9920725232 With Body to body massage wit...
 
Call Girls Hongasandra Just Call 👗 7737669865 👗 Top Class Call Girl Service B...
Call Girls Hongasandra Just Call 👗 7737669865 👗 Top Class Call Girl Service B...Call Girls Hongasandra Just Call 👗 7737669865 👗 Top Class Call Girl Service B...
Call Girls Hongasandra Just Call 👗 7737669865 👗 Top Class Call Girl Service B...
 
➥🔝 7737669865 🔝▻ pathankot Call-girls in Women Seeking Men 🔝pathankot🔝 Esc...
➥🔝 7737669865 🔝▻ pathankot Call-girls in Women Seeking Men  🔝pathankot🔝   Esc...➥🔝 7737669865 🔝▻ pathankot Call-girls in Women Seeking Men  🔝pathankot🔝   Esc...
➥🔝 7737669865 🔝▻ pathankot Call-girls in Women Seeking Men 🔝pathankot🔝 Esc...
 
Just Call Vip call girls Ankleshwar Escorts ☎️9352988975 Two shot with one gi...
Just Call Vip call girls Ankleshwar Escorts ☎️9352988975 Two shot with one gi...Just Call Vip call girls Ankleshwar Escorts ☎️9352988975 Two shot with one gi...
Just Call Vip call girls Ankleshwar Escorts ☎️9352988975 Two shot with one gi...
 
Top profile Call Girls In dharamshala [ 7014168258 ] Call Me For Genuine Mode...
Top profile Call Girls In dharamshala [ 7014168258 ] Call Me For Genuine Mode...Top profile Call Girls In dharamshala [ 7014168258 ] Call Me For Genuine Mode...
Top profile Call Girls In dharamshala [ 7014168258 ] Call Me For Genuine Mode...
 
Top Rated Call Girls South Mumbai : 9920725232 We offer Beautiful and sexy Ca...
Top Rated Call Girls South Mumbai : 9920725232 We offer Beautiful and sexy Ca...Top Rated Call Girls South Mumbai : 9920725232 We offer Beautiful and sexy Ca...
Top Rated Call Girls South Mumbai : 9920725232 We offer Beautiful and sexy Ca...
 

01 boot process

  • 1. RHCSA BOOT CAMP The Boot Process Monday, July 11, 2011
  • 2. OVERVIEW The boot process gets a machine from the useless off state to the feature rich operating system we all know and love Requires cooperation between hardware and software to correctly hand off processing Akin to the life cycle of a human - birth, newborn, infant, toddler, teen, adult Monday, July 11, 2011
  • 3. BIRTH Power switch flipped on Electricity flows from wall, through power supply where it gets converted to the levels necessary for the computer, and on to the motherboard, drives, CPU and more Completely unaware of the world or even what’s attached to the motherboard. Monday, July 11, 2011
  • 4. INFANT BIOS - Basic Input/Output System - CPU looks for instructions starting at a specific address, which happens to be where BIOS resides. BIOS initializes and starts the.... POST - Power On Self Test - A simple set of tests that BIOS performs to verify basic functioning of attached hardware. Like an infant, extremely limited understanding of world Searches for valid MBR, loads the software found there and transfers control to the... Monday, July 11, 2011
  • 5. TODDLER Boot Loader - Special software installed to the MBR of the boot partition which selects and loads the kernel. Can be configured to immediately load the default OS, or can offer choice to user Slightly better understanding of world - can read linux filesystems, sometimes includes powerful debugging and configuration support. Main job: select and load kernel, transfer control to kernel Monday, July 11, 2011
  • 6. TEENAGER Dreaded teenager age: knows a lot about the world, but doesn’t contribute a thing. Still pretty useless. Kernel loads and initializes. Device drivers are loaded and initialized. Basic hardware checks performed. The First Process is created from nothing: init Monday, July 11, 2011
  • 7. ADULT init loads the inittab, specifying what the default runlevel should be, then additional configuration files specify what software needs to be started. init starts running all of the specified startup scripts at this point. Services are started by init, including network configurations, X Windows, network services, databases, etc. At this point, the machine is finally becoming useful: otherwise, an adult Eventually, login processes are started and the boot process is complete! Monday, July 11, 2011
  • 8. MORE ON INIT RHEL 6 marks Red Hat’s departure from the old style SystemV initialization framework. Time to [mostly] forget about inittab! RHEL 6 now uses Upstart to handle startup, shutdown and service management. http://upstart.ubuntu.com The only configuration /etc/inittab provides anymore is what the default runlevel should be, as Upstart supports the notion of runlevels to ease transition from SysV style initialization to Upstart. Monday, July 11, 2011
  • 9. UPSTART The configuration files for Upstart are under: /etc/init Files in this directory detail configuration for certain global events, like ctrl-alt-delete, as well as maintaining TTY gettys, handling runlevels and more. A runlevel defines what services are running... Monday, July 11, 2011
  • 10. RUNLEVELS Runlevels: S: System startup 0: OS stopped, machine halted ( usually powers off as well ) 1: Single user mode - for maintenance 2: Multiuser, no NFS shares 3: Full multiuser, TUI 4: Unused 5: Full multiuser, GUI 6: Reboot Monday, July 11, 2011
  • 11. RUNLEVELS telinit: Signal the init process to change the current runlevel Switching runlevels is fairly uncommon - generally only used if system maintenance needs to be performed Runlevels can be used to control what services a machine provides, and can sometimes be useful to quickly reconfigure a machine for a new task Monday, July 11, 2011
  • 12. UPSTART OVERVIEW So the basic flow of operation for Upstart is as follows: At bootup, the kernel starts /sbin/init. After /sbin/ init loads configuration files and is ready, the first event is emitted: startup The startup event causes /etc/init/rcS.conf to fire, which in turn runs the familiar /etc/rc.d/ rc.sysinit. After rc.sysinit finishes, rcS.conf uses /etc/inittab to determine the default runlevel, then runs telinit to that runlevel. Monday, July 11, 2011
  • 13. UPSTART OVERVIEW telinit emits the runlevel event, which fires off /etc/ init/rc.conf rc.conf fires off the familiar /etc/rc.d/rc script with the appropriate runlevel to fire off all of the startup scripts in the appropriate /etc/rcX.d directory. WHEW! All of this, mainly so that the transition to Upstart is relatively painless for the system administrators more comfortable with SysV initialization. Monday, July 11, 2011
  • 14. INIT SCRIPTS What is actually running in a given runlevel is defined by the init scripts for that level. That standard location for the init scripts is: /etc/rcX.d Where the X corresponds to the runlevel For example, /etc/rc5.d contains all of the init scripts that, combined, provide runlevel 5 service Monday, July 11, 2011
  • 15. RC DIRECTORIES The files in the rc directories start with either an S or a K: S means to start the service, ie run the command with “start” as an argument K means to kill the service, ie run the command with “stop” as an argument After the S or K, there is a two digit number which is used for ordering the execution of the scripts Monday, July 11, 2011
  • 16. ENTERING A RUNLEVEL So when the init process “enters” a runlevel, the steps are: Run all of the Kill scripts, in order, with “stop” as an argument Run all of the Start scripts, in order, with “start” as an argument Monday, July 11, 2011
  • 17. INIT SCRIPTS If you look closely, you will see that /etc/rcX.d actually holds a collection of symbolic links The actual script files are stored in /etc/init.d The main reason for this is so that there is only one copy of each init script, reducing the chance that a script change won’t be reflected in all runlevels. You can run the scripts directly, or use the service command to start/stop various components of the OS. Monday, July 11, 2011
  • 18. MANAGING INIT SCRIPTS You can manage the links to the init scripts manually, or you can use the chkconfig command to get the job done: chkconfig --list List all processes and display their default status in each run-level. chkconfig [--level levels] name <on|off|reset> This command will modify the chkconfig configuration for a particular service, setting it on/off for the given runlevels. Monday, July 11, 2011
  • 19. GRUB Grand Unified Boot Loader Recall that GRUB is responsible for the initial kernel load at boot time. Using GRUB, an administrator can control what kernel is loaded, what options are passed to the kernel, as well as initial ramdisk configurations. Monday, July 11, 2011
  • 20. GRUB CONFIGURATION GRUB’s configuration file is /boot/grub/grub.conf, which is configured as follows: default=0 timeout=10 splashimage=(hd0,0)/grub/splash.xpm.gz title RedHat Enterprise Linux ! root (hd0,0) ! kernel /vmlinuz ro root=LABEL=/ ! initrd /initrd Monday, July 11, 2011
  • 21. GRUB SHELL Command mode – Pressing “c” while the boot menu is displayed will provide the user with the GRUB shell, where a limited set of commands can be used to explore the filesystem before booting. A full list of the commands available can be found by pressing Tab while in command mode. Editing mode – Pressing “e” while the boot menu is displayed will provide the user with the opportunity to edit a line in GRUB’s configuration file. Append mode – Pressing “a” while the boot menu is displayed will allow the user to append to the kernel line for the default kernel in GRUB’s configuration file Esc – can be pressed at any time to return you to the previous menu Monday, July 11, 2011
  • 22. BOOTING TO A GIVEN RUNLEVEL Using GRUB, add a number to the end of the kernel command line to override the default runlevel. Also, adding the letter “s” or the word “single” to the end of the command line is very important: this boots into single user mode, which by default, will not require a password to obtain a root shell. Very important! Monday, July 11, 2011
  • 23. LAB 1. Reboot your machine into the single user runlevel and verify root access without a password. 2. Review a few of the init.d scripts 3. Review the configuration files in /etc/init Monday, July 11, 2011