In Windows IOT - is there an option via command line to delete unplugged (hidden) Ethernet adapters?
My issue is, when I am plug in an USB-TO-ETHERNET device adapter, it is have the name, lets say, "Ethernet 2". Then I want to set static ip like -
netsh int ip set address "Ethernet 2" static 123.0.0.123 255.255.255.0 0.0.0.0
But when I am unplug the above adapter, and plug it to another USB port, it is have the name, lets say, "Ethernet 3".
"Ethernet 2" is not appear anymore, for example in ipconfig.
And when I set static ip for the new one ("Ethernet 3") with same details, like
netsh int ip set address "Ethernet 3" static 123.0.0.123 255.255.255.0 0.0.0.0
I am getting the error -
The object already exists.
I tried to reset "Ethernet 2" to DHCP without success -
netsh int ip set address "Ethernet 2" dhcp
But I am getting the error below:
The filename, directory name, or volume label syntax is incorrect.
Any idea how to overcome this issue? To forget the settings of "Ethernet 2" and apply it on "Ethernet 3".
Thanks.