kernel - MYLINUXGURU
Download
Report
Transcript kernel - MYLINUXGURU
UNIX (Linux) Introduction
Module-1
OS Kernel
In computing, the kernel is the central component of OS.
It is a bridge between applications and the actual data processing done at
the hardware level.
The kernel's responsibilities include managing the system's resources (the
communication between hardware and software components).
CPU
• It runs the operating system and applications, constantly
receiving input from the user or active software programs.
• It processes the data and produces output, which may stored by an
application or displayed on the screen.
• The world's first CPU was introduced by Intel in 1971. The Intel 4004 was a 4-bit CPU, clocked at 740 KHz and
capable of executing up to 92,600 instructions per second. Five months after the Intel 4004, the Intel 8008
was introduced. This was the world's first 8-bit microprocessor.
• INTEL (x86)
• SPARC
• IBM POWER
• AMD
Open Source?
• Software & Source code available to all
• Freedom to distribute software and source code
• Ability to modify and create derived works
• Integrity of author’s code
FEDOROA Project
•
•
community support
Personal systems
RHEL (Red hat Enterprise Linux)
• Stable, thoroughly tested software
• Professional support servers
• Centralized Management tools for large networks
UNIX Principles
• Everything is a file (including hardware)
• Small, single purpose programs
• Ability to chain programs together to perform complex tasks
• Configuration data stored in text
Logging in to a Linux System
• Two types of login screens:
•
•
•
•
•
•
Virtual consoles (Text based) & Graphical logins (display managers)
RHEL use GNOME/KDE display manager
Run-level -3 is a text based
Up-to 6 virtual consoles & one graphical console
Switch among the virtual consoles ( Ctrl-Alt-F[1-6])
Access the graphical console by typing Ctrl-Alt-F7
Root User:
• Special administrative account
• Also called super user
• Root has complete control over system
How to login as root:
SU creates new shell as root
SUDO commands runs command as root
<id> command shows who you are?
Editing text files:
• Nano
• Gedit
• Vim
• Gvim
• VI
Important Directories
•
•
•
•
•
•
•
•
•
•
Home Directory
User Executables
System Executables
Other mounts
Configuration
Temporary files
Kernels & boot loader
Server Data
System information
Shared libraries
-
/root , /home/<username>
/bin, /usr/bin,/usr/local/bin
/sbin, /usr/sbin, /usr/local/sbin
/media , /mnt
/etc
/tmp
/boot
/var , /srv
/proc, /sys
/lib,/usr/lib, /usr/local/lib
Run Levels
• A run-level is a system state that is defined by the services listed in /etc/rc.d.
• Configuration file to update runlevel $ vi /etc/inittab update line “ id:3:initdefault:
• To check which run level your are now $ Who -r
• You can change the run level just by typing # init0 or init6 # init 5
LEVEL NAME
DESCRIPTION
Immediately shuts down system and powers it
0
Halt
off, if it can
Brings system to a bare essentials mode for
1
Single user
maintenance
2
User-defined
Custom
Multi-user with console
3
All services are running but X11
only
4
User-defined
Custom
5
Multi-user with display and
All services are running including X11 (or GUI)
console
6
Reboot
Reboots the machine
Login to running server: (Things to check)
•
•
•
•
•
•
•
•
•
Server Name <hostname>
OS Patch level <uname –a>
Run level <who –r>
OS release <cat /etc/redhat-release>
Memory /SWAP <free>
CPU count/type <cat /proc/cpuinfo>
Harddiks <fdisk –l>
Any one logged in ? <who>
Hardware detail? <demesg>
……continue
Login to running server: (Things to check)
• File system detail <df –h>
• Any volume manager? <vgs>
• Logical volumes? <lvs>
• Physical volumes? <pvs>
• What process running? <ps –ef>
• System load? <top>
• IP address? <ifconfig>
RHEL Versions: