Stack Exchange network consists of 183 Q&A communities including Stack Overflow, the largest, most trusted online community for developers to learn, share their knowledge, and build their careers.
Now available on Stack Overflow for Teams! AI features where you work: search, IDE, and chat.
Ask questions, find answers and collaborate at work with Stack Overflow for Teams. Explore Teams
Teams
Q&A for work
Connect and share knowledge within a single location that is structured and easy to search.
How to route only specific subnet (source ip) to a particular interface? OS: Linux
I know I can do easily by dest ipdestination IP by using something like
route add 1.2.3.4/24 dev eth4
but I do not see how can route based on source ipIP.
I know I can do easily by dest ip by using something like route add 1.2.3.4/24 dev eth4 but I do not see how can route based on source ip.
I know I can do easily by destination IP by using something like
but I do not see how can route based on source IP.
How to route only specific subnet (source ip) to a particular interface?