Link to home
Create AccountLog in
Avatar of Clairedlune
ClairedluneFlag for Canada

asked on

How do I remove a Virtual Hard Disk from a VM in ESXi

Hi, I hope that someone can offer me some guidance with the following task:

Object:  On a host system running VMWare ESXi 4.1 there are currently two virtual machines configured with the following guest OS’s

•      Microsoft Enterprise Server 2003
•      Microsoft Enterprise Server 2008

The vm with MS2008 has three virtual disks configured as follows:

           disk 1 ~50GB  
            disk 2 ~1.9TB
            disk 3 ~1.9TB

I would like to release the storage mapped to disk 3 so that I can reallocate a portion of it to the other Virtual Machine (MS 2003 Guest OS) defined on the host.
I have included an attachment document containing screen captures of the host inventory and 2008 VM configuration – “How do I  remove  a Virtual Disk from a VM in ESXi 4.doc”
I would greatly appreciate any advice/suggestions  on the protocol one should follow to accomplish this goal.

Since this is my first post to Experts Exchange I am open to suggestions on how I should post questions/screen-captures more efficiently.

Thanks in advance!
 How-do-I--remove--a-Virtual-Disk.doc
SOLUTION
Avatar of Andrew Hancock (VMware vExpert PRO / EE Fellow/British Beekeeper)
Andrew Hancock (VMware vExpert PRO / EE Fellow/British Beekeeper)
Flag of United Kingdom of Great Britain and Northern Ireland image

Link to home
membership
Create an account to see this answer
Signing up is free. No credit card required.
Create Account
Avatar of Clairedlune

ASKER

Thankyou hanccocka,

First shutdown the Virtual Machine and ensure there are no files on the virtual disk in the operating system you require, but this procedure is not reverseible.


From within the OS, I first performed a backup of all the files and then removed the file system off of the disk.  I also took it off-line - do you think that taking it off-line is necessary or should I leave it on line - I don't want to complicate things?
 

Select the Virtual Machine in the vSphere Client when connected to the ESXi 4.1 server.

Click Edit Settings, Hightlight the Virtual Disk - Hard Disk 3 and Click Remove

and then Select Remove from Virtual Machine and delete files from disk.
 


Just want to understand the difference here.  Am I correct in assuming that if I choose to simply remove the disk from the virtual machine that I could (assuming the file systems are compatible) add this disk to another virtual machine, eg. MS2003?  Or given that this is simply a data disk perhaps add it to the existing machine at a later date?

When I select remove from virtual machine and delete files from disk should I see the datastore update the unallocated storage space?  Is there usually a lag assoc. with the update?

Thanks!
ASKER CERTIFIED SOLUTION
Link to home
membership
Create an account to see this answer
Signing up is free. No credit card required.
Create Account
SOLUTION
Link to home
membership
Create an account to see this answer
Signing up is free. No credit card required.
Create Account
Thanks for responding to the follow-up questions I raised - most helpful.
I'll try and implement the changes tomorrow a.m.