You are on page 1of 21

BInGEST

23 13 PAGE NO.
LIVE LINUX TRAININ PRORAM
AWAKENING THE YouTH
&gives euntqu no,
THROUGH A CDLTURE CF called as PID
PiGHTEDUCATIO
what is meaning ID
+Real Demonstratous

> Lets pro ceed in Day2 PID

Nofe ps -au

This coutse Graini nq wen


be repeakad in fakure (1o7S) TeDJ
hear

START sleep>
Stct e instance madiow ps-uax rep e p
ec2-ger s l e p p 3eo

NEW TOPIC
PID Civen by korne)

When yoy qo deep nte


Dev Ctt cOde
LN ou w see PID
Coupite
Compilor| s ololer ON he RAMI
macine cede
(Binary Hoally, kernel decldes
i WLat areaE shoule qle
Spacee Dreeess|
(preces)
An in s SpaceHa
Cer nel) entire code wil loededI

code asil be
Whon ur p roqreu loe ds APle te
on run by QPU a t loaded
PAM Our kerne
Code l be reLo ed ko
COhver t Enho prote3s
H e sPae
PAGE NO.:
DATE:

in us space N o , as we enoN
Nodo
procegs Fs
e n host manaqe Oun
e ata o code, older T wil help
ue now uSn Toulble shoeHn I Gpp

data we keuwe o
store E in Ale 8- Now
l e i n side older

PID is the rauwe


kerne
4telderCDir)
123
ThS Dorecieryis maunfea
he /proe tn LinuyY,
2AM
cd/eroe Here, Hhe
enHre binar
Thes are is bean stored Here
here T
10 h e direchorys
T60 2
in name w i LCode SecHan PonC{
PID ! (EnshuaHns) i s Land d
frormaion is geing
e d 1602 entre store STATIC MENJ

00m-SCore
S hu 1n some pogra
syscall protes

PCOCes
ea He

run Hme uger inpu


everyung
abou yrur process | b tor 4is ud daa
will be
dyna wre memoCY
v slatus e
Feap me
PAGE NO.
DATE: II

T s , Heap meu manaqe


fserY crical be se As developer hefr
edays most a proqrcu sespansibitR s to Pee
areakinq inpu rom hob memory spaa
user

Now 03 an Ad min_
m a ll oe ( 1uo) , ou hoe2 no ho

oe whieh cou ideu


NaLe i s y_var | wewo ea kage
HEAP>
ake_ space rom MEM
Toe) valqrind
*Nou handliuq i s meu
sudo yuw instell O
isvery eritce

Now euen allec Complere


proee3S Cop l e e 3 yalqrind --hep
t 10o byhe will
allbeahe process Res
LTkis e l cau eheeL
memory leok,ele
preeess (whlch doesn HH
cacha manaewerk
meein
$valqrine--Ieak-check =fu
- Fool- meu che ce
s 1oobyepace
wil be aven e
other proceSS
tinclode josheau
sIn nan~ std
sloufy clowly ukuzaHa
will fnerease. int meain ()
o Heap me
ahory =(dher ")
at ne ime
malloe (loo)
ully reserves o r
UndeHnoo process.
we are nof reejng

Hhdly,yoy have e bye


ybw Ing hall 9cC-cH
reboe 4he syshou 9 my app cPP
PAGE NO.:
DATE: II

wlheh dahe
Mehec
HEAP 4UWM ARy tPm -qlusr 1bin dh
CoreuHls
1o0 by hes
alloe 1roe prm -qi

_EAY SUMMAreY more ino ab ou


100byy
Sourte RPM padcaa
e r roTS
Src.pm

mya pp,c pm -q coreAls


los cuud ilos
fxing
ree fyf
Even weknoo hoto
1BM prje+ t us valgrind tool b
Tapp.C t's to hue he
COre lenousledge oHasee
valgrind -
-I heck-Fall ines
.

-ool=mewoos
ola.quE
BREAL

No chaleugo Now, wisee


now
SYSTEND
UNIT HLE

No2E ABaut CG200P

ehary C1o-o) CPU

+ For esplain us we

swI qlve wil creare seup


invali read
bcoz t's not cones Und er our space1
PAGE NO.:
- Install DATE: I

-congue
-WE3 SERVER
slar s
Apache
hHp dae

sudo YO nstall hhe ho has poe er 6

CompleleT
ereahe PAle Tissumbe
sbeonas y GUV shell |
e d /var /wws| htm -(bash )
vimal htm sh- ae
1 at

3un 23 Jau
s h shel
Permission den es
T4 sudo ch- bash -c dahe
PemiSsin de Sun 3
sudo wHI by bosh
Eren we haue2 v e roo shot
powe
Sudo powe why
ee-usa
Sudo date Pop.t

we 3ot error
Cwe (1) cmd(2
Hoes to creahe l e wi here , sdo w| ony
e2-uger aLecOUntonly OpplYto date , b u no

CULe aluays ruus ulHh nouo cne will

ePow oE who runs TUwby bash X bash is


Ha Cmd l in wi ec2 -ser

Thets hy wre a t erro


b you ser sudo
c a t > vima.
wil ruu wTHh root-
sudo bdsh -c Fm
Poer wel co me
Sudo i d
id (root) by tus trhekttsos) we

cau ge ouy targe.


PAGENO.:
DATE: II

whteh cat
uic O O

1s- usrbin lea


3eat eeshadow
ermsten dete d 11
+ chmoel uS
T e ca be
read
ls
by only rooF|} -rwSr-X-X
Cat eteshodouw
r e e t eam
Nou anyhoedy will use a
read H le
rUn by toopawer

sudo Cat letc/shodow


cat Jeeasha dauo 4
worinq
Thi's can bedone
b u Sup poce we doa'
chmoe -s usr|bin ca
houre sudo power
L rewoui ng poue(cUID)
No whou-
LO
power T c S dde yping
C a Cud e n
we hoe very eangerou5 Ct visble p n

SET UID S U I D We reghe_d vimal btm

sta He pretes
Nouo
by t's, any Cmo
uil1 ony be rUuM powe 6udo b+po
bHp
Too whoeuer runs tut e ps au grep
Cwal 11
PAGENO.:
DATE:
P no tstey
pid
nesat-tolp
Then CG20oP
Noko anybod new the Pollouo wlerever s in ONIT

Ple
ou erea Fe
wels paae
03-
ONIT He becoz i s l e
will help s manae
vimahhtm Our s e r e e C emd)

Here SysTEM CTL


Here, we sterts web ComeS in play
s e ew h hHps
s s also emd &
SySTEMD s meinteinnq t,

You usO au
systemao will ha ndle

@group hHps cma maze uni


Hle
s ban'
be aPplle
Now httpd (web server)
,
bu we c COme3 wit inburlel
fm Cndsalso ays heud, unit, le 1
Ulke hHp 11
uGr Tib systeual7
LFor s You don
att unts
ue CUA cmd ke le by
diff. ctels
htHpd vi - 1 - ) - | htpdservire

we houre o ell Servi ce


uni

our Uwuts in Uni He


LServee
e abou a r cmd hHpa
ExeeS a t = / u s T sbiol
PAGE NO.:
DATE:

Cun

Noow in t s l e wewe cam apply

Cgrop rule ws.

sysemcH status hHhpd. ed t e eyshemd ayc


serye

sudomedic
This cmd wll Ou hHtpd-seryice.d
onif

tact to eysemd.
Con ad
AcHe inacH ve
Nou here you Ca
Su dol Cre akee e wT any
stat Con
name
sats set lius !
A e ve u nnin vVimal.con

Menory Limit=1G
Talses 213 (limits25au)
Memory SM Nouo, we s e Uut
CCGToup hHpdseruree PreeesS

This is by de fault Neu you weu o


rewore h s i t s , r fle
clgeupshousinq

ournaletl hhpd, servte prio ry


vimal,cor
all loqs abou
s e Nov, we to Fell

oUr SYsheueHa

enow hpe-s0Ueed hLoinq ne


i l e or applyinq
cqroup
ImpleneN heo
by defew|E.
PACE NO.:
DATE: 1

diereus
systemetl daemon- rel oo
eysemd delts
No by tus we inHal i e now file
wpe dlaHnq sur chnges

s k e H shatus .serree o o , here we aave two


FRESH TOPIC
Orop-Ln
iaaeo lsepuM
Areh x6-
Mebr SM OPUS

ert dmd eco de FyPe


pro c e s s o r

syekewct status httpo roees sor n


S I no apolied.
ePt

CPU 2

$yshewe
Max Spe ed 2394 H

unt
This key oor CPu
Servee shodld alco
bepara shores m
Cs policy)
Meuory LmitT seeHon
dmdecode -string
processor tequen
afer aupde nq s secion|| a3qHHz
394 MHz

tese. ls cpu
shatos CPU
ONLNE
es

Meu 32.1 M mt 1G DproC


PAGE NO. :
DATE: I 1

Nou, syeheueFL is yow ins Fall tun


un e ,bu
manc.qi
He nd e d r e tona-hHp p
manaqln omd cnly ctsuwiches
prd aflnty
ps-o pdstab-C ht hHpe
h
PiD STAS
SL Ss
m eang s
1E means,HWspreqau
process S
seabter dst & 2nd CPU.
Servin now
Now, wau Jo bin
aud o -s STOP Cpido Ws process o CPY
hHp
pS - O on
gTA sye teue sho uo hHpd.se rre

Cslopped, CPU APhoiye


noF leed
oUIreHy no
appliel1
pd,eom m, rss, °lo CPPy
i n vima.con e cun
--SorF rsS
apply ePUAPHnTy
o iqhE h e Service
CPU emoryD IG
CPUAPP
No wau to dweek
d ae u o0 - T e l o a d

my Co s sudo

restart
Onn which CPU I1 sudo SuS

tund - t _ htthpd-P
on 1 s -APPini
Now hHtpd is
ony
PAGE NO.
DATE:

P xax hiererekt Curnal etl -

man syetemd.resource Sudo sysewd - run


seep 3co
- contto

Pnnin os On
Serv e

Neus,He re re Tren s ent yes


ind E o es are
So,tBle
Here is ocmd
h e r e use eon
Houo canwe ereae ou
edT& appy
Unit l e Pe Our
cpece PP.22

sudo systemd-TVn Mew Li1t: lG


ke wen on e
whc Careup Guu
or a e , cal,
docen comag Hera OS parqmoke 11Gre
paclea
yum insall mloeae
dla re oeae Pass
Sysheuol-run
Here Hey Ars No Pile
Untt l e for dde p dale ds t e y will
ere ae
g enHre da
hen heu run et lena

Hle bt afler a e nd cud i l


seta
me they wuill delehe faee tHme
e cu nmale H s cme l
alse ConRORe etll
. seruic esource HP
nillinf iE
This or netane will kelp lot
Plle ' resodrees mueu |
PAGE NO.:
DATE:

Sudo
pdate db askseF -e 1
yeheud -run
ade
P BloeLTOweaht=10 Sun Jan
, Serveee Thsdae
wwwing as unTE Cmd wl
n CPU L
Here we tidted O
to don be l l
Tegources o Hp. BREAK

oeae Pn lore in abou harduae


lshw
descriph on compu-or

-neuor

1oeahe P sud o s hw meuo


His le will Spec Htc

ho Shcwn here -C neoo


C
So agqain ruw updakedb Inl StoreAe

sudo shw -busino

l e und we have tagkse

skse Pa
c 22
cd arwwlu ml
whieh cpu
lshw - h m 7 os.hm
pro 22's
Now, eues e e o ,

This cme coan change Os.htm


He aHniy on the Hy
sudo aseset
APHnTy cho ngeed
Phs y0u donneed
res ta servire4
PACE NO.:
DATE:

$rpm kene Ho todhble (ot


ny one cpu
Ung -

sud o 2U Cpulonline
E mdin feins p u here O

noabau- yo V
Nouo yOu Only cpu
olece indi FUing
csys/des ces/ nproe2
N U M A N o d e

J415 . epuset.
cpuO

cpa sudo bash -c


epu0 on'ite echo 1 > fopul onlin e
nproe

ca cpul online 2

Lets go +o Jeep inFo


both areon U n e
CPU L44
Iproel epuin fo
Ca
QuicL WinnersCoupons
This wiI tell exac
odeleiL abru OPU.
Cwd
proe USer
l6Cpys takiua da-a tro
H e erne

C
/proel cpuinfo l qrep
physheca l harduwd
processor w e - L

stTce
PAGE NO.:
DATE: I

hp Crun by user systemd -cqepe

eysteuetl etaruus hHp


Lve stah
Coireup ysheuu.sieey kHpd. s Currewry hore is
conrol on congh pous o
resoures by elice

RAEG) Ps eo pd, e , cgre0p, com

CaG)
(2G Use Systo

hthpd (1G) Nos


ViU
ab160 M@) Pr
ec ser
Pro Pro4
M8)

sllee
6ysheus syseu
S ee Uce2
systeuetl -F slhce
toe sltee wll see
Syeeu,elice Lalces lo6 do CPU
use sttce Erun Prgg3 will Coe
heu wha will happe
syshemd cgls
cup ,
sltce
User .suce

SysheM. spe
PAGE NO.:
DATE:

dd - /Jev lzero while:


ot ev Inuil

Here, ui see one


CPO o6o 4h
t
auoef pu s
Cud fo unnt Ale bash s noo at e

eYsew CO p +aaa 190 lo


d is also talel ng

elo ele l~yakwdJsyda e 9CP


eLserue e
sudo
make sne 6pu oHine

desc =my stress


CPU A+ one pola
ICseFvee Hme ony
Exec Sfact Cmd ene nstruaHom
eloek ean execue

q eon-reloa d cat&

s,srtee not/mulH-R sleep 3co


tasti t
AaaTo you wt see dd CPU Scheduling

Cuelts a n o06 CPU

A hsHme, STATUS OFCPUU


-sherint
he
emd n ser
Vmste
Sqme
CP c p u is dle
space 1 hou)
fo 6,Hhey
ILdoJ O
neue

Tdte
beCame
PAGE NO.:
DATE:

Aer closl nqall b e( ps pd,cls Cdd


Cmdg
76T7 dd s
76s2 d TS
vmstaF
Hme
o For conttolu wa t i , shanm
6
oU Cau chd qe 4roup
iwis
sudo syteuet star s Serv ce J
ou wi 6y ul CPUsharos = 1024
shortincreasiuo
Sop hs no
has no
whle: [Serviee meani rg
ouo S y w eer buor
CPU Sheres = 12 Copavisl
nereasin
8 hile lop
S2
( /)tatfHme
Hwe
Shart
si 66
TesarE

herer 33
egta s2
CPU
UsIng
me shuting
ewor
This wi anly

Susteu wih TS elass


-m

Dohile chrtp 7796


0op S C H E D _ O T H E

333

33
PAGE NO.:
DATE:

f o che ngin s chedaliug yoU want. some


o f your process neec to be

eretutecl o gher priariky


Serutee
heu v cau tell CPU
CPU Sh edu llingPolicy complehe e t proeessS
in 10me s ind o
heeyou Ca s chedlabars are nownS
wrtte your desrog as Deadlne scheduers I|
sohedauug polic eehrE
tor 6m
SCRED-DEADTINE
mpsta

sudo yow nsta syssea e h r E -d --sehed-runHwe seoo

s che d- deadu ne

ae wHin
per cpU i s
npsa your cw
nano
nae sec

mpstat -P ALL ( No iwill see w


euer not aGn some mareP
one
30l Cpu 1last Hme Hhe
Se con
wore on lo0 °
updale
Ro many PToCesS
One more power tul
are in y queue

Sar Sudo yom install per


we nee c perfotmance
soma ng Cpu

r2
SwTTthiy

aene4)
PAGENO:
DATE:

sched recore syceud

slecp 20
soekeF

Noig hs 20 see Servte

Hme
ohat hauppened to
POiEwH sere
systeuet tist- unitles

AS
sCePe

servee

Sockat

Pet sche d mels hee

arge
Yme

It s similar e CRONTAS8
b wh weore funehienalh
BREAL

8ystewd- run toudh hh.t


Some more n on-achve-60
L +Ae Ple skauld
3J0B sCHEDULING
timer be creaed ater
Servtec
60s 1
O n On ms
CRONTAB satus me

NEW in LINOY Trhg9er a3s ToF

(bnit) APter 3s Hme


-o Servhee wll auto maHeal
funed (achvates ) &- del ete
afler Hat,
PAGE NO.:
DATE:I

tot more funcHonalih


w cau cchlee_wH yuw intall hoJTsk
.Hmer11
TIMER UNIT) Cempleel|
toaick x
6udo dhsk-L
lsbl qws

Xvda volomes
xvda 10 G
Xvdoa2 a same Pertm
tsAtadh
votume
By dhan ce iE your
parHH on del ehed

vd
caf PPP, txE pdisk -/avaf
ello
PPP.tx
2
Hoo to qeF bac
Creatod T
OU le22
ms.ext2
Tool Jestdiuk 4 meeir mydatg
nToes|xudf
sudo yom insal esTJ mydalqa
no available -h
daP fnstall/epe epel

reboo7

/sdeuIxvdf1 mydag
CphA
PAGE NO.
DATE: II

Tydate ls
botr
oueh b .
here 1 s
rm b.F

Usembace mye n e moreHing


ma
naina & me itor

4 Umount myedaa
yow nstall cockpit
make eHine
#Hestdis CouLp elo

Eler
Disk xvda
DDL xvdp
Imel stemc restart pmlog
# Sys e e t l stas
sher
cockpi
Analyse
b Advanced
Lison [1:qoqo
P Linux

Po&s nd roe t

Crooe

GUI

Ct pm Coekpi

Copy done
PAGENO.:
DATE: 1

oep

epdump
Lnst
tep domp

ep dowp iCmP
wheu onybody
Ping to me

w ho w here

cpdu nup e p pork&o

-n)
twl show p

hthp 1 0 3 vimal.htm

11 -n hey uil|
ope palkeF

&shop
elate.

QnA
fime

END OF DAY 2
-hank yoy, sir

You might also like