VMware Cloud Community
pauls13
Contributor
Contributor
Jump to solution

How to move second partition on VM to new LUN

I have recently set up a new san with 2 partitions or luns one called system for all my c: drives of my vm's and one call storage for the data files of my vm's. I used VMconverter to move some old servers to the system lun on my san which has copied the data partitions to the system lun, and I now want to move the data disk of the vms to my storage lun which is raid 5. Can someone tell me if its possible how I can do this?

0 Kudos
1 Solution

Accepted Solutions
RParker
Immortal
Immortal
Jump to solution

Yeah, you can point converter to the VM on the server. Then use it to specify the datastore on the same server. Use the "select volumes and resize" for only the e: drive and point it to the system LUN destination on the same ESX server. Then it should migrate that volume over to the LUN, and once it's complete, everything should be ready.

You will then need to manual configure the VM to remove the e: drive (original location) and add the e: drive (system LUN location). It's a bit longer, and vmkfstools would be faster.. but it will work...

Let me know if you have problems. Additionally if you copy/paste your /vmfs/volumes exactly how it appears on your system in a PM, I can reply with a message of exactly the command you can copy /paste into your putty/ssh session, and it will be done...

View solution in original post

0 Kudos
10 Replies
vmroyale
Immortal
Immortal
Jump to solution

Check out this related thread:

http://communities.vmware.com/message/694658

Brian Atkinson | vExpert | VMTN Moderator | Author of "VCP5-DCV VMware Certified Professional-Data Center Virtualization on vSphere 5.5 Study Guide: VCP-550" | @vmroyale | http://vmroyale.com
0 Kudos
pauls13
Contributor
Contributor
Jump to solution

Hi I looked at the post but I am not sure if this is the solution for me, what I need is to to move my e: drive of VM1, which is currently on my System lun, to my Data Lun, does that make sense?

0 Kudos
RParker
Immortal
Immortal
Jump to solution

Well do you have a partition or a drive? You can't split a partition to a different LUN, but you can move a drive.

all you have to do is use converter to split the partition to another drive, or move the drive to the new LUN you created.

VM-1 /vmfs/volumes/ESXLUN1/C-drive.vmdk

VM-1 /vmfs/volumes/ESXSYSLUN2/E-Drive.vmdk

It would look something like that, depending on how you configured your VM.

0 Kudos
pauls13
Contributor
Contributor
Jump to solution

Hi RParker,

its the latter, I want to move my Drive to another LUN. how do I use VMconverter to achive that?

0 Kudos
RussH
Enthusiast
Enthusiast
Jump to solution

From the console of the ESX hosts, you can use 'vmkfstools -i {source volume} {destination volume}' to move the VMDK between the luns....

0 Kudos
pauls13
Contributor
Contributor
Jump to solution

is there a way I can move the drive using the GUI, as my CLI skills are hopeless

0 Kudos
RussH
Enthusiast
Enthusiast
Jump to solution

Not that I know of. But the syntax is v.straightforward -

Source=/vmfs/volumes/system/testvm2.vmdk

Destination=/vmfs/volumes/data/testvm2.vmdk

vmkfstools -i /vmfs/volumes/system/testvm2.vmdk /vmfs/volumes/data/testvm2.vmdk

0 Kudos
RParker
Immortal
Immortal
Jump to solution

Yeah, you can point converter to the VM on the server. Then use it to specify the datastore on the same server. Use the "select volumes and resize" for only the e: drive and point it to the system LUN destination on the same ESX server. Then it should migrate that volume over to the LUN, and once it's complete, everything should be ready.

You will then need to manual configure the VM to remove the e: drive (original location) and add the e: drive (system LUN location). It's a bit longer, and vmkfstools would be faster.. but it will work...

Let me know if you have problems. Additionally if you copy/paste your /vmfs/volumes exactly how it appears on your system in a PM, I can reply with a message of exactly the command you can copy /paste into your putty/ssh session, and it will be done...

0 Kudos
lukas_radil
Enthusiast
Enthusiast
Jump to solution

Hi,

I have had similar problem with some machines. Here is my solution:

1/ Migrate only boot partition to datastore which is created for OS vmdk file and configure your VM. Leave VM powered off.

2/ Migrate data partition to datastore which is created for data. You must create temporary VM for this purpose.

3/ after second migration is complete. Remove data vmdk file from temporary VM(only from configuration, leave file on disk) and add it to VM with OS.

4/ Delete temporary VM.

Lukas

0 Kudos
RParker
Immortal
Immortal
Jump to solution

Those are easy steps. Migrating the vmdk to another datastore is easy too.

At first I thought you were trying to clone another VM, but I see now you just want to move the vmdk files to the appropriate datastore. so this creates a new VM when you move only 1 vmdk file?

0 Kudos