zab bix cdf guidance

Upload: murtaza-makati

Post on 04-Jun-2018

251 views

Category:

Documents


0 download

TRANSCRIPT

  • 8/13/2019 Zab Bix Cdf Guidance

    1/27

    Guidance on Installation and Configuration of a

    Zabbix Monitoring System for CDF Offline

    Gerald Guglielmo

    (CD-doc-2659)

  • 8/13/2019 Zab Bix Cdf Guidance

    2/27

    Table of Contents

    1Introduction...........................................................................................................32Specification of ard!are "e#uirement$.............................................................3

    2.1%a$ic ard!are "ecommendation$.............................................................3 2.2&$timating Data'a$e Sie............................................................................

    3Configuration of t*e +S &n,ironment...................................................................5 3.1S ./ &n,ironment..................................................................................5

    3.1.10dditional "$ for S .2..........................................................5 3.1.2"unning nder .3.9..............................................................5 3.1.3"unning nder 5.2.5..............................................................5

    3.2S 5./ &n,ironment..................................................................................4 3.2.1"unning nder 5.1.6..............................................................4

    Configuration of t*e %acend Data'a$e...............................................................4 .1o$tgre$ Data'a$e Configuration................................................................4 .2$#l Data'a$e Configuration....................................................................7

    5%uilding and In$tallation of 8a''i.......................................................................768a''i 0gent$ and Sender$...................................................................................7

    6.1General 8a''i 0gent Configuration...........................................................9 6.1.1$er Defined :e$..........................................................................9

    6.2u$*ing 0gent Configuration to o$t$......................................................1;48a''i Ser,er......................................................................................................1;7Starting 8a''i 0gent$ and Ser,er$...................................................................1;

    7.1Starting 8a''i Ser,er Daemon................................................................1; 7.2Starting 8a''i 0gent$ on "emote o$t$.................................................1;

    924

  • 8/13/2019 Zab Bix Cdf Guidance

    3/27

    1 Introduction

    0n important feature of an operational $$tem i$ a $et of metric$ fora$$e$$ing t*e $$tem?$ performance. etric$ can 'e integrated into t*e$$tem or de,eloped out$ide t*e $$tem t*roug* aggregation of $$tem

    information. 0 e component of production $$tem$ i$ often monitoring of t*eoperational a$pect$ of t*e $$tem in real or near real time.

    =*ere are man commercial $$tem$ a$ !ell a$ freel a,aila'le $$tem$a,aila'le on t*e !e'@ and 8a''i i$ one of t*e freel a,aila'le $$tem$. 8a''ii$ an open $ource monitoring $$tem t*at can 'e do!nloaded at*ttpA>>!!!.a''i.com>. =*e $$tem$ con$i$t$ of agent$ t*at can 'e run on t*e$$tem$ to 'e monitored@ a $er,er t*at collect$ data from t*e agent$ and$tore$ it in a data'a$e@ and a !e' interface for monitoring and configuration'a$ed on p*p.

    In$talling and commi$$ioning of a monitoring $$tem for CD +ffline !ould

    *opefull impro,e t*e efficienc of operation$ and in t*e longer term reducet*e o,erall effort load re#uired to maintain t*e$e $$tem$. =*i$ document i$de$igned to pro,ide guidance on *o! 8a''i could 'e in$talled andcommi$$ioned for CD +ffline. o!e,er $ome part$ are $ufficientl generaland t*u$ it could 'e u$ed a$ a guide for ot*er proBect$.

    2 Secification of !ard"are #e$uirements

    =*e 8a''i $$tem can place a *ea, load on t*e operating $$tem. 0 #uic

    loo u$ing top $*o!$ t*at t*e a''iagent and t*e a''i $er,er place onl a$mall load on t*e $$tem for a $mall configuration of one *o$t and 2parameter$ at t*e default rate. o!e,er@ on a $ingle C 3G* proce$$or it i$$*o!ing a load a,erage around 4. =*i$ load i$ mainl from t*e o$tgre$po$tma$ter@ t*erefore for e,en from a #uic minimal te$t one i$ going to needgood *ard!are to run t*e $$tem. =*e 8a''i $er?$ anual*a$ $omeguideline$.

    2.1 Basic Hardware Recommendations

    =o monitor all of t*e node$ in t*e current C0 $$tem t*e 8a''i $er?$

    anualrecommendation i$ for at lea$t 2G% of emor and a dual coreC. Di$ $pace depend$ on t*e amount of data per monitor ccle and *o!long it !ill 'e $a,ed. o!e,er t*e $malle$t $$tem recommendation for 5;*o$t$ i$ muc* le$$ performant t*an t*e initial de$top $$tem te$ted@ andet t*e de$top !a$ $eeing a moderate load. =*i$ indicate$ t*at guidancein t*e manual ma 'e on t*e optimi$tic $ide and it mig*t 'e 'etter to go!it* a more ro'u$t $$tem. If an intermediate deploment 'ecome$

    3>24

    http://www.zabbix.com/http://www.zabbix.com/
  • 8/13/2019 Zab Bix Cdf Guidance

    4/27

    a,aila'le@ more accurate e$timate$ and under$tanding are liel to 'egenerated. period)F2F36;;F5; 'te$

    trendEda$F(item$-per-*o$tF*o$t$>17;;)F2F36;;F127 'te$

    e,entEda$F(e,ent$>period)F2F36;;F13; 'te$

    =*e *arde$t of t*e$e to e$timate i$ t*e e,ent data a$ it i$ *o! often trigger$ firein t*e $$tem. 0 ,er con$er,ati,e e,ent$>period ,alue of 1 per $econd can 'eu$ed for a !ell operating $$tem e,en !it* a large num'er of item$ monitored.&,ent$ $*ould 'e rarer t*an t*i$@ a$ t*i$ repre$ent$ pro'lem$ occurring ona,erage once per $econd in t*e production $$tem. Scale do!n e,ent data 'a$edon eperience.

    =*e a'o,e formula$ can 'e con,erted into $caling factor$ ' u$ing rea$ona'le'a$e ,alue a$$umption$. or in$tance@ it i$ *and to $ee t*e formula$ a'o,ereduced to 'te$>item-per-*o$t>minute>3;-da$ for *i$tor and trend data. Inot*er !ord$@ !*at i$ t*e impact of $toring one item e,er minute from one *o$tfor 3; da$ If !e later !ant to no! t*e ,alue for 1; item$ on eac* of 1;;;*o$t$ !e Bu$t need to multiplt ' 1;F1;;;. =o $cale to 6; da$ !ould 'e anadditional factor of t!o. et a mont* repre$ent 3; da$.

    *i$torE2.;6%>item>*o$t>minute>mont*

    trendE;.2;%>item>*o$t>minute>mont*

    0$$ume 2; item$ per *o$t and 1;;; *o$t$@ t*en !e *a,e

    *i$torE;G%>minute>mont*

    trendE3.G%>minute>mont*

    If !e furt*er increa$ed t*e trend $a,ing period to 3 mont*$@ t*at !ould 'oo$t t*etrend to a'out 12G%@ and t*e *i$tor plu$ trend to a'out 52 G%.

    =*e o,erl pe$$imi$tic e,ent data for one mont* !ould 'e

    e,entE321%

    and if eep for a ear@ 3.7G%. =*at !ould mean 56G% for t*e $cenario. Scalingfor CD mean$ Bu$t $caling t*e *i$tor and trend data.Gerr6 tr6 to get $omee$timate$ *ere.

    >24

  • 8/13/2019 Zab Bix Cdf Guidance

    5/27

    % Configuration of t&e OS 'n(ironment

    0 li$t of $oft!are re#uirement$ for 8a''i are defined in t*e 8a''i $er?$anual!*ic* i$ a,aila'le online at *ttpA>>!!!.a''i.com>. +n Scientificinu ermi .2@ t*e in$talled ,er$ion of p*p@ ,er$ion .3.9@ *a$ a 'ug t*atcannot properl par$e $tatic function declaration$. =*ere are different !a$around t*i$ i$$ue and t*i$ $ection !ill di$cu$$ion $ome of t*e option$.

    =*e 0pac*e !e' $er,er al$o need$ to 'e running.

    3.1 SLF 4.X Environment

    %)1)1 *dditional #+Ms for S,F -)2

    =*i$ i$ a li$ting of additional rpm$ t*at ma need to 'e in$talled for S.2. =o get a late enoug* ,er$ion of t*e curl li'rarie$@ it !a$ nece$$arto get a ne!er $ource rpm from el$e!*ere and re'uild it !it* rpm'uild(rpm'uild --re'uild curl-4.15.5-2.el5.$rc.rpm). +nce re'uilt from

    $ource$@ t*e in$tallation !a$ ea$.

    "e'uilt from $ource rpm$A

    curl-4.15.5-2.i376.rpm

    curl-de,el-4.15.5-2.i376.rpm

    curl-de'uginfo-4.15.5-2.i376.rpm

    %)1)2 #unning .nder +!+ -)%)/

    0n6 rpm$ t*at need to 'e in$talled to get t*e !e' interface !oringSupport pro,ided '6 gd li'rarie$ did not come '6 default on m6mac*ine. Ga$on or aul

    =*e p*p .3.9 ,er$ion *a$ a par$ing 'ug t*at cannot *andle $taticfunction declaration$. +nce can !or around t*i$ pro'lem ' remo,ingt*e e!ord H$tatic from t*e declaration of all function$ in t*e p*p !e'interface $cript$. In ,er$ion 1.. of 8a''i it appear$ t*at t*e onl$cript !it* $tatic function declaration$ i$ p*p>include>copt.li'.p*p.

    %)1)% #unning .nder +!+ 0)2)0

    or t*e 'uild of p*p ,er$ion 5.2.5@ it !a$ nece$$ar to *a,e *ttpd-de,elin$talled. =*e ,er$ion of *ttpd-de,el in t*e S.2 um repo$itor i$$ufficient@ 'ut ma not 'e in$talled ' default (um in$tall *ttpd-de,elF).

    In$talled ,ia umA

    *ttpd-de,el-2.;.52-37.$l.2.i376.rpm

    5>24

    http://www.zabbix.com/http://www.zabbix.com/
  • 8/13/2019 Zab Bix Cdf Guidance

    6/27

    %uilt and in$talled from tar file$A

    gd-2.;.33.tar.g

    p*p-5.2.5.tar.g

    =*e gd li'rarie$ !ere need $o p*p could $upport t*e !e' interface.%uilding t*e$e li'rarie$ !a$ $imple.

    .>configure

    mae

    mae in$tall

    =*e configuration and 'uilding of p*p $*o!n !ill include $upport forpo$tgre$@ pre$uma'l for m$#l t*e configuration $tep i$ $imilar !it* a$!ap of t*e data'a$e engine name.

    .>configure --ena'le-'cmat* --!it*-ap$2E>u$r>$'in>ap$ --ena'le-gd-nati,e-ttf --!it*-pg$#l --!it*-config-file-pat*E>etc J!it*-gdE>u$r>local

    mae

    mae in$tall

    cp p*p.ini-recommended >etc>p*p.ini

    It i$ nece$$ar to $et t*e timeone in t*e p*p.ini file to a,oid annoing!arning$. It i$ al$o nece$$ar to c*ange t*e maimum eecution time to3;; $econd$ or t*e 8a''i c*ec$ on initial in$tallation !ill fail. &ditp*p.ini and add>modif t*e follo!ing line$

    date.timeoneE 0merica>C*icago

    maeecutiontimeE3;;

    In order for 0pac*e to u$e t*e ne!l 'uild p*p@ 0pac*e need$ to 'econfigured to load t*e module. =*e configuration for 0pac*e on S .2mac*ine$ li$t$ t*e p*p module in t!o place$@ !*ic* i$ an error@ 'ut forcon$i$tenc and to t*e$e in$truction$ detail c*ange$ in 'ot* place$. In>etc>*ttpd>conf>*ttpd.conf@ c*ange from p*p to p*p5A

    oadodule p*p5module >u$r>li'>*ttpd>module$>li'p*p5.$o

    and in >etc>*ttpd>conf.d>p*p.conf (duplicate-'ut !a p*p configured)@

    c*ange from p*p to p*p5A

    oadodule p*p5module module$>li'p*p5.$o

    6>24

  • 8/13/2019 Zab Bix Cdf Guidance

    7/27

    3.2 SLF .X Environment

    S 5./ come$ !it* p*p 5.1.6@ it i$ 'elie,ed t*at t*i$ ,er$ion of p*p doe$not *a,e a pro'lem par$ing $tatic function declaration$ 'a$ed on article$po$ted on t*e Internet di$cu$$ing 8a''i in$tallation on "& 5. =*ereforea $tandard S 5./ in$tallation@ per*ap$ !it* a um in$tall Hp*pF@ $*ould'e compati'le !it* t*e 8a''i di$tri'ution a$ i$. It i$ *ig*l liel *o!e,er

    t*at t*e timeone $etting and ma... !ill $till need to 'e $et in p*p.ini@e$peciall $ince t*e latter $etting i$ a re#uirement of 8a''i and not ageneral ,alue for t*e $etting.

    an$

  • 8/13/2019 Zab Bix Cdf Guidance

    8/27

    i$ 'a$ed on *i$ eperience !it* t*at in$tallation. a$ u$er po$tgre$AIn$tall po$tgre$ and mae $ure it i$ running. (c*ec tail -f>,ar>li'>pg$#l>pg$tartup.log if t*ere are an pro'lem$ $tarting up t*edata'a$e $er,er).>u$r>'in>createu$er (a''i -created' --no-createrole --p!prompt>u$r>'in>createu$er (a''i --created' --no-createrole --p!prompt

    created' -+ (a''i (a''i

    S*ould include *ere information on default o$tgre$ configuration.

    =*e 8a''i $er?$ anual$*ould 'e u$ed for t*e detail$ of t*i$ proce$$.0$$uming a u$er account *a$ 'een created ' t*e initial configuration oft*e data'a$e engine@ t*ere are onl a fe! $tep$ t*at need to 'eaccompli$*ed. ir$t log into t*e data'a$e and create a ne! data'a$e calleda''i. 0fter logging out t*e remaining ta$$ are to create t*e data'a$eta'le$@ load initial data and load initial image$. 8a''i pro,ide$ $#l $cript$for accompli$*ing eac* of t*e$e ta$$.

    4.2 %&s'( Database "on#ig$ration

    S*ould include *ere information on default 6$#l configuration.

    =*e 8a''i $er?$ anual$*ould 'e u$ed for t*e detail$ of t*i$ proce$$.0$$uming a u$er account *a$ 'een created ' t*e initial configuration oft*e data'a$e engine@ t*ere are onl a fe! $tep$ t*at need to 'eaccompli$*ed. ir$t log into t*e data'a$e and create a ne! data'a$e calleda''i. 0fter logging out t*e remaining ta$$ are to create t*e data'a$eta'le$@ load initial data and load initial image$. 8a''i pro,ide$ $#l $cript$for accompli$*ing eac* of t*e$e ta$$.

    0 uilding and Installation of Zabbix

    =*e 8a''i $er?$ anual i$ fairl good on *o! to 'uild t*e $er,er@ agent$and front end !e' interface. =*e !e' interface i$ p*p code and doe$ not needcompilation. o!e,er it i$ important to do a Hmae clean 'efore t*econfigure $tep to a,oid pro'lem$ due to an pre,iou$ attempt$ at mae t*atmig*t *a,e occurred.

    =*e follo!ing $tep$ $*o! *o! to 'uild and in$tall t*e $er,er@ agent$ and frontend !e' interface u$ing o$tgre$. or $#l one !ould Bu$t replace J!it*-po$tgre$ !it* J!it*-m$#l. =*e 'uild can 'e done a$ an normal u$er@*o!e,er t*e in$tallation $tep $*ould 'e done a$ root. Kote t*at t*e !e'interface code !ill need to 'e copied to a ne! director called a''i undert*e root director $pecified in t*e 0pac*e configuration for !e' page$ ('default it $eem$ to 'e >,ar>!!!>*tml).

    7>24

  • 8/13/2019 Zab Bix Cdf Guidance

    9/27

    mae clean.>configure --!it*-pg$#l --ena'le-$er,er --ena'le-agent --!it*-li'curlmaemae in$tallmdir >,ar>!!!>*tml>(a''i

    cd frontend$>p*pcp -" F >,ar>!!!>*tml>(a''i

    Zabbix *gents and Senders

    Collection of data on t*e remote $$tem$ i$ for t*e mo$t part done ' 8a''iagent daemon$. =*e agent$ *a,e a predefined $et of e$@ or c*ec$@ t*eunder$tand@ $ome !*ic* tae parameter$@ and one can al$o add u$er definede$ in a configuration file. In man ca$e$ t*i$ mec*ani$m i$ $ufficient to doall of t*e data collection on t*e remote $$tem$. o!e,er in t*e e,ent a long

    running proce$$ need$ to periodicall mae data a,aila'le for monitoring@t*ere i$ a $ender command t*at can 'e u$ed to $end t*e data directl to t*e$er,er. =*i$ $ection !ill not di$cu$$ t*e $ender command@ a''i$ender@ andin$tead !ill focu$ on t*e agent daemon@ a''iagentd.

    ).1 *enera( +abbi, -gent "on#ig$ration

    =*e agent configuration file contain$ parameter $etting$ forcommunication 'et!een t*e agent and $er,er@ u$er defined e$ !*ic*allo! for per$onalied c*ec$@ and $ome general operating parameter$. ort*e mo$t part t*e default $etting$ are $ufficient. +ne !ill *a,e to c*ange at

    lea$t t*e Ser,er $etting I addre$$ a$ ' default it u$e$ t*e loop'acinterface 124.;.;.1. If one !ant$ to ena'le acti,e c*ec$ from t*e $er,er$ide@ t*en t*ere i$ a o$tname parameter t*at need$ to 'e c*anged@ot*er!i$e t*e default$ for 'ot* $er,er and agent port$ are fine. 0n $pecialc*ec$ t*at 8a''i doe$ not defined ' default !ill need to 'e added.

    )1)1 .ser Defined 4eys

    =*e 8a''i $er?$ anualdoe$ a fair Bo' of eplaining *o! to createu$er e$ in t*e agent configuration file. =*e declaration $tart$ !it*$erarameterE@ follo!ed ' a e name@ and t*en a comma follo!ed

    ' t*e command to eecute. or eample@ a e name of firefl6.pingi$defined to eecute a ping command t*at i$ furt*er proce$$ed u$ing nipipe$ and command$.

    $erarameterEfirefl6.ping@ping -c 1 firefl6 L grep mde, L cut -d?E? -f2 Lcut -d?>? -f1

    9>24

  • 8/13/2019 Zab Bix Cdf Guidance

    10/27

    0$ a te$t@ one can c*ec t*e ne!l defined e ' in,oing t*e agent!it* t*e te$t flagA

    'a$*-3.;;M .>(a''iagentd -tNfirefl6.pingN -c .>(a''iagentd.conf

    firefl6.ping OtL ;.;);P

    =*e output *a$ t*e $ame 'a$ic format a$ t*e predefined e$. It appear$to 'e fairl ea$ to al$o $et up u$er parameter$ t*at tae flei'leargument$A

    $erarameterEfirefl6.grepOFP@grep -c M1 M2$erarameterEfirefl6.ec*oOFP@ec*o NM1 to M2N

    Kotice t*at ou need to $pecif *o! to u$e t*e argument$@ 'ut t*at i$not $urpri$ing. 0gain te$ting t*e defined e !ill !or i$ ea$ u$ing t*ete$t flag to t*e agent.

    'a$*-3.;;M .>(a''iagentd -tNfirefl6.ec*oO$oup@ nut$PN -c

    .>(a''iagentd.conffirefl6.ec*oOec*o N$oup to nut$NP OtL$oup to nut$P

    'a$*-3.;;M .>(a''iagentd -tNfirefl6.grepOt*e@>*ome>gug>Ko,aQue$tion$.ttPN -c .>(a''iagentd.conffirefl6.grepOgrep -c t*e >*ome>gug>Ko,aQue$tion$.ttP OtL2)P

    ).2 !$sing -gent "on#ig$ration to Hosts

    Keed a !a to pu$* t*e $ame 'a$ic configuration@ alt*oug* if acti,e c*ec$are ena'led t*ere !ould need to 'e one line different in eac* one@ to all oft*e monitored node$.Ga$on and aul

    5 Zabbix Ser(er

    Configuration of t*e 8a''i Ser,er re#uire$ $etting t*e interface t*e $er,er!ill li$ten on@ !*ic* ' default i$ t*e loop'ac interface 124.;.;.1. =*e defaultport $*ould 'e $ufficient. It !ill al$o 'e nece$$ar to define t*e data'a$e u$ername in t*e configuration file@ >etc>a''i>a''i$er,er.conf@ and t*epa$$!ord for t*at u$er if needed. Kote *o! to deal !it* t*e pa$$!ord i$

    coupled to *o! t*e data'a$e !a$ originall configured@Ga$on and aul

    6 Starting Zabbix *gents and Ser(ers

    Ideall t*ere $*ould 'e a mec*ani$m for $tarting and $topping t*e $er,er andagent$ in an automated !a to a,oid *a,ing to do t*i$ ' *and on multiplemac*ine$. =*i$ could 'e done t*roug* t*e init.d mec*ani$m@ or an ot*er

    1;>24

  • 8/13/2019 Zab Bix Cdf Guidance

    11/27

    mec*ani$m in u$e for t*e $$tem$.Ga$on and aul

    an$ etc>init.d>a''iagentd and >etc>init.d>a''i$er,er and c*ange t*e%0S&DI" definition to 'eA

    %0S&DI"E>u$r>local>(a''i

    /.1 Starting +abbi, Server Daemon

    Ga$on and aul

    or automaticall $tarting t*e $er,er daemon fir$t prepare t*e $er,erdaemon $tart $cript for u$e ' c*config. &dit >etc>init.d>a''i$er,er(note t*e R a$* mar$ are re#uired)@ add near t*e top@ Bu$t 'elo!R>'in>$*AR c*configA 3)5 95 95R de$criptionA 8a''i Ser,er

    Ket u$ing c*config@ configure t*e automatic $tarting and $topping of$er,er daemon.c*config -le,el 3)5 (a''i$er,er on

    /.2 Starting +abbi, -gents on Remote Hosts

    Ga$on and aul

    or automaticall $tarting t*e agent daemon fir$t prepare t*e agentd $tart$cript@ a$ !a$ done for t*e $er,er daemon@ for u$e ' c*config. In>etc>init.d>a''iagentd (Kote t*e R *a$* mar$ are once againnece$$ar)@ add near t*e top@ Bu$t 'elo! R>'in>$*AR c*configA 3)5 95 95R de$criptionA 8a''i 0gentdKet u$ing c*config@ configure t*e automatic $tarting and $topping of t*eagentd daemon.c*config -le,el 3)5 (a''iagentd on

    / 7eb Configuration of Zabbix+n t*e fir$t attempt to login a$ t*e $uper admini$trator@ u$er 0dmin@ t*e!e' interface !ill tae ou t*roug* a $erie$ of configuration $tep$. art oft*i$ proce$$ i$ to c*ec for re#uired functionalit in p*p. 0fter t*e initialconfiguration one !ill t*en need to declare to t*e $$tem !*at *o$t$ tomonitor@ c*ec$ to perform@ trigger$ to e,aluate@ u$er$ to allo! andpermi$$ion$ to grant@ grap*$ to pro,ide@ etc.

    11>24

  • 8/13/2019 Zab Bix Cdf Guidance

    12/27

    0.1 nitia( eb "on#ig$ration

    =*ere are a $erie$ of $tep$ t*e !e' interface !ill !al ou t*roug* t*e fir$ttime ou log in under t*e 0dmin account ($uper admini$trator). +ne of t*efinal ta$$ i$ to manuall $a,e and t*en cop a p*p configuration file intot*e a''i area.

    (a''i.conf.p*p >,ar>!!!>*tml>(a''i>conf

    0.2 +abbi, em(ates

    =emplate$ !or a$ container$ to *old item$ to monitor and trigger$a$$ociated !it* t*o$e item$ $o t*at t*e can 'e applied con$i$tentl tomultiple *o$t$. 0$$ociating a template !it* a *o$t e$$entiall define$ all oft*e item$ and trigger$ in t*e template for t*e ne! *o$t at one time. =*i$greatl $implifie$ management of monitoring $imilar *o$t$. or eample@ allinu $er,er$ *a,e a >tmp director and !e mig*t !ant to monitor $pacefree for >tmp and trigger if it fall$ 'elo! 1;T. Defining a c*ec on >tmp and

    a trigger for le$$ t*an 1;T on t*at c*ec in a template mean$ all *o$t$a$$ociated !it* t*at template !ill *a,e t*e c*ec and trigger defined.=emplate$ can 'e ,ie!ed a$ grouping *o$t$ t*at need t*e $ame monitoringand triggering toget*er.

    =*e creating and configuring of template$ i$ done in $eparate $tep$. romt*e configuration page for *o$t$@ one toggle$ to H=emplate$ and t*en$elect$ HCreate =emplate. +nce created one need$ to add item$ andtrigger$. =*e form$ for creating item$ and trigger$ can 'e acce$$ed ,ia t*e$elect lin on t*e line li$ting t*e template on t*e H=emplate$ page@ ort*roug* t*e item$ or trigger$ page and $election t*e de$ired template int*e pull do!n menu.

    0dding item$ i$ fairl $traig*t for!ard. +ne need$ to define a name for t*eitem and t*e e@ !*ic* e$$entiall loo$ lie t*e input to t*e 8a''i 0gent!*en te$ting a parameter. or eample@ a e defined a$Hfirefl6.ec*oO$oup@ nut$P a$$uming t*e agent$ under$tand t*at definition.

    0dding trigger$ are a little more difficult@ 'ut once t*e pattern i$under$tood it 'ecome$ ea$ier. 0gain a name *a$ to 'e gi,en for t*e triggeralong !it* an epre$$ion to 'e e,aluated. =*e ea$ie$t !a to define anepre$$ion i$ to $elect in$ert and t*en c*oo$e t*e $elect 'utton on t*epopup menu. 0 condition !ill need to 'e defined in t*e popup form@ 'utagain t*e form gi,e$ $ome guidance *ere.

    0.3 +abbi, Host *ro$s

  • 8/13/2019 Zab Bix Cdf Guidance

    13/27

    all of t*e ,ariou$ component$ t*at $*ould 'e monitored a$ one larger unit.or eample@ con$ider a $$tem of t!o logging node$ and one data'a$enode t*at compri$e a logging $$tem. =*e t!o logger node$ mig*t *a,e onetemplate $*ared@ !*ile t*e data'a$e *a$ a different one t*at *a$ data'a$ec*ec$ defined. rom a monitoring per$pecti,e@ to $ee if t*e entire logging$$tem i$ !oring one !ant$ to monitor all t*ree node$. =o accompli$* t*i$

    ta$ one could create a ogger *o$t group and a$$ociate all t*ree node$!it* t*at *o$t group. =*i$ a$$ociation !ould t*en allo! $omeone to acce$$monitoring for t*e entire $$tem ' Bu$t $electing t*e one *o$t group.

    0.4 5sers and 5ser *ro$s

    $er$ are indi,idual account$ for logging in and acce$$ing t*e $$tem.$er group$ repre$ent a container for mapping u$er$ to *o$t$ t*roug* *o$tgroup$ and defining acce$$ permi$$ion$ on a granularit of *o$t group$. Int*i$ !a acce$$ to monitoring and configuration of monitoring for *o$t$ i$controlled ' t*e 8a''i $uper admini$trator. =*u$ it i$ fairl ea$ to define

    acce$$ control$ for u$er$ once ou no! *o!. It $*ould 'e noted *o!e,ert*i$ i$ not documented in t*e 8a''i $er?$ anualat t*i$ time.

    /)-)1 Zabbix .sers

    0dding a ne! u$er can ea$il 'e done a$ t*e 8a''i $uper admini$trator@u$er 0dmin. rom t*e admini$tration page@ clic on Create $er and fillin t*e re#ue$ted information. o$t of it i$ $traig*t for!ard and it !illtell ou if ou mi$$ an re#uired information !*en ou tr $a,ing it. In a$imple in$tallation one mig*t create an admini$tration account fordefining *o$t$@ trigger$@ etc@ and Bu$t u$e t*e gue$t account for

    monitoring. In a more comple en,ironment one mig*t !ant $eparateadmini$trator$ and ,ie!ing account$ for $eparate functional $$tem$monitored@ for eample eperiment$ or $er,ice$.

    % default 8a''i define$ a $uper admini$trator account@ called 0dmin@and a gue$t account !it*out a pa$$!ord. % default t*e gue$t account*a$ no pri,ilege$ and t*u$ cannot do an monitoring or admini$tration.

  • 8/13/2019 Zab Bix Cdf Guidance

    14/27

    to itU add t*e *o$t group$ for read-!rite or read-onl. % defaulte,ert*ing i$ configured a$ den.

    =o illu$trate t*e proce$$@ a$$ume a ne! u$er account *a$ 'een createdcalled C0"ead@ and t*e goal i$ to create and configure a ne! u$ergroup. +ne could Bu$t update an ei$ting group ' $electing it from t*eH$er Group$ page@ 'ut in t*i$ eample a ne! u$er group !ill 'e

    created. Starting on t*e 0dmini$tration page for H$er$ toggled toN$er Group$N and $elect HCreate Group. 0 form !ill appear t*at !illallo! one to create and configure t*e ne! u$er group. Kote t*at t*eform i$ identical to t*e one u$ed to update ei$ting u$er group$@ onl int*i$ ca$e t*e field$ are not et $et. or group name one !ould gi,e NC0onitoringN and t*en under $er$ $elect add to add t*e u$er$ to t*egroup. In t*i$ eample C0"ead !ould 'e $elected. 0ll t*at remain$no! i$ to add permi$$ion$ for an *o$t group$ to a$$ociate !it* t*e u$ergroup.

    +f t*e t*ree po$$i'le option$ for *o$t group$@ read-!rite@ read-onl@ and

    den@ ' default all *o$t group$ are defined a$ den. =*ere are $eparateli$t$ and 'utton$ to manage t*em for eac* categor. =*u$ acce$$permi$$ion$ are defined on t*e *o$t group le,el. In our eample !e Bu$t!ant read-onl and are a$$uming t*e *o$t group$ HC0 eadnode$ andHC0 $er,er$ !ere pre,iou$l defined. $ing t*e appropriate Hadd'utton t*e$e *o$t group$ can 'e added to t*e read-onl li$t. +nce t*econfiguration i$ $a,ed@ t*en u$er C0"ead !ill 'e a'le to ,ie! all *o$t$defined in t*o$e t!o *o$t group$.

    18 Oerational Suort

    Support of t*e 8a''i in$tallation co,er$ *ard!are and operating $$tem fort*e $er,er@ deploment of t*e 8a''i agent$ to remote node$@ and in$tallationand operation$ of t*e 8a''i $er,er and frontend in a productionen,ironment. ard!are and operating $$tem $upport could 'e pro,ided 'different functional unit$ !it*in t*e organiation if needed.

    16.1 Hardware S$ort

    =*ere are different le,el$ of *ard!are $upport t*at can 'e pro,ided.Complete *ard!are $upport mean$ *andling all *ard!are i$$ue$ do!n toreplacement of 'ad component$. o!e,er t*ere i$ no re#uirement t*at t*e

    primar *ard!are $upport organiation internall pro,ide complete*ard!are $upport@ and can delegate replacement acti,itie$ to anot*erorganiation. =*e propo$al for t*e CD C0 deploment i$ t*at t*eermila' &periment acilitie$ department t*e pro,ide t*e $ame le,el of$upport t*at t*e currentl pro,ide for ot*er C0 *ard!are.Ga$on i$current $upport 95

    1>24

  • 8/13/2019 Zab Bix Cdf Guidance

    15/27

    16.2 7erating S&stem S$ort

    Support of t*e 'a$ic operating $$tem include$ in$tallation@ upgrade$@ anddiagno$tic $upport of t*e $er,er and !e' interface mac*ine. =*e operating$$tem $*ould 'e a $tandard operating $$tem t*at t*e $upportingorganiation i$ comforta'le $upporting and i$ compati'le !it* t*e 8a''ire#uirement$. It i$ 'elie,ed t*at 8a''i !ill !or !ell under S ./ or

    S 5./@ and eit*er of t*e$e $*ould 'e $ufficient. 0$ !it* t*e *ard!are$upport@ t*e propo$al for CD C0 i$ t*at t*e ermila' &perimentacilitie$ department t*e pro,ide $upport.

    16.3 +abbi, 7erationa( S$ort

    Support !ill 'e needed for in$talling@ configuring@ upgrading andmaintaining t*e 8a''i $oft!are. =*e main purpo$e of 8a''i i$ for $$temmonitoring@ !*ic* include$ operating $$tem le,el and *ig*er le,el$er,ice$ monitoring.

  • 8/13/2019 Zab Bix Cdf Guidance

    16/27

    could $et up a trigger $o t*at it fire$ !*en a le,el reac*e$ 9;T@ 'ut doe$not clear until t*at le,el fall$ 'elo! 4;T for eample.

  • 8/13/2019 Zab Bix Cdf Guidance

    17/27

    'etter enforce acce$$ control$. Since t*e code i$ p*p $cript$@ doing t*i$ Bu$tmean$ placing t*em in t*e $ame place a$ t*e 8a''i p*p(>,ar>!!!>*tml>a''i on m te$t $etup) $cript$ and no!ing t*e proper "pat* (*ttpA>>firefl.fnal.go,>a''i>a''i=e$t.p*p).

  • 8/13/2019 Zab Bix Cdf Guidance

    18/27

    >> li$t of ei$ting group$

    >>Mgroupname$Earra()U

    Mgroupname$Earra(Ninu $er,er$N@

    NC0 $er,er$N)U

    >> ne!group@ NN if none

    Mne!groupENC0 eadnode$NU

    >> li$t of template$

    >>Mtemplatename$Earra()U

    Mtemplatename$Earra(N=emplateinuN@

    N=emplateC0N@

    N=emplateDummN)U

    >> li$t of *o$t$

    M*o$t$Earra(Nicaf;1.fnal.go,N@ Nicaf;2.fnal.go,N@

    Nicaf;3.fnal.go,N@

    Nicaf;.fnal.go,N@

    Ni$er,er99.fnal.go,N)U

    >> li$t of ip addre$$e$

    Mip$Earra(N192.167.1.1N@

    N192.167.1.2N@

    N192.167.1.3N@

    N192.167.1.N@

    N192.167.14.6N)U

    Mdn$Earra()U

    McountEcount(M*o$t$)U

    >> fill dn$ arra !it* NN a$ !e are u$ing I addre$$e$

    for(MiE;U MiWMcountU MiXX) Y

    Mdn$OP E NNU

    Z

    V

    17>24

  • 8/13/2019 Zab Bix Cdf Guidance

    19/27

    12)2)2 Main +rocessing Scrit

    Wp*p

    ec*o Nourt* te$t u$ing re#uireonce mec*ani$m for data import[nNU

    Rini$et(Nincludepat*N@ N.A.>a''i-1..>frontend$A.>a''i-1..>frontend$>p*pA.>a''i-1..>frontend$>includeN)U

    >> ,aria'le to flag config.inc.p*p to not call $etup.inc.p*p 'ecau$e I

    >> do not *a,e a configured a''i in$tallation. comment out ma'e for

    >> !oring in$tallation (gugcmdline !ould need to 'e un$et) atc*e$*ac to

    >> config.inc.p*p at t*e moment.

    MgugcmdlineE1U

    >> re#uire$ a later p*p t*an i$ on $lf

    re#uireonce Ninclude>config.inc.p*pNU

    re#uireonce Ninclude>*o$t$.inc.p*pNU

    >> Bu$t include t*e data *ere

    re#uireonce (N.>a''i=e$t.inc.p*pN)U

    re#uireonce (N.>a''iunc.inc.p*pN)U

    >> t*i$ i$ Bu$t a dump of t*e data read reformattedec*o N Group$E(NU

    foreac* (Mgroup$ a$ Mgname) Y

    ec*o NMgname@NU

    Z

    ec*o N)[nNU

    ec*o N =emplate$E(NU

    foreac* (Mtemplate$ a$ Mtname) Y

    ec*o NMtname@NU

    Z

    ec*o N)[nNU

    ec*o N Ke!groupEMne!group[nNU

    ec*o N o$t$E(NU

    19>24

  • 8/13/2019 Zab Bix Cdf Guidance

    20/27

    foreac* (M*o$t$ a$ M*name) Y

    ec*o NM*name@NU

    Z

    ec*o N)[nNU

    ec*o N I$E(NU

    foreac* (Mip$ a$ Miname) Y

    ec*o NMiname@NU

    Z

    ec*o N)[nNU

    >> map group format to data'a$e entrie$

    MgmapEgroup$cmdlinemap()U

    Mgroup$Earra()U

    foreac* (Mgmap a$ Mid EV Mname) Y if (inarra(Mname@Mgroupname$)) Y

    ec*o Natc*ed Group Mid Mname[nNU

    Mgroup$OPEMidU

    Z

    Z

    >> map template format to data'a$e entrie$

    MtmapEtemplate$cmdlinemap()U

    >>,areport(Mtmap)U

    Mtemplate$Earra()U

    foreac* (Mtmap a$ Mid EV Mname) Y

    if (inarra(Mname@Mtemplatename$)) Y

    ec*o Natc*ed =emplate Mid Mname[nNU

    Mtemplate$OMidPEMnameU

    Z

    Z

    ,areport(Mgroup$)U

    ,areport(Mtemplate$)U

    >> no! tr actuall adding *o$t$

    2;>24

  • 8/13/2019 Zab Bix Cdf Guidance

    21/27

    MindeE;U

    foreac* (M*o$t$ a$ M*o$t) Y

    ec*o NMinde MipOMindeP[nNU

    ec*o Ntringadd*o$t(M*o$t@Mport@M$tatu$@Mu$eip@Mdn$OMindeP@Mip$OMindeP@Mtemplat

    e$@Mne!group@Mgroup$)UNU add*o$t(M*o$t@Mport@M$tatu$@Mu$eip@Mdn$OMindeP@Mip$OMindeP@Mtemplate$@Mne!group@Mgroup$)U

    MindeEMindeX1U

    Z

    V

    12)2)% !eler Functions Scrit

    Wp*p>>ec*o Nunction te$ting for template$ and group$[nNU

    >> re#uire$ a later p*p t*an i$ on $lf

    re#uireonce Ninclude>config.inc.p*pNU

    re#uireonce Ninclude>*o$t$.inc.p*pNU

    function getacce$$i'le*o$t$(\Mu$erdata) Y

    Mpermre$ E &""&SS="IKGIK&U

    Mperm E &""&0D+K]U

    Mre$data E ?M*o$tdataON*o$tidNP?U

    Mu$erid E\ Mu$erdataO?u$erid?PU

    Mu$ertpe E\ Mu$erdataO?tpe?PU

    M!*ere E ??U

    M$#l E ?$elect di$tinct [email protected] a$ nodename@*.*o$tid@*.*o$t@min(r.permi$$ion) a$ [email protected]$erid ?.

    ? from *o$t$ * left Boin *o$t$group$ *g on *g.*o$tidE*.*o$tid ?.

    ? left Boin group$ g on g.groupidE*g.groupid ?.

    ? left Boin rig*t$ r on r.idEg.groupid andr.tpeE?."&S+"C&=]&G"+.

    ? left Boin u$er$group$ ug on ug.u$rgrpidEr.groupid and

    21>24

  • 8/13/2019 Zab Bix Cdf Guidance

    22/27

    ug.u$eridE?.Mu$erid.

    ? left Boin node$ n on ?.D%id2nodeid(?*.*o$tid?).?En.nodeid ?.

    M!*ere.? group '*.*[email protected]@n.name@*.*[email protected]$erid ?.

    ? order ' [email protected]@ *.*o$t@ permi$$ion de$c@ u$erid de$c?U

    Md'*o$t$ E D%$elect(M$#l)U

    Mproce$$ed E arra()U

    !*ile(M*o$tdata E D%fetc*(Md'*o$t$))

    Y

    if(i$null(M*o$tdataO?nodeid?P)) M*o$tdataO?nodeid?P Eid2nodeid(M*o$tdataO?*o$tid?P)U

    >F if no rig*t$ defined u$ed node rig*t$ F>

    if( (i$null(M*o$tdataO?permi$$ion?P) LLi$null(M*o$tdataO?u$erid?P)) )

    Y

    if( i$$et(Mproce$$edOM*o$tdataO?*o$tid?PP) )

    continueU

    if(i$$et(Mnode$))

    Y

    Mnode$ E getacce$$i'lenode$'u$er(Mu$erdata@

    &"D&K]@&"+D&G&@&""&SD0=00""0])U

    Z

    if( i$$et(Mnode$OM*o$tdataO?nodeid?PP) LLMu$ertpeEES&"=]&80%%I/S&" )

    M*o$tdataO?permi$$ion?P E &"D&K]U

    el$e

    M*o$tdataO?permi$$ion?P EMnode$OM*o$tdataO?nodeid?PPO?permi$$ion?PU

    Z

    Mproce$$edOM*o$tdataO?*o$tid?PP E trueU

    22>24

  • 8/13/2019 Zab Bix Cdf Guidance

    23/27

  • 8/13/2019 Zab Bix Cdf Guidance

    24/27

    >F if no rig*t$ defined u$ed node rig*t$ F>

    Md'group$ E D%$elect(?$elect n.nodeid a$ [email protected] a$nodename@*g.groupid@*g.name@min(r.permi$$ion) [email protected]$erid?.

    ? from group$ *g left Boin rig*t$ r on r.idE*g.groupid andr.tpeE?."&S+"C&=]&G"+.

    ? left Boin u$er$group$ g on r.groupidEg.u$rgrpid andg.u$eridE?.Mu$erid.

    ? left Boin node$ n on ?.D%id2nodeid(?*g.groupid?).?En.nodeid ?.

    M!*ere.? group ' n.nodeid@ n.name@ *g.groupid@ *[email protected]$erid@ g.u$erid ?.

    ? order ' n.name@ *g.name@ permi$$ion de$c?)U

    Mproce$$ed E arra()U

    !*ile(Mgroupdata E D%fetc*(Md'group$))

    Y

    if(i$null(MgroupdataO?nodeid?P)) MgroupdataO?nodeid?P Eid2nodeid(MgroupdataO?groupid?P)U

    >F den if no rig*t$ defined F>

    if( i$null(MgroupdataO?permi$$ion?P) LLi$null(MgroupdataO?u$erid?P) )

    Y

    if(i$$et(Mproce$$edOMgroupdataO?groupid?PP))

    continueU

    if(i$$et(Mnode$))

    Y

    Mnode$ E getacce$$i'lenode$'u$er(Mu$erdata@

    &"D&K]@&"+D&G&@&""&SD0=00""0])U

    Z

    if( i$$et(Mnode$OMgroupdataO?nodeid?PP) LLMu$ertpeEES&"=]&80%%I/S&" )

    MgroupdataO?permi$$ion?P E &"D&K]U

    2>24

  • 8/13/2019 Zab Bix Cdf Guidance

    25/27

    el$e

    MgroupdataO?permi$$ion?P EMnode$OMgroupdataO?nodeid?PPO?permi$$ion?PU

    Z

    >> Mproce$$edOMgroupdataO?permi$$ion?PP E trueU

    Mproce$$edOMgroupdataO?groupid?PP E trueU

    Mre$ultOMgroupdataO?groupid?PP E e,al(?return ?.Mre$data.?U?)U

    Z

    un$et(Mproce$$ed@ Mgroupdata@ Md'group$)U

    if(Mpermre$ EE &""&SS="IKGIK&)

    Y

    if(count(Mre$ult) EE ;)

    Mre$ult E ?-1?U

    el$e

    Mre$ult E implode(?@?@Mre$ult)U

    Z

    return Mre$ultU

    Z

    function group$cmdlinemap() Y

    glo'al MS&"D&=0ISU

    Md'groupEarra()U

    if (MS&"D&=0ISO?alia$?P EE ?0dmin?) Y

    ec*o Nde'ugA u$er 0dmin in group$cmdlinemap[nNU

    Md'group$ED%$elect(N$elect di$tinct groupid@name from group$ N.

    N !*ere groupid in (N.

    getacce$$i'legroup$'u$er(MS&"D&=0IS@&""&0D+K]@null@null@getcurrentnodeid()).

    N) order ' nameN)U

    Z el$e Y

    25>24

  • 8/13/2019 Zab Bix Cdf Guidance

    26/27

    Md'group$ED%$elect(N$elect di$tinct groupid@name from group$ N.

    N !*ere groupid in (N.

    getacce$$i'legroup$(MS&"D&=0IS).

    N) order ' nameN)U

    Z

    MgroupmapEarra()U

    !*ile(Md'groupED%fetc*(Md'group$))

    Y

    MgroupmapOMd'groupONgroupidNPPEMd'groupONnameNPU

    Z

    return MgroupmapU

    Z

    >>group$cmdlinemap()U

    function template$cmdlinemap() Y

    glo'al MS&"D&=0ISU

    if (MS&"D&=0ISO?alia$?P EE ?0dmin?) Y

    ec*o Nde'ugA u$er 0dmin in template$cmdlinemap[nNU

    Macce$$i'le*o$t$ Egetacce$$i'le*o$t$'u$er(MS&"D&=0IS@&""&0D+K])U

    Z el$e Y ec*o Nde'ugA u$er Gue$t in template$cmdlinemap[nNU

    Macce$$i'le*o$t$ E getacce$$i'le*o$t$(MS&"D&=0IS)U

    Z

    M$#l E N$elect di$tinct *.F from *o$t$ * !*ere NU

    M$#l .E D%innode(?*.*o$tid?@ Mnodeid).

    N and *.*o$tid in (N.Macce$$i'le*o$t$.N) N.

    N and *.$tatu$EN.+S=S=0=S=&0=&.

    N order ' *.*o$t@*.*o$tidNU

    Md'*o$t$ E D%$elect(M$#l)U

    26>24

  • 8/13/2019 Zab Bix Cdf Guidance

    27/27

    MtemplatemapEarra()U

    !*ile(M*o$t E D%fetc*(Md'*o$t$))

    Y

    MtemplatemapOM*o$tON*o$tidNPPEM*o$tON*o$tNPU

    Z

    return MtemplatemapU

    Z

    >>MEtemplate$cmdlinemap()U

    >>,areport(M)U

    >>MEgroup$cmdlinemap()U

    >>,areport(M)UV

    24>24