(command.CommandList
  children: [
    (command.ShAssignment
      pairs: [
        (assign_pair
          lhs: (sh_lhs_expr.Name name:PATH)
          op: assign_op.Equal
          rhs: {(/sbin) (Id.Lit_Other ':') (/bin) (Id.Lit_Other ':') (/usr/bin)}
          spids: [43]
        )
      ]
    )
    (command.ShAssignment
      pairs: [
        (assign_pair
          lhs: (sh_lhs_expr.Name name:FSCK_LOGFILE)
          op: assign_op.Equal
          rhs: {(/var/log/fsck/checkroot)}
          spids: [50]
        )
      ]
    )
    (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: [63]
            )
          ]
        )
      ]
    )
    (command.AndOr
      ops: [Id.Op_DPipe]
      children: [
        (C {(Id.Lit_LBracket '[')} {(DQ ($ Id.VSub_DollarName '$SULOGIN'))} {(Id.Lit_RBracket ']')})
        (command.ShAssignment
          pairs: [
            (assign_pair
              lhs: (sh_lhs_expr.Name name:SULOGIN)
              op: assign_op.Equal
              rhs: {(no)}
              spids: [76]
            )
          ]
        )
      ]
    )
    (C {(.)} {(/lib/init/vars.sh)})
    (C {(.)} {(/lib/lsb/init-functions)})
    (C {(.)} {(/lib/init/mount-functions.sh)})
    (command.ShFunction
      name: do_start
      body: 
        (command.BraceGroup
          children: [
            (C {(trap)} {(DQ )} {(INT)})
            (command.AndOr
              ops: [Id.Op_DAmp]
              children: [
                (C {(Id.Lit_LBracket '[')} {(DQ ($ Id.VSub_DollarName '$SULOGIN'))} 
                  {(Id.Lit_Equals '=')} {(yes)} {(Id.Lit_RBracket ']')}
                )
                (C {(sulogin)} {(-t)} {(30)} {($ Id.VSub_DollarName '$CONSOLE')})
              ]
            )
            (command.ShAssignment
              pairs: [
                (assign_pair
                  lhs: (sh_lhs_expr.Name name:KERNEL)
                  op: assign_op.Equal
                  rhs: 
                    {
                      (DQ 
                        (command_sub
                          left_token: (Token id:Id.Left_DollarParen val:'$(' span_id:160)
                          command_list: (command.CommandList children:[(C {(uname)} {(-s)})])
                        )
                      )
                    }
                  spids: [158]
                )
              ]
            )
            (command.ShAssignment
              pairs: [
                (assign_pair
                  lhs: (sh_lhs_expr.Name name:MACHINE)
                  op: assign_op.Equal
                  rhs: 
                    {
                      (DQ 
                        (command_sub
                          left_token: (Token id:Id.Left_DollarParen val:'$(' span_id:170)
                          command_list: (command.CommandList children:[(C {(uname)} {(-m)})])
                        )
                      )
                    }
                  spids: [168]
                )
              ]
            )
            (C {(read_fstab)})
            (command.ShAssignment
              pairs: [
                (assign_pair
                  lhs: (sh_lhs_expr.Name name:ENABLE_SWAP)
                  op: assign_op.Equal
                  rhs: {(no)}
                  spids: [199]
                )
              ]
            )
            (command.Case
              to_match: {(DQ ($ Id.VSub_DollarName '$KERNEL'))}
              arms: [
                (case_arm
                  pat_list: [{(Linux)}]
                  action: [
                    (command.If
                      arms: [
                        (if_arm
                          cond: [
                            (C {(Id.Lit_LBracket '[')} {(DQ ($ Id.VSub_DollarName '$NOSWAP'))} 
                              {(Id.Lit_Equals '=')} {(yes)} {(Id.Lit_RBracket ']')}
                            )
                          ]
                          action: [
                            (command.AndOr
                              ops: [Id.Op_DPipe]
                              children: [
                                (C {(Id.Lit_LBracket '[')} {(DQ ($ Id.VSub_DollarName '$VERBOSE'))} 
                                  {(Id.Lit_Equals '=')} {(no)} {(Id.Lit_RBracket ']')}
                                )
                                (C {(log_warning_msg)} 
                                  {(DQ ('Not activating swap as requested via bootoption noswap.'))}
                                )
                              ]
                            )
                            (command.ShAssignment
                              pairs: [
                                (assign_pair
                                  lhs: (sh_lhs_expr.Name name:ENABLE_SWAP)
                                  op: assign_op.Equal
                                  rhs: {(no)}
                                  spids: [255]
                                )
                              ]
                            )
                          ]
                          spids: [216 231]
                        )
                      ]
                      else_action: [
                        (command.If
                          arms: [
                            (if_arm
                              cond: [
                                (C {(Id.Lit_LBracket '[')} {(DQ ($ Id.VSub_DollarName '$swap_on_lv'))} 
                                  {(Id.Lit_Equals '=')} {(yes)} {(Id.Lit_RBracket ']')}
                                )
                              ]
                              action: [
                                (command.AndOr
                                  ops: [Id.Op_DPipe]
                                  children: [
                                    (C {(Id.Lit_LBracket '[')} {(DQ ($ Id.VSub_DollarName '$VERBOSE'))} 
                                      {(Id.Lit_Equals '=')} {(no)} {(Id.Lit_RBracket ']')}
                                    )
                                    (C {(log_warning_msg)} 
                                      {(DQ ('Not activating swap on logical volume.'))}
                                    )
                                  ]
                                )
                              ]
                              spids: [262 277]
                            )
                            (if_arm
                              cond: [
                                (C {(Id.Lit_LBracket '[')} {(DQ ($ Id.VSub_DollarName '$swap_on_file'))} 
                                  {(Id.Lit_Equals '=')} {(yes)} {(Id.Lit_RBracket ']')}
                                )
                              ]
                              action: [
                                (command.AndOr
                                  ops: [Id.Op_DPipe]
                                  children: [
                                    (C {(Id.Lit_LBracket '[')} {(DQ ($ Id.VSub_DollarName '$VERBOSE'))} 
                                      {(Id.Lit_Equals '=')} {(no)} {(Id.Lit_RBracket ']')}
                                    )
                                    (C {(log_warning_msg)} {(DQ ('Not activating swap on swapfile.'))})
                                  ]
                                )
                              ]
                              spids: [301 316]
                            )
                          ]
                          else_action: [
                            (command.ShAssignment
                              pairs: [
                                (assign_pair
                                  lhs: (sh_lhs_expr.Name name:ENABLE_SWAP)
                                  op: assign_op.Equal
                                  rhs: {(yes)}
                                  spids: [343]
                                )
                              ]
                            )
                          ]
                        )
                      ]
                    )
                  ]
                  spids: [212 213 353 -1]
                )
                (case_arm
                  pat_list: [{(Id.Lit_Star '*')}]
                  action: [
                    (command.ShAssignment
                      pairs: [
                        (assign_pair
                          lhs: (sh_lhs_expr.Name name:ENABLE_SWAP)
                          op: assign_op.Equal
                          rhs: {(yes)}
                          spids: [360]
                        )
                      ]
                    )
                  ]
                  spids: [356 357 364 -1]
                )
              ]
            )
            (command.If
              arms: [
                (if_arm
                  cond: [
                    (C {(Id.Lit_LBracket '[')} {(DQ ($ Id.VSub_DollarName '$ENABLE_SWAP'))} 
                      {(Id.Lit_Equals '=')} {(yes)} {(Id.Lit_RBracket ']')}
                    )
                  ]
                  action: [
                    (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 ('Activating swap'))})
                            (command.Simple
                              words: [{(swapon)} {(-a)} {(-e)}]
                              redirects: [
                                (redir.Redir
                                  op: (Token id:Id.Redir_Great val:'>' span_id:419)
                                  fd: -1
                                  arg_word: {(/dev/null)}
                                )
                                (redir.Redir
                                  op: (Token id:Id.Redir_GreatAnd val:'2>&' span_id:422)
                                  fd: 2
                                  arg_word: {(1)}
                                )
                              ]
                            )
                            (C {(log_action_end_msg)} {($ Id.VSub_QMark '$?')})
                          ]
                          spids: [388 403]
                        )
                      ]
                      else_action: [
                        (C {(log_daemon_msg)} {(DQ ('Activating swap'))})
                        (C {(swapon)} {(-a)} {(-v)})
                        (C {(log_end_msg)} {($ Id.VSub_QMark '$?')})
                      ]
                    )
                  ]
                  spids: [370 385]
                )
              ]
            )
            (command.ShAssignment
              pairs: [
                (assign_pair
                  lhs: (sh_lhs_expr.Name name:KERNEL)
                  op: assign_op.Equal
                  rhs: 
                    {
                      (DQ 
                        (command_sub
                          left_token: (Token id:Id.Left_DollarParen val:'$(' span_id:494)
                          command_list: (command.CommandList children:[(C {(uname)})])
                        )
                      )
                    }
                  spids: [492]
                )
              ]
            )
            (command.If
              arms: [
                (if_arm
                  cond: [
                    (command.AndOr
                      ops: [Id.Op_DAmp]
                      children: [
                        (C {(Id.Lit_LBracket '[')} {(DQ ($ Id.VSub_DollarName '$rootcheck'))} 
                          {(Id.Lit_Equals '=')} {(yes)} {(Id.Lit_RBracket ']')}
                        )
                        (C {(Id.Lit_LBracket '[')} {(DQ ($ Id.VSub_DollarName '$KERNEL'))} 
                          {(Id.Lit_Equals '=')} {(Linux)} {(Id.Lit_RBracket ']')}
                        )
                      ]
                    )
                  ]
                  action: [
                    (command.ShAssignment
                      pairs: [
                        (assign_pair
                          lhs: (sh_lhs_expr.Name name:ddev)
                          op: assign_op.Equal
                          rhs: 
                            {
                              (DQ 
                                (command_sub
                                  left_token: (Token id:Id.Left_DollarParen val:'$(' span_id:534)
                                  command_list: 
                                    (command.CommandList
                                      children: [
                                        (C {(mountpoint)} {(-qx)} {($ Id.VSub_DollarName '$rootdev')})
                                      ]
                                    )
                                )
                              )
                            }
                          spids: [532]
                        )
                      ]
                    )
                    (command.ShAssignment
                      pairs: [
                        (assign_pair
                          lhs: (sh_lhs_expr.Name name:rdev)
                          op: assign_op.Equal
                          rhs: 
                            {
                              (DQ 
                                (command_sub
                                  left_token: (Token id:Id.Left_DollarParen val:'$(' span_id:546)
                                  command_list: 
                                    (command.CommandList
                                      children: [(C {(mountpoint)} {(-d)} {(/)})]
                                    )
                                )
                              )
                            }
                          spids: [544]
                        )
                      ]
                    )
                    (command.If
                      arms: [
                        (if_arm
                          cond: [
                            (command.AndOr
                              ops: [Id.Op_DAmp]
                              children: [
                                (C {(Id.Lit_LBracket '[')} {(DQ ($ Id.VSub_DollarName '$ddev'))} 
                                  {(Id.KW_Bang '!') (Id.Lit_Equals '=')} {(DQ ($ Id.VSub_DollarName '$rdev'))} {(Id.Lit_RBracket ']')}
                                )
                                (C {(Id.Lit_LBracket '[')} {(DQ ($ Id.VSub_DollarName '$ddev'))} 
                                  {(Id.KW_Bang '!') (Id.Lit_Equals '=')} {(DQ ('4:0'))} {(Id.Lit_RBracket ']')}
                                )
                              ]
                            )
                          ]
                          action: [
                            (command.If
                              arms: [
                                (if_arm
                                  cond: [
                                    (C {(Id.Lit_LBracket '[')} 
                                      {
                                        (DQ 
                                          (command_sub
                                            left_token: 
                                              (Token
                                                id: Id.Left_DollarParen
                                                val: '$('
                                                span_id: 599
                                              )
                                            command_list: 
                                              (command.CommandList
                                                children: [(C {(mountpoint)} {(-qx)} {(/dev/root)})]
                                              )
                                          )
                                        )
                                      } {(Id.Lit_Equals '=')} {(DQ ('4:0'))} {(Id.Lit_RBracket ']')}
                                    )
                                  ]
                                  action: [
                                    (command.ShAssignment
                                      pairs: [
                                        (assign_pair
                                          lhs: (sh_lhs_expr.Name name:rootdev)
                                          op: assign_op.Equal
                                          rhs: {(/dev/root)}
                                          spids: [620]
                                        )
                                      ]
                                    )
                                  ]
                                  spids: [594 617]
                                )
                              ]
                              else_action: [
                                (command.If
                                  arms: [
                                    (if_arm
                                      cond: [
                                        (command.AndOr
                                          ops: [Id.Op_DAmp Id.Op_DAmp]
                                          children: [
                                            (C {(rm)} {(-f)} {(/run/rootdev)})
                                            (C {(mknod)} {(-m)} {(600)} {(/run/rootdev)} {(b)} 
                                              {
                                                (braced_var_sub
                                                  token: (Token id:Id.VSub_Name val:rdev span_id:652)
                                                  suffix_op: 
                                                    (suffix_op.Unary
                                                      op_id: Id.VOp1_Percent
                                                      arg_word: {(':*')}
                                                    )
                                                )
                                              } 
                                              {
                                                (braced_var_sub
                                                  token: (Token id:Id.VSub_Name val:rdev span_id:658)
                                                  suffix_op: 
                                                    (suffix_op.Unary
                                                      op_id: Id.VOp1_Pound
                                                      arg_word: {('*:')}
                                                    )
                                                )
                                              }
                                            )
                                            (C {(Id.Lit_LBracket '[')} {(-e)} {(/run/rootdev)} 
                                              {(Id.Lit_RBracket ']')}
                                            )
                                          ]
                                        )
                                      ]
                                      action: [
                                        (command.ShAssignment
                                          pairs: [
                                            (assign_pair
                                              lhs: (sh_lhs_expr.Name name:rootdev)
                                              op: assign_op.Equal
                                              rhs: {(/run/rootdev)}
                                              spids: [679]
                                            )
                                          ]
                                        )
                                      ]
                                      spids: [627 676]
                                    )
                                  ]
                                  else_action: [
                                    (command.ShAssignment
                                      pairs: [
                                        (assign_pair
                                          lhs: (sh_lhs_expr.Name name:rootfatal)
                                          op: assign_op.Equal
                                          rhs: {(yes)}
                                          spids: [686]
                                        )
                                      ]
                                    )
                                  ]
                                )
                              ]
                            )
                          ]
                          spids: [556 591]
                        )
                      ]
                    )
                  ]
                  spids: [500 529]
                )
              ]
            )
            (command.If
              arms: [
                (if_arm
                  cond: [
                    (C {(Id.Lit_LBracket '[')} {(DQ ($ Id.VSub_DollarName '$rootfatal'))} 
                      {(Id.Lit_Equals '=')} {(yes)} {(Id.Lit_RBracket ']')}
                    )
                  ]
                  action: [
                    (C {(log_failure_msg)} 
                      {
                        (DQ ('The device node ') ($ Id.VSub_DollarName '$rootdev') 
                          (' for the root filesystem is missing or incorrect \n') ('or there is no entry for the root filesystem listed in /etc/fstab. \n') 
                          ('The system is also unable to create a temporary node in /run. \n') ('This means you have to fix the problem manually.')
                        )
                      }
                    )
                    (C {(log_warning_msg)} 
                      {
                        (DQ ('A maintenance shell will now be started. \n') 
                          ('CONTROL-D will terminate this shell and restart the system.')
                        )
                      }
                    )
                    (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') 
                                  ('Will restart in 5 seconds.')
                                )
                              }
                            )
                            (C {(sleep)} {(5)})
                          ]
                          spids: [757 766]
                        )
                      ]
                    )
                    (command.AndOr
                      ops: [Id.Op_DPipe]
                      children: [
                        (C {(Id.Lit_LBracket '[')} {(DQ ($ Id.VSub_DollarName '$VERBOSE'))} 
                          {(Id.Lit_Equals '=')} {(no)} {(Id.Lit_RBracket ']')}
                        )
                        (C {(log_action_msg)} {(DQ ('Will now restart'))})
                      ]
                    )
                    (C {(reboot)} {(-f)})
                  ]
                  spids: [715 730]
                )
              ]
            )
            (command.ShAssignment
              pairs: [
                (assign_pair
                  lhs: (sh_lhs_expr.Name name:FSCKCODE)
                  op: assign_op.Equal
                  rhs: {(0)}
                  spids: [873]
                )
              ]
            )
            (command.If
              arms: [
                (if_arm
                  cond: [
                    (C {(Id.Lit_LBracket '[')} {(-e)} {(/run/initramfs/fsck-root)} 
                      {(Id.Lit_RBracket ']')}
                    )
                  ]
                  action: [
                    (command.ShAssignment
                      pairs: [
                        (assign_pair
                          lhs: (sh_lhs_expr.Name name:rootcheck)
                          op: assign_op.Equal
                          rhs: {(no)}
                          spids: [892]
                        )
                      ]
                    )
                  ]
                  spids: [878 889]
                )
              ]
            )
            (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 '$rootcheck'))} 
                          {(Id.Lit_Equals '=')} {(yes)} {(Id.Lit_RBracket ']')}
                        )
                        (C {(log_warning_msg)} 
                          {(DQ ('Fast boot enabled, so skipping root file system check.'))}
                        )
                      ]
                    )
                    (command.ShAssignment
                      pairs: [
                        (assign_pair
                          lhs: (sh_lhs_expr.Name name:rootcheck)
                          op: assign_op.Equal
                          rhs: {(no)}
                          spids: [929]
                        )
                      ]
                    )
                  ]
                  spids: [900 905]
                )
              ]
            )
            (command.If
              arms: [
                (if_arm
                  cond: [
                    (command.Simple
                      words: [{(which)} {(findmnt)}]
                      redirects: [
                        (redir.Redir
                          op: (Token id:Id.Redir_Great val:'>' span_id:943)
                          fd: -1
                          arg_word: {(/dev/null)}
                        )
                        (redir.Redir
                          op: (Token id:Id.Redir_GreatAnd val:'2>&' span_id:946)
                          fd: 2
                          arg_word: {(1)}
                        )
                      ]
                    )
                  ]
                  action: [
                    (command.If
                      arms: [
                        (if_arm
                          cond: [
                            (C {(Id.Lit_LBracket '[')} 
                              {
                                (DQ 
                                  (command_sub
                                    left_token: (Token id:Id.Left_DollarParen val:'$(' span_id:958)
                                    command_list: 
                                      (command.CommandList
                                        children: [
                                          (C {(findmnt)} {(-f)} {(-n)} {(-o)} {(FSTYPE)} {(/)})
                                        ]
                                      )
                                  )
                                )
                              } {(Id.Lit_Equals '=')} {(DQ (btrfs))} {(Id.Lit_RBracket ']')}
                            )
                          ]
                          action: [
                            (command.AndOr
                              ops: [Id.Op_DAmp]
                              children: [
                                (C {(Id.Lit_LBracket '[')} {(DQ ($ Id.VSub_DollarName '$rootcheck'))} 
                                  {(Id.Lit_Equals '=')} {(yes)} {(Id.Lit_RBracket ']')}
                                )
                                (C {(log_warning_msg)} 
                                  {(DQ ('btrfs root detected, so skipping root file system check.'))}
                                )
                              ]
                            )
                            (command.ShAssignment
                              pairs: [
                                (assign_pair
                                  lhs: (sh_lhs_expr.Name name:rootcheck)
                                  op: assign_op.Equal
                                  rhs: {(no)}
                                  spids: [1006]
                                )
                              ]
                            )
                          ]
                          spids: [953 982]
                        )
                      ]
                    )
                  ]
                  spids: [937 950]
                )
              ]
            )
            (command.If
              arms: [
                (if_arm
                  cond: [
                    (C {(Id.Lit_LBracket '[')} {(DQ ($ Id.VSub_DollarName '$rootcheck'))} 
                      {(Id.Lit_Equals '=')} {(yes)} {(Id.Lit_RBracket ']')}
                    )
                  ]
                  action: [
                    (command.If
                      arms: [
                        (if_arm
                          cond: [
                            (command.AndOr
                              ops: [Id.Op_DAmp Id.Op_DAmp]
                              children: [
                                (command.Pipeline
                                  children: [
                                    (C {(mount)} {(-n)} {(-o)} {(remount) (Id.Lit_Comma ',') (ro)} 
                                      {($ Id.VSub_DollarName '$rootdev')} {(/)}
                                    )
                                  ]
                                  negated: T
                                )
                                (command.Pipeline
                                  children: [
                                    (command.Simple
                                      words: [
                                        {(mount)}
                                        {(-n)}
                                        {(-o)}
                                        {(remount) (Id.Lit_Comma ',') (ro)}
                                        {(-t)}
                                        {(dummytype)}
                                        {($ Id.VSub_DollarName '$rootdev')}
                                        {(/)}
                                      ]
                                      redirects: [
                                        (redir.Redir
                                          op: (Token id:Id.Redir_Great val:'2>' span_id:1131)
                                          fd: 2
                                          arg_word: {(/dev/null)}
                                        )
                                      ]
                                    )
                                  ]
                                  negated: T
                                )
                                (command.Pipeline
                                  children: [
                                    (command.Simple
                                      words: [
                                        {(mount)}
                                        {(-n)}
                                        {(-o)}
                                        {(remount) (Id.Lit_Comma ',') (ro)}
                                        {(/)}
                                      ]
                                      redirects: [
                                        (redir.Redir
                                          op: (Token id:Id.Redir_Great val:'2>' span_id:1152)
                                          fd: 2
                                          arg_word: {(/dev/null)}
                                        )
                                      ]
                                    )
                                  ]
                                  negated: T
                                )
                              ]
                            )
                          ]
                          action: [
                            (C {(log_failure_msg)} 
                              {
                                (DQ 
                                  (
'Cannot check root file system because it is not mounted read-only.'
                                  )
                                )
                              }
                            )
                            (command.ShAssignment
                              pairs: [
                                (assign_pair
                                  lhs: (sh_lhs_expr.Name name:rootcheck)
                                  op: assign_op.Equal
                                  rhs: {(no)}
                                  spids: [1166]
                                )
                              ]
                            )
                          ]
                          spids: [1087 1156]
                        )
                      ]
                    )
                  ]
                  spids: [1017 1032]
                )
              ]
            )
            (command.If
              arms: [
                (if_arm
                  cond: [
                    (C {(Id.Lit_LBracket '[')} {(DQ ($ Id.VSub_DollarName '$rootcheck'))} 
                      {(Id.Lit_Equals '=')} {(yes)} {(Id.Lit_RBracket ']')}
                    )
                  ]
                  action: [
                    (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: [1239]
                                )
                              ]
                            )
                          ]
                          spids: [1207 1236]
                        )
                      ]
                      else_action: [
                        (command.ShAssignment
                          pairs: [
                            (assign_pair
                              lhs: (sh_lhs_expr.Name name:force)
                              op: assign_op.Equal
                              rhs: {(DQ )}
                              spids: [1248]
                            )
                          ]
                        )
                      ]
                    )
                    (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: [1275]
                                )
                              ]
                            )
                          ]
                          spids: [1257 1272]
                        )
                      ]
                      else_action: [
                        (command.ShAssignment
                          pairs: [
                            (assign_pair
                              lhs: (sh_lhs_expr.Name name:fix)
                              op: assign_op.Equal
                              rhs: {(DQ (-a))}
                              spids: [1284]
                            )
                          ]
                        )
                      ]
                    )
                    (command.ShAssignment
                      pairs: [
                        (assign_pair
                          lhs: (sh_lhs_expr.Name name:spinner)
                          op: assign_op.Equal
                          rhs: {(DQ (-C))}
                          spids: [1294]
                        )
                      ]
                    )
                    (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: [1320]
                                )
                              ]
                            )
                          ]
                          spids: [1309 1317 1324 -1]
                        )
                      ]
                    )
                    (command.If
                      arms: [
                        (if_arm
                          cond: [
                            (C {(Id.Lit_LBracket '[')} 
                              {(DQ (${ Id.VSub_Name KERNEL) (':') (${ Id.VSub_Name MACHINE))} {(Id.Lit_Equals '=')} {(Linux) (Id.Lit_Other ':') (s390x)} {(Id.Lit_RBracket ']')}
                            )
                          ]
                          action: [
                            (command.ShAssignment
                              pairs: [
                                (assign_pair
                                  lhs: (sh_lhs_expr.Name name:spinner)
                                  op: assign_op.Equal
                                  rhs: {(DQ )}
                                  spids: [1360]
                                )
                              ]
                            )
                          ]
                          spids: [1334 1357]
                        )
                      ]
                    )
                    (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 root file system'))})
                            (C {(logsave)} {(-s)} {($ Id.VSub_DollarName '$FSCK_LOGFILE')} {(fsck)} 
                              {($ Id.VSub_DollarName '$spinner')} {($ Id.VSub_DollarName '$force')} {($ Id.VSub_DollarName '$fix')} {(-t)} 
                              {($ Id.VSub_DollarName '$roottype')} {($ Id.VSub_DollarName '$rootdev')}
                            )
                            (command.ShAssignment
                              pairs: [
                                (assign_pair
                                  lhs: (sh_lhs_expr.Name name:FSCKCODE)
                                  op: assign_op.Equal
                                  rhs: {($ Id.VSub_QMark '$?')}
                                  spids: [1416]
                                )
                              ]
                            )
                            (command.If
                              arms: [
                                (if_arm
                                  cond: [
                                    (C {(Id.Lit_LBracket '[')} {(DQ ($ Id.VSub_DollarName '$FSCKCODE'))} 
                                      {(Id.Lit_Equals '=')} {(0)} {(Id.Lit_RBracket ']')}
                                    )
                                  ]
                                  action: [(C {(log_action_end_msg)} {(0)})]
                                  spids: [1420 1435]
                                )
                              ]
                              else_action: [
                                (C {(log_action_end_msg)} {(1)} 
                                  {(DQ ('code ') ($ Id.VSub_DollarName '$FSCKCODE'))}
                                )
                              ]
                            )
                          ]
                          spids: [1370 1385]
                        )
                      ]
                      else_action: [
                        (C {(log_daemon_msg)} {(DQ ('Will now check root file system'))})
                        (C {(logsave)} {(-s)} {($ Id.VSub_DollarName '$FSCK_LOGFILE')} {(fsck)} 
                          {($ Id.VSub_DollarName '$spinner')} {($ Id.VSub_DollarName '$force')} {($ Id.VSub_DollarName '$fix')} {(-V)} {(-t)} 
                          {($ Id.VSub_DollarName '$roottype')} {($ Id.VSub_DollarName '$rootdev')}
                        )
                        (command.ShAssignment
                          pairs: [
                            (assign_pair
                              lhs: (sh_lhs_expr.Name name:FSCKCODE)
                              op: assign_op.Equal
                              rhs: {($ Id.VSub_QMark '$?')}
                              spids: [1492]
                            )
                          ]
                        )
                        (C {(log_end_msg)} {($ Id.VSub_DollarName '$FSCKCODE')})
                      ]
                    )
                  ]
                  spids: [1189 1204]
                )
              ]
            )
            (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: [1540 1555]
                )
                (if_arm
                  cond: [
                    (C {(Id.Lit_LBracket '[')} {(DQ ($ Id.VSub_DollarName '$FSCKCODE'))} {(-gt)} {(3)} 
                      {(Id.Lit_RBracket ']')}
                    )
                  ]
                  action: [
                    (C {(log_failure_msg)} 
                      {
                        (DQ 
                          (
'An automatic file system check (fsck) of the root filesystem failed. \n'
                          ) ('A manual fsck must be performed, then the system restarted. \n') 
                          ('The fsck should be performed in maintenance mode with the \n') ('root filesystem mounted in read-only mode.')
                        )
                      }
                    )
                    (C {(log_warning_msg)} 
                      {
                        (DQ ('The root filesystem is currently mounted in read-only mode. \n') 
                          ('A maintenance shell will now be started. \n') ('After performing system maintenance, press CONTROL-D \n') 
                          ('to terminate the maintenance shell and restart the system.')
                        )
                      }
                    )
                    (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') 
                                  ('Will restart in 5 seconds.')
                                )
                              }
                            )
                            (C {(sleep)} {(5)})
                          ]
                          spids: [1615 1624]
                        )
                      ]
                    )
                    (command.AndOr
                      ops: [Id.Op_DPipe]
                      children: [
                        (C {(Id.Lit_LBracket '[')} {(DQ ($ Id.VSub_DollarName '$VERBOSE'))} 
                          {(Id.Lit_Equals '=')} {(no)} {(Id.Lit_RBracket ']')}
                        )
                        (C {(log_action_msg)} {(DQ ('Will now restart'))})
                      ]
                    )
                    (C {(reboot)} {(-f)})
                  ]
                  spids: [1565 1580]
                )
                (if_arm
                  cond: [
                    (C {(Id.Lit_LBracket '[')} {(DQ ($ Id.VSub_DollarName '$FSCKCODE'))} {(-gt)} {(1)} 
                      {(Id.Lit_RBracket ']')}
                    )
                  ]
                  action: [
                    (C {(log_failure_msg)} 
                      {
                        (DQ ('The file system check corrected errors on the root partition \n') 
                          ('but requested that the system be restarted.')
                        )
                      }
                    )
                    (C {(log_warning_msg)} {(DQ ('The system will be restarted in 5 seconds.'))})
                    (C {(sleep)} {(5)})
                    (command.AndOr
                      ops: [Id.Op_DPipe]
                      children: [
                        (C {(Id.Lit_LBracket '[')} {(DQ ($ Id.VSub_DollarName '$VERBOSE'))} 
                          {(Id.Lit_Equals '=')} {(no)} {(Id.Lit_RBracket ']')}
                        )
                        (C {(log_action_msg)} {(DQ ('Will now restart'))})
                      ]
                    )
                    (C {(reboot)} {(-f)})
                  ]
                  spids: [1669 1684]
                )
              ]
            )
            (command.If
              arms: [
                (if_arm
                  cond: [
                    (command.Pipeline
                      children: [
                        (command.Simple
                          words: [
                            {(mount)}
                            {(-n)}
                            {(-o)}
                            {(remount) (Id.Lit_Comma ',') ($ Id.VSub_DollarName '$rootopts') 
                              (Id.Lit_Comma ',') ($ Id.VSub_DollarName '$rootmode')
                            }
                            {($ Id.VSub_DollarName '$fstabroot')}
                            {(/)}
                          ]
                          redirects: [
                            (redir.Redir
                              op: (Token id:Id.Redir_Great val:'2>' span_id:1781)
                              fd: 2
                              arg_word: {(/dev/null)}
                            )
                          ]
                        )
                      ]
                      negated: T
                    )
                  ]
                  action: [
                    (C {(mount)} {(-n)} {(-o)} 
                      {(remount) (Id.Lit_Comma ',') ($ Id.VSub_DollarName '$rootopts') 
                        (Id.Lit_Comma ',') ($ Id.VSub_DollarName '$rootmode')
                      } {(/)}
                    )
                  ]
                  spids: [1761 1785]
                )
              ]
            )
            (command.If
              arms: [
                (if_arm
                  cond: [
                    (command.Sentence
                      child: 
                        (C {(Id.Lit_LBracket '[')} {(DQ ($ Id.VSub_DollarName '$rootmode'))} 
                          {(Id.KW_Bang '!') (Id.Lit_Equals '=')} {(DQ (ro))} {(Id.Lit_RBracket ']')}
                        )
                      terminator: (Token id:Id.Op_Semi val:';' span_id:1835)
                    )
                  ]
                  action: [(C {(mtab_migrate)})]
                  spids: [1819 1837]
                )
              ]
            )
            (command.If
              arms: [
                (if_arm
                  cond: [
                    (command.AndOr
                      ops: [Id.Op_DAmp Id.Op_DAmp]
                      children: [
                        (C {(selinux_enabled)})
                        (C {(Id.Lit_LBracket '[')} {(-x)} {(/sbin/restorecon)} {(Id.Lit_RBracket ']')})
                        (C {(Id.Lit_LBracket '[')} {(-r)} {(/etc/mtab)} {(Id.Lit_RBracket ']')})
                      ]
                    )
                  ]
                  action: [(C {(restorecon)} {(/etc/mtab)})]
                  spids: [1847 1872]
                )
              ]
            )
            (C {(rm)} {(-f)} {(/run/rootdev)})
            (C {(/etc/init.d/mountkernfs.sh)} {(reload)})
            (C {(/etc/init.d/mountdevsubfs.sh)} {(reload)})
          ]
        )
    )
    (command.ShFunction
      name: do_status
      body: 
        (command.BraceGroup
          children: [
            (command.ShAssignment
              pairs: [
                (assign_pair
                  lhs: (sh_lhs_expr.Name name:rootrw)
                  op: assign_op.Equal
                  rhs: {(false)}
                  spids: [1945]
                )
              ]
            )
            (command.ShAssignment
              pairs: [
                (assign_pair
                  lhs: (sh_lhs_expr.Name name:swapon)
                  op: assign_op.Equal
                  rhs: {(false)}
                  spids: [1949]
                )
              ]
            )
            (command.If
              arms: [
                (if_arm
                  cond: [
                    (command.Sentence
                      child: (C {(Id.Lit_LBracket '[')} {(-f)} {(/etc/mtab)} {(Id.Lit_RBracket ']')})
                      terminator: (Token id:Id.Op_Semi val:';' span_id:1963)
                    )
                  ]
                  action: [
                    (command.If
                      arms: [
                        (if_arm
                          cond: [
                            (command.Sentence
                              child: 
                                (command.Pipeline
                                  children: [
                                    (C {(grep)} {(DQ (' / '))} {(/etc/mtab)})
                                    (C {(grep)} {(-q)} {(rw)})
                                  ]
                                  negated: F
                                )
                              terminator: (Token id:Id.Op_Semi val:';' span_id:1985)
                            )
                          ]
                          action: [
                            (command.ShAssignment
                              pairs: [
                                (assign_pair
                                  lhs: (sh_lhs_expr.Name name:rootrw)
                                  op: assign_op.Equal
                                  rhs: {(true)}
                                  spids: [1990]
                                )
                              ]
                            )
                          ]
                          spids: [1968 1987]
                        )
                      ]
                    )
                  ]
                  spids: [1953 1965]
                )
              ]
            )
            (command.If
              arms: [
                (if_arm
                  cond: [
                    (command.Sentence
                      child: (C {(Id.Lit_LBracket '[')} {(-f)} {(/proc/swaps)} {(Id.Lit_RBracket ']')})
                      terminator: (Token id:Id.Op_Semi val:';' span_id:2010)
                    )
                  ]
                  action: [
                    (command.If
                      arms: [
                        (if_arm
                          cond: [
                            (command.Sentence
                              child: 
                                (C {(Id.Lit_LBracket '[')} 
                                  {
                                    (DQ 
                                      (command_sub
                                        left_token: 
                                          (Token
                                            id: Id.Left_DollarParen
                                            val: '$('
                                            span_id: 2020
                                          )
                                        command_list: 
                                          (command.CommandList
                                            children: [
                                              (command.Pipeline
                                                children: [
                                                  (C {(cat)} {(/proc/swaps)})
                                                  (C {(grep)} {(-v)} {(Id.Lit_Other '^') (Filename)})
                                                ]
                                                negated: F
                                              )
                                            ]
                                          )
                                      )
                                    )
                                  } {(Id.Lit_RBracket ']')}
                                )
                              terminator: (Token id:Id.Op_Semi val:';' span_id:2037)
                            )
                          ]
                          action: [
                            (command.ShAssignment
                              pairs: [
                                (assign_pair
                                  lhs: (sh_lhs_expr.Name name:swapon)
                                  op: assign_op.Equal
                                  rhs: {(true)}
                                  spids: [2042]
                                )
                              ]
                            )
                          ]
                          spids: [2015 2039]
                        )
                      ]
                    )
                  ]
                  spids: [2000 2012]
                )
              ]
            )
            (command.If
              arms: [
                (if_arm
                  cond: [
                    (command.Sentence
                      child: 
                        (command.AndOr
                          ops: [Id.Op_DPipe]
                          children: [
                            (C {(Id.Lit_LBracket '[')} {(true)} {(Id.Lit_Equals '=')} 
                              {(DQ ($ Id.VSub_DollarName '$rootrw'))} {(Id.Lit_RBracket ']')}
                            )
                            (C {(Id.Lit_LBracket '[')} {(true)} {(Id.Lit_Equals '=')} 
                              {(DQ ($ Id.VSub_DollarName '$swapon'))} {(Id.Lit_RBracket ']')}
                            )
                          ]
                        )
                      terminator: (Token id:Id.Op_Semi val:';' span_id:2080)
                    )
                  ]
                  action: [
                    (command.ControlFlow
                      token: (Token id:Id.ControlFlow_Return val:return span_id:2085)
                      arg_word: {(0)}
                    )
                  ]
                  spids: [2052 2082]
                )
              ]
              else_action: [
                (command.ControlFlow
                  token: (Token id:Id.ControlFlow_Return val:return span_id:2093)
                  arg_word: {(4)}
                )
              ]
            )
          ]
        )
    )
    (command.Case
      to_match: {(DQ ($ Id.VSub_Number '$1'))}
      arms: [
        (case_arm
          pat_list: [{(start)} {(DQ )}]
          action: [(C {(do_start)})]
          spids: [2112 2116 2122 -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.Redir
                  op: (Token id:Id.Redir_GreatAnd val:'>&' span_id:2141)
                  fd: -1
                  arg_word: {(2)}
                )
              ]
            )
            (command.ControlFlow
              token: (Token id:Id.ControlFlow_Exit val:exit span_id:2145)
              arg_word: {(3)}
            )
          ]
          spids: [2125 2130 2150 -1]
        )
        (case_arm pat_list:[{(stop)}] spids:[2153 2154 2161 -1])
        (case_arm
          pat_list: [{(status)}]
          action: [
            (C {(do_status)})
            (command.ControlFlow
              token: (Token id:Id.ControlFlow_Exit val:exit span_id:2171)
              arg_word: {($ Id.VSub_QMark '$?')}
            )
          ]
          spids: [2164 2165 2176 -1]
        )
        (case_arm
          pat_list: [{(Id.Lit_Star '*')}]
          action: [
            (command.Simple
              words: [{(echo)} {(DQ ('Usage: checkroot.sh [start|stop]'))}]
              redirects: [
                (redir.Redir
                  op: (Token id:Id.Redir_GreatAnd val:'>&' span_id:2189)
                  fd: -1
                  arg_word: {(2)}
                )
              ]
            )
            (command.ControlFlow
              token: (Token id:Id.ControlFlow_Exit val:exit span_id:2193)
              arg_word: {(3)}
            )
          ]
          spids: [2179 2180 2198 -1]
        )
      ]
    )
    (C {(Id.Lit_Other ':')})
  ]
)