How to access computer connected through USB tethering

pradeepsixer

Commendable
Jul 21, 2016
6
0
1,510
Here is my network setup: My android mobile(192.168.0.100) is connected to a WiFi router (192.168.0.1). I have enabled USB tethering on the mobile for internet access on my desktop (192.168.42.189). Also from my connection, the gateway is 192.168.42.129. So now we can infer the following from all these data:

Router IP: 192.168.0.1
Mobile's IP (for WiFi interface): 192.168.0.100
Mobile's IP (for USB interface): 192.168.42.129
Desktop's IP: 192.186.42.189

I've added the route: Subnet 192.168.42.0 with mask 255.255.255.0 and the gateway as 192.168.0.100.

I can ping the router from my desktop, but I cannot ping my desktop from the router or any other WiFi router connected device

Why cannot I access the desktop, even though I have added the route?
 

kanewolf

Titan
Moderator
Because a wifi connected device would have a 192.168.0.x IP address. They have no routes to 192.168.42.x Their default gateway is 192.168.0.1 (from DHCP). If your android mobile can connect to the router, and you can USB tether, then why wouldn't you ethernet connect to the router and have a single subnet ?
 

pradeepsixer

Commendable
Jul 21, 2016
6
0
1,510


It is because of the room size. The telephone jack is not working in my room. The one in which it works is bed room, and it does not have enough space to accomodate my desktop


But I have added a route for 192.168.42.x subnet with my mobile 192.168.0.100 as the gateway. It should work with that, no?