Jump to content
Welcome to our new Citrix community!
  • 0

Installing USB drivers into a layer


Nick Panaccio

Question

We're running App Layering 4.5 in our lab, hosted on XenServer 7.1, and I've got a question regarding installing USB drivers into a layer - OS or App.

 

We use Nuance PowerMic's for Dragon Medical 360 (NaturallySpeaking), and when you plug them in, USB drivers are installed on the device. In our current XenDesktop 6.5 environment (without App Layering), hosted on XenServer 7, we are only able to install these drivers [by plugging the device in; there is no packaged installer] by changing the vDisk to Private so that we have read/write access. We then publish it in Citrix, connect to the VDI session, plug in the microphone (switching it to Generic in Receiver) so that the USB drivers are installed, and then logoff. We can then finish the vDisk and change it back to Standard for read-only access. This is all due to the fact that you can't connect USB devices in a guest on XenServer.

 

With App Layering, I was wondering how others were going about this, as I know I've seen people post about Dragon and App Layering (a recipe would be nice, too). Changing the vDisk to Private like we do currently just doesn't sound like a good idea, and one that likely breaks something. Short of me using something like Admin Studio to [hopefully capture drivers and installing it onto either the OS layer or the Dragon application layer, I'm not sure how to actually go about this.

 

Does anyone have any advice here? I'd certainly appreciate it.

Link to comment

13 answers to this question

Recommended Posts

  • 0

If you have the driver files in your driver repository on one server (C:\windows\system32\DriverStore\FileRepository)

you may be able to get away with copying them out to a chosen location and then using the pnputil command line tool to load them into the driver repository in a layer for your other server (personally I'd do OS layer for all hardware drivers). Documentation here: https://technet.microsoft.com/en-us/library/cc772036(v=ws.11).aspx

 

I've done this successfully with certain drivers in the past but your mileage may vary.

Link to comment
  • 0

Hi Nick,

Blair's way to do it sounds like it may be the easiest way.  Normally what you need to so to install drivers that need to see a device is to first create a packaging platform layer with the VDA installed.  Since the VDA gives you a usb connection.  Then create your app layer with that packaging platform layer as a prerequisite.  You will then have to join the packagin machine to the domain, add it to a catalog and delivery group so you can access it through XenDesktop so your drivers will see the device.  Then before you are done back out the domain join etc.

 

One other option is to create a platform layer specifically for the VDAs with Dragon and install the drivers there.  That is a little easier becasue you will be joining the domain there anyway.

 

But if Blairs way of doing it works that sounds pretty neat to me.

 

Rob

Link to comment
  • 0

If you have the driver files in your driver repository on one server (C:\windows\system32\DriverStore\FileRepository)

you may be able to get away with copying them out to a chosen location and then using the pnputil command line tool to load them into the driver repository in a layer for your other server (personally I'd do OS layer for all hardware drivers). Documentation here: https://technet.microsoft.com/en-us/library/cc772036(v=ws.11).aspx

 

I've done this successfully with certain drivers in the past but your mileage may vary.

 

I was hoping that this would be an easy win, but it appears as though the driver that is being used is actually already in the FileRepository (it's a Microsoft driver), as no new files/folders were created after connecting the mic to my session. I have even used the ConfigMgrDriverGrabber utility to grab the drivers before and after the install to see if anything was new, but it's all identical. And just to say that I did, I ran pnputil on all of the .INF files associated with this driver (based on my ProcMon log). Nothing.

 

 

Hi Nick,

Blair's way to do it sounds like it may be the easiest way.  Normally what you need to so to install drivers that need to see a device is to first create a packaging platform layer with the VDA installed.  Since the VDA gives you a usb connection.  Then create your app layer with that packaging platform layer as a prerequisite.  You will then have to join the packagin machine to the domain, add it to a catalog and delivery group so you can access it through XenDesktop so your drivers will see the device.  Then before you are done back out the domain join etc.

 

One other option is to create a platform layer specifically for the VDAs with Dragon and install the drivers there.  That is a little easier becasue you will be joining the domain there anyway.

 

But if Blairs way of doing it works that sounds pretty neat to me.

 

Rob

 

I think I've been looking at this too long, because you lost me here. I'm currently modifying my Platform layer, which is joined to the domain, in XenServer. I can't add this device to a Machine Catalog without first creating it in PVS and assigning it a vDisk, which I wouldn't be able to do unless I created a full template and deployed that beforehand. No matter how long I search, I can't seem to find any other way of accomplishing this (you'd think there'd be a guide out there somewhere).

Link to comment
  • 0

Rob,

 

I went through the process that you recommended, but there appears to still be an issue - either with my process or something else. Here's what I did:

 

  1. Created a new packaging Platform layer ("for creating and updating Layers") using my current Windows 10 x64 OS Layer
  2. Installed Citrix VDA 7.15 on it (remote desktop access only), and joined it to the domain
  3. Published this VM in Citrix and connected to the VDI
  4. Plugged in my PowerMic, and switched it to Generic in Receiver; this initiates the driver installation
  5. Logged off the VDI
  6. Uninstalled Citrix VDA 7.15, left the domain, and rebooted
  7. Logged into the local desktop in XenServer and validated that the PowerMic showed up [as a hidden device]
  8. Finalized the layer
  9. Added a version to my Dragon Medical 360 App Layer, selecting the same OS Layer, my Citrix Receiver 4.4.3000 Prerequisite Layer, and this newly created packaging Platform Layer
  10. Logged into the local desktop in XenServer and validated that the PowerMic showed up [as a hidden device], and then finalized that layer
  11. Edited my current Windows 10 Image to use the same OS Layer, Dragon Medical 360 App Layer (but not the Citrix Receiver 4.4.3000 layer), and my old Platform Layer, which has Receiver installed alongside Citrix VDA and PVS 7.15

Once that new vDisk was created, I logged into my VDI and saw that the PowerMic drivers were not present, and did install once I plugged in the mic and switched to Generic. I expected that based on step 11, which brings me to my next question - if I can only select one Platform Layer when creating an Image, do I then need to make sure that my packaging Platform Layer actually has the same components (Citrix VDA + PVS, XenServer tools, domain joined, etc.) that my original Platform Layer ("for publishing Layered Images") has? I assume that if I change this Image to use the new packaging Platform Layer, then I will not actually be able to use this in Citrix because of the lack of the VDA/PVS agents.

Link to comment
  • 0

Nick,

I am trying to follow along but you should be creating the publishing platform layer to get the vda installed and available when you are packaging, then use the publishing platform layer when you create your dragon layer to get the driver you need installed into the dragon layer.  It looks like you installed the PowerMic drivers into the packaging platform layer which will never be added to your image.

 

Rob

Link to comment
  • 0

Nick,

I am trying to follow along but you should be creating the publishing platform layer to get the vda installed and available when you are packaging, then use the publishing platform layer when you create your dragon layer to get the driver you need installed into the dragon layer.  It looks like you installed the PowerMic drivers into the packaging platform layer which will never be added to your image.

 

Rob

 

Before creating that packaging Platform Layer, I attempted to add a version to my Dragon App Layer. When I got to the Platform Layer section in the App wizard, I was unable to select any publishing Layered images; the wizard tells me that they cannot be used for creating layers because they are intended for publishing Layered Images (see attached). Reading your original reply about packaging Platform Layers, I'm a little more confused, because I thought that's what you said I should be doing.

 

Would I be able to just create a new version of my existing publishing Platform Layer (which has VDA/PVS installed, is joined to the domain, etc.) and install the drivers there, and then simply update my current Image with this new publishing Platform Layer? It wouldn't bother me in the least if all images had these drivers.

post-12519988-0-02886100-1506705527_thumb.jpg

Link to comment
  • 0

I was able to successfully inject the PowerMicII-NS USB drivers into my image, though it required a few more steps than described above. In case somebody else runs across a similar issue, this is what I had to do:

 

  1. Add a new version of your existing Publishing Platform Layer
  2. Publish the VM in Citrix, and then connect to the VDI
  3. Plug in the PowerMicII-NS microphone
  4. In the Citrix toolbar, click on Devices and select Manage Devices
  5. Find the PowerMicII (Dictaphone Corporation) and click on the Switch to generic button
  6. The USB drivers will then install
  7. Logoff the VM, and then Finalize the layer
  8. Create a new Packaging Platform Layer
  9. Join this layer to the domain and install Citrix PVS and VDA (like you would on a normal Publishing Platform Layer)
  10. Publish the VM in Citrix, and then connect to the VDI
  11. Plug in the PowerMicII-NS microphone
  12. In the Citrix toolbar, click on Devices and select Manage Devices
  13. Find the PowerMicII (Dictaphone Corporation) and click on the Switch to generic button
  14. The USB drivers will then install
  15. Logoff the VM
  16. Leave the domain, uninstall Citrix PVS and VDA, and then Finalize the layer
  17. Add a new version of your existing Dragon NaturallySpeaking App Layer, selecting the newly created Packaging Platform Layer [from step 8] when you get to the Platform Layer section of the wizard
  18. Since nothing needs to be changed here, immediately Finalize the Layer
  19. Build your new Image Template using the newest Platform Layer and newest Dragon NaturallySpeaking App Layer

Once I did all of this, I was able to launch my VDI desktop, plug in my microphone, and have it show up without being prompted to install. From the initial instructions - unless I'm still missing something - I should not have had to modify the existing Publishing Platform Layer, and instead should have only had to perform steps 8 and on. However, when I choose my Publishing Platform Layer that did not have the USB drivers installed on them, even with the newest Dragon App Layer, Device Manager did not show any PowerMicII-NS devices, and did in fact prompt me to install the drivers upon switching to generic.

 

So, it appears as though I need to add these drivers to both the Publishing Platform Layer, and also the Packaging Platform Layer (which is used when updating the App Layer). This is confusing as hell, and requires a considerable amount of time, but it's also the only solution that appears to be working for me.

 

Rob, does this all make sense to you? Or should I be doing something else to accomplish this?

Link to comment
  • 0

Doing more testing, it actually appears as though the only place it matters where I install these USB drivers is in the Publishing Platform Layer. I have tested the following:

 

OS Layer: Windows 10 x64 [1607]

Publishing Platform Layer: Citrix PVS/VDA 7.15 (USB drivers installed in this layer)

App Layer: Dragon NaturallySpeaking (no USB drivers installed via Packaging Platform Layer)

Result: USB drivers are installed on the vDisk

 

OS Layer: Windows 10 x64 [1607]

Publishing Platform Layer: Citrix PVS/VDA 7.15 (USB drivers installed in this layer)

App Layer: Dragon NaturallySpeaking (USB drivers installed via Packaging Platform Layer)

Result: USB drivers are installed on the vDisk

 

OS Layer: Windows 10 x64 [1607]

Publishing Platform Layer: Citrix PVS/VDA 7.15 (no USB drivers installed in this layer)

App Layer: Dragon NaturallySpeaking (USB drivers installed via Packaging Platform Layer)

Result: USB drivers are not installed on the vDisk

 

On one hand, I'm glad that I only need to worry about one layer when it comes to injecting USB drivers into an image. On the other, if I have to inject different drivers for different applications, and I don't want these drivers available to everyone, it's going to be a massive pain to manage all of this, if that's even possible at all. It'll likely just increase the amount of actual images that we'll need to run, which defeats some of the purpose of App Layering in general.

Link to comment
  • 0

I too am facing similar kind of problem and not being able to have the USB drivers injected into published vdisk (LTSR 7.15) in either of the following way :

 

  1. Using a packaging platform layer to inject FingerPrinter drivers into Application layer ( As per Prescribed by Rob ). All seems to be  working fine during build but when the image is published it does not associate the drivers with the device. A new device dialog box is popped up however not finding the driver it got listed as unknown device. (Control panel program and features show that the FingerPrint driver utility is being installed.)
  2. Creating a VDA layer to be used as a prerequisite layer for USB driver layer. The results are same.

 

Using the Platform publishing layer not explored yet however looks not a good idea to create multiple platform publishing layers for driver injection. Googling all I found was the recipe for VMware Horizon View (https://support.citrix.com/article/CTX226364)

 

Has anybody else has the same challenge and found a solution?

Link to comment
  • 0

I was only ever able to get it to work by injecting the drivers into the Publishing Platform Layer that my image uses. I don't care that the drivers are now available to any image creating with the layer, but others may.

 

Also, if you're using the AppLayeringImagePrep.ps1 script found on JGSpiers.com, keep in mind that part of the script removes all ghost devices before finalizing the layer. I wound up modifying the script to omit that one section so that my ghost devices (and subsequent drivers) were not removed from the layer.

Link to comment
  • 0

I'm having an issue where I publish a layer with a platform layer so that I can deploy it via Citrix.  I add the layer to the domain, add the machine to a machine catalog, and add it to a delivery group.  I log in via citrix and I install the drivers that I need.  Then I remove the layer from the domain and finalize the layer as I do with all other layers.  The kicker is that when I try to publish an image with this layer, it gets hung when "Assembling the registry" and it eventually times out.  If I revert the image back to the previous version of that layer, it publishes just fine.  Any ideas?

Link to comment

Create an account or sign in to comment

You need to be a member in order to leave a comment

Create an account

Sign up for a new account in our community. It's easy!

Register a new account

Sign in

Already have an account? Sign in here.

Sign In Now
×
×
  • Create New...