Disable hot plug and unplug for NIC and USB for clients

From Notes_Wiki

Home > VMWare platform > VMWare Horizon > Disable hot plug and unplug for NIC and USB for clients

When users connect to Horizon VDI via Horizon client, they get option to unplug both USB and NIC. USB unplug is useful to safely remove USB device, but NIC unplug disconnections the VM. After that we need to remove the old NIC from the VM at vSphere/vCenter level and reconfigure the VM with same IP on a new NIC. To avoid all this we can disable hot plug only for NIC without disabling it for USB also via:

  1. Run below as administrator. Running as "Local system account" is not necessary:
    regedit.exe
  2. Go to HKEY_LOCAL_MACHINE\SYSTEM\CurrentControlSet\Enum\PCI
  3. For each sub-folder, open sub-sub folder and look at value of service. For one of them it would contain value vxnet3
  4. For that device in Capabilities reduce the current value by 4. In our case we saw capability value of 16, so we reduced it by 4 in hexadecimal to 12.
  5. The changes get reflected immediately without requiring reboot. You should still get USB unplug option but option to unplug NIC should not be there.

Refer:


Disable complete hot plug including USB drive

Avoid below in case USB forwarding is required / enabled for particular VDI VM / user:

  1. From a web browser, connect to the HTML5 Client (vCenter).
  2. Log in with Administrator credentials.
  3. Navigate to the virtual machine you want to modify.
  4. Power off the virtual machine.
  5. Right-click the virtual machine and select Edit Settings.
  6. Click the VM Options tab.
  7. Click Advanced > Edit Configuration.
  8. Click Add Configuration Params to enter a new row
  9. In the new row, enter the name devices.hotplug and a value of false.
  10. Power on the virtual machine.

Refer:



Home > VMWare platform > VMWare Horizon > Disable hot plug and unplug for NIC and USB for clients