VMware Cloud Community
Wajeeh
Enthusiast
Enthusiast
Jump to solution

RDM use space on Datastore or SAN

Dear All,

As per my understanding RDM creates a mapping file in data store in virtual machine folder but it does not consume any space on datastore but yes, on SAN. I've a virtual machine with 50GB vmdk and a physical RDM of 50 GB , the memory for the machine is 8GB so vsphere client, I see the provisioned space for machine as 108. So, it means 50GB of RDM is also included in provisioned space shown in vsphere client.

The same is reflecting on datastore space, the datastore provisioned space also showing 50GB RDM counted in provisioned space, where as the data has to be on SAN, can anyone clarify this why in space calculation datastore is also counting rdm as provisioned space on itself.

Please let me know if my question is not clear.

Thanks,

Tags (2)
Reply
0 Kudos
1 Solution

Accepted Solutions
a_p_
Leadership
Leadership
Jump to solution

Since the rdm file doesn't use disk space (only a few bytes for the header/descriptor file), this disk space is still available for other VMs.

André

View solution in original post

Reply
0 Kudos
13 Replies
a_p_
Leadership
Leadership
Jump to solution

There's a difference between the provisioned space and the used space. The provisioned space is the total amount of disk space that may be used by the VM, no matter whether and where it is allocated. Even in case of a thin provisioned virtual disk, the provisioned space will take the "full" disk space (the size you configured) into account.

André

Reply
0 Kudos
Wajeeh
Enthusiast
Enthusiast
Jump to solution

Hello André,


Thank you for your quick response. I understand the provisioned space is the total amount of space that a VM may use for vmdk files either thin or thick.

But here I am asking for RDM the 50GB RDM space will be used on SAN not on datastore, but why it is calculated on datastore provisioned space. am I clear ?

Reply
0 Kudos
a_p_
Leadership
Leadership
Jump to solution

I understand you point, and I basically agree that it's at least questionable whether the space should be added to the datastore's provisioned space. However, from a technical point of view, the rdm file appears as a sparse file on the VMFS file system (similar to a thin provisioned virtual disk file) with the provisioned size in the size column, but zero used blocks when you run e.g. ls -lisa.

André

Reply
0 Kudos
Wajeeh
Enthusiast
Enthusiast
Jump to solution

Hello André,

So, the important question is for example I am willing to create another 50GB virtual machine in same datastore, I consider 50GB RDM space showing in provisioned space of datasore as free always in datastore with the concept that data is always on SAN not on vmfs. I always consider that this space is still available to me for use.

Thanks for usual help.

Reply
0 Kudos
a_p_
Leadership
Leadership
Jump to solution

Since the rdm file doesn't use disk space (only a few bytes for the header/descriptor file), this disk space is still available for other VMs.

André

Reply
0 Kudos
Wajeeh
Enthusiast
Enthusiast
Jump to solution

Hello André,

This is what I wanted to be sure because that provisioned space was giving be big doubt, and I was thinking that space is not available for vmdk OR a new virtual machine. Now after discussion with you, it is clear.

Thanks again for helping.

Regards,

Reply
0 Kudos
Wscholz
Enthusiast
Enthusiast
Jump to solution

Hmm,

for me it is not clear what you see on which dialog. I give you an example from my environment to show you how it should look.

I have a VM with a local 40GB vmdk and a raw device with 100GB.

VI Client VM View:

viclientview.JPG

The provisioned Storage is 143GB which consists of 40GB local vmdk + 100GB raw device + 3GB vRam, Logs etc

VI Client Datastore View:

datastoreview.JPG

Here you can see that on the datastore only 43GB show up. 40GB local vmdk + vRam etc, but not the 100GB from the raw device

If i do a du command on the command line against the two vmdks i see:

duview.JPG

here you can clearly see the difference. The -rdmp file has a size of 0 on the datastore, because it is only a mapping. The -flat file of the local vmdk instead shows 40GB.

What do you see in these views ?

------------------------------------------------------------------------- If you found my answer useful please consider marking it as "correct" or "helpful". Thanks a lot
Reply
0 Kudos
Wajeeh
Enthusiast
Enthusiast
Jump to solution

Hello,

Thanks for your response. Actually I am not using ESX but ESXi so can you please tell me how to get those results in ESXi from command line. How to reach vmfs data store and then to virtual machine directory in command line. I'm asking because not used  to of using command line in ESXi. I want to see those results.

Waiting for response.

Reply
0 Kudos
Wscholz
Enthusiast
Enthusiast
Jump to solution

I use ESXi too. You have to enable ssh access first to be able to login from remote. See

http://kb.vmware.com/selfservice/microsites/search.do?language=en_US&cmd=displayKC&externalId=200474...

for instructions.

------------------------------------------------------------------------- If you found my answer useful please consider marking it as "correct" or "helpful". Thanks a lot
Reply
0 Kudos
Wajeeh
Enthusiast
Enthusiast
Jump to solution

Hello Wsclohz,

Please find the screen shot of my rdmp.vmdk after running the du command. it shows 0 but for flat.vmdk it shows the space which is a thin disk.

rdmp_1.jpg

Also see below view from Win SCP the rdmp.vmdk is showing 50GB size

SCP_View.jpg

So, do you have anything to say for this like you asked me earlier yesterday for these views. I will be waiting for your response.

Regards,

Reply
0 Kudos
a_p_
Leadership
Leadership
Jump to solution

All of the output looks as expected. You may have missed the ls command I mentioned earlier, which shows you both, the provisioned size as well as the current disk usage. Simply run ls -lsa (or ls -lsah for human readable output).

André

Reply
0 Kudos
Wscholz
Enthusiast
Enthusiast
Jump to solution

Yes looks expected. For the rdmp vmdk you would also see 50GB in the Vsphere Client, this does not show the actual disk usage of the file. Therefore i would trust the du or the ls -lsa command.

------------------------------------------------------------------------- If you found my answer useful please consider marking it as "correct" or "helpful". Thanks a lot
Reply
0 Kudos
Wajeeh
Enthusiast
Enthusiast
Jump to solution

Thanks André,

Now I tried the 'ls -lsah' for the virtual machine, I am able to see all the provisioned space and used space in one view. Thanks for your help

Reply
0 Kudos