Normation CC-BY-SA
[Link]
systemd: Evolution,
systemd: Evolution,
Revolution or Decline ?
Revolution or Decline ?
___________________________
___________________________
Huh? What's this systemd thingie doing Huh? What's this systemd thingie doing
as PID ?! as PID ?!
Matthieu CERDA
Normation CC-BY-SA
[Link]
"
Who are you ?
Name Matthieu CERDA
Email : [Link]@[Link]
Web site : [Link]
Twitter : @Kegeruneku
Job System engineer at Normation
CFEngine Enthusiast, power user and trainer
R!!er Integrator, packager
"n#rastrctre Team member
Normation CC-BY-SA
[Link]
#
What are $e going to tal% a&out
Systemd
$bt not onl%&
Normation CC-BY-SA
[Link]
'
What are $e going to tal% a&out
T'e crrent sitation o# o(en init s%stems
W'at is s%stem!)
W'at can we !o wit' it)
W'% all t'is contro*ers% abot it)
Normation CC-BY-SA
[Link]
(
)oday's ma*or o+en init systems ,-".
SysVinit + BSDinit: ,istorical- s'ell scri(t base! sim(le
init s%stems- sing .SB e/tensions on 0N1+.in/ an!
!e(en!enc% tags on BS2 to a!! !e(en!encies.
Upstart: 1bnt3s init #la*or- ses s(eci#ic
con#igration #iles $45obs6& to manage ser*ices.
OpenRC: 0entoo3s init #la*or- en'ance! S%s7init
*ersion wit' more (ower#l ser*ice con#igration +
!e(en!enc% 'an!ling.
Normation CC-BY-SA
[Link]
/
)oday's ma*or o+en init systems ,"-".
SMF: Solaris init s%stem- sing 89. : s'ell
scri(ts to !e#ine 'ow a ser*ice is to be manage!.
launchd- ses (list $/ml+binar% /ml& #iles to
!e#ine 'ow a ser*ice is to be manage!.
;src- rnit- !aemon-tools- e(oc'- ...
Normation CC-BY-SA
[Link]
0
Why so many reim+lementations ?
Performance: init se! to wor< in a seriali=e!
#as'ion- one scri(t a#ter t'e ot'er. .ong + 'ng
scri(ts > slow + 'ng boot.
Definition: No !e(en!enc% !e#inition- restart
be'a*ior- ...&
Security: E*er% (rocess is awar!e! #ll root
(ri*ileges b% !e#alt an! 'a*e to 'an!le (ri*ilege
!ro((ing b% itsel#.
Eo: 49ine is bigger.6
Normation CC-BY-SA
[Link]
1
systemd ID card
Create! + 9aintaine! b% .ennart ?oettering an! @a% Sie*ers
2ro(-in re(lacement #or S%s7init- 4nit6 base!.
0N1+.in/ s(eci#ic
'tt(:++www.#ree!es<to(.org+wi<i+So#tware+s%stem!+
Normation CC-BY-SA
[Link]
2
systemd goals
Re(lace S%s7init- 2-Bs an! !e* wit'
en'ance! #eatres
Com(letel% se(arate t'e s%stem an! t'e
a((lications
?ro*i!e ni#ie! s%stem com(onents
Enable t'e se o# an 4a((liance6 t%(e o#
o(erating s%stem
Normation CC-BY-SA
[Link]
3
4ervice management ca+a&ilities
1ses s%stem! 4nits6
?ro*i!es:
A (ossibilit% to ma<e sre a ser*ice is alwa%s
starte!
A (ossibilit% to restrict a (rocess to a s(eci#ic
Cgro(
Nati*e Soc<et + 2-Bs acti*ation
Normation CC-BY-SA
[Link]
4ervice management ca+a&ilities
E/am(le: A(enSS, nit $2ebian&
B1nitC
2escri(tion>A(enBS2 Secre S'ell ser*er
A#ter>networ<.target a!it!.ser*ice
Con!ition?at'E/ists>D+etc+ss'+ss'!EnotEtoEbeErn
BSer*iceC
En*ironmentFile>-+etc+!e#alt+ss'
E/ecStart>+sr+sbin+ss'! -2 FSS,2EA?TS
E/ecReloa!>+bin+<ill -,1? F9A"N?"2
@ill9o!e>(rocess
Restart>on-#ailre
B"nstallC
Wante!B%>[Link]
Alias>ss'!.ser*ice
Normation CC-BY-SA
[Link]
"
4oc%et activation ca+a&ilities
E/am(le: C1?S soc<et nit $2ebian&
B1nitC
2escri(tion>C1?S ?rinting Ser*ice Soc<ets
BSoc<etC
.istenStream>+*ar+rn+c(s+c([Link]<
Bin!"?*GAnl%>i(*G-onl%
B"nstallC
Wante!B%>soc<[Link]
T'is nit will start t'e ser*ice (ro*i!e! b% t'e 4c(s6
nit i# someone tries to access +*ar+rn+c(s+c([Link]<
Normation CC-BY-SA
[Link]
#
Process isolation
Ane ma% want a (rocess to be starte! wit' an isolate!
en*ironment #or secrit% reasons
s%stem! (ro*i!es se*eral wa%s to rn a (rocess in a
restricte! en*ironment:
Tra!itionnal c'roots- sing t'e 4Root2irector%6 nit
s(eci#ication
Names(ace restrictions- to #orbi! some o(erations to t'e
ser*ice $E/am(le: "naccessible2irectories to #orbi!
access to a !irector%&
Containeri=ation: 1sing a lig'tweig't containeri=ation
a((roac'
Normation CC-BY-SA
[Link]
'
systemd containers
"t3s li<e a limite! .8C- wa% easier to se.
Ane e/am(le is wort' t'osan! wor!s:
S(awn a s'ell insi!e a 2ebian testing installation
Boot an Arc'.in/ AS insi!e a container
Reboot %or own root insi!e a container $wit' btr#s or HFS&
I !ebootstra( --arc'>am!GJ testing K+!ebian+
I s%stem!-ns(awn -2 K+!ebian+
I (acstra( -c -! K+arc'+ base
I s%stem!-ns(awn -b2 K+arc'+
I btr#s sb*olme sna(s'ot + +.tm(
I s%stem!-ns(awn --(ri*ate-networ< -2 +.tm( -b
Normation CC-BY-SA
[Link]
(
systemd in a 5loud - 6irtuali7ed environment
S%stem! ten!s to become a stan!ar! in t'ose <in! o#
en*ironments
?ro*i!es interesting abstraction o# (rocesses
s%stem!-ns(awn is a great all% #or testing+continos
integration en*ironments
2oc<er : s%stem! : etc! > CoreAS
'tt(:++[Link]
Clstere! 0N1+.in/ base! 2oc<er a((liance
ser*ing AS
Normation CC-BY-SA
[Link]
/
5ontroversy ,-".
9ono(ol%
0N1+.in/ centrism
Co!e com(licate! an! bloate!
Too man% ser*ices n!er t'e same management
0NA9E relations'i(
Normation CC-BY-SA
[Link]
0
5ontroversy ,"-".
?blic commnication is... rog'.
Bro<en transition #rom S%s7init
Force! a!o(tion b% absorbing essential ser*ices
$!e*&
"nconsistent tilit% s%nta/
Normation CC-BY-SA
[Link]
1
Lestions ) :& Lestions ) :&