At times when you try to configure Virtual Network Switches in Hyper-V, an error is seen. The complete error message is as shown below:
Error applying Virtual Switch Properties changes Failed while adding virtual Ethernet switch connections. Failed to connect Ethernet switch port(switch name=' <deviceid>",port name="< port id>",adapter GUID='{GUID id}'): The system cannot find the file specified.(0x80070002).
In this article, we’ve compiled several ways to fix the error seen while applying the virtual switch properties in hyper-v. Ensure you gave created a backup of the settings before trying out the below fixes.
Fix 1: Reset the Network Connection using the “netcfg” command
Step 1: Open the Run Dialog with Windows+R.
Step 2: In the Run dialog window, type powershell and hold the keys Ctrl+Shift+Enter. This opens the Elevated PowerShell window
Step 3:In the UAC window that shows up, click on Yes.
Step 4: In the PowerShell window that opens, enter the below command to reset the network connection and hit Enter
netcfg -d
Step 5: Now, reboot the server.
After that , Open the Virtual Switch Manager in Hyper-V and check if the error resolves.
Fix 2: Change the name of the Network Adapter for Hyper V Manager using PowerShell
Step 1: Open the Run Dialog with Windows+R.
Step 2: In the Run dialog window, type powershell and hold the keys Ctrl+Shift+Enter. This opens the Elevated PowerShell window
Step 3:In the UAC window that shows up, click on Yes.
Step 4: In the PowerShell window that opens, enter the below command to change the name of the network adapter.
New-VMSwitch -name <NameOfTheSwitch> -NetAdapterName <NameOfNetworkAdapter> -AllowManagementOS $true
where,
NameOfTheSwitch is the name of the switch to be created. This is how the name displays in Hyper-V.
NameOfNetworkAdapter is the name of the network adapter that is to be associated with the switch.
For example, if you want to create a switch named “QoS switch” over your “Wired Ethernet connection 1” then the command should be,
New-VMSwitch -name "QoS switch" -NetAdapterName "Wired Ethernet connection 1" -AllowManagementOS $true
Step 5: Open the Virtual Switch Manager in Hyper-V and check if the switch is listed.
Fix 3:Update the Network Adapter Driver
Step 1: Hold the keys Windows and R to open the Run Terminal window
Step 2: Type devmgmt.msc and hit Enter
Step 3: In the Device Manager window that opens, scroll down and double-click on Network adapters
Step 2: Right-click on the required network adapter and click on Update Driver
Step 3: In the Update Drivers window, click on Search Automatically for drivers.
Step 4: System searches and you will be notified of any updated drivers are found.
Step 5: Follow the onscreen instructions and update the drivers.
Step 6: Open the Virtual Switch Manager in Hyper-V and check if the error resolves.
Fix 4: Uninstall and re-install the Network Adapter
Step 1: Hold the keys Windows and R to open the Run Terminal window.
Step 2: Type devmgmt.msc and hit Enter.
Step 3: In the Device Manager window that opens, scroll down and double-click on Network adapters.
Step 4: Right-click on the required network adapter and click on Update Driver.
Step 5: In the Uninstall Device window, tick the Delete the driver software for this device.
Step 6: Click on the Uninstall button.
Step 7: Follow the on-screen instructions to complete the Uninstallation process.
Step 8: Restart the system and check if the system installs the default Wi-Fi Driver. You can verify this by opening the Device Manager and clicking on the button Scan for hardware changes as shown below.
Step 9: Check if the disconnection issue resolves.
Step 10: Open the Virtual Switch Manager in Hyper-V and check if the error resolves.
Fix 5: Allow Network Sharing
Step 1: Open Run Dialog using Win+R.
Step 2: Type ncpa.cpl and hit Enter.
Step 3: In the appearing window, right-click on your Network Adapter.
Step 4: Choose Properties.
Step 5: In the Properties window that opens, go to Sharing tab.
Step 6: Tick on Allow other network users to connect through this computer’s Internet connection.
Step 7: Click on the OK button.
Step 8: Now, open the Virtual switch manager in Hyper V and check if you still see the error.
That’s All.
We hope you have found this article useful. Kindly comment and let us know the fix that helped you solve the issue.
Thank you for Reading.