Re: [PATCH] libblkid: make blkid_do_wipe() work with probes with offset

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

 



On Tue, Apr 19, 2016 at 11:18:51AM +0200, Karel Zak wrote:
> On Tue, Apr 19, 2016 at 11:05:02AM +0200, Petr Uzel wrote:
> > On Mon, Apr 18, 2016 at 08:00:18PM +0200, Karel Zak wrote:
> > > On Mon, Apr 18, 2016 at 04:22:05PM +0200, Petr Uzel wrote:
> > > > When a probe is created with an offset, e.g. via
> > > > blkid_probe_set_device(), this offset is correctly used when looking for
> > > > the signatures, but is not respected by blkid_do_wipe() function.
> > > > Therefore the signature is removed from an invalid location.
> > > 
> > > Wow, excellent catch. 
> > 
> > Thanks, feels good to again contribute a fix after such a long time :)
> > 
> > > How did you found it? Do you use libblkid in some partitioning tool or
> > > installer?
> > 
> > Yes, I'm trying to implement a --wipesignatures for parted - this
> > would wipe the signatures from a new partition, _before_ the kernel
> > is informed. This is to avoid mess like RAID autoassembly...
> > 
> > [If only there was some sane mechanism lock a device to temporarily
> > prevent udev from touching it :/]
> 
> since v2.28 fdisk wipes disks (--wipe=auto,always,never), but it does
> not care about partitions. 
>
> Maybe we can improve it and add --wipe-partitions too. IMHO it should
> not be enabled by default, because change disk layout and keep
> filesystems seems like a valid use-case.

Agreed, it certainly has to be disabled by default.


        Petr

-- 
Petr Uzel
TL SUSE L3 Team 2

Attachment: signature.asc
Description: Digital signature


[Index of Archives]     [Netdev]     [Ethernet Bridging]     [Linux Wireless]     [Kernel Newbies]     [Security]     [Linux for Hams]     [Netfilter]     [Bugtraq]     [Yosemite News]     [MIPS Linux]     [ARM Linux]     [Linux RAID]     [Linux Admin]     [Samba]

  Powered by Linux