MACOS : Multiple routes via 2 network interfaces

georgelza

Expert Member
Joined
Sep 13, 2004
Messages
1,073
Reaction score
81
Location
Johannesburg/Alberton
MAC Friends:

H all, use to do this way back when I still used Windozeeeee.

I connect to my iPhone using Hotspot. all internet traffic this goes through my WLAN/en0 port.
Then want to secondary connect to a 2nd network through my cabled connection via en13 (I have a usb-c to RG45 dongle).
Tried. "sudo route -n add 10.15.20.0/24 10.4.11.1

10.15.20.0/24" is the network where my target server is sitting on and "10.4.11.1" is the GW assigned for the network on which my cabled connection/IP allocated on.

Please help.

G
 
sudo route -n add -net 10.15.20.0/24 10.4.11.1

The other 2 options are -host for one device only, or you can send the traffic to a spesific network interface
 
Top
Sign up to the MyBroadband newsletter
X