base_partitions:
Changed the flags for fsck (-n to -fy) to force the fsck and
force the unmount and correction of any errors.
Changed the fsck command from yes|cmd to just cmd since we are
now providing the -y option.


Signed-off-by: Akshay Lal <[email protected]>

--- autotest/client/bin/base_partition.py       2010-04-02 13:09:00.000000000 
-0700
+++ autotest/client/bin/base_partition.py       2010-04-02 13:09:00.000000000 
-0700
@@ -612,7 +612,7 @@
                         self.fstype)
 
 
-    def fsck(self, args='-n', record=True):
+    def fsck(self, args='-fy', record=True):
         """
         Run filesystem check
 
@@ -620,7 +620,6 @@
                 which works on most tools.
         """
 
-
         # I hate reiserfstools.
         # Requires an explit Yes for some inane reason
         fsck_cmd = '%s %s %s' % (self.get_fsck_exec(), self.device, args)
@@ -628,7 +627,7 @@
             fsck_cmd = 'yes "Yes" | ' + fsck_cmd
         sys.stdout.flush()
         try:
-            utils.system("yes | " + fsck_cmd)
+            utils.system_output(fsck_cmd)
         except:
             if record:
                 self.job.record('FAIL', None, fsck_cmd, error.format_error())
_______________________________________________
Autotest mailing list
[email protected]
http://test.kernel.org/cgi-bin/mailman/listinfo/autotest

Reply via email to