(CommandList children: [ (Assignment keyword: Assign_None pairs: [ (assign_pair lhs: (LeftVar name:PATH) rhs: {(/sbin) (Lit_Other ":") (/usr/sbin) (Lit_Other ":") (/bin) (Lit_Other ":") (/usr/bin)} spids: [35] ) ] spids: [35] ) (Assignment keyword: Assign_None pairs: [(assign_pair lhs:(LeftVar name:DESC) rhs:{(DQ ("Graphite backend daemon"))} spids:[44])] spids: [44] ) (Assignment keyword: Assign_None pairs: [(assign_pair lhs:(LeftVar name:NAME) rhs:{(carbon-cache)} spids:[49])] spids: [49] ) (Assignment keyword: Assign_None pairs: [ (assign_pair lhs: (LeftVar name:DAEMON) rhs: {(/usr/bin/) ($ VSub_Name "$NAME")} spids: [52] ) ] spids: [52] ) (Assignment keyword: Assign_None pairs: [ (assign_pair lhs: (LeftVar name:PIDFILE) rhs: {(/var/run/) ($ VSub_Name "$NAME") (.pid)} spids: [56] ) ] spids: [56] ) (Assignment keyword: Assign_None pairs: [ (assign_pair lhs: (LeftVar name:DAEMON_ARGS) rhs: { (DQ ("--config=/etc/carbon/carbon.conf --pidfile=") ($ VSub_Name "$PIDFILE") (" --logdir=/var/log/carbon/ start") ) } spids: [61] ) ] spids: [61] ) (Assignment keyword: Assign_None pairs: [ (assign_pair lhs: (LeftVar name:SCRIPTNAME) rhs: {(/etc/init.d/) ($ VSub_Name "$NAME")} spids: [68] ) ] spids: [68] ) (AndOr children: [ (C {(Lit_Other "[")} {(-x)} {(DQ ($ VSub_Name "$DAEMON"))} {(Lit_Other "]")}) (C {(exit)} {(0)}) ] op_id: Op_DPipe ) (AndOr children: [ (C {(Lit_Other "[")} {(-r)} {(/etc/default/graphite-carbon)} {(Lit_Other "]")}) (C {(.)} {(/etc/default/graphite-carbon)}) ] op_id: Op_DAmp ) (C {(.)} {(/lib/lsb/init-functions)}) (If arms: [ (if_arm cond: (Sentence command: (C {(Lit_Other "[")} {(KW_Bang "!")} {(-r)} {(/etc/carbon/carbon.conf)} {(Lit_Other "]")}) terminator: <Op_Semi ";"> ) action: (CommandList children: [ (AndOr children: [ (C {(Lit_Other "[")} {(DQ ($ VSub_Name "$VERBOSE"))} {(KW_Bang "!") (Lit_Other "=")} {(no)} {(Lit_Other "]")} ) (C {(echo)} {(DQ ("Missing /etc/carbon/carbon.conf - not starting."))}) ] op_id: Op_DAmp ) (C {(exit)} {(0)}) ] ) spids: [-1 123] ) ] spids: [-1 152] ) (If arms: [ (if_arm cond: (Sentence command: (C {(Lit_Other "[")} {(DQ ($ VSub_Name "$CARBON_CACHE_ENABLED"))} {(KW_Bang "!") (Lit_Other "=")} {(DQ (true))} {(Lit_Other "]")} ) terminator: <Op_Semi ";"> ) action: (CommandList children: [ (AndOr children: [ (C {(Lit_Other "[")} {(DQ ($ VSub_Name "$VERBOSE"))} {(KW_Bang "!") (Lit_Other "=")} {(no)} {(Lit_Other "]")} ) (C {(echo)} {(DQ ("carbon-cache disabled in /etc/default/graphite-carbon"))}) ] op_id: Op_DAmp ) (C {(exit)} {(0)}) ] ) spids: [-1 174] ) ] spids: [-1 203] ) (FuncDef name: do_start body: (BraceGroup children: [ (AndOr children: [ (SimpleCommand words: [ {(start-stop-daemon)} {(--start)} {(--quiet)} {(--pidfile)} {($ VSub_Name "$PIDFILE")} {(--exec)} {($ VSub_Name "$DAEMON")} {(--test)} ] redirects: [(Redirect op_id:Redir_Great arg_word:{(/dev/null)} fd:-1 spids:[229])] ) (C {(return)} {(1)}) ] op_id: Op_DPipe ) (AndOr children: [ (C {(start-stop-daemon)} {(--start)} {(--quiet)} {(--pidfile)} {($ VSub_Name "$PIDFILE")} {(--exec)} {($ VSub_Name "$DAEMON")} {(--)} {($ VSub_Name "$DAEMON_ARGS")} ) (C {(return)} {(2)}) ] op_id: Op_DPipe ) ] spids: [210] ) spids: [206 209] ) (FuncDef name: do_stop body: (BraceGroup children: [ (C {(start-stop-daemon)} {(--stop)} {(--quiet)} {(--retry) (Lit_Other "=") (TERM/30/KILL/5)} {(--pidfile)} {($ VSub_Name "$PIDFILE")} {(--name)} {($ VSub_Name "$NAME")} ) (Assignment keyword: Assign_None pairs: [ (assign_pair lhs: (LeftVar name:RETVAL) rhs: {(DQ ($ VSub_QMark "$?"))} spids: [299] ) ] spids: [299] ) (AndOr children: [ (C {(Lit_Other "[")} {(DQ ($ VSub_Name "$RETVAL"))} {(Lit_Other "=")} {(2)} {(Lit_Other "]")} ) (C {(return)} {(2)}) ] op_id: Op_DAmp ) (C {(start-stop-daemon)} {(--stop)} {(--quiet)} {(--oknodo)} {(--retry) (Lit_Other "=") (0/30/KILL/5)} {(--exec)} {($ VSub_Name "$DAEMON")} ) (AndOr children: [ (C {(Lit_Other "[")} {(DQ ($ VSub_QMark "$?"))} {(Lit_Other "=")} {(2)} {(Lit_Other "]")}) (C {(return)} {(2)}) ] op_id: Op_DAmp ) (C {(rm)} {(-f)} {($ VSub_Name "$PIDFILE")}) (C {(return)} {(DQ ($ VSub_Name "$RETVAL"))}) ] spids: [277] ) spids: [273 276] ) (Case to_match: {(DQ ($ VSub_Number "$1"))} arms: [ (case_arm pat_list: [{(start)}] action: (CommandList children: [ (AndOr children: [ (C {(Lit_Other "[")} {(DQ ($ VSub_Name "$VERBOSE"))} {(KW_Bang "!") (Lit_Other "=")} {(no)} {(Lit_Other "]")} ) (C {(log_daemon_msg)} {(DQ ("Starting ") ($ VSub_Name "$DESC"))} {(DQ ($ VSub_Name "$NAME"))} ) ] op_id: Op_DAmp ) (C {(do_start)}) (Case to_match: {(DQ ($ VSub_QMark "$?"))} arms: [ (case_arm pat_list: [{(0)} {(1)}] action: (AndOr children: [ (C {(Lit_Other "[")} {(DQ ($ VSub_Name "$VERBOSE"))} {(KW_Bang "!") (Lit_Other "=")} {(no)} {(Lit_Other "]")} ) (C {(log_end_msg)} {(0)}) ] op_id: Op_DAmp ) spids: [430 433 454 -1] ) (case_arm pat_list: [{(2)}] action: (AndOr children: [ (C {(Lit_Other "[")} {(DQ ($ VSub_Name "$VERBOSE"))} {(KW_Bang "!") (Lit_Other "=")} {(no)} {(Lit_Other "]")} ) (C {(log_end_msg)} {(1)}) ] op_id: Op_DAmp ) spids: [457 458 479 -1] ) ] spids: [421 427 482] ) ] ) spids: [387 388 485 -1] ) (case_arm pat_list: [{(stop)}] action: (CommandList children: [ (AndOr children: [ (C {(Lit_Other "[")} {(DQ ($ VSub_Name "$VERBOSE"))} {(KW_Bang "!") (Lit_Other "=")} {(no)} {(Lit_Other "]")} ) (C {(log_daemon_msg)} {(DQ ("Stopping ") ($ VSub_Name "$DESC"))} {(DQ ($ VSub_Name "$NAME"))} ) ] op_id: Op_DAmp ) (C {(do_stop)}) (Case to_match: {(DQ ($ VSub_QMark "$?"))} arms: [ (case_arm pat_list: [{(0)} {(1)}] action: (AndOr children: [ (C {(Lit_Other "[")} {(DQ ($ VSub_Name "$VERBOSE"))} {(KW_Bang "!") (Lit_Other "=")} {(no)} {(Lit_Other "]")} ) (C {(log_end_msg)} {(0)}) ] op_id: Op_DAmp ) spids: [531 534 555 -1] ) (case_arm pat_list: [{(2)}] action: (AndOr children: [ (C {(Lit_Other "[")} {(DQ ($ VSub_Name "$VERBOSE"))} {(KW_Bang "!") (Lit_Other "=")} {(no)} {(Lit_Other "]")} ) (C {(log_end_msg)} {(1)}) ] op_id: Op_DAmp ) spids: [558 559 580 -1] ) ] spids: [522 528 583] ) ] ) spids: [488 489 586 -1] ) (case_arm pat_list: [{(status)}] action: (AndOr children: [ (C {(status_of_proc)} {(DQ ($ VSub_Name "$DAEMON"))} {(DQ ($ VSub_Name "$NAME"))}) (AndOr children: [(C {(exit)} {(0)}) (C {(exit)} {($ VSub_QMark "$?")})] op_id: Op_DPipe ) ] op_id: Op_DAmp ) spids: [589 590 616 -1] ) (case_arm pat_list: [{(restart)} {(force-reload)}] action: (CommandList children: [ (C {(log_daemon_msg)} {(DQ ("Restarting ") ($ VSub_Name "$DESC"))} {(DQ ($ VSub_Name "$NAME"))} ) (C {(do_stop)}) (Case to_match: {(DQ ($ VSub_QMark "$?"))} arms: [ (case_arm pat_list: [{(0)} {(1)}] action: (CommandList children: [ (C {(do_start)}) (Case to_match: {(DQ ($ VSub_QMark "$?"))} arms: [ (case_arm pat_list: [{(0)}] action: (C {(log_end_msg)} {(0)}) spids: [667 668 674 -1] ) (case_arm pat_list: [{(1)}] action: (C {(log_end_msg)} {(1)}) spids: [677 678 684 -1] ) (case_arm pat_list: [{(Lit_Other "*")}] action: (C {(log_end_msg)} {(1)}) spids: [687 688 694 -1] ) ] spids: [658 664 697] ) ] ) spids: [649 652 700 -1] ) (case_arm pat_list: [{(Lit_Other "*")}] action: (C {(log_end_msg)} {(1)}) spids: [703 704 712 -1] ) ] spids: [640 646 715] ) ] ) spids: [619 622 718 -1] ) (case_arm pat_list: [{(Lit_Other "*")}] action: (CommandList children: [ (SimpleCommand words: [ {(echo)} { (DQ ("Usage: ") ($ VSub_Name "$SCRIPTNAME") (" {start|stop|status|restart|force-reload}") ) } ] redirects: [(Redirect op_id:Redir_GreatAnd arg_word:{(2)} fd:-1 spids:[733])] ) (C {(exit)} {(3)}) ] ) spids: [721 722 742 -1] ) ] spids: [378 384 744] ) (C {(Lit_Other ":")}) ] )