Monty85
Contributor
Contributor

Extending a iscsi LUN without losing VM

Jump to solution

I originally created a 500 GB iSCSI VMFS lun for my datastore. I noticed that I had more SAN storage available, so I increased the LUN size from 500 GB to 1.3 TB LUN for our VMWare datastore. I currently have a DC VM on that LUN that I want to extend. When I go to Storage and add Extend, it says that the drive will be formatted and all data will be erased. This is a ESXi v3.5 host. What is the best way to extend this LUN without losing my domain controller VM?

Should I try to move the VM to internal storage using the datastore browser? Do I have to use VMWare Converter to move the VM off the iscsi lun until the LUN is extended or is there another way? With your recommendations can you also provide exact directions to carry out? This is a production environment and I don't have a lot of experience doing this type of move. Your comments are greatly appreciated.

Tags (3)
0 Kudos
1 Solution

Accepted Solutions
Cooldude09
Commander
Commander

Hi Monty,

One thing to remember, whenever you play any such thing w.r.t sizing of the LUN's always take relevant backup and then do what you want to play around. The error which you are getting is the error for the new extend that when added , all the data on the new extend will be lost, so definitely you can proceed without any hestations.

Regards

Anil

Save the planet, Go Green

if you found my answer to be useful, feel free to mark it as Helpful or Correct.

If U find my answer useful, feel free to give points by clicking Helpful or Correct. Subscribe yourself at walkonblock.com

View solution in original post

0 Kudos
8 Replies
Cooldude09
Commander
Commander

Hi Monty,

One thing to remember, whenever you play any such thing w.r.t sizing of the LUN's always take relevant backup and then do what you want to play around. The error which you are getting is the error for the new extend that when added , all the data on the new extend will be lost, so definitely you can proceed without any hestations.

Regards

Anil

Save the planet, Go Green

if you found my answer to be useful, feel free to mark it as Helpful or Correct.

If U find my answer useful, feel free to give points by clicking Helpful or Correct. Subscribe yourself at walkonblock.com
0 Kudos
Monty85
Contributor
Contributor

So the VM that is currently on the 500 GB iscsi LUN that I am extending will not be affected correct?

Thanks!

0 Kudos
Cooldude09
Commander
Commander

Yes Monty , it wont, normally users do get confused with the warning message. Mayb VMware should modify the same saying that data on new extend will be lost.

Regards

Anil

Save the planet, Go Green

if you found my answer to be useful, feel free to mark it as Helpful or Correct.

If U find my answer useful, feel free to give points by clicking Helpful or Correct. Subscribe yourself at walkonblock.com
0 Kudos
Monty85
Contributor
Contributor

My existing VM that is on the 500 GB LUN that I am extending will be unaffected correct?

Thanks!

0 Kudos
Craig_Baltzer
Expert
Expert

The warning you are seeing when you do an "Add Extent" is saying that the disk/LUN you are about to add will be formatted and all data erased, not the existing LUN that was already in the datastore. So for example if you had a 500GB LUN already formatted as VMFS with VMs on it, and you wanted to add a 800GB LUN as an extent to that existing 500GB datastore, then the 800GB LUN would be wiped out but any data on the 500GB LUN would remain intacted. around page 136 goes through the process...

If you took your 500GB LUN and expanded it to 1.3TB on the SAN, then you'd want to move the VM off the existing datastore and re-do the VMFS partition to include all of the storage (there is no way to "expand" a VMFS partition itself, just add extents to a datastore/volume), In that case if you have vMotion/vCenter agent license for the ESXi box and another datastore on the box with sufficient space to hold the VM, then you can either svmotion or cold migrate the VM to the other datastore, do your re-partitioning of the VMFS volume, and then move the VM back.

If you don't have vMotion/vCenter agent license for the ESXi box but do have another datastore on the box with sufficient space you can use the Datastore Browser to do the move and move back. Shtudown the VM first and remove it from inventory, then create a directory to hold it on the other datastore that you'll use for temporary space. Then go back to the datastore currently holding the VM, select all of the files in the VMs directory, then do a right-click "Move" to the other datastore. Once you have the VMFS partition and datastore re-created using all of the expanded LUN, then go to the datastore browser on the newly expanded LUN, create a directory for the VM, and then go back to the datastore browser on the temporary datastore and repeat the "move" process in the opposite direction. After the move completes, go to the newly expanded datastore, navigate to the VMs .vmx file, right click and Add to Inventory...

Cooldude09
Commander
Commander

Yes it wont... Smiley Happy

Regards

Anil

Save the planet, Go Green

if you found my answer to be useful, feel free to mark it as Helpful or Correct.

If U find my answer useful, feel free to give points by clicking Helpful or Correct. Subscribe yourself at walkonblock.com
0 Kudos
Monty85
Contributor
Contributor

Yeah I know, I just did it. I just wanted some confirmation. Thanks a lot!

0 Kudos
Cooldude09
Commander
Commander

Thats good to know... Go Green..... Smiley Happy

Regards

Anil

Save the planet, Go Green

if you found my answer to be useful, feel free to mark it as Helpful or Correct.

If U find my answer useful, feel free to give points by clicking Helpful or Correct. Subscribe yourself at walkonblock.com
0 Kudos