(CommandList children: [ (Assignment keyword: Assign_None pairs: [(assign_pair lhs:(LhsName name:DOMAINNAME) op:Equal rhs:{(/bin/domainname)} spids:[18])] spids: [18] ) (Assignment keyword: Assign_None pairs: [(assign_pair lhs:(LhsName name:HOSTNAME) op:Equal rhs:{(/bin/hostname)} spids:[21])] spids: [21] ) (Assignment keyword: Assign_None pairs: [(assign_pair lhs:(LhsName name:YPWHICH) op:Equal rhs:{(/usr/bin/ypwhich)} spids:[24])] spids: [24] ) (Assignment keyword: Assign_None pairs: [(assign_pair lhs:(LhsName name:YPXFR) op:Equal rhs:{(/usr/libexec/ypxfr)} spids:[27])] spids: [27] ) (Assignment keyword: Assign_None pairs: [(assign_pair lhs:(LhsName name:YP_DIR) op:Equal rhs:{(/var/yp)} spids:[30])] spids: [30] ) (Assignment keyword: Assign_None pairs: [(assign_pair lhs:(LhsName name:MAKEDBM) op:Equal rhs:{(/usr/sbin/yp_mkdb)} spids:[33])] spids: [33] ) (Assignment keyword: Assign_None pairs: [ (assign_pair lhs: (LhsName name:MAPLIST) op: Equal rhs: { (DQ ('master.passwd.byname master.passwd.byuid passwd.byname passwd.byuid ') ('\t group.byname group.bygid hosts.byname hosts.byaddr services.byname ') ('\t rpc.byname rpc.bynumber networks.byname networks.byaddr netgroup ') ('\t netgroup.byuser netgroup.byhost netid.byname publickey.byname ') ('\t bootparams ethers.byname ethers.byaddr eui64.byname eui64.byid ') ('\t amd.host mail.aliases ypservers protocols.byname protocols.bynumber ') ('\t netmasks.byaddr') ) } spids: [36] ) ] spids: [36] ) (Assignment keyword: Assign_None pairs: [(assign_pair lhs:(LhsName name:ERROR_EXISTS) op:Equal rhs:{(DQ (NO))} spids:[54])] spids: [54] ) (C {(umask)} {(077)}) (Assignment keyword: Assign_None pairs: [(assign_pair lhs:(LhsName name:ERROR) op:Equal rhs:{(USAGE)} spids:[68])] spids: [68] ) (If arms: [ (if_arm cond: [(C {(Lit_Other '[')} {($ VSub_Pound '$#')} {(-eq)} {(1)} {(Lit_Other ']')})] action: [ (If arms: [ (if_arm cond: [ (C {(Lit_Other '[')} {($ VSub_Number '$1')} {(Lit_Other '=')} {(DQ (-m))} {(Lit_Other ']')} ) ] action: [ (Assignment keyword: Assign_None pairs: [ (assign_pair lhs: (LhsName name:DOMAIN) op: Equal rhs: { (CommandSubPart command_list: (CommandList children: [(C {(${ VSub_Name DOMAINNAME)})] ) left_token: <Left_Backtick '`'> spids: [112 116] ) } spids: [111] ) ] spids: [111] ) (Assignment keyword: Assign_None pairs: [ (assign_pair lhs: (LhsName name:SERVERTYPE) op: Equal rhs: {(MASTER)} spids: [119] ) ] spids: [119] ) (Assignment keyword: Assign_None pairs: [ (assign_pair lhs: (LhsName name:ERROR) op: Equal rhs: {(EmptyPart)} spids: [123] ) ] spids: [123] ) ] spids: [16777215 108] ) ] spids: [16777215 126] ) (If arms: [ (if_arm cond: [ (C {(Lit_Other '[')} {($ VSub_Number '$1')} {(Lit_Other '=')} {(DQ (-u))} {(Lit_Other ']')} ) ] action: [ (Assignment keyword: Assign_None pairs: [ (assign_pair lhs: (LhsName name:DOMAIN) op: Equal rhs: { (CommandSubPart command_list: (CommandList children: [(C {(${ VSub_Name DOMAINNAME)})] ) left_token: <Left_Backtick '`'> spids: [152 156] ) } spids: [151] ) ] spids: [151] ) (Assignment keyword: Assign_None pairs: [ (assign_pair lhs: (LhsName name:SERVERTYPE) op: Equal rhs: {(UPDATE)} spids: [159] ) ] spids: [159] ) (Assignment keyword: Assign_None pairs: [ (assign_pair lhs: (LhsName name:ERROR) op: Equal rhs: {(EmptyPart)} spids: [163] ) ] spids: [163] ) ] spids: [16777215 148] ) ] spids: [16777215 166] ) ] spids: [16777215 87] ) ] spids: [16777215 168] ) (If arms: [ (if_arm cond: [(C {(Lit_Other '[')} {($ VSub_Pound '$#')} {(-eq)} {(2)} {(Lit_Other ']')})] action: [ (If arms: [ (if_arm cond: [ (C {(Lit_Other '[')} {($ VSub_Number '$1')} {(Lit_Other '=')} {(DQ (-m))} {(Lit_Other ']')} ) ] action: [ (Assignment keyword: Assign_None pairs: [ (assign_pair lhs: (LhsName name:DOMAIN) op: Equal rhs: {(${ VSub_Number 2)} spids: [207] ) ] spids: [207] ) (Assignment keyword: Assign_None pairs: [ (assign_pair lhs: (LhsName name:SERVERTYPE) op: Equal rhs: {(MASTER)} spids: [213] ) ] spids: [213] ) (Assignment keyword: Assign_None pairs: [ (assign_pair lhs: (LhsName name:ERROR) op: Equal rhs: {(EmptyPart)} spids: [217] ) ] spids: [217] ) ] spids: [16777215 204] ) ] spids: [16777215 220] ) (If arms: [ (if_arm cond: [ (C {(Lit_Other '[')} {($ VSub_Number '$1')} {(Lit_Other '=')} {(DQ (-s))} {(Lit_Other ']')} ) ] action: [ (Assignment keyword: Assign_None pairs: [ (assign_pair lhs: (LhsName name:DOMAIN) op: Equal rhs: { (CommandSubPart command_list: (CommandList children: [(C {(${ VSub_Name DOMAINNAME)})] ) left_token: <Left_Backtick '`'> spids: [246 250] ) } spids: [245] ) ] spids: [245] ) (Assignment keyword: Assign_None pairs: [ (assign_pair lhs: (LhsName name:SERVERTYPE) op: Equal rhs: {(SLAVE)} spids: [253] ) ] spids: [253] ) (Assignment keyword: Assign_None pairs: [ (assign_pair lhs: (LhsName name:MASTER) op: Equal rhs: {(${ VSub_Number 2)} spids: [257] ) ] spids: [257] ) (Assignment keyword: Assign_None pairs: [ (assign_pair lhs: (LhsName name:ERROR) op: Equal rhs: {(EmptyPart)} spids: [263] ) ] spids: [263] ) ] spids: [16777215 242] ) ] spids: [16777215 266] ) (If arms: [ (if_arm cond: [ (C {(Lit_Other '[')} {($ VSub_Number '$1')} {(Lit_Other '=')} {(DQ (-u))} {(Lit_Other ']')} ) ] action: [ (Assignment keyword: Assign_None pairs: [ (assign_pair lhs: (LhsName name:DOMAIN) op: Equal rhs: {(${ VSub_Number 2)} spids: [291] ) ] spids: [291] ) (Assignment keyword: Assign_None pairs: [ (assign_pair lhs: (LhsName name:SERVERTYPE) op: Equal rhs: {(UPDATE)} spids: [297] ) ] spids: [297] ) (Assignment keyword: Assign_None pairs: [ (assign_pair lhs: (LhsName name:ERROR) op: Equal rhs: {(EmptyPart)} spids: [301] ) ] spids: [301] ) ] spids: [16777215 288] ) ] spids: [16777215 304] ) ] spids: [16777215 183] ) ] spids: [16777215 306] ) (If arms: [ (if_arm cond: [(C {(Lit_Other '[')} {($ VSub_Pound '$#')} {(-eq)} {(3)} {(Lit_Other ']')})] action: [ (If arms: [ (if_arm cond: [ (C {(Lit_Other '[')} {($ VSub_Number '$1')} {(Lit_Other '=')} {(DQ (-s))} {(Lit_Other ']')} ) ] action: [ (Assignment keyword: Assign_None pairs: [ (assign_pair lhs: (LhsName name:DOMAIN) op: Equal rhs: {(${ VSub_Number 3)} spids: [345] ) ] spids: [345] ) (Assignment keyword: Assign_None pairs: [ (assign_pair lhs: (LhsName name:SERVERTYPE) op: Equal rhs: {(SLAVE)} spids: [351] ) ] spids: [351] ) (Assignment keyword: Assign_None pairs: [ (assign_pair lhs: (LhsName name:MASTER) op: Equal rhs: {(${ VSub_Number 2)} spids: [355] ) ] spids: [355] ) (Assignment keyword: Assign_None pairs: [ (assign_pair lhs: (LhsName name:ERROR) op: Equal rhs: {(EmptyPart)} spids: [361] ) ] spids: [361] ) ] spids: [16777215 342] ) ] spids: [16777215 364] ) ] spids: [16777215 321] ) ] spids: [16777215 366] ) (If arms: [ (if_arm cond: [ (Sentence child: (C {(Lit_Other '[')} {(DQ (${ VSub_Name ERROR))} {(Lit_Other '=')} {(DQ (USAGE))} {(Lit_Other ']')} ) terminator: <Op_Semi ';'> ) ] action: [ (SimpleCommand words: [{(cat)}] redirects: [ (HereDoc op: <Redir_DLess '<<'> fd: 16777215 here_begin: {(EscapedLiteralPart token:<Lit_EscapedChar '\\_'>) (_usage)} here_end_span_id: 409 stdin_parts: [ ('usage: ypinit -m [domainname]\n') (' ypinit -s master_server [domainname]\n') (' ypinit -u [domainname]\n') ('\n') ("The `-m' flag builds a master YP server, and the `-s' flag builds\n") ("a slave YP server. When building a slave YP server, `master_server'\n") ('must be an existing, reachable YP server.\n') ("The `-u' is for updating the ypservers map on a master server.\n") ] ) (Redir op:<Redir_GreatAnd '1>&'> fd:1 arg_word:{(2)}) ] ) (ControlFlow token:<ControlFlow_Exit exit> arg_word:{(1)}) ] spids: [16777215 388] ) ] spids: [16777215 416] ) (If arms: [ (if_arm cond: [ (Sentence child: (C {(Lit_Other '[')} {(-z)} {(DQ (${ VSub_Name DOMAIN))} {(Lit_Other ']')}) terminator: <Op_Semi ';'> ) ] action: [ (SimpleCommand words: [{(cat)}] redirects: [ (HereDoc op: <Redir_DLess '<<'> fd: 16777215 here_begin: {(EscapedLiteralPart token:<Lit_EscapedChar '\\_'>) (_no_domain)} here_end_span_id: 452 stdin_parts: [ ("The local host's YP domain name has not been set. Please set it with\n") ('the domainname(1) command or pass the domain as an argument to ypinit(8).\n') ] ) (Redir op:<Redir_GreatAnd '1>&'> fd:1 arg_word:{(2)}) ] ) (ControlFlow token:<ControlFlow_Exit exit> arg_word:{(1)}) ] spids: [16777215 437] ) ] spids: [16777215 459] ) (Assignment keyword: Assign_None pairs: [ (assign_pair lhs: (LhsName name:HOST) op: Equal rhs: { (CommandSubPart command_list: (CommandList children:[(C {(${ VSub_Name HOSTNAME)})]) left_token: <Left_Backtick '`'> spids: [466 470] ) } spids: [465] ) ] spids: [465] ) (If arms: [ (if_arm cond: [ (Sentence child: (C {(Lit_Other '[')} {(-z)} {(DQ (${ VSub_Name HOST))} {(Lit_Other ']')}) terminator: <Op_Semi ';'> ) ] action: [ (SimpleCommand words: [{(cat)}] redirects: [ (HereDoc op: <Redir_DLess '<<'> fd: 16777215 here_begin: {(EscapedLiteralPart token:<Lit_EscapedChar '\\_'>) (_no_hostname)} here_end_span_id: 502 stdin_parts: [ ("The local host's hostname has not been set. Please set it with the\n") ('hostname(1) command.\n') ] ) (Redir op:<Redir_GreatAnd '1>&'> fd:1 arg_word:{(2)}) ] ) (ControlFlow token:<ControlFlow_Exit exit> arg_word:{(1)}) ] spids: [16777215 487] ) ] spids: [16777215 509] ) (If arms: [ (if_arm cond: [ (Sentence child: (C {(Lit_Other '[')} {(DQ (${ VSub_Name SERVERTYPE))} {(Lit_Other '=')} {(DQ (SLAVE))} {(Lit_Other ']')} ) terminator: <Op_Semi ';'> ) ] action: [ (Assignment keyword: Assign_None pairs: [ (assign_pair lhs: (LhsName name:COUNT) op: Equal rhs: { (CommandSubPart command_list: (CommandList children: [ (Pipeline children: [ (SimpleCommand words: [ {(${ VSub_Name YPWHICH)} {(-d)} {(${ VSub_Name DOMAIN)} {(-m)} ] redirects: [ (Redir op: <Redir_Great '2>'> fd: 2 arg_word: {(/dev/null)} ) ] ) (C {(grep)} {(-i)} {(${ VSub_Name MASTER)}) (C {(wc)} {(-l)}) (C {(tr)} {(-d)} {(DQ (' '))}) ] negated: F ) ] ) left_token: <Left_Backtick '`'> spids: [553 594] ) } spids: [552] ) ] spids: [552] ) (If arms: [ (if_arm cond: [ (C {(Lit_Other '[')} {(DQ ($ VSub_Name '$COUNT'))} {(Lit_Other '=')} {(DQ (0))} {(Lit_Other ']')} ) ] action: [ (SimpleCommand words: [ {(echo)} { (DQ ("Can't enumerate maps from ") (${ VSub_Name MASTER) ('. Please check that it is running.') ) } ] redirects: [(Redir op:<Redir_GreatAnd '1>&'> fd:1 arg_word:{(2)})] ) (SimpleCommand words: [{(echo)} {(DQ ('Note: using hardcoded maplist for map transfers.'))}] redirects: [(Redir op:<Redir_GreatAnd '1>&'> fd:1 arg_word:{(2)})] ) (Assignment keyword: Assign_None pairs: [ (assign_pair lhs: (LhsName name:YPMAPLIST) op: Equal rhs: {(${ VSub_Name MAPLIST)} spids: [641] ) ] spids: [641] ) ] spids: [16777215 614] ) ] else_action: [ (Assignment keyword: Assign_None pairs: [ (assign_pair lhs: (LhsName name:YPMAPLIST) op: Equal rhs: { (CommandSubPart command_list: (CommandList children: [ (Pipeline children: [ (C {(${ VSub_Name YPWHICH)} {(-d)} {(${ VSub_Name DOMAIN)} {(-m)}) (C {(cut)} {(-d) (EscapedLiteralPart token:<Lit_EscapedChar '\\ '>)} {(-f1)} ) ] negated: F ) ] ) left_token: <Left_Backtick '`'> spids: [651 672] ) } spids: [650] ) ] spids: [650] ) ] spids: [647 675] ) (SimpleCommand words: [{(echo)} {(DQ )}] redirects: [(Redir op:<Redir_GreatAnd '1>&'> fd:1 arg_word:{(2)})] ) ] spids: [16777215 549] ) ] spids: [16777215 686] ) (Assignment keyword: Assign_None pairs: [ (assign_pair lhs: (LhsName name:ID) op: Equal rhs: { (CommandSubPart command_list: (CommandList children:[(C {(id)} {(-u)})]) left_token: <Left_Backtick '`'> spids: [693 697] ) } spids: [692] ) ] spids: [692] ) (If arms: [ (if_arm cond: [ (Sentence child: (C {(Lit_Other '[')} {(DQ (${ VSub_Name ID))} {(KW_Bang '!') (Lit_Other '=')} {(DQ (0))} {(Lit_Other ']')} ) terminator: <Op_Semi ';'> ) ] action: [ (SimpleCommand words: [ {(echo)} {(DQ ('You have to be the superuser to run this. Please login as root.'))} ] redirects: [(Redir op:<Redir_GreatAnd '1>&'> fd:1 arg_word:{(2)})] ) (ControlFlow token:<ControlFlow_Exit exit> arg_word:{(1)}) ] spids: [16777215 719] ) ] spids: [16777215 736] ) (If arms: [ (if_arm cond: [ (C {(Lit_Other '[')} {(KW_Bang '!')} {(-d)} {(${ VSub_Name YP_DIR)} {(-o)} {(-f)} {(${ VSub_Name YP_DIR)} {(Lit_Other ']')} ) ] action: [ (SimpleCommand words: [ {(echo)} { (DQ ('The directory ') (${ VSub_Name YP_DIR) (" doesn't exist. Restore it from the distribution.") ) } ] redirects: [(Redir op:<Redir_GreatAnd '1>&'> fd:1 arg_word:{(2)})] ) (ControlFlow token:<ControlFlow_Exit exit> arg_word:{(1)}) ] spids: [16777215 765] ) ] spids: [16777215 787] ) (C {(echo)} {(-n)} {(DQ ('Server Type: ') (${ VSub_Name SERVERTYPE) (' Domain: ') (${ VSub_Name DOMAIN))} ) (If arms: [ (if_arm cond: [ (Sentence child: (C {(Lit_Other '[')} {(DQ (${ VSub_Name SERVERTYPE))} {(Lit_Other '=')} {(DQ (SLAVE))} {(Lit_Other ']')} ) terminator: <Op_Semi ';'> ) ] action: [(C {(echo)} {(-n)} {(DQ (' Master: ') (${ VSub_Name MASTER))})] spids: [16777215 824] ) ] spids: [16777215 838] ) (C {(echo)} {(DQ )}) (If arms: [ (if_arm cond: [ (Sentence child: (C {(Lit_Other '[')} {(DQ (${ VSub_Name SERVERTYPE))} {(KW_Bang '!') (Lit_Other '=')} {(DQ (UPDATE))} {(Lit_Other ']')} ) terminator: <Op_Semi ';'> ) ] action: [ (SimpleCommand words: [{(cat)}] redirects: [ (HereDoc op: <Redir_DLess '<<'> fd: 16777215 here_begin: {(EscapedLiteralPart token:<Lit_EscapedChar '\\_'>) (_notice1)} here_end_span_id: 880 stdin_parts: [ ('\n') ('Creating an YP server will require that you answer a few questions.\n') ('Questions will all be asked at the beginning of the procedure.\n') ('\n') ] ) ] ) (C {(echo)} {(-n)} {(DQ ('Do you want this procedure to quit on non-fatal errors? [y/n: n] '))} ) (C {(read)} {(DOEXIT)}) (Case to_match: {(${ VSub_Name DOEXIT)} arms: [ (case_arm pat_list: [{(y) (Lit_Other '*')} {(Y) (Lit_Other '*')}] action: [ (Assignment keyword: Assign_None pairs: [ (assign_pair lhs: (LhsName name:ERROR_EXIT) op: Equal rhs: {(DQ (YES))} spids: [915] ) ] spids: [915] ) ] spids: [907 912 921 16777215] ) (case_arm pat_list: [{(Lit_Other '*')}] action: [ (Assignment keyword: Assign_None pairs: [ (assign_pair lhs: (LhsName name:ERROR_EXIT) op: Equal rhs: {(DQ (NO))} spids: [928] ) ] spids: [928] ) (C {(echo)} {(DQ )}) (C {(echo)} {(DQ ('Ok, please remember to go back and redo manually whatever fails.'))} ) (C {(echo)} {(DQ ("If you don't, something might not work. "))}) ] spids: [925 926 954 16777215] ) ] spids: [898 904 957] ) (If arms: [ (if_arm cond: [ (Sentence child: (C {(Lit_Other '[')} {(-d)} {(DQ (${ VSub_Name YP_DIR) (/) (${ VSub_Name DOMAIN))} {(Lit_Other ']')} ) terminator: <Op_Semi ';'> ) ] action: [ (C {(echo)} {(DQ )}) (C {(echo)} {(-n)} { (DQ ('Can we destroy the existing ') (${ VSub_Name YP_DIR) (/) (${ VSub_Name DOMAIN) (' and its contents? [y/n: n] ') ) } ) (C {(read)} {(KILL)}) (Assignment keyword: Assign_None pairs: [ (assign_pair lhs: (LhsName name:ERROR) op: Equal rhs: {(EmptyPart)} spids: [1012] ) ] spids: [1012] ) (Case to_match: {(${ VSub_Name KILL)} arms: [ (case_arm pat_list: [{(y) (Lit_Other '*')} {(Y) (Lit_Other '*')}] action: [ (Assignment keyword: Assign_None pairs: [ (assign_pair lhs: (LhsName name:ERROR) op: Equal rhs: {(DQ (DELETE))} spids: [1032] ) ] spids: [1032] ) ] spids: [1024 1029 1038 16777215] ) (case_arm pat_list: [{(Lit_Other '*')}] action: [ (Assignment keyword: Assign_None pairs: [ (assign_pair lhs: (LhsName name:ERROR) op: Equal rhs: {(EmptyPart)} spids: [1045] ) ] spids: [1045] ) ] spids: [1042 1043 1048 16777215] ) ] spids: [1015 1021 1051] ) (If arms: [ (if_arm cond: [ (Sentence child: (C {(Lit_Other '[')} {(DQ (${ VSub_Name ERROR))} {(Lit_Other '=')} {(DQ (DELETE))} {(Lit_Other ']')} ) terminator: <Op_Semi ';'> ) ] action: [ (If arms: [ (if_arm cond: [ (Sentence child: (Pipeline children: [ (C {(rm)} {(-rf)} {(${ VSub_Name YP_DIR) (/) (${ VSub_Name DOMAIN)} ) ] negated: T ) terminator: <Op_Semi ';'> ) ] action: [ (SimpleCommand words: [ {(echo)} { (DQ ("Can't clean up old directory ") (${ VSub_Name YP_DIR) (/) (${ VSub_Name DOMAIN) (.) ) } ] redirects: [(Redir op:<Redir_GreatAnd '1>&'> fd:1 arg_word:{(2)})] ) (ControlFlow token: <ControlFlow_Exit exit> arg_word: {(1)} ) ] spids: [16777215 1094] ) ] spids: [16777215 1120] ) ] spids: [16777215 1074] ) ] else_action: [ (C {(echo)} {(DQ ('OK, please clean it up by hand and start again. Bye'))}) (ControlFlow token: <ControlFlow_Exit exit> arg_word: {(0)} ) ] spids: [1123 1138] ) ] spids: [16777215 980] ) ] spids: [16777215 1141] ) (If arms: [ (if_arm cond: [ (Sentence child: (Pipeline children: [ (C {(mkdir)} {(DQ (${ VSub_Name YP_DIR) (/) (${ VSub_Name DOMAIN))}) ] negated: T ) terminator: <Op_Semi ';'> ) ] action: [ (SimpleCommand words: [ {(echo)} { (DQ ("Can't make new directory ") (${ VSub_Name YP_DIR) (/) (${ VSub_Name DOMAIN) (.) ) } ] redirects: [(Redir op:<Redir_GreatAnd '1>&'> fd:1 arg_word:{(2)})] ) (ControlFlow token:<ControlFlow_Exit exit> arg_word:{(1)}) ] spids: [16777215 1162] ) ] spids: [16777215 1188] ) ] spids: [16777215 866] ) ] spids: [16777215 1190] ) (If arms: [ (if_arm cond: [ (Sentence child: (C {(Lit_Other '[')} {(DQ (${ VSub_Name SERVERTYPE))} {(Lit_Other '=')} {(DQ (MASTER))} {(Lit_Other ']')} ) terminator: <Op_Semi ';'> ) ] action: [ (If arms: [ (if_arm cond: [ (C {(Lit_Other '[')} {(KW_Bang '!')} {(-f)} {(${ VSub_Name YP_DIR) (/Makefile)} {(Lit_Other ']')} ) ] action: [ (If arms: [ (if_arm cond: [ (C {(Lit_Other '[')} {(KW_Bang '!')} {(-f)} {(${ VSub_Name YP_DIR) (/Makefile.dist)} {(Lit_Other ']')} ) ] action: [ (SimpleCommand words: [ {(echo)} {(DQ ("Can't find ") (${ VSub_Name YP_DIR) ('/Makefile.dist. '))} ] redirects: [(Redir op:<Redir_GreatAnd '1>&'> fd:1 arg_word:{(2)})] ) (ControlFlow token: <ControlFlow_Exit exit> arg_word: {(1)} ) ] spids: [16777215 1251] ) ] spids: [16777215 1273] ) (C {(cp)} {(${ VSub_Name YP_DIR) (/Makefile.dist)} {(${ VSub_Name YP_DIR) (/Makefile)} ) ] spids: [16777215 1232] ) ] spids: [16777215 1289] ) ] spids: [16777215 1212] ) ] spids: [16777215 1292] ) (If arms: [ (if_arm cond: [ (Sentence child: (C {(Lit_Other '[')} {(DQ (${ VSub_Name SERVERTYPE))} {(Lit_Other '=')} {(DQ (SLAVE))} {(Lit_Other ']')} ) terminator: <Op_Semi ';'> ) ] action: [ (C {(echo)} {(DQ ('There will be no further questions. The remainder of the procedure'))}) (C {(echo)} { (DQ ('should take a few minutes, to copy the databases from ') (${ VSub_Name MASTER) (.) ) } ) (ForEach iter_name: MAP iter_words: [{(${ VSub_Name YPMAPLIST)}] do_arg_iter: F body: (DoGroup children: [ (C {(echo)} {(DQ ('Transferring ') (${ VSub_Name MAP) (...))}) (If arms: [ (if_arm cond: [ (Sentence child: (Pipeline children: [ (C {(${ VSub_Name YPXFR)} {(-p)} {(${ VSub_Name YP_DIR)} {(-h)} {(${ VSub_Name MASTER)} {(-c)} {(-d)} {(${ VSub_Name DOMAIN)} {(${ VSub_Name MAP)} ) ] negated: T ) terminator: <Op_Semi ';'> ) ] action: [ (SimpleCommand words: [{(echo)} {(DQ ("Can't transfer map ") (${ VSub_Name MAP) (.))}] redirects: [(Redir op:<Redir_GreatAnd '1>&'> fd:1 arg_word:{(2)})] ) (Assignment keyword: Assign_None pairs: [ (assign_pair lhs: (LhsName name:ERROR_EXISTS) op: Equal rhs: {(DQ (YES))} spids: [1412] ) ] spids: [1412] ) (If arms: [ (if_arm cond: [ (Sentence child: (C {(Lit_Other '[')} {(DQ (${ VSub_Name ERROR_EXIT))} {(Lit_Other '=')} {(DQ (YES))} {(Lit_Other ']')} ) terminator: <Op_Semi ';'> ) ] action: [(ControlFlow token:<ControlFlow_Exit exit> arg_word:{(1)})] spids: [16777215 1437] ) ] spids: [16777215 1445] ) ] spids: [16777215 1395] ) ] spids: [16777215 1448] ) ] spids: [1348 1451] ) spids: [1342 16777215] ) (C {(echo)} {(DQ )}) (If arms: [ (if_arm cond: [ (Sentence child: (C {(Lit_Other '[')} {(DQ (${ VSub_Name ERROR_EXISTS))} {(Lit_Other '=')} {(DQ (YES))} {(Lit_Other ']')} ) terminator: <Op_Semi ';'> ) ] action: [ (SimpleCommand words: [ {(echo)} { (DQ (${ VSub_Name HOST) (' has been setup as an YP slave server with errors. ') ) } ] redirects: [(Redir op:<Redir_GreatAnd '1>&'> fd:1 arg_word:{(2)})] ) (SimpleCommand words: [{(echo)} {(DQ ('Please remember fix any problem that occurred.'))}] redirects: [(Redir op:<Redir_GreatAnd '1>&'> fd:1 arg_word:{(2)})] ) ] spids: [16777215 1480] ) ] else_action: [ (C {(echo)} { (DQ (${ VSub_Name HOST) (' has been setup as an YP slave server without any errors. ') ) } ) ] spids: [1506 1519] ) (C {(echo)} {(DQ ("Don't forget to update map ypservers on ") (${ VSub_Name MASTER) (.))}) (ControlFlow token:<ControlFlow_Exit exit> arg_word:{(0)}) ] spids: [16777215 1314] ) ] spids: [16777215 1538] ) (Assignment keyword: Assign_None pairs: [(assign_pair lhs:(LhsName name:LIST_OK) op:Equal rhs:{(DQ (NO))} spids:[1541])] spids: [1541] ) (WhileUntil keyword: <KW_While while> cond: [ (Sentence child: (C {(Lit_Other '[')} {(DQ (${ VSub_Name LIST_OK))} {(Lit_Other '=')} {(DQ (NO))} {(Lit_Other ']')} ) terminator: <Op_Semi ';'> ) ] body: (DoGroup children: [ (If arms: [ (if_arm cond: [ (Sentence child: (C {(Lit_Other '[')} {(DQ (${ VSub_Name SERVERTYPE))} {(Lit_Other '=')} {(DQ (MASTER))} {(Lit_Other ']')} ) terminator: <Op_Semi ';'> ) ] action: [ (Assignment keyword: Assign_None pairs: [ (assign_pair lhs: (LhsName name:HOST_LIST) op: Equal rhs: {(DQ (${ VSub_Name HOST))} spids: [1592] ) ] spids: [1592] ) (C {(echo)} {(DQ )}) (C {(echo)} { (DQ ( 'At this point, we have to construct a list of this domains YP servers.' ) ) } ) (C {(echo)} {(DQ (${ VSub_Name HOST) (' is already known as master server.'))}) (C {(echo)} {(DQ ('Please continue to add any slave servers, one per line. When you are'))} ) (C {(echo)} {(DQ ('done with the list, type a <control D>.'))}) (C {(echo)} {(DQ ('\tmaster server : ') (${ VSub_Name HOST))}) ] spids: [16777215 1589] ) ] spids: [16777215 1647] ) (If arms: [ (if_arm cond: [ (Sentence child: (C {(Lit_Other '[')} {(DQ (${ VSub_Name SERVERTYPE))} {(Lit_Other '=')} {(DQ (UPDATE))} {(Lit_Other ']')} ) terminator: <Op_Semi ';'> ) ] action: [ (Assignment keyword: Assign_None pairs: [ (assign_pair lhs: (LhsName name:HOST_LIST) op: Equal rhs: {(DQ (${ VSub_Name HOST))} spids: [1674] ) ] spids: [1674] ) (Assignment keyword: Assign_None pairs: [ (assign_pair lhs: (LhsName name:NEW_LIST) op: Equal rhs: {(DQ )} spids: [1682] ) ] spids: [1682] ) (Assignment keyword: Assign_None pairs: [ (assign_pair lhs: (LhsName name:MASTER_NAME) op: Equal rhs: {(DQ )} spids: [1687] ) ] spids: [1687] ) (Assignment keyword: Assign_None pairs: [ (assign_pair lhs: (LhsName name:SHORT_HOST) op: Equal rhs: { (CommandSubPart command_list: (CommandList children: [ (Pipeline children: [ (C {(echo)} {(${ VSub_Name HOST)}) (C {(cut)} {(-d.)} {(-f1)}) ] negated: F ) ] ) left_token: <Left_Backtick '`'> spids: [1693 1707] ) } spids: [1692] ) ] spids: [1692] ) (If arms: [ (if_arm cond: [ (Sentence child: (C {(Lit_Other '[')} {(-f)} {(${ VSub_Name YP_DIR) (/) (${ VSub_Name DOMAIN) (/ypservers)} {(Lit_Other ']')} ) terminator: <Op_Semi ';'> ) ] action: [ (Sentence child: (ForEach iter_name: srv iter_words: [ { (CommandSubPart command_list: (CommandList children: [ (Pipeline children: [ (C {(${ VSub_Name MAKEDBM)} {(-u)} {(${ VSub_Name YP_DIR) (/) (${ VSub_Name DOMAIN) (/ypservers) } ) (C {(grep)} {(-v)} {(DQ ('^YP'))}) (C {(tr)} {(DQ (Lit_Other '\\') (t))} {(DQ (' '))}) (C {(cut)} {(-d) (EscapedLiteralPart token: <Lit_EscapedChar '\\ '> ) } {(-f1)} ) ] negated: F ) ] ) left_token: <Left_Backtick '`'> spids: [1738 1785] ) } ] do_arg_iter: F body: (DoGroup children: [ (Assignment keyword: Assign_None pairs: [ (assign_pair lhs: (LhsName name:short_srv) op: Equal rhs: { (CommandSubPart command_list: (CommandList children: [ (Pipeline children: [ (C {(echo)} {(${ VSub_Name srv)}) (C {(cut)} {(-d.)} {(-f1)}) ] negated: F ) ] ) left_token: <Left_Backtick '`'> spids: [1793 1807] ) } spids: [1792] ) ] spids: [1792] ) (If arms: [ (if_arm cond: [ (C {(Lit_Other '[')} {(DQ (${ VSub_Name SHORT_HOST))} {(KW_Bang '!') (Lit_Other '=')} {(DQ (${ VSub_Name short_srv))} {(Lit_Other ']')} ) ] action: [ (If arms: [ (if_arm cond: [ (Sentence child: (C {(Lit_Other '[')} {(DQ (${ VSub_Name NEW_LIST))} {(Lit_Other '=')} {(DQ )} {(Lit_Other ']')} ) terminator: <Op_Semi ';'> ) ] action: [ (Assignment keyword: Assign_None pairs: [ (assign_pair lhs: (LhsName name:NEW_LIST) op: Equal rhs: {(DQ (${ VSub_Name srv))} spids: [1857] ) ] spids: [1857] ) ] spids: [16777215 1854] ) ] else_action: [ (Assignment keyword: Assign_None pairs: [ (assign_pair lhs: (LhsName name:NEW_LIST) op: Equal rhs: { (DQ (${ VSub_Name NEW_LIST) (' ') (${ VSub_Name srv) ) } spids: [1868] ) ] spids: [1868] ) ] spids: [1865 1880] ) ] spids: [16777215 1832] ) ] spids: [16777215 1883] ) ] spids: [1789 1886] ) spids: [1737 1786] ) terminator: <Op_Semi ';'> ) (Assignment keyword: Assign_None pairs: [ (assign_pair lhs: (LhsName name:MASTER_NAME) op: Equal rhs: { (CommandSubPart command_list: (CommandList children: [ (Pipeline children: [ (C {(${ VSub_Name MAKEDBM)} {(-u)} {(${ VSub_Name YP_DIR) (/) (${ VSub_Name DOMAIN) (/ypservers) } ) (C {(grep)} {(DQ ('^YP_MASTER_NAME'))}) (C {(tr)} {(DQ (Lit_Other '\\') (t))} {(DQ (' '))}) (C {(cut)} {(-d) (EscapedLiteralPart token: <Lit_EscapedChar '\\ '> ) } {(-f2)} ) ] negated: F ) ] ) left_token: <Left_Backtick '`'> spids: [1891 1936] ) } spids: [1890] ) ] spids: [1890] ) ] spids: [16777215 1729] ) ] spids: [16777215 1939] ) (C {(echo)} {(DQ )}) (C {(echo)} { (DQ ('Update the list of hosts running YP servers in domain ') (${ VSub_Name DOMAIN) (.) ) } ) (C {(echo)} {(DQ ('Master for this domain is ') (${ VSub_Name MASTER_NAME) (.))}) (C {(echo)} {(DQ )}) (C {(echo)} { (DQ ('First verify old servers, type ') (EscapedLiteralPart token: <Lit_EscapedChar '\\\\'> ) (EscapedLiteralPart token:<Lit_EscapedChar '\\\\'>) (' to remove a server.') ) } ) (C {(echo)} {(DQ ('Then add new servers, one per line. When done type a <control D>.'))} ) (C {(echo)} {(DQ )}) (C {(echo)} {(DQ ('\tmaster server : ') (${ VSub_Name HOST))}) (If arms: [ (if_arm cond: [ (Sentence child: (C {(Lit_Other '[')} {(DQ (${ VSub_Name NEW_LIST))} {(KW_Bang '!') (Lit_Other '=')} {(DQ )} {(Lit_Other ']')} ) terminator: <Op_Semi ';'> ) ] action: [ (Sentence child: (ForEach iter_name: node iter_words: [{($ VSub_Name '$NEW_LIST')}] do_arg_iter: F body: (DoGroup children: [ (C {(echo)} {(-n)} {(DQ ('\tverify host : [') (${ VSub_Name node) ('] '))} ) (C {(read)} {(verify)}) (If arms: [ (if_arm cond: [ (Sentence child: (C {(Lit_Other '[')} {(DQ (${ VSub_Name verify))} {(KW_Bang '!') (Lit_Other '=')} {(DQ (EscapedLiteralPart token:<Lit_EscapedChar '\\\\'>))} {(Lit_Other ']')} ) terminator: <Op_Semi ';'> ) ] action: [ (Assignment keyword: Assign_None pairs: [ (assign_pair lhs: (LhsName name:HOST_LIST) op: Equal rhs: { (DQ (${ VSub_Name HOST_LIST) (' ') (${ VSub_Name node) ) } spids: [2084] ) ] spids: [2084] ) ] spids: [16777215 2081] ) ] spids: [16777215 2096] ) ] spids: [2040 2099] ) spids: [2036 2038] ) terminator: <Op_Semi ';'> ) ] spids: [16777215 2028] ) ] spids: [16777215 2103] ) ] spids: [16777215 1671] ) ] spids: [16777215 2106] ) (C {(echo)} {(-n)} {(DQ ('\tnext host to add: '))}) (WhileUntil keyword: <KW_While while> cond: [(C {(read)} {(h)})] body: (DoGroup children: [ (C {(echo)} {(-n)} {(DQ ('\tnext host to add: '))}) (Assignment keyword: Assign_None pairs: [ (assign_pair lhs: (LhsName name:HOST_LIST) op: Equal rhs: {(DQ (${ VSub_Name HOST_LIST) (' ') (${ VSub_Name h))} spids: [2139] ) ] spids: [2139] ) ] spids: [2127 2151] ) ) (C {(echo)} {(DQ )}) (C {(echo)} {(DQ ('The current list of NIS servers looks like this:'))}) (C {(echo)} {(DQ )}) (ForEach iter_name: h iter_words: [ { (CommandSubPart command_list: (CommandList children:[(C {(echo)} {(${ VSub_Name HOST_LIST)})]) left_token: <Left_Backtick '`'> spids: [2181 2187] ) } ] do_arg_iter: F body: (DoGroup children:[(C {(echo)} {(${ VSub_Name h)})] spids:[2191 2201]) spids: [2180 2188] ) (C {(echo)} {(DQ )}) (C {(echo)} {(-n)} {(DQ ('Is this correct? [y/n: y] '))}) (C {(read)} {(hlist_ok)}) (Case to_match: {($ VSub_Name '$hlist_ok')} arms: [ (case_arm pat_list: [{(n) (Lit_Other '*')}] action: [(C {(echo)} {(DQ ("Let's try the whole thing again..."))})] spids: [2233 2235 2242 16777215] ) (case_arm pat_list: [{(N) (Lit_Other '*')}] action: [(C {(echo)} {(DQ ("Let's try the whole thing again..."))})] spids: [2245 2247 2254 16777215] ) (case_arm pat_list: [{(Lit_Other '*')}] action: [ (Assignment keyword: Assign_None pairs: [ (assign_pair lhs: (LhsName name:LIST_OK) op: Equal rhs: {(DQ (YES))} spids: [2260] ) ] spids: [2260] ) ] spids: [2257 2258 2264 16777215] ) ] spids: [2226 2230 2267] ) ] spids: [1566 2270] ) ) (C {(echo)} {(DQ ('Building ') (${ VSub_Name YP_DIR) (/) (${ VSub_Name DOMAIN) (/ypservers...))}) (C {(rm)} {(-f)} {(${ VSub_Name YP_DIR) (/ypservers)}) (C {(touch)} {(-f)} {(${ VSub_Name YP_DIR) (/ypservers)}) (C {(rm)} {(-f)} {(${ VSub_Name YP_DIR) (/) (${ VSub_Name DOMAIN) (/ypservers)}) (Pipeline children: [ (ForEach iter_name: host iter_words: [{(${ VSub_Name HOST_LIST)}] do_arg_iter: F body: (DoGroup children: [ (SimpleCommand words: [{(echo)} {(DQ (${ VSub_Name host) (' ') (${ VSub_Name host))}] redirects: [ (Redir op: <Redir_DGreat '>>'> fd: 16777215 arg_word: {(${ VSub_Name YP_DIR) (/ypservers)} ) ] ) (C {(echo)} {(DQ (${ VSub_Name host) (' ') (${ VSub_Name host))}) ] spids: [2329 2364] ) spids: [2323 2327] ) (C {(${ VSub_Name MAKEDBM)} {(-)} {(${ VSub_Name YP_DIR) (/) (${ VSub_Name DOMAIN) (/ypservers)}) ] negated: F ) (If arms: [ (if_arm cond: [ (Sentence child: (C {(Lit_Other '[')} {($ VSub_QMark '$?')} {(-ne)} {(0)} {(Lit_Other ']')}) terminator: <Op_Semi ';'> ) ] action: [ (SimpleCommand words: [{(echo)} {(DQ )}] redirects: [(Redir op:<Redir_GreatAnd '1>&'> fd:1 arg_word:{(2)})] ) (SimpleCommand words: [ {(echo)} { (DQ ("Couldn't build yp data base ") (${ VSub_Name YP_DIR) (/) (${ VSub_Name DOMAIN) (/ypservers.) ) } ] redirects: [(Redir op:<Redir_GreatAnd '1>&'> fd:1 arg_word:{(2)})] ) (Assignment keyword: Assign_None pairs: [ (assign_pair lhs: (LhsName name:ERROR_EXISTS) op: Equal rhs: {(DQ (YES))} spids: [2427] ) ] spids: [2427] ) (If arms: [ (if_arm cond: [ (Sentence child: (C {(Lit_Other '[')} {(DQ (${ VSub_Name ERROR_EXIT))} {(Lit_Other '=')} {(DQ (YES))} {(Lit_Other ']')} ) terminator: <Op_Semi ';'> ) ] action: [(ControlFlow token:<ControlFlow_Exit exit> arg_word:{(1)})] spids: [16777215 2452] ) ] spids: [16777215 2460] ) ] spids: [16777215 2397] ) ] spids: [16777215 2462] ) (If arms: [ (if_arm cond: [ (Sentence child: (C {(Lit_Other '[')} {(DQ (${ VSub_Name SERVERTYPE))} {(Lit_Other '=')} {(DQ (MASTER))} {(Lit_Other ']')} ) terminator: <Op_Semi ';'> ) ] action: [ (Assignment keyword: Assign_None pairs: [ (assign_pair lhs: (LhsName name:CUR_PWD) op: Equal rhs: { (CommandSubPart command_list: (CommandList children:[(C {(pwd)})]) left_token: <Left_Backtick '`'> spids: [2488 2490] ) } spids: [2487] ) ] spids: [2487] ) (C {(cd)} {(${ VSub_Name YP_DIR)}) (C {(echo)} {(DQ ('Running ') (${ VSub_Name YP_DIR) (/Makefile...))}) (If arms: [ (if_arm cond: [ (Sentence child: (Pipeline children: [ (C {(make)} {(Lit_VarLike 'NOPUSH=') (True)} {(Lit_VarLike 'UPDATE_DOMAIN=') (${ VSub_Name DOMAIN)} {(Lit_VarLike 'YP_DIR=') (${ VSub_Name YP_DIR)} ) ] negated: T ) terminator: <Op_Semi ';'> ) ] action: [ (SimpleCommand words: [{(echo)} {(DQ )}] redirects: [(Redir op:<Redir_GreatAnd '1>&'> fd:1 arg_word:{(2)})] ) (SimpleCommand words: [{(echo)} {(DQ ('Error running Makefile.'))}] redirects: [(Redir op:<Redir_GreatAnd '1>&'> fd:1 arg_word:{(2)})] ) (Assignment keyword: Assign_None pairs: [ (assign_pair lhs: (LhsName name:ERROR_EXISTS) op: Equal rhs: {(DQ (YES))} spids: [2553] ) ] spids: [2553] ) (If arms: [ (if_arm cond: [ (Sentence child: (C {(Lit_Other '[')} {(DQ (${ VSub_Name ERROR_EXIT))} {(Lit_Other '=')} {(DQ (YES))} {(Lit_Other ']')} ) terminator: <Op_Semi ';'> ) ] action: [(ControlFlow token:<ControlFlow_Exit exit> arg_word:{(1)})] spids: [16777215 2578] ) ] spids: [16777215 2586] ) ] spids: [16777215 2531] ) ] spids: [16777215 2589] ) (C {(cd)} {(${ VSub_Name CUR_PWD)}) (C {(echo)} {(DQ )}) (If arms: [ (if_arm cond: [ (Sentence child: (C {(Lit_Other '[')} {(DQ (${ VSub_Name ERROR_EXISTS))} {(Lit_Other '=')} {(DQ (YES))} {(Lit_Other ']')} ) terminator: <Op_Semi ';'> ) ] action: [ (SimpleCommand words: [ {(echo)} { (DQ (${ VSub_Name HOST) (' has been setup as an YP master server with errors. ') ) } ] redirects: [(Redir op:<Redir_GreatAnd '1>&'> fd:1 arg_word:{(2)})] ) (SimpleCommand words: [{(echo)} {(DQ ('Please remember fix any problem that occurred.'))}] redirects: [(Redir op:<Redir_GreatAnd '1>&'> fd:1 arg_word:{(2)})] ) ] spids: [16777215 2626] ) ] else_action: [ (C {(echo)} { (DQ (${ VSub_Name HOST) (' has been setup as an YP master server without any errors. ') ) } ) ] spids: [2652 2665] ) ] spids: [16777215 2484] ) ] spids: [16777215 2667] ) ] )