Discussion:
Force reread of partition table
(too old to reply)
Drew Myers
2004-12-02 22:21:24 UTC
Permalink
When creating a new partition with fdisk on a RedHat box, I receive
the following message:

Re-read table failed with error 16: Device or resource busy

I seem to recall a way to force the reread to occur now, without
rebooting the system.


Can anyone fill in the blank for me?

Thanks,
mjt
2004-12-02 23:35:30 UTC
Permalink
Post by Drew Myers
When creating a new partition with fdisk on a RedHat box, I receive
Re-read table failed with error 16: Device or resource busy
that's probably because you had at least one partiton
mounted while using fdisk (even swap). it's much safer
to run fdisk from a live CD based distro.
Post by Drew Myers
I seem to recall a way to force the reread to occur now,
without rebooting the system.
... there is no "force"
--
<< http://michaeljtobler.homelinux.com/ >>
You're not drunk if you can lie on the floor without holding on.
-- Dean Martin
Michael Heiming
2004-12-03 10:44:49 UTC
Permalink
Post by mjt
Post by Drew Myers
When creating a new partition with fdisk on a RedHat box, I receive
Re-read table failed with error 16: Device or resource busy
[..]
Post by mjt
Post by Drew Myers
I seem to recall a way to force the reread to occur now,
without rebooting the system.
... there is no "force"
Mh, try:

man partprobe
--
Michael Heiming (X-PGP-Sig > GPG-Key ID: EDD27B94)
mail: echo ***@urvzvat.qr | perl -pe 'y/a-z/n-za-m/'
#bofh excuse 392: It's union rules. There's nothing we can do
about it. Sorry.
mjt
2004-12-03 14:13:09 UTC
Permalink
Post by mjt
Post by Drew Myers
I seem to recall a way to force the reread to occur now,
without rebooting the system.
... there is no "force"
 man partprobe
... that's to inform the kernel. my assumption was
that the the error is coming from *fdisk* - this
error is normally reported by fdisk when there is
a mounted partition, and fdisk is trying to reread
the partition table just after fdisk writes the
new table.
--
<< http://michaeljtobler.homelinux.com/ >>
Do something big -- fuck a giant
Michael Heiming
2004-12-03 14:42:45 UTC
Permalink
Post by mjt
Post by mjt
Post by Drew Myers
I seem to recall a way to force the reread to occur now,
without rebooting the system.
... there is no "force"
?man?partprobe
... that's to inform the kernel. my assumption was
that the the error is coming from *fdisk* - this
error is normally reported by fdisk when there is
a mounted partition, and fdisk is trying to reread
the partition table just after fdisk writes the
new table.
Partprobe will inform the kernel, so the system/fdisk will be
able to see changes. The problem is usually changes to the disk
the root partition is living on, which can be solved using
partprobe without needing to reboot. At least that's what I
understood from the OP.
--
Michael Heiming (X-PGP-Sig > GPG-Key ID: EDD27B94)
mail: echo ***@urvzvat.qr | perl -pe 'y/a-z/n-za-m/'
#bofh excuse 47: Complete Transient Lockout
mjt
2004-12-03 15:20:49 UTC
Permalink
Post by Michael Heiming
Post by mjt
?man?partprobe
... that's to inform the kernel. my assumption was
that the the error is coming from fdisk - this
error is normally reported by fdisk when there is
a mounted partition, and fdisk is trying to reread
the partition table just after fdisk writes the
new table.
Partprobe will inform the kernel, so the system/fdisk will be
able to see changes. The problem is usually changes to the disk
the root partition is living on, which can be solved using
partprobe without needing to reboot. At least that's what I
understood from the OP.
... thanks for that! i would test this, but i dont want
to re-write my partition table at the moment :))
--
<< http://michaeljtobler.homelinux.com/ >>
I'm a Lisp variable -- bind me!
Keith Keller
2004-12-03 00:58:48 UTC
Permalink
Post by Drew Myers
When creating a new partition with fdisk on a RedHat box, I receive
Re-read table failed with error 16: Device or resource busy
I seem to recall a way to force the reread to occur now, without
rebooting the system.
Yeah--umount every filesystem on the drive in question. If your /
is on the same drive, then you must reboot. If your /usr, /var, or
any other area which is used by daemons, is on the same drive, you'll
likely need to enter runlevel 1 to umount those filesystems before
having fdisk reread the partition table.

In general, it's a lot easier to reboot, and you can be sure that the
kernel has the correct partition table.

--keith
--
kkeller-***@wombat.san-francisco.ca.us
(try just my userid to email me)
AOLSFAQ=http://wombat.san-francisco.ca.us/cgi-bin/fom
Loading...