Changeset 2617

Show
Ignore:
Timestamp:
10/12/07 02:03:23 (1 year ago)
Author:
dhozac
Message:

Run fsck on filesystems in the guest's fstab.

Files:

Legend:

Unmodified
Added
Removed
Modified
Copied
Moved
  • trunk/scripts/vserver.functions

    r2615 r2617  
    894894} 
    895895 
     896function fsckAllFS 
     897{ 
     898    local cfgdir=$1 
     899    local fstab="$cfgdir"/fstab 
     900    local FSTAB_FILE 
     901    local fsck_exitcode 
     902 
     903    test -e "$fstab" || return 0 
     904 
     905    export FSTAB_FILE="$fstab" 
     906    $_FSCK -s -n -A -T 
     907    fsck_exitcode=$? 
     908    test "$fsck_exitcode" -eq 0 -o \ 
     909         "$fsck_exitcode" -eq 1 || return $fsck_exitcode 
     910} 
     911 
    896912## Usage: waitForSync <vserver> <context> <vshelper-fifo-varname> 
    897913function initSync 
  • trunk/scripts/vserver.start

    r2599 r2617  
    106106popd >/dev/null 
    107107 
     108fsckAllFS        "$VSERVER_DIR" 
     109 
    108110mountRootFS      "$VSERVER_DIR" 
    109111generateOptions  "$VSERVER_DIR"