![]() If you're editing both files in a text editor within an SSH session, you might copy&paste their contents. Now, copy /usr/local/etc/tinc/lebridge/hosts/box1 from box 1 to box 2, and /usr/local/etc/tinc/lebridge/hosts/box2 from box2 to box1.# cat /usr/local/etc/tinc/lebridge/rsa_key.pub > /usr/local/etc/tinc/lebridge/hosts/box1 Still on box 1, append its public key to its host configuration file:. ![]() On box 1 (tinc client) also create its host configuration file /usr/local/etc/tinc/lebridge/hosts/box1, but omit the address as it'll be assigned a dynamic ip address:.# cat /usr/local/etc/tinc/lebridge/rsa_key.pub > /usr/local/etc/tinc/lebridge/hosts/box2 Still on box 2, append its public key to its host configuration file:.On box 2 (tinc server) create its host configuration file /usr/local/etc/tinc/lebridge/hosts/box2:.On box 1 (tinc client) create a slightly different configration file /usr/local/etc/tinc/lebridge/nf:.On box 2 (tinc server) create the configration file /usr/local/etc/tinc/lebridge/nf:.# mkdir -p /usr/local/etc/tinc/lebridge/hosts We will name our tinc connection lebridge and have to create a directory to place its configuration in on box 1 and 2:.Here are the steps which are needed to build such a scenario on FreeBSD 10.3 as depicted above: Thus, RSTP will prefer the direct connection, and only if that one is down, it'll use the Internet connection (unless that one is down, too). 100 MBit nics or 1GE cards have lower costs of 20000, respectively. Since tap devices present themselves as 10 MBits/sec interfaces, their RSTP costs are 2000000. em1 on box 1 can even be some kind of ppp uplink with a dynamic ip address. Instead of em(4) based ethernet cards you can use any supported nic, of course. | (public ip 1) | (oooooooooo) | (public ip 2) | Lan 1 | | direct ethernet connection | | lan 2 That tap device will then be connected to the bridge. Tinc is an SSL VPN software which can also transport layer 2 ethernet frames when configured on a tap device. But what if one connection should use the Internet? Here comes tinc into play. That way both boxes (or software switches, if you like) had a redundant connection to each other and could tolerate the loss of one interconnection. Thus, you could connect two (or more) ports of a FreeBSD box running if_bridge to another FreeBSD box running if_bridge, too, and won't experience a network storm. if_bridge even supports the Rapid Spanning Tree Protocol (RSTP) which avoids network loops. Redundant ethernet bridge with FreeBSD and tinc Redundant ethernet bridge with FreeBSD and tincįreeBSD comes with the if_bridge(4) driver which interconnects network cards in order to form an Ethernet switch (or historically a multiport bridge, hence the name).
0 Comments
Leave a Reply. |
Details
AuthorWrite something about yourself. No need to be fancy, just an overview. ArchivesCategories |