On 15/12/2019 21:57, Denis Fondras wrote:
Hi,
I have this setup :
em3: flags=8843<UP,BROADCAST,RUNNING,SIMPLEX,MULTICAST> mtu 1500
lladdr
index 4 priority 0 llprio 3
media: Ethernet autoselect (1000baseSX full-duplex)
status: active
inet6 fe80::aa9:b803:8a7a:ca72%em3 prefixlen 64 scopeid 0x4
inet 172.16.0.254 netmask 0xffffff00 broadcast 172.16.0.255
em4: flags=8843<UP,BROADCAST,RUNNING,SIMPLEX,MULTICAST> mtu 1500
lladdr
index 5 priority 0 llprio 3
media: Ethernet autoselect (1000baseSX full-duplex)
status: active
inet 172.16.0.249 netmask 0xfffffffc broadcast 172.16.0.251
inet6 fe80::29ae:98d:f238:fd68%em4 prefixlen 64 scopeid 0x5
I have a computer with IPv4 address 172.16.0.248 connected to em3.
When I try to ping it, obviously it goes to em4.
How can I route 172.16.0.248 through em3 ?
I tried with :
* route add 172.16.0.248/32 172.16.0.254 -iface em3
* route add 172.16.0.248/32 -llinfo -link -static -iface em3
but without luck.
Thank you in advance,
Denis
You can do this with pf route-to
G