Re: What is the status with migrating partition code out of the kernel and into partx?

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

 



On Fri, Mar 19, 2010 at 10:59, Karel Zak <kzak@xxxxxxxxxx> wrote:
> On Thu, Mar 18, 2010 at 09:21:04PM -0400, Mike Frysinger wrote:
>> On Thursday 18 March 2010 11:24:13 Phillip Susi wrote:
>> > It seems that while it has been several years since this was first
>> > proposed and partx was developed to work with udev to handle partition
>> > detection in user space, this has still not been done.  Why is this?
>> > Has there been resistance to this or has there just been a lack of
>> > motivation?  Are there any good technical reasons why this has not yet
>> > been adopted?
>>
>> could you clarify what you mean by "migrating partition code out of the
>> kernel" ?  the kernel can never shed its partition parsing logic ...
>
>  Why? You can parse partition table in userspace (initramfs) and use
>  BLKPG_ADD_PARTITION ioctl to inform kernel about the disk layout or
>  you can use device-mapper to create new devices.
>
>  IMHO we don't use this concept, because the current way (parse all in
>  kernel) works usually fine.

There are quite a few cases which are not handled properly. We would
probably need a global flag telling the kernel not to parse tables by
default, and a per-device flag, to instruct the kernel to leave all to
userspace, if so requested.

The in-kernel parser is just too dumb to recognize all sorts of common
metadata on the device which invalidate any possible partition table.
Like the kernel used to happily announce partition of a raid member,
which do not even exist on the device.

Regardless of all that, the default in-kernel partition table
handling, and the partition table parser code will not be replaced by
userspace. But it should be possible to delegate all that to
userspace, on systems which can handle that. This is not reliable
possible today.

So there is definitely more to do than: "usually works fine". :)

Kay
--
To unsubscribe from this list: send the line "unsubscribe util-linux-ng" in
the body of a message to majordomo@xxxxxxxxxxxxxxx
More majordomo info at  http://vger.kernel.org/majordomo-info.html

[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