VMware Cloud Community
lethargos
Enthusiast
Enthusiast
Jump to solution

A specified parameter was not correct: spec.deviceChange.device when trying to expand disk

Hello,

 

I have an issue in vSphere when trying to increase the disk size of a virtual machine. I try to edit the virtual machine and change the disk size to a larger, but I get the following error:

 

A specified parameter was not correct: spec.deviceChange.device

 

The virtual machines where this issue occurs have at least two hard disks. The main one resides in a storage volume called "vmstorage" and the one that I cannot increase resides in a different volume storage called "datastorekubedata".

This basically looks like a permissions error, but the error would lead you to believe that there's a syntax error, even if I'm making the change directly from the vSphere GUI.

My guess is that the problem comes from the fact that the disks that cannot be expanded are not part of the folder where the virtual machine is, given that I can resize the disks that reside in the same folder (and, of course, the same datastore).

Any ideas how I can expand the disk in this situation? This looks like a bug.

I'm using vSphere 6.7.0.54000

Tags (1)
Reply
0 Kudos
1 Solution

Accepted Solutions
lethargos
Enthusiast
Enthusiast
Jump to solution

Sorry for the late answer (I barely use the email address associated with this account, and I can't seem to be able to change it), now I understand what has happened. The disk's size is less than 2TB, so that's definitely not the issue. On top of that, I would probably have got a clearer error.

In any case, with vmkfstools -X I also ended up with the same error. I had to run the command in verbose mode to understand what was going on and so I ended up with this:

Unable to get adaptertype for '/vmfs/volumes/5d092ea7-c0c36652-bbd2-0017a477082c/kubestatic/db-slave-3-live.vmdk' : One of the parameters supplied is invalid (1)

So I realised that the problem was the fact that the controller type was different than it expected:

ddb.adapterType = "pvscsi"

I'm not sure if this was related to the virtual machine or to the metadata the disk (flat) itself contained, but changing it to 'lsilogic' allowed me to increase the disk using "vmkfstools -X newsizeG /path/to/disk". At this point actually I was able to do it directly from the vSphere client also.

View solution in original post

Reply
0 Kudos
3 Replies
rehan2906shaikh
Contributor
Contributor
Jump to solution

Hello,

To use a larger disk, make sure you use the GUID partition table (GPT) partitioning scheme when you initialize and format the disks. Remember, you cannot use a disk larger than 2 TB if you plan to use VMware fault tolerance (FT) protection for your VM. If your VM has snapshots, be sure to delete them before you extend the disk.

Reply
0 Kudos
rehan2906shaikh
Contributor
Contributor
Jump to solution

Please share us exact error screenshot 

Reply
0 Kudos
lethargos
Enthusiast
Enthusiast
Jump to solution

Sorry for the late answer (I barely use the email address associated with this account, and I can't seem to be able to change it), now I understand what has happened. The disk's size is less than 2TB, so that's definitely not the issue. On top of that, I would probably have got a clearer error.

In any case, with vmkfstools -X I also ended up with the same error. I had to run the command in verbose mode to understand what was going on and so I ended up with this:

Unable to get adaptertype for '/vmfs/volumes/5d092ea7-c0c36652-bbd2-0017a477082c/kubestatic/db-slave-3-live.vmdk' : One of the parameters supplied is invalid (1)

So I realised that the problem was the fact that the controller type was different than it expected:

ddb.adapterType = "pvscsi"

I'm not sure if this was related to the virtual machine or to the metadata the disk (flat) itself contained, but changing it to 'lsilogic' allowed me to increase the disk using "vmkfstools -X newsizeG /path/to/disk". At this point actually I was able to do it directly from the vSphere client also.

Reply
0 Kudos