VMware {code} Community
ashvitech
Contributor
Contributor

How do I know the VMDK contains mixed partitions/volumes?

I am using VMware's VDDK APIs and mount utlitiy. By using /p option on windows, it displays the volumes.

vmware-mount "E:/VMs/WinVM.vmdk" /p

- Volume 1: 4094 Mb

- Volume 2: 7 Mb

Sometimes utlitiy displays file system info :

Volume 1: 456 Mb HPFS/NTFS

Is there any way to know specfic file system for volume (whether it is Windows or Linux)? So that in mixed partitions case I can mount serately using linux and windows host.

Thanks in Advance...

Reply
0 Kudos
4 Replies
admin
Immortal
Immortal

Using VixDiskLib, you can read the partition table and figure the file system for each partition. See for example: http://en.wikipedia.org/wiki/Partition_(computing)

-Sudarsan

ashvitech
Contributor
Contributor

Thanks Sudarsan, I got the required info from given link. Also latest VDDK mount utility seems consistent with partion info as

C:\vmware-mount "E:\WIN2KVM\WIN2KVM (2).vmdk" /p

Volume 1 : 9 MB, HPFS/NTFS

Volume 2 : 4 MB, HPFS/NTFS

I have tried with MetaData handling APIs, but not got any partion table info.

Used: VixDiskLib_GetMetadataKeys, VixDiskLib_ReadMetadata, ... methods

Documentation says "possibly disk label, LUN or partition layout, .... information" will get.

Is there any APIs which gives partition table?

Reply
0 Kudos
hkrishnan
Enthusiast
Enthusiast

You can use VixDiskLib and read sector 0, which contains the partition table.

There are no separate APIs to read partition table.

Hari

ashvitech
Contributor
Contributor

Thanks... Got the information from sector 0. I have to go through all codes/values for files systems ... NTFS, FAT, ....EXT....

The VDK open source code has it and also implemented partitions part using sector 0. It is also very useful.

Thanks,

AshVI

Reply
0 Kudos