From: Vasiliy G Tolstov <v.tolstov@selfip.ru>
To: linux-kernel@vger.kernel.org
Subject: change partition table on live disk (resize root partition)
Date: Tue, 28 Dec 2010 12:24:09 +0300 [thread overview]
Message-ID: <1293528249.8310.8.camel@vase> (raw)
Hello.
If i need to resize root partition on live file system i do
fdisk /dev/sda delete old partition table and write new. After that
fdisk say's that system use old partition table before reread it via
partprobe or something else.
But if i modify root partition partprobe say's that it is already in use
and i need to reboot system to see changes and do resize fs.
Is that possible to reread partition table for root fs without
rebooting? I ca'n use lvm on something else, i'm use plain ext3 fs.
P.S. This is need for xen domU, i see that in blkfront_connect function
this code:
/*
* Potentially, the back-end may be signalling
* a capacity change; update the capacity.
*/
err = xenbus_scanf(XBT_NIL, info->xbdev->otherend,
"sectors", "%Lu", §ors);
if (XENBUS_EXIST_ERR(err))
return;
printk(KERN_INFO "Setting capacity to %Lu\n",
sectors);
set_capacity(info->gd, sectors);
revalidate_disk(info->gd);
If i'm add after revalidate disk some function to reread partiotion
table does it can work?
Sorry for may be stupid question...
--
Vasiliy G Tolstov <v.tolstov@selfip.ru>
Selfip.Ru
reply other threads:[~2010-12-28 9:24 UTC|newest]
Thread overview: [no followups] expand[flat|nested] mbox.gz Atom feed
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=1293528249.8310.8.camel@vase \
--to=v.tolstov@selfip.ru \
--cc=linux-kernel@vger.kernel.org \
/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