Hello all,
In your view, what is the most reliable and safe way to increase an LV housing the root filesystem of a Centos 6 VM. I am thinking either growing the virtual HD virtual device, or creating a new device and adding it as a PV to the VM, or perhaps migrating the whole FS to a new virtual disk.
Any input on how best to proceed would be appreciated.
Cheers,
Boris.
On 10/30/2015 08:42 AM, Boris Epstein wrote:
I am thinking either growing the virtual HD virtual device, or creating a new device and adding it as a PV to the VM
Either of those should work. Whichever you choose should be the path you take in the future. I don't use VMware, but I suspect you'll need to reboot if you choose to grow the virtual HD, but the additional VHD probably won't require a reboot.
Boris Epstein wrote:
Hello all,
In your view, what is the most reliable and safe way to increase an LV housing the root filesystem of a Centos 6 VM. I am thinking either growing the virtual HD virtual device, or creating a new device and adding it as a PV to the VM, or perhaps migrating the whole FS to a new virtual disk.
Any input on how best to proceed would be appreciated.
Dumb question: why do you need a larger root filesystem?
First, how big is root? And if this is for stuff under, say, /var/www, I'd make a separate logical drive/partition, and mount that, rsync everything from /var/www to that, then shut down the web, and remount the new filesystem on /var/www.
Root, itself, doesn't need to be huge. We're using 500G, and seriously considering making it 125G in the future, with data, or web stuff, is on a separate partition, so when there's a sudden explosion of data, / is safe.
mark
On Fri, Oct 30, 2015 at 12:57 PM, m.roth@5-cent.us wrote:
Boris Epstein wrote:
Hello all,
In your view, what is the most reliable and safe way to increase an LV housing the root filesystem of a Centos 6 VM. I am thinking either
growing
the virtual HD virtual device, or creating a new device and adding it as
a
PV to the VM, or perhaps migrating the whole FS to a new virtual disk.
Any input on how best to proceed would be appreciated.
Dumb question: why do you need a larger root filesystem?
First, how big is root? And if this is for stuff under, say, /var/www, I'd make a separate logical drive/partition, and mount that, rsync everything from /var/www to that, then shut down the web, and remount the new filesystem on /var/www.
Root, itself, doesn't need to be huge. We're using 500G, and seriously considering making it 125G in the future, with data, or web stuff, is on a separate partition, so when there's a sudden explosion of data, / is safe.
mark
Mark,
Thanks for your input.
Well, we are talking much smaller scale here (only about 30 GB at present, planning to roughly double it).
I agree with you that it is best to keep usage/operational data outside of root - but it just historically so happened that this is how we do things. So for now this is the task and I need to perform it somehow.
Cheers,
Boris.
Hi, The best and safe way to do that is by adding another vHD as a new PV to your root_vg and then grow your LV. No need to stop services, shutdown or reboot the VM; if it's in prod environment.
Julius
On Oct 30, 2015, at 19:18, Boris Epstein borepstein@gmail.com wrote:
On Fri, Oct 30, 2015 at 12:57 PM, m.roth@5-cent.us wrote:
Boris Epstein wrote:
Hello all,
In your view, what is the most reliable and safe way to increase an LV housing the root filesystem of a Centos 6 VM. I am thinking either
growing
the virtual HD virtual device, or creating a new device and adding it as
a
PV to the VM, or perhaps migrating the whole FS to a new virtual disk.
Any input on how best to proceed would be appreciated.
Dumb question: why do you need a larger root filesystem?
First, how big is root? And if this is for stuff under, say, /var/www, I'd make a separate logical drive/partition, and mount that, rsync everything from /var/www to that, then shut down the web, and remount the new filesystem on /var/www.
Root, itself, doesn't need to be huge. We're using 500G, and seriously considering making it 125G in the future, with data, or web stuff, is on a separate partition, so when there's a sudden explosion of data, / is safe.
mark
Mark,
Thanks for your input.
Well, we are talking much smaller scale here (only about 30 GB at present, planning to roughly double it).
I agree with you that it is best to keep usage/operational data outside of root - but it just historically so happened that this is how we do things. So for now this is the task and I need to perform it somehow.
Cheers,
Boris. _______________________________________________ CentOS mailing list CentOS@centos.org https://lists.centos.org/mailman/listinfo/centos
Boris Epstein wrote:
On Fri, Oct 30, 2015 at 12:57 PM, m.roth@5-cent.us wrote:
Boris Epstein wrote:
In your view, what is the most reliable and safe way to increase an LV housing the root filesystem of a Centos 6 VM. I am thinking either growing the virtual HD virtual device, or creating a new device and adding it as a PV to the VM, or perhaps migrating the whole FS to a new virtual disk.
Any input on how best to proceed would be appreciated.
Dumb question: why do you need a larger root filesystem?
First, how big is root? And if this is for stuff under, say, /var/www, I'd make a separate logical drive/partition, and mount that, rsync everything from /var/www to that, then shut down the web, and remount the new filesystem on /var/www.
Root, itself, doesn't need to be huge. We're using 500G, and seriously considering making it 125G in the future, with data, or web stuff, is on a separate partition, so when there's a sudden explosion of data, / is safe.
Well, we are talking much smaller scale here (only about 30 GB at present, planning to roughly double it).
<snip> Ok, that *is* small. I'd worry about a logfile suddenly growing massively, and freezing your system. (Yes, it has happened here, and then there was the time a summer student ran something, wouldn't be back until Monday... and got a 20G logfile, which blew out the NFS-mounted home directory fs, on which a number of other people resided... including *me*, and his manager, and our division head....)
mark
Ok, that *is* small. I'd worry about a logfile suddenly growing massively, and freezing your system. (Yes, it has happened here, and then there was the time a summer student ran something, wouldn't be back until Monday... and got a 20G logfile, which blew out the NFS-mounted home directory fs, on which a number of other people resided... including *me*, and his manager, and our division head....)
mark
CentOS mailing list CentOS@centos.org https://lists.centos.org/mailman/listinfo/centos
Mark,
Absolutely - plus, we just need more space:)
Does it make any difference whether to use full disk device for your LV (i.e., /dev/sdc or some such) or make a partition instead (say, /dev/sdc1 covering the whole disk end to end)? I mean, are there any pro's and con's to using either as extra space for the logical group?
Thanks.
Boris.
On Tue, Nov 3, 2015 at 4:51 PM, Boris Epstein borepstein@gmail.com wrote:
Does it make any difference whether to use full disk device for your LV (i.e., /dev/sdc or some such) or make a partition instead (say, /dev/sdc1 covering the whole disk end to end)? I mean, are there any pro's and con's to using either as extra space for the logical group?
Just like with software RAID (using mdadm), you can create partitions or use the raw disk.
In the past I've been of the thought that a block device having partitions is a good idea in terms of something visible denoting the use of the device. But that may not be necessary in all situations.
Might check out the warnings and opinions at the following URLs to make your decision. [ Opinions advise to create a partition and not to put LVM on a raw disk. ]
[0] http://www.tldp.org/HOWTO/LVM-HOWTO/initdisks.html [1] http://unix.stackexchange.com/questions/76588/what-is-the-best-practice-for-... [2] http://serverfault.com/questions/439022/does-lvm-need-a-partition-table