(command.CommandList children: [ (command.ShAssignment pairs: [ (assign_pair lhs: (sh_lhs_expr.Name name:PATH) op: assign_op.Equal rhs: {<'/sbin'> <Id.Lit_Colon ':'> <'/bin'> <Id.Lit_Colon ':'> <'/usr/bin'>} spids: [40] ) ] ) (command.ShAssignment pairs: [ (assign_pair lhs: (sh_lhs_expr.Name name:FSCK_LOGFILE) op: assign_op.Equal rhs: {<'/var/log/fsck/checkfs'>} spids: [47] ) ] ) (command.AndOr ops: [Id.Op_DPipe] children: [ (C {<Id.Lit_LBracket '['>} {(DQ ($ Id.VSub_DollarName '$FSCKFIX'))} {<Id.Lit_RBracket ']'>}) (command.ShAssignment pairs: [ (assign_pair lhs: (sh_lhs_expr.Name name:FSCKFIX) op: assign_op.Equal rhs: {<no>} spids: [60] ) ] ) ] ) (C {<.>} {<'/lib/init/vars.sh'>}) (C {<.>} {<'/lib/lsb/init-functions'>}) (C {<.>} {<'/lib/init/mount-functions.sh'>}) (C {<.>} {<'/lib/init/swap-functions.sh'>}) (command.ShFunction name: do_start body: (BraceGroup children: [ (C {<trap>} {(DQ )} {<INT>}) (command.ShAssignment pairs: [ (assign_pair lhs: (sh_lhs_expr.Name name:BAT) op: assign_op.Equal rhs: {(DQ )} spids: [148] ) ] ) (command.ShAssignment pairs: [ (assign_pair lhs: (sh_lhs_expr.Name name:fscheck) op: assign_op.Equal rhs: {(DQ <yes>)} spids: [153] ) ] ) (command.If arms: [ (if_arm cond: [(C {<is_fastboot_active>})] action: [ (command.AndOr ops: [Id.Op_DAmp] children: [ (C {<Id.Lit_LBracket '['>} {(DQ ($ Id.VSub_DollarName '$fscheck'))} {<Id.Lit_Equals '='>} {<yes>} {<Id.Lit_RBracket ']'>} ) (C {<log_warning_msg>} {(DQ <'Fast boot enabled, so skipping file system check.'>)} ) ] ) (command.ShAssignment pairs: [ (assign_pair lhs: (sh_lhs_expr.Name name:fscheck) op: assign_op.Equal rhs: {<no>} spids: [189] ) ] ) ] spids: [160 165] ) ] ) (command.If arms: [ (if_arm cond: [ (command.AndOr ops: [Id.Op_DAmp Id.Op_DAmp] children: [ (C {<Id.Lit_LBracket '['>} {(DQ ($ Id.VSub_DollarName '$fscheck'))} {<Id.Lit_Equals '='>} {<yes>} {<Id.Lit_RBracket ']'>} ) (C {<Id.Lit_LBracket '['>} {<Id.KW_Bang '!'>} {(DQ ($ Id.VSub_DollarName '$BAT'))} {<Id.Lit_RBracket ']'>} ) (C {<Id.Lit_LBracket '['>} {(DQ ($ Id.VSub_DollarName '$FSCKTYPES'))} {<Id.KW_Bang '!'> <Id.Lit_Equals '='>} {(DQ <none>)} {<Id.Lit_RBracket ']'>} ) ] ) ] action: [ (C {<swaponagain>} {(SQ <'lvm and md'>)}) (command.If arms: [ (if_arm cond: [ (command.AndOr ops: [Id.Op_DPipe] children: [ (C {<Id.Lit_LBracket '['>} {<-f>} {<'/forcefsck'>} {<Id.Lit_RBracket ']'>} ) (C {<grep>} {<-q>} {<-s>} {<-w>} {<-i>} {(DQ <forcefsck>)} {<'/proc/cmdline'>} ) ] ) ] action: [ (command.ShAssignment pairs: [ (assign_pair lhs: (sh_lhs_expr.Name name:force) op: assign_op.Equal rhs: {(DQ <-f>)} spids: [305] ) ] ) ] spids: [273 302] ) ] else_action: [ (command.ShAssignment pairs: [ (assign_pair lhs: (sh_lhs_expr.Name name:force) op: assign_op.Equal rhs: {(DQ )} spids: [314] ) ] ) ] ) (command.If arms: [ (if_arm cond: [ (C {<Id.Lit_LBracket '['>} {(DQ ($ Id.VSub_DollarName '$FSCKFIX'))} {<Id.Lit_Equals '='>} {<yes>} {<Id.Lit_RBracket ']'>} ) ] action: [ (command.ShAssignment pairs: [ (assign_pair lhs: (sh_lhs_expr.Name name:fix) op: assign_op.Equal rhs: {(DQ <-y>)} spids: [340] ) ] ) ] spids: [322 337] ) ] else_action: [ (command.ShAssignment pairs: [ (assign_pair lhs: (sh_lhs_expr.Name name:fix) op: assign_op.Equal rhs: {(DQ <-a>)} spids: [349] ) ] ) ] ) (command.ShAssignment pairs: [ (assign_pair lhs: (sh_lhs_expr.Name name:spinner) op: assign_op.Equal rhs: {(DQ <-C>)} spids: [358] ) ] ) (command.Case to_match: {(DQ ($ Id.VSub_DollarName '$TERM'))} arms: [ (case_arm pat_list: [{<dumb>} {<network>} {<unknown>} {(DQ )}] action: [ (command.ShAssignment pairs: [ (assign_pair lhs: (sh_lhs_expr.Name name:spinner) op: assign_op.Equal rhs: {(DQ )} spids: [384] ) ] ) ] spids: [373 381 389 -1] ) ] ) (command.AndOr ops: [Id.Op_DAmp] children: [ (C {<Id.Lit_LBracket '['>} { (DQ (command_sub left_token: <Id.Left_DollarParen '$('> child: (C {<uname>} {<-m>}) ) ) } {<Id.Lit_Equals '='>} {<s390x>} {<Id.Lit_RBracket ']'>} ) (command.ShAssignment pairs: [ (assign_pair lhs: (sh_lhs_expr.Name name:spinner) op: assign_op.Equal rhs: {(DQ )} spids: [413] ) ] ) ] ) (command.ShAssignment pairs: [ (assign_pair lhs: (sh_lhs_expr.Name name:FSCKTYPES_OPT) op: assign_op.Equal rhs: {(DQ )} spids: [421] ) ] ) (command.AndOr ops: [Id.Op_DAmp] children: [ (C {<Id.Lit_LBracket '['>} {(DQ ($ Id.VSub_DollarName '$FSCKTYPES'))} {<Id.Lit_RBracket ']'>} ) (command.ShAssignment pairs: [ (assign_pair lhs: (sh_lhs_expr.Name name:FSCKTYPES_OPT) op: assign_op.Equal rhs: {(DQ <'-t '> ($ Id.VSub_DollarName '$FSCKTYPES'))} spids: [436] ) ] ) ] ) (command.ShFunction name: handle_failed_fsck body: (BraceGroup children: [ (C {<log_failure_msg>} { (DQ <'File system check failed. \n'> <'A log is being saved in '> (${ Id.VSub_Name FSCK_LOGFILE) <' if that location is writable. \n'> <'Please repair the file system manually.'> ) } ) (C {<log_warning_msg>} { (DQ <'A maintenance shell will now be started. \n'> <'CONTROL-D will terminate this shell and resume system boot.'> ) } ) (command.If arms: [ (if_arm cond: [ (command.Pipeline children: [(C {<sulogin>} {($ Id.VSub_DollarName '$CONSOLE')})] negated: T ) ] action: [ (C {<log_failure_msg>} { (DQ <'Attempt to start maintenance shell failed. \n'> <'Continuing with system boot in 5 seconds.'> ) } ) (C {<sleep>} {<5>}) ] spids: [475 484] ) ] ) ] ) ) (command.If arms: [ (if_arm cond: [ (C {<Id.Lit_LBracket '['>} {(DQ ($ Id.VSub_DollarName '$VERBOSE'))} {<Id.Lit_Equals '='>} {<no>} {<Id.Lit_RBracket ']'>} ) ] action: [ (C {<log_action_begin_msg>} {(DQ <'Checking file systems'>)}) (C {<logsave>} {<-s>} {($ Id.VSub_DollarName '$FSCK_LOGFILE')} {<fsck>} {($ Id.VSub_DollarName '$spinner')} {<-M>} {<-A>} {($ Id.VSub_DollarName '$fix')} {($ Id.VSub_DollarName '$force')} {($ Id.VSub_DollarName '$FSCKTYPES_OPT')} ) (command.ShAssignment pairs: [ (assign_pair lhs: (sh_lhs_expr.Name name:FSCKCODE) op: assign_op.Equal rhs: {($ Id.VSub_QMark '$?')} spids: [552] ) ] ) (command.If arms: [ (if_arm cond: [ (C {<Id.Lit_LBracket '['>} {(DQ ($ Id.VSub_DollarName '$FSCKCODE'))} {<-eq>} {<32>} {<Id.Lit_RBracket ']'>} ) ] action: [ (C {<log_action_end_msg>} {<1>} {(DQ <'code '> ($ Id.VSub_DollarName '$FSCKCODE'))} ) (C {<log_warning_msg>} {(DQ <'File system check was interrupted by user'>)} ) ] spids: [557 572] ) (if_arm cond: [ (C {<Id.Lit_LBracket '['>} {(DQ ($ Id.VSub_DollarName '$FSCKCODE'))} {<-gt>} {<1>} {<Id.Lit_RBracket ']'>} ) ] action: [ (C {<log_action_end_msg>} {<1>} {(DQ <'code '> ($ Id.VSub_DollarName '$FSCKCODE'))} ) (C {<handle_failed_fsck>}) ] spids: [592 607] ) ] else_action: [(C {<log_action_end_msg>} {<0>})] ) ] spids: [506 521] ) ] else_action: [ (command.If arms: [ (if_arm cond: [ (C {<Id.Lit_LBracket '['>} {(DQ ($ Id.VSub_DollarName '$FSCKTYPES'))} {<Id.Lit_RBracket ']'>} ) ] action: [ (C {<log_action_msg>} { (DQ <'Will now check all file systems of types '> ($ Id.VSub_DollarName '$FSCKTYPES') ) } ) ] spids: [637 648] ) ] else_action: [ (C {<log_action_msg>} {(DQ <'Will now check all file systems'>)}) ] ) (C {<logsave>} {<-s>} {($ Id.VSub_DollarName '$FSCK_LOGFILE')} {<fsck>} {($ Id.VSub_DollarName '$spinner')} {<-V>} {<-M>} {<-A>} {($ Id.VSub_DollarName '$fix')} {($ Id.VSub_DollarName '$force')} {($ Id.VSub_DollarName '$FSCKTYPES_OPT')} ) (command.ShAssignment pairs: [ (assign_pair lhs: (sh_lhs_expr.Name name:FSCKCODE) op: assign_op.Equal rhs: {($ Id.VSub_QMark '$?')} spids: [695] ) ] ) (command.If arms: [ (if_arm cond: [ (C {<Id.Lit_LBracket '['>} {(DQ ($ Id.VSub_DollarName '$FSCKCODE'))} {<-eq>} {<32>} {<Id.Lit_RBracket ']'>} ) ] action: [ (C {<log_warning_msg>} {(DQ <'File system check was interrupted by user'>)} ) ] spids: [699 714] ) (if_arm cond: [ (C {<Id.Lit_LBracket '['>} {(DQ ($ Id.VSub_DollarName '$FSCKCODE'))} {<-gt>} {<1>} {<Id.Lit_RBracket ']'>} ) ] action: [(C {<handle_failed_fsck>})] spids: [724 739] ) ] else_action: [ (C {<log_success_msg>} { (DQ <'Done checking file systems. \n'> <'A log is being saved in '> (${ Id.VSub_Name FSCK_LOGFILE) <' if that location is writable.'> ) } ) ] ) ] ) ] spids: [209 253] ) ] ) (command.Simple words: [{<rm>} {<-f>} {<'/fastboot'>} {<'/forcefsck'>}] redirects: [(redir op:<Id.Redir_Great '2>'> loc:(redir_loc.Fd fd:2) arg:{<'/dev/null'>})] do_fork: T ) ] ) ) (command.Case to_match: {(DQ ($ Id.VSub_Number '$1'))} arms: [ (case_arm pat_list: [{<start>} {(DQ )}] action: [(C {<do_start>})] spids: [792 796 802 -1] ) (case_arm pat_list: [{<restart>} {<reload>} {<force-reload>}] action: [ (command.Simple words: [ {<echo>} {(DQ <'Error: argument \''> ($ Id.VSub_Number '$1') <'\' not supported'>)} ] redirects: [(redir op:<Id.Redir_GreatAnd '>&'> loc:(redir_loc.Fd fd:1) arg:{<2>})] do_fork: T ) (command.ControlFlow token:<Id.ControlFlow_Exit exit> arg_word:{<3>}) ] spids: [805 810 830 -1] ) (case_arm pat_list:[{<stop>} {<status>}] spids:[833 836 843 -1]) (case_arm pat_list: [{<Id.Lit_Star '*'>}] action: [ (command.Simple words: [{<echo>} {(DQ <'Usage: checkfs.sh [start|stop]'>)}] redirects: [(redir op:<Id.Redir_GreatAnd '>&'> loc:(redir_loc.Fd fd:1) arg:{<2>})] do_fork: T ) (command.ControlFlow token:<Id.ControlFlow_Exit exit> arg_word:{<3>}) ] spids: [846 847 865 -1] ) ] ) (C {<Id.Lit_Colon ':'>}) ] )