While using
Update-VmfsDatastore, we consistently get the error:
Update-VmfsDatastore -Datastore $Source -TemporaryDatastore $Temp -TargetVmfsVersion "6" -Server $Server
" Update-VmfsDatastore : Cannot validate argument on parameter 'id'. the argument is null or empty. Provide an argument that is not null or empty; and then try the command again. "
Pleas help.
You cant upgrade an existing Datastore to VMFS6. Prior the VMFS 2,3 up to 5 can upgraded. For VMFS 6.0 you have to create a new Datastore and use svMotion to migrate the VMs onto.
Regards
Joerg
How exactly did you set/define the variables?
Please provide the required portion of your code.
André
Connect-VIServer xxxx -User xxxx -Password
$Source = Get-Datastore "xxx-LUNXX"
$Temp = Get-Datastore "yyy-LUNYY"
$Server = (Get-VIServer -Server "xxxx" -User xxx )
Update-VmfsDatastore -Datastore $Source -TemporaryDatastore $Temp -TargetVmfsVersion "6" -Server $Server
Assuming that the variables are set properly, I can only think of a bug within the Update-VMFSDatastore cmdlet, or an object on the source datastore which isn't expected.
Can you confirm that the datastore isn't used for e.g. HA heartbeats, templates, ...?
André
IRIX201110141: You are right, there's no direct update available for VMFS5 to VMFS6. However, the Update-VMFSDatastore cmdlet takes this into account, by evacuating the source datastore prior to recreating/reformatting it with the new format.
a.p.
Ahh...... now i understood! Thx for clarification. Thats a nice Posh function!!
Regards
Joerg
Thanks a.p
data store is not used and its completely empty. also, we have tested on multiple data stores across multiple vcenters. all of them are throwing same errors.
BTW i am pramod colleague
Out of curiosity, are all the datastores that you've tried to upgrade empty?
If yes, it may be worth a try to create a tiny VM on that datastore to find out whether the cmdlet expects at least one VM on the datastore.
André
yeah. i moved out VMs before using as temp datastore.
just now deleted data store and recreated datastore with vmfs 5 still failed with same error
Did you try this with at least one tiny VM on the source datastore?
André
Andre - do you know wether the command Update-VmfsDatastore
does more than the steps:
1. move out all VMs
2. check if vmfs-volume is ready to unmount
3. unmount
4. run a vmkfstools command to format the already existing partition one on the LUN/disk
If thats all it does we could create a sh.script that does the same - but gives us better troubleshooting hints
if any template or VM on temp data store it will give error during pre check.
Facing similar issue, tried with all the suggested recommendations, same error everytim
Hi pramodnaik,
Could you output the contents of the variables you are using? Please obfuscate any information you don't want to be seen publicly. If you could run the output with the Format-List * option as well please.
You can also probably limit this to just the parameter that is having issues if you look at the error. The variable that is causing a problem with be underscored with "~" symbols and this is the one that would be interesting to see the output from.
Cannot validate argument on parameter 'id'
This is indicating that the cmdlet is having issues with what is being passed to it. Its strange because Id is a readonly attribute of the objects but this might be a wrong lead to follow. The output of your variables should help... maybe...
Kind regards.
FileSystemVersion : 5.61
DatacenterId :
Datacenter :
ParentFolderId :
ParentFolder :
DatastoreBrowserPath :
FreeSpaceMB : 5675792
CapacityMB : 6291200
Accessible : True
Type : VMFS
StorageIOControlEnabled : True
CongestionThresholdMillisecond : 30
State : Available
ExtensionData : VMware.Vim.Datastore
CapacityGB : 6143.75
FreeSpaceGB : 5542.765625
Name :
Id : Datastore-datastore-45496
Uid :
FileSystemVersion : 5.81
Datacenter :
ParentFolderId :
ParentFolder :
DatastoreBrowserPath :
FreeSpaceMB : 6290185
CapacityMB : 6291200
Accessible : True
Type : VMFS
StorageIOControlEnabled : True
CongestionThresholdMillisecond : 30
State : Available
ExtensionData : VMware.Vim.Datastore
CapacityGB : 6143.75
FreeSpaceGB : 6142.7587890625
Name :
Id :
Uid :
Hi dnk9999,
There we are - the second datastore object is missing the Id attribute. This make it an incomplete object and hence the error.
Now this doesn‘t help your issue but at least we know the Update-VmfsDatastore cmdlet is probably okay.
The second object appears to be the target so let’s focus on that - now I would have thought every object would be assigned an Id because that’s how vCenter tracks stuff by assigning its own name to things.
Can you confirm that in the datastore objects you output what fields you blanked, if any? I would have expected the following to be present in your objects: DatacenterId, Datacenter, ParentFolderId, ParentFolder, DatastoreBrowserPath, Name, Id and Uid.
Also what vCenter privileges do you hold when running the cmdlet, i.e. do you have the Administrator role at the vCenter level?
Kind regards.
sorry for confusing.
id attribute i removed it while pasting here. i have admin privileges
D’oh! I‘m gathering then the Id attribute is also on the $Server object as well then.
Hello
I have exactly the same issue and it errors in exactly the same way.
Does anyone have an update to this?