Packet tunneling over UDP, multiple channels
You can not select more than 25 topics Topics must start with a letter or number, can include dashes ('-') and can be up to 35 characters long.
 
 
 
 

36 lines
1.4 KiB

  1. # Virtual cable with uplinks to example host at 10.0.0.1:2 and [fe::1]:2,
  2. # and downlink ranges 10.1.0.0/16 (any port) and [fe::1:0:0/96]:3
  3. #
  4. # + creates a local tap named "example" with tunneling MTU (1450)
  5. # + uses UDP port 3 for this cable end
  6. # + reniced service daemon
  7. # + single-v logging to /var/log/rrqnet-example.log
  8. # + cable PSK /etc/rrqnet/keys/example[1-4].key (not included)
  9. # + 10 packet buffers and a single dispatch thread
  10. # + using static IPv4 assignment
  11. #
  12. # This template includes an extension block to manage a dnsmasq instance
  13. # for serving dhcp (only). Usage:
  14. # ifup exampe=dnsmasq
  15. # ifdown exampe=dnsmasq
  16. auto example
  17. iface example inet manual
  18. mtu 1450
  19. address 192.168.222.2/24
  20. rrqnet_port 3
  21. rrqnet_nice -3
  22. rrqnet_log -v /var/log/rrqnet-example.log
  23. rrqnet_remote 10.0.0.1:2=/etc/rrqnet/keys/example1.key
  24. rrqnet_remote [fe::1]:2=/etc/rrqnet/keys/example2.key
  25. rrqnet_remote 10.1.0.0/16=/etc/rrqnet/keys/example3.key
  26. rrqnet_remote [fe::1:0:0/96]:3=/etc/rrqnet/keys/example4.key
  27. rrqnet_options -B 10 -T 1
  28. iface dnsmasq inherits example
  29. up /usr/sbin/dnsmasq -i example -a 192.168.222.2 -I lo -I wlan0 -I eth0 \
  30. -p 0 -K -D -N -b --dhcp-sequential-ip \
  31. -F 192.168.222.100,192.168.222.200,255.255.255.0,192.168.222.255 \
  32. --dhcp-hostsfile=/etc/network/example.dhcphosts
  33. down pkill -f 'dnsmasq -i example'