Best to run (from an elevated command prompt):
netsh interface ipv4 show interfaces
Which gives something like:
Idx Met MTU State Name
--- ---------- ---------- ------------ ---------------------------
12 35 1500 connected Ethernet
1 75 4294967295 connected Loopback Pseudo-Interface 1
then use the index number (Idx) of the interface. Also note the State of the interface. If it says disconnected nothing you do is going to have an effect.
netsh interface ipv4 set interface "12"
Ok.
Then add each parameter one at a time and see which one is causing the problem. For what it is worth I don't see the need for any of your parameters. The "netsh interface ipv4 set interface" command is not going to switch from using one interface to the other. If the interface doesn't show "connected" in "netsh interface ipv4 show interfaces" it's not going to work.
Instead of netsh I would look at device manager
then right click on each network adapter and select Properties then Power Management (tab). Uncheck
"Allow the computer to turn off this device to save power"
then hit OK.
Windows sometimes doesn't turn the adapter back on when it should.
Also look at newer drivers for your adapters. Realtek in particular has had problems with Win 10. Don't trust Windows to know if the drivers are the best. Get them directly from the maker's site.
You might also look at
netstat -rn | more
(from an elevated command prompt)
Look at the metric for each IPv4 interface. Assume you would want it to use the Ethernet if both were active so its metric should be set lower than than that of the WiFi
https://www.howtogee...rds-in-windows/