User manual

Chapter 4 - Layer 3 Command Set - IP Networking Tun Command (Tunnels Building)
Alvarion BreezeNET B130/B300 GigE 109 Operational User Manual
Outgoing packets are encapsulated into IP datagrams and sent to the dst address.
The src address is inserted into the datagram as source address.
The src address must be a real IP-address for one of the devices' interfaces; for the
same reason, it shall be attainable from the device at the tunnel's remote end
through the existing network (and not only through this tunnel).
On the remote site of the tunnel, the src and dst addresses swap their roles.
The mtu optional parameter allows the user to set the Maximum Transfer Unit
size for packets going through the tunnel. Default value is 1480 bytes.
Disabling the tunnel number N may be done by executing the command:
tun N clear
Example:
ifconfig tun0 1.1.1.1 1.1.1.2
tun 0 src 195.23.23.23 dst 194.34.34.34
Here, the ifconfig command defines internal IP-addresses for both ends of a
tunnel #0 as addresses for an interface denoted as tun0; then, the tun command
defines real IP-addresses for the tunnel #0 extremities.
At the opposite side of the tunnel this would look as follows:
ifconfig tun0 1.1.1.2 1.1.1.1
tun 0 src 194.34.34.34 dst 195.23.23.23
If you use a Cisco Systems router at the remote end, you may configure it as
follows:
interface Tunnel0
ip address 1.1.1.2 255.255.255.252
tunnel source 194.34.34.34
tunnel destination 195.23.23.23
CAUTION
The dst address shall also be attainable through an interface of the device different from that used
to access the tunnel. This can be done, for example, by using explicit static routing (the route add
command), or by prohibiting importation of some of the RIP protocol route descriptors arriving to
that interface. If this condition is not satisfied, a looping may happen, when already encapsulated
packets come back to the tunnel entrance, and so on, causing system overload. The system
watches over such situations, and when discovering a loop, drops erroneous packets and writes a
message tunX: looping … into the system log.