Connect with us

Hi, what are you looking for?

Citrix Provisioning Services

Citrix PVS server Vdisk is locked 0xffff8017 error as VMs boot up

Wow it’s been busy as we approach the end of the year. I am going through my Inbox as I can and I really appreciate all the comments and emails from you all. Really makes it worth while hearing how these posts are helping out there in the real world.

Here’s a quick fix for today. PVS 6.1 environment with latest updates started showing the following error anytime a VM attempted to boot:

Vdisk is locked. 0xffff8017

The fix is not that painful but you will need to kick off everyone that is still connected and running using that vDisk. So there is an outage involved in this procedure for people that use that image.

1. Tell all your users that are still connected to save their work and log off. This is going to be a complete outage for anyone that uses that particular image.

2. Go to your DDC and put the Desktop Group in maintenance mode. This will prevent the DDC from attempting to start up VMs and potentially lock up the vDisk while you are working on it. Then Force Shutdown on all the VMs. Verify in XenCenter they are all shutdown.

3. RDP to a single PVS server and in the PVS Console, go to the Store and right click on your vDisk. Verify there is no gold lock next to the vDisk. If there is clear all the locks. Then click “Unassign from Selected Devices(s)…”

4. Make sure all your VMs are checked and click Unassign

5. If you have maintenance versions, I suggest you merge them at this point. You’ll want to use the “Merged Base – Last base + all updates from that base” option so you get an nice single .vhd file to play with.

6. Once you have verified you have a nice little .vhd file you can rename it if you wish. Now copy that .vhd file and the associated .pvp file to all your other PVS stores. Get all your PVS servers in sync and check the replication status. They should all have blue dots:

7. Now go back to your Store view and right click on your vDisk. You should now see an option to Delete. Click it.

8. MAKE SURE you DO NOT check the Delete the associated VHD files check box. Just hit Yes only. All it does is delete it from the PVS database. It will not touch anything in your Store this way. Better safe than sorry. Do this on all your PVS servers.

9. Now right click on “Store” and click “Add or Import Existing vDisk…”

10. Click Search to search your Store for vDisks. Only check that new .vhd you had created in step 5 and 6 above. Then click Add once it stops being greyed out.

11. It will be imported in Private mode every time. Go ahead and switch it to Standard mode. You might also want to check Cache type, Enable Active Directory machine account password management, and KMS on the Microsoft Volume Licensing tab because all that stuff will likely not carry over for you.

12. Now go to your Device Collection. In this example I have 20+ Devices that need this particular vDisk golden image. I’m not going to sit here and click and modify each one. So I will set the vDisk on the first VM only.

13. Now right click that VM you just set and click “Copy Device Properties…”

14. Hit “Clear All”, then check “vDisk Assignment” only, then hit Copy.

15. Now just highlight all your other VMs, right click in the highlighted area, and click Paste. Instantly all your VMs will be assigned that vDisk.

16. Now just boot up a couple of VMs and verify the “Vdisk is locked. 0xffff8017” error is gone. Then disable Maintenance mode on your DDC and you’re back in business. Don’t forget to tell your users to log back in. You can delete all those old .vhd, .avhd, and .pvp files from old versions of your image if you like or archive them somewhere. It will help keep your Store nice and clean.



  1. Dragon64

    July 18, 2013 at 6:36 AM

    I have found that if you just delete the LOK file associated to the VHD file that you are using and then reset the target it works like a champ without having to do all this other stuff. Furthermore, I notice that if the LOK file is 1k instead of the normal 0k that is when it happens.

  2. Melvin

    October 28, 2013 at 10:05 AM

    Hi Jason,

    I dont have multiple versions of the vdisk, but getting same issue. I have 4 PVS servers but cant find some under replication status . Any Suggestions

  3. Srinivas

    November 3, 2014 at 7:54 AM

    Can we delete .lok file when the target devices are connected ?

  4. Srinivas

    November 4, 2014 at 4:57 AM

    Hi Dragon64,

    how to get rid of that vdisk lok file size. in my case its as you said, its coming if the size is 1Kb. any thoughts.


Leave a Reply

Your email address will not be published. Required fields are marked *

You May Also Like

Citrix Workspace

You can use FIDO2 hardware security keys plugged into your physical desktop over the Citrix HDX remoting protocol for use with virtualized Windows Desktop...


Today I would like to go over proper URL redirection when using SSL but first I would like to preface this by describing what...

Exchange 2003

A useful Exchange 2003 guide I wrote for a friend’s blog originally but I am posting it here on mine now for your viewing...


In a worst case scenario and all your web servers have failed, what do you do? You could have a standby group of servers... began in 2008 as a way for me to give back to the IT community. This website features the latest news and how-to's on enterprise mobility, security, virtualization, cloud architecture, and other technologies I work with. This website has evolved over time to become a go-to reference hub for these technologies. It receives hundreds of thousands of unique visitors from all over the world each month. More details on the About Me page.
Copyright © 2008-2023