OpenBSD: Gateway outside subnet (works in Linux)
Posted
by
kshade
on Server Fault
See other posts from Server Fault
or by kshade
Published on 2013-10-20T10:45:00Z
Indexed on
2013/10/20
15:56 UTC
Read the original article
Hit count: 194
We need to set up an OpenBSD host to use a default gateway that's outside of it's subnet. This is all I need to do on Linux (not the actual IPs) to achieve it:
ifconfig eth0 33.33.33.33/31 up
route add 33.33.33.254 dev eth0
route add default gw 33.33.33.254
The problem is that we don't know the proper equivalent of the middle command in OpenBSD. The man page says:
If the destination is directly reachable via an interface requiring no intermediary system to act as a gateway, the -iface modifier should be specified;
Sadly we can't seem to figure out how to make it work with that. This is a virtual host on an OVH server, they have documentation for many other operating systems showing how to do it here: http://help.ovh.co.uk/BridgeClient
© Server Fault or respective owner