Latest LQ Deal: Latest LQ Deals
Go Back > Forums > Linux Forums > Linux - Server
User Name
Linux - Server This forum is for the discussion of Linux Software used in a server related context.


  Search this Thread
Old 05-08-2012, 01:29 PM   #1
LQ Newbie
Registered: Jul 2010
Posts: 1

Rep: Reputation: 0
How to hot add disk to a filesystem

Hey all, thanks for taking a moment to read and perhaps provide me some insight.

I have virtualized Linux machines that have base configurations on them, including disk size. I realize that over time one, or more, of those Linux VMs may experience a disk capacity issue. As such, I would like to identify a way to hot-add data disk to the VM without incurring an outage to the disk. Windows 2008 R2 can do this, so I have to believe Linux can also, after all, Microsoft surely steals the best ideas they have from the Linux community. (Note, I'm talking about extending data disk, not the root partition.)

I've Googled this to no end and every solution I've tried always causes an outage to the disk. I am going to attribute this to my inability to Google. ;-)

Thanks in advance.
Old 05-08-2012, 09:32 PM   #2
LQ Guru
Registered: Jan 2006
Location: Virginia, USA
Distribution: Slackware, Ubuntu MATE, Mageia, and whatever VMs I happen to be playing with
Posts: 15,535
Blog Entries: 25

Rep: Reputation: 4485Reputation: 4485Reputation: 4485Reputation: 4485Reputation: 4485Reputation: 4485Reputation: 4485Reputation: 4485Reputation: 4485Reputation: 4485Reputation: 4485
I think this would depend a lot on what virtualization engine you are using.

Here's an article on how to do it in VirtualBox:
Old 05-10-2012, 02:44 AM   #3
LQ Newbie
Registered: May 2012
Posts: 28

Rep: Reputation: Disabled
A LVM configured Linux VM would be very easy to hot add a disk without downtime by vgextend /dev/sd<NewlyAddedDisk>
Old 05-10-2012, 04:45 AM   #4
LQ Veteran
Registered: Aug 2003
Location: Australia
Distribution: Lots ...
Posts: 18,205

Rep: Reputation: 2951Reputation: 2951Reputation: 2951Reputation: 2951Reputation: 2951Reputation: 2951Reputation: 2951Reputation: 2951Reputation: 2951Reputation: 2951Reputation: 2951
Short answer, probably not.
If you can extend the partition (disk) the filesystem is on, yes you can. If, as @xZi indicates, the filesystem is on LVM2, then it can be trivially extended - even onto additional "disks". This is not something you can convert to - it must be setup in advance - but only once.
If you happen to be using btrfs (unlikely) you can proceed as you are used to in Win2008 - just add the disk to the filesystem. Btrfs is still considered less than stable by some people.
Old 05-10-2012, 05:22 AM   #5
Registered: Apr 2012
Location: /root
Distribution: Ubuntu, Redhat, Fedora, CentOS
Posts: 190

Rep: Reputation: 55
are you here asking a adding a new disk into linux without reboot it ? or adding a already visible disk in fdisk -l to lvm or somewhere else ?

but your scenario i unclear here. so explain it what exactly are you trying to doing?


Thread Tools Search this Thread
Search this Thread:

Advanced Search

Posting Rules
You may not post new threads
You may not post replies
You may not post attachments
You may not edit your posts

BB code is On
Smilies are On
[IMG] code is Off
HTML code is Off

Similar Threads
Thread Thread Starter Forum Replies Last Post
MDADM fails to hot remove disk alirezan1 Linux - Newbie 8 03-21-2012 10:34 AM
Hard-disk too hot! ario Linux - Hardware 28 03-09-2011 04:21 AM
Hot-add SAN LUN dcostakos Linux - Hardware 5 03-11-2005 02:16 PM
hot plugging and mounting a USB memory disk Alf829 Fedora 9 10-07-2004 11:21 AM > Forums > Linux Forums > Linux - Server

All times are GMT -5. The time now is 09:34 PM.

Main Menu
Write for LQ is looking for people interested in writing Editorials, Articles, Reviews, and more. If you'd like to contribute content, let us know.
Main Menu
RSS1  Latest Threads
RSS1  LQ News
Twitter: @linuxquestions
Facebook: linuxquestions Google+: linuxquestions
Open Source Consulting | Domain Registration