Windows 10 multiple Ethernet connections with one being connected to the internet but PC doesnt connect to the internet [closed]

I have a win10 machine in a rural area with no ability to connect to a private network. The computer is used to track measurements of specific sensors which are connected with ethernet to the computer. I want it to upload data to my cloud using a huawei internet stick.

And here is the problem: When I plug in my internet stick it will not connect to the internet (no response ping 8.8.8.8 or visit google with browser possible). So I figured out that I need to uncheck the "automatic metric" in the ethernet adapter settings. I've set them to 1 (also 2, 3, 4..) and was able to connect to the internet. But then I faced another problem, I was unable to connect to my sensors. As soon as I unplug my internet stick, I was able to connect to the sensors again.

This is driving me nuts. I have no manual of the sensors since it was a development product of 3rd party. But I assume that the IP is given from the sensors (dhcp most likely on that sensor-hardware). I haven't try it out but do I need to set the default gateway of the sensor-connection to the IP of my internet stick? So in case it can not find a route at the sensor, it would redirect to the default gateway to the internet?

Thanks in advance, sorry I am quite new in networking.


Solution 1:

A lot (most? all?) USB-based celluar modems act as a NAT gateway and simulate a regular ethernet connection. What it sounds like is happening here is that the IP range that the USB stick uses is the same as the IP range your sensors use.

So when you plug it in, the computer sees two adapters with the same range, and so it assumes that they are both on the same network - when they are not. Changing the metric will make Windows use the lower metric'd interface for all its network traffic - but it doesn't know that the two interfaces are actually different.

If this is what's happening (and it's just an assumption), then you will have to re-number one of the networks.

The way to validate this is to run ipconfig when you have the dongle plugged in. If the first 3 sets of digits in the IP addresses on both adapters are the same (e.g. 192.168.0, then it's a 99% chance that this is the problem.