Index: eoip.4 =================================================================== RCS file: /cvs/src/share/man/man4/eoip.4,v retrieving revision 1.4 diff -u -p -r1.4 eoip.4 --- eoip.4 29 May 2019 19:37:06 -0000 1.4 +++ eoip.4 30 Sep 2019 00:11:55 -0000 @@ -83,12 +83,68 @@ route to the tunnel destination than the via the tunnel interface. Alternatively, the tunnel traffic may be configured in a separate routing table to the encapsulated traffic. +.Ss Network Interface Administration +.Nm +interfaces may be configured by +.Xr ifconfig 8 +or +.Xr netstart 8 +using the following options: +.Bl -tag -width indent +.It Cm tunnel Ar src_address dest_address +Set the unicast IPv4 or IPv6 addresses for the encapsulating IP packets. +The addresses may only be configured while the interface is down. +.It Fl Ns Cm tunnel +Clear the addresses used for the encapsulating IP packets. +The addresses may only be cleared while the interface is down. +.It Cm vnetid Ar tunnel-identifier +Configure the virtual network identifier to use as the Tunnel Identifier. +The virtual network identifier may only be configured while the +interface is down. +The Tunnel Identifier is a 16-bit value between 0 and 65535 inclusive. +.It Cm tunneldomain Ar rdomain +Set the routing table the tunnel traffic operates in. +The routing table may only be configured while the interface is down. +.It Cm tunnelttl Ar ttl +Set the Time-To-Live field in IPv4 encapsulation headers, or the +Hop Limit field in IPv6 encapsulation headers. +.It Cm tunneldf +Disable fragmentation of tunnel traffic by the interface. +This sets the Don't Fragment (DF) bit on IPv4 packets, +and disables fragmentation of IPv6 packets. +.It Fl Ns Cm tunneldf +Allow fragmentation of tunnel traffic. +.\" This clears the Don't Fragment (DF) bit on IPv4 packets, +.\" and allows fragmentation of IPv6 packets. +.It Cm rxprio Ar prio +Configure how the interface sets the priority of incoming packets. +.Ar packet +maintains the existing priority of the packet. +Priority may be hardcoded with a number from 0 to 7. +.Ar outer +uses the Type of Service field in IPv4 encapsulation headers, or +the Traffic Class field in IPv6 encapsulation headers to set the +packet priority. +.It Cm txprio Ar prio +Configure which value is used in the Type of Service field in IPv4 +encapsulation headers, or the Traffic Class field in IPv6 encapsulation +headers. +Values may be hardcoded with a number from 0 to 7, or +.Ar packet +to specify that the current priority of a packet should be used. +.It Cm keepalive Ar period count +Enable the transmission of keepalive packets to detect tunnel failure. +Keepalives may only be configured while the interface is down. +.It Fl Ns Cm keepalive +Disable the transmission of keepalive packets to detect tunnel failure. +Keepalives may only be disabled while the interface is down. +.El .Ss Programming Interface .Nm interfaces support the following .Xr ioctl 2 calls for configuring tunnel options: -.Bl -tag -width indent -offset 3n +.Bl -tag -width indent .It Dv SIOCSLIFPHYADDR Fa "struct if_laddrreq *" Set the unicast IPv4 or IPv6 addresses for the encapsulating IP packets. The addresses may only be configured while the interface is down. @@ -101,7 +157,7 @@ The addresses may only be cleared while Configure a virtual network identifier for use as the Tunnel Identifier. The virtual network identifier may only be configured while the interface is down. -The Tunnel Identifier is a 16-bit value. +The Tunnel Identifier is a 16-bit value between 0 and 65535 inclusive. .It Dv SIOCGVNETID Fa "struct ifreq *" Get the virtual network identifer used in the GRE Key header. .It Dv SIOCSLIFPHYRTABLE Fa "struct ifreq *" @@ -173,6 +229,7 @@ On Host A # route add default B # ifconfig eoipN create # ifconfig eoipN tunnel A D +# ifconfig eoipN vnetid T # ifconfig eoipN up # route add E D .Ed @@ -181,7 +238,7 @@ On Host D (MikroTik): .Bd -literal -offset indent [admin@MikroTik] > interface eoip [admin@MikroTik] /interface eoip> add name="eoipN" \e -\e... local-address=D remote-address=A +\e... tunnel-id=T local-address=D remote-address=A [admin@MikroTik] /interface eoip> enable eoipN .Ed .Sh SEE ALSO