Re: parted -- functionality and documentation

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

 



On Mon, 16 Jun 2003, Michael Schwendt wrote:

> First of all, I can't explain it. I'd just like to point out that
> parted also contains such a warning, and I've seen it frequently:
> 
>     "The kernel was unable to re-read the partition table on %s
>     (%s). This means Linux won't know anything nothing about the
>     modifications you made until you reboot.  You should reboot your
>     computer before doing anything with %s."
> 
> But also this which I don't remember having seen before:
> 
>     "Error informing the kernel about modifications to partition %s
>     - %s. This means Linux won't know about any changes you made to
>     %s until you reboot - so you shouldn't mount it or use it in any
>     way before rebooting."
> 
> *Maybe* (oh, i shouldn't speculate, but use the source ;) it depends
> on what changes are applied to the partition table. Perhaps adding a
> new partition works, but deleting and changing partitions doesn't, or
> something like that.

i did a couple more tests, and here are the results.  if, on my 
system, i use "fdisk" to create a new partition, and "w" to write 
it out, i get the warning i've seen for quite some time --
"WARNING: Re-reading the partition table failed with error 16:
Device or resource busy... blah blah ... new table will be used
at next reboot."

so, even though the new partition shows up via "fdisk", any
attempt to create a filesystem on it generates an error of
"No such device or address ...".

in addition (and more significantly), there is no mention of that
new fdisk-created partition in /proc/partitions, which is allegedly
the list of partitions that the kernel recognizes, and that
reinforces the impression that the kernel just won't see this
partition until the next reboot.  so, knowing that, i can use
fdisk to remove it.

with parted, however, i can create a new partition with
(parted) mkpart logical ext3 15000 20000
(parted) q

i get no warnings when i exit, the new partition *is* 
listed in /proc/partitions and, sure enough, i can create
a filesystem on it, mount it, copy stuff to it, etc.

so, somehow, parted is forcing the kernel to recognize
the new partition in a way that fdisk doesn't.

rday

p.s.  one wonders what the effect would be of just 
forcing the appending of a new line of data at the end
of /proc/partitions, but i'm not that suicidal.




[Index of Archives]     [Fedora Users]     [Centos Users]     [Kernel Development]     [Red Hat Install]     [Red Hat Watch]     [Red Hat Development]     [Red Hat Phoebe Beta]     [Yosemite Forum]     [Fedora Discussion]     [Gimp]     [Stuff]     [Yosemite News]

  Powered by Linux