[ale] Xen Server adding a virtual disk to a VM

Scott Plante splante at insightsys.com
Mon Oct 17 15:52:34 EDT 2016


I wanted to clarify my question a bit. When I create a new VM, I usually create one small disk (like 10GB) and do the OS install on that with fairly standard options. So that disk is partitioned with a /boot and a swap and at least a root partition. Maybe a /home if the distro wants it. Then, if the purpose of the VM will require more than the minimal space I'll create another virtual disk and add it to the VM. Maybe down the line I'll have to add yet another virtual disk, as I'm going through right now. It's only these last two cases I'm asking about. I can't see where it'd be worth fighting with the installer to get it to not partition the boot drive, even if that were possible. 


Scott 

----- Original Message -----

From: "Scott Plante" <splante at insightsys.com> 
To: "Atlanta Linux Enthusiasts" <ale at ale.org> 
Sent: Monday, October 17, 2016 2:49:24 PM 
Subject: Re: [ale] Xen Server adding a virtual disk to a VM 


Thanks guys. This thread has been very informative. 


So you don't LVM inside a VM, but do you partition? I've always partitioned because it's how I was taught (pre-VM), but suppose you have a Linux VM, and you want to add a 200GB partition for some application. You go into your VM software and create the virtual disk and attach it to the VM. Inside the VM it appears as a new device, say /dev/xvde. You could create a partition and /dev/xvde1 would appear and you could mkfs /dev/xvde1 or you could skip the partitioning and just mkfs /dev/xvde. One reason you generally partition is for the sector alignment stuff, but (correct me if I'm wrong) that doesn't apply to a virtual disk. The sector alignment would be taken care of when you partition the drive inside XenServer, VMWare or whatever's running on the bare metal. Another reason you might normally partition a drive is to separate your OS from your data, to make sure run-away log files don't crash your database, etc., but that doesn't apply here because you've already created a separate virtual disk for that purpose. 


I asked a friend at the pub Friday night who works with lots of VMs and he says he partitions just as a reminder to himself that he has or hasn't done something with the virtual disk. So he might go add a new disk to a half-dozen VMs, and when he goes into each one he can more easily tell whether he has taken care of it yet or something like that. If I add or remove a disk once a month it's a lot, so that's not a big selling point for me. Still, I suppose it could be useful as some longer term "documentation" kind of thing. 


So those of you on the list who deal with VMs: do you partition your virtual disks? 


Scott 


p.s. my recent VM experience is mostly with XenServer, so forgive me if my question and/or terminology doesn't make sense for ESXi, KVM, or other VM environments. 

-------------- next part --------------
An HTML attachment was scrubbed...
URL: <http://mail.ale.org/pipermail/ale/attachments/20161017/a5d06eca/attachment.html>


More information about the Ale mailing list