public inbox for linux-kernel@vger.kernel.org
 help / color / mirror / Atom feed
From: Oleg Verych <olecom@flower.upol.cz>
To: linux-kernel@vger.kernel.org
Cc: Michael Tokarev <mjt@tls.msk.ru>
Subject: Re: re-reading the partition table on a "busy" drive
Date: Fri, 08 Sep 2006 07:55:12 +0200	[thread overview]
Message-ID: <450105C0.2010603@flower.upol.cz> (raw)
In-Reply-To: <45004707.4030703@tls.msk.ru>

Hallo,

Michael Tokarev wrote:
> Currently, the kernel refuses to re-read partition table
> from a drive which has usage count > 0.  Motivation for
> this is pretty clear ,
 >                        pretty annoying -- in order to change
> to reboot the machine.
> 
Yes, very interesting thing. While one will destroy its part.table, he can not 
see until reboot, heh. But there were days, when grub used to install itself on 
XFS partition (XFS isn't FAT-boot-record compatible) *silently*, but nothing 
was wrong to me : it's linux-gnu ;D

I would love just little kernel boot parameter to configure it, or sysctl in 
procfs.

> I wonder if it's possible to actually read the new partition
> table, compare it with previous, and apply changes IF they
> don't conflict with currently open partitions?  Say, if we
> have sda1 and sda2, sda1 is open/mounted, and new partition
> table does not have sda2, but sda1 is unchanged - it's pretty
> safe to apply new partition table, without affecting mounted
> sda1.  Ditto for adding new partitions.
> 
> Yes, a line should be drawn somewhere - say, if sda3 was
> mounted, and we removed unused sda2, but sda3 (which becomes
> sda2 with new table) is intact, we should not apply new
> table.
> 
> Is it possible to implement such a feature?  I mean, is it
> easy to know which *partitions* (subdevices?) of the whole
> device are currently in use, as opposed to the whole drive?
> 
IMHO you've wrote much more here, then just for not-so-useless-solution, that 
i've wrote above, unless you want another wind0s clever-heuristic with patches 
from happy users to lkml: <http://article.gmane.org/gmane.linux.kernel/437388>

> Thanks.
> 
> /mjt


-- 
-o--=O`C  /. .\   (+)
  #oo'L O      o    |
<___=E M    ^--    |  (you're barking up the wrong tree)


  reply	other threads:[~2006-09-08  4:55 UTC|newest]

Thread overview: 7+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2006-09-07 16:21 re-reading the partition table on a "busy" drive Michael Tokarev
2006-09-08  5:55 ` Oleg Verych [this message]
2006-09-08  6:58   ` Jan Engelhardt
     [not found]     ` <20060908135858.GB14370@flower.upol.cz>
2006-09-08 13:34       ` Michael Tokarev
2006-09-08 13:47         ` Jan Engelhardt
2006-09-08 14:56           ` Oleg Verych
2006-09-08  8:27 ` Olaf Hering

Reply instructions:

You may reply publicly to this message via plain-text email
using any one of the following methods:

* Save the following mbox file, import it into your mail client,
  and reply-to-all from there: mbox

  Avoid top-posting and favor interleaved quoting:
  https://en.wikipedia.org/wiki/Posting_style#Interleaved_style

* Reply using the --to, --cc, and --in-reply-to
  switches of git-send-email(1):

  git send-email \
    --in-reply-to=450105C0.2010603@flower.upol.cz \
    --to=olecom@flower.upol.cz \
    --cc=linux-kernel@vger.kernel.org \
    --cc=mjt@tls.msk.ru \
    /path/to/YOUR_REPLY

  https://kernel.org/pub/software/scm/git/docs/git-send-email.html

* If your mail client supports setting the In-Reply-To header
  via mailto: links, try the mailto: link
Be sure your reply has a Subject: header at the top and a blank line before the message body.
This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox