After redeploying some virtual machines (VMs) in my Hyper-V Demo environment, the following Microsoft TCP/IP error message popped-up within a VM, while I was trying to set its static IP address.
The IP address <IP address> you have entered for this network adapter is already assigned to another adapter (<Name of adapter>) which is no longer present in the computer. If the same address is assigned to both adapters and they both become active, only one of them will use this address. This may result in incorrect system configuration.
Do you want to remove the static IP configuration for the absent adapter?
Keep in mind that the error message can be slightly different depending on the server operating system (OS) you are running.
This error can have several causes. The most common is when you delete a VMs virtual network adapter (vNIC), which has a static IP address (also known as fixed IP address), and in a later phase attach a new vNIC (removing and re-adding a vNIC) and try to set the same static IP address again.
Other causes can be when a VM is not properly migrated between different Hyper-V hosts or when a backup of a VM is set back to another host, then the one where the VM previously ran.
And it can also occur after a physical to virtual (P2V) conversion of a server.
You can fix this issue, by uninstalling the ghosted (dimmed) network adapter inside the VM. As usually, there are several ways to do this, one of them is by use of the registry, but there is also an easier and quicker fix. This one is shown below:
First of all, answer No to the error question in the pop-up (be aware when you do so, temporarily both network adapters will have the same IP address).
Press the Windows + R keys to open the Run box ,type cmd, and press Enter or click OK.
In the opened Command Prompt window type:
Press Enter and type:
Press Enter, this will open Device Manager.
When Device Manager is open, click View, and then click Show Hidden Devices, to make the ghosted network adapter(s) visible.
Expand the Network adapters tree and right-click the ghosted network adapter and then click Uninstall device.
It is possible that there are more ghosted network adapters listed, but start with the first one shown. Afterwards you can uninstall all others.
In the Uninstall Device pop-up, click Uninstall to confirm the removal of the device.
Repeat these steps for all other ghosted network adapters (if applicable). When they are all removed, you can set the static IP address on the new network adapter. This should now work.
You can always check the right IP address settings, by running ipconfig in a Command Prompt window.
Hope this blog post will help you whenever you face the same issue.