bug-parted
[Top][All Lists]
Advanced

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

Re: address@hidden: Bug#136501: Parted segfaults on startup with Minix-c


From: Andreas Dilger
Subject: Re: address@hidden: Bug#136501: Parted segfaults on startup with Minix-created partition table]
Date: Sun, 3 Mar 2002 21:41:38 -0700
User-agent: Mutt/1.2.5i

On Mar 04, 2002  08:11 +1100, Andrew Clausen wrote:
> Parted does funky stuff with caches, etc., so I wouldn't be
> surprised if we're causing some corner case.

Actually, the parted BLKFLSBUF tickles a bug that was in ext3 2.2 for
a while (hit that on an internal server).  Didn't we discuss removing
this call entirely?  Basically, if a device is in-use in the kernel
calling BLKFLSBUF is not sufficient to force all buffers to disk (it
will refuse to flush busy buffers), and we won't be able to change a
partition that is in-use anyways.

A patch for parted-1.6 is below.

Cheers, Andreas
======================================================================
diff -ru libparted/linux.c.orig libparted/linux.c
--- libparted/linux.c.orig      Wed Feb 27 15:33:45 2002
+++ libparted/linux.c   Thu Feb 28 18:11:16 2002
@@ -914,7 +914,8 @@
                dev->read_only = 0;
        }
 
-       _flush_cache (dev);
+       /* _flush_cache (dev); */
+       sync(); sync();
 
        return 1;
 }
--
Andreas Dilger
http://sourceforge.net/projects/ext2resize/
http://www-mddsp.enel.ucalgary.ca/People/adilger/




reply via email to

[Prev in Thread] Current Thread [Next in Thread]