Enabling Hyper-V USB passthrough to Access a USB Storage Device

Enabling Hyper-V USB passthrough to Access a USB Storage Device. Are you a professional looking to get the most out of your virtualization environment? If so, let’s explore USB passthrough with Hyper-V. USB passthrough lets you directly connect a peripheral device like a storage drive or an external hard disk to a remote Hyper-V server and make it available, as if the device were physically connected.

This level of control gives professionals unparalleled access and flexibility when dealing with remote connections, allowing them to securely transport large amounts of data without any loss in speed or quality.

So, in this blog post we cover the basics of enabling and utilizing USB passthrough for Hyper-V so that you use all its powerful features today!

What is Hyper-V USB Passthrough?

When working within a virtual computer, USB devices may be used thanks to the USB passthrough function. It is a pity that Hyper-V hosts do not automatically offer USB passthrough. While these aren’t the only ways to get Hyper-V USB passthrough, they’ll get the job done:

  1. Go into the Enhanced Session Mode.
  2. Launch a session of the Remote Desktop Protocol (RDP).
  3. Set up some network based USB fixes.
  4. Finally, introduce software based USB fixes into your system.

Since the first two choices don’t need any additional software and may be adjusted by hand in just a few minutes, we’ll focus on them here.

Prerequisites for USB Passthrough in Hyper-V

Well, the following requirements must be met in order to allow the VM local resource access resource:

  1. You must turn on the policy and settings, if you want to use Enhanced Session Mode. Additionally, Enhanced Session Mode is only available for VMs of generation 2.
  2. Virtual Machine Connection (VMConnect) requires a computer to operate Windows Server 2022, 2019, 2016, Windows 11/10, or Windows 8.1.
  3. A supported version of Windows Server 2022, Windows Server 2019 or 2016, Windows 10, or Windows 8.1 must be installed on the virtual server.
  4. You must first have Remote Access Services activated on the host machine to link to a virtual machine.

The Best Way to Enable USB Drive Passthrough in Hyper-V

usb drive passthrough

Importantly, Hyper-V uses Windows’ built in media mechanism to provide passthrough mode for most USB disk devices. However, since only one program at a time may communicate with a given USB device, Windows’ disk sector plays the role of go between for all such devices.

Therefore, your USB drive has to be recognized as a Mass Storage Device in Windows before it link in passthrough mode. Unfortunately, external USB drives from other manufacturers are incompatible.

Ensure the disk is viewable in Disk Partitions. Then, delete it from all online storage spaces immediately. Lacking the Offline feature prevents the disk from being used as a passthrough.

Choose the digital controllers in the properties box of the VM if you wish to add the passthrough drive. Then, click Add once you’ve selected Hard Drive on the top.

Adding a drive to a VMware virtual device’s virtual Operating system is not possible, while adding a drive to an operating virtual device’s digital SCSI connection is.

Changing the pointer to the Physical Hard Disk option and then picking the desired drive is how you connect a disk. But first, please confirm your selection by selecting OK.

Incompatible Non-Disk USB Devices with Hyper-V

Besides, Hyper-V inability to forward USB devices has raised a lot of eyebrows. Commonly, a poor contrast to USB passthrough-capable applications like VMware Workstation or Oracle VirtualBox is shown with the problem.

Type 1 Hypervisor

With Type 1 hypervisors, like Hyper-V, is distinguished from type 2 hypervisors, which allow for basic USB passthrough because the latter does not provide virtualization services themselves.

Type 2 Hypervisor

Type 2 hypervisors install the management OS immediately on the hardware, and the virtualization is just another software running on top of it. Capturing a USB port to prevent other apps from using it is very easy under a type 2 emulator.

Suppose you’ve ever worked with a type 2 emulator in such a setup. In that case, you’ll know that they declare unequivocally that the USB device may be connected to either the host or the visitor, with no collaboration, availability dividing up, or anything else.

Firstly, generation hypervisors aren’t software. Securely integrated kernels onto disk partitions. As a software shim masquerading as a rooted device, a virtual machine does not require the same isolation level as a type 1 hypervisor.

Hence, Hyper-V is unable to do this since it goes against the very nature of type 1 virtualization for one OS version to block a USB connector from all other OS versions. So, a type 1 hypervisor, like a type 2 hypervisor, assigns a particular USB port to a running VM?

Seems feasible in theory. Nonetheless, the reality of the technology being used is of little concern. Sadly, Hyper-V doesn’t provide that feature. 

If USB passthrough is essential to your plan, Hyper-V is not the solution you’re looking for, and using the VMS in Visual Studio forces you to do so. The remainder of you should consider a type 2 hypervisor. It’s no secret that VirtualBox is a staple on my computer.

Even, if it’s not perfect, the licensing terms are fair enough for most people to utilize.

Do You Want Hyper-V to Support USB Passthrough?

If you’re looking for a desktop solution, Hyper-V is designed for the server. Furthermore, Microsoft embraces cloud ideas with great enthusiasm, even to the detriment of many other solutions.

Certainly, it’s simple to comprehend how host-based USB isn’t a good option when you think about a cloud that relies on virtualization, perhaps an on premises server. First, a virtual machine’s availability is always in question.

A VM is no longer tied to a physical server, regardless of whether or not a cluster is present, thanks to Common Nothing Live Deployment. Therefore, using a USB as a host is entirely unnecessary.

However, Client Hyper popularity V’s has skyrocketed in the years since then. The Windows 10 operating system greatly improves the portability of virtual computers. In addition, Windows 10 users have a lot more convincing reasons to want USB passthrough.

Method 3 demonstrates, however, that Microsoft does provide an option that involves contracting out the USB connection to its controller system. It’s unfortunate that this only has limited applicability.

In light of this, should we anticipate that Microsoft seeks to design a suitable USB passthrough alternative? Since it would take a lot of work, and the console software’s range would eventually match the guest OS that users employ, it’s still inclined toward not implementing it.

Technique 1: USB Network Based Solutions

Prioritize network based solutions if you require access to a USB connection in an automated infrastructure.

Firstly, choose a Digi item to use. We can’t say we fully recommend them since we’ve only encountered one of their products and haven’t experimented with their newer technology, but they’re still there.

Therefore, they must be performing well. It’s important to remember that USB hubs, and not connectors, have one to one correspondence with various OSes. Instead of purchasing a specific device with several connections, you should link multiple virtual PCs.

Technique 2: The Remote Desktop Protocol

When an OS is loaded into a virtual machine, it mimics the behaviour of a physical PC very closely. For example, allowing remote access connectivity may be done on the System settings page.

At that point, it is possible to access it virtually in the same way as any other Windows PC.

Here’s how to make an RDP session compatible with USB devices:

  1. First, launch mstsc.exe from the Run or command line.
  2. Then, to see further configuration options, choose the corresponding button.
  3. As the dialogue box widens, other tabs become visible. Finally, select the more option under the Local Resources menu.
  4. There is still be another window displaying a dialogue. In this section, you see a checkbox labelled “Other compatible Plug and Play (PnP) devices” and a list of any other devices it found. Verify anything that needs it.

When you link to any server via RDP and then press OK, these settings are kept until you change them. Remote Console Access Manager is another helpful tool that may be used. However, it has several oddities and reliability issues.

Its capacity to store a large number of distinct connection settings for far flung hosts in a hierarchical arrangement more than compensates for them.

Technique 3: Improved USB Connection in Session Mode

Although the third strategy is the most reliable, it also has the most restrictions. Enhanced Session Mode was introduced in Hyper-V 2012 and was included with User Hyper-V in Windows 8.

Through this method, VMConnect.exe includes a number of session technologies that are normally associated with RDP. Selecting Connect from the respective menus in Hyper-V Manager & Failover Cluster Manager begins a such application.

In addition to using the icon, you may also run VMConnect at the command line. Ordinarily, exe needs to be elevated.

Consequently, Hyper-management V’s interface is called VMConnect. Like physical systems in a cloud server, Hyper-V virtual processors may function without a console being physically connected to the system.

The hypervisor console software provides the keyboard, monitor, and mouse inputs. Experienced Type 2 hypervisors usually feature more comprehensive control panels. The Enhanced Session Mode in Hyper-client V is based on the features of the Remote Desktop application, which has had considerably more time to improve.

Setting up Hyper-V USB Passthrough with Enhanced Session Mode

Enhanced Session Mode

Client Hyper-V installations have the Enhanced Session Option activated by standard. You need to enable it personally to use it with the server SKUs. Next, vmms, Hyper-VM V’s management service, has to be relaunched. The quickest approach is PowerShell:

If you’re executing this cmdlet from a remote location, you’ll need to use the -ComputerName option.

Use Hyper-V Manager if you want to:

  1. Select the host in the left pane, and then click Right. To adjust Hyper-settings, V’s choose the menu item.
  2. Enhanced Session Mode Settings may be accessed through the sections on the left side of the screen.
  3. Select the checkbox labeled Enable enhanced session mode, and then hit OK.

In order to make USB redirection work, the Guest services interface program is not required to be running.

Enabling Hyper-V USB Passthrough to Access a USB Storage Device Conclusion

When used in conjunction with Client Hyper-V, Enhanced Session Mode provides functionality similar to that of a type 2 hypervisor. However, since it uses Remote Desktop Protocol (RDP), it is not really traveling via the USB device. When using a type 1 hypervisor, the performance of certain devices may suffer, while in other cases, they might not even work at all.

Avatar for Farhan Yousuf
Farhan Yousuf

I am a content writer with more than five years of experience in the field. I have written for a variety of industries, and I am highly interested in learning new things. I have a knack for writing engaging copy that captures the reader's attention. In my spare time, I like to read and travel.

0 0 votes
Article Rating
Subscribe
Notify of
0 Comments
Most Voted
Newest Oldest
Inline Feedbacks
View all comments
0
Would love your thoughts, please comment.x
()
x