Advertisement
Guest User

batman over vlan, no bridge

a guest
Jul 28th, 2012
99
0
Never
Not a member of Pastebin yet? Sign Up, it unlocks many cool features!
Bash 4.79 KB | None | 0 0
  1. root@a:~# cat /etc/config/batman-adv
  2. config mesh 'bat0'
  3.     option interfaces 'eth0_2'
  4.  
  5. root@a:~# cat /etc/config/network
  6. config interface 'loopback'
  7.     option ifname 'lo'
  8.     option proto 'static'
  9.     option ipaddr '127.0.0.1'
  10.     option netmask '255.0.0.0'
  11.  
  12. config interface 'lan'
  13.     option type 'bridge'
  14.     option proto 'static'
  15.     option ipaddr '10.254.130.178'
  16.     option netmask '255.255.0.0'
  17.     option accept_ra '1'
  18.     option ifname 'eth0.1 bat0'
  19.  
  20. config switch
  21.     option name 'eth0'
  22.     option reset '1'
  23.     option enable_vlan '1'
  24.  
  25. config switch_vlan
  26.     option device 'eth0'
  27.     option vlan '1'
  28.     option ports '0t 1 3 4'
  29.  
  30. config switch_vlan
  31.     option device 'eth0'
  32.     option vlan '2'
  33.     option ports '0t 2t'
  34.  
  35. config switch_port
  36.     option pvid '2'
  37.     option port '2'
  38.  
  39. config interface 'eth0_2'
  40.     option ifname 'eth0.2'
  41.     option proto 'none'
  42.     option mtu '1528'
  43.  
  44. config interface 'bat0'
  45.     option ifname 'bat0'
  46.     option proto 'none'
  47.     option mtu '1500'
  48.  
  49. root@a:~# batctl o
  50. [B.A.T.M.A.N. adv 2012.2.0, MainIF/MAC: eth0.2/f8:d1:11:54:50:f9 (bat0)]
  51.   Originator      last-seen (#/255)           Nexthop [outgoingIF]:   Potential nexthops ...
  52. No batman nodes in range ...
  53. root@a:~# batctl bl
  54. disabled
  55. root@a:~# brctl show
  56. bridge name bridge id       STP enabled interfaces
  57. br-lan      8000.f8d1115450f9   no      eth0.1
  58.                             wlan0
  59.                             bat0
  60. root@a:~# ifconfig
  61. bat0      Link encap:Ethernet  HWaddr 22:83:70:69:C3:0B  
  62.           UP BROADCAST RUNNING MULTICAST  MTU:1500  Metric:1
  63.           RX packets:0 errors:0 dropped:0 overruns:0 frame:0
  64.           TX packets:283 errors:0 dropped:26 overruns:0 carrier:0
  65.           collisions:0 txqueuelen:0
  66.           RX bytes:0 (0.0 B)  TX bytes:26053 (25.4 KiB)
  67.  
  68. br-lan    Link encap:Ethernet  HWaddr F8:D1:11:54:50:F9  
  69.           inet addr:10.254.130.178  Bcast:10.254.255.255  Mask:255.255.0.0
  70.           inet6 addr: fe80::fad1:11ff:fe54:50f9/64 Scope:Link
  71.           UP BROADCAST RUNNING MULTICAST  MTU:1500  Metric:1
  72.           RX packets:704 errors:0 dropped:0 overruns:0 frame:0
  73.           TX packets:416 errors:0 dropped:0 overruns:0 carrier:0
  74.           collisions:0 txqueuelen:0
  75.           RX bytes:65422 (63.8 KiB)  TX bytes:66494 (64.9 KiB)
  76.  
  77. eth0      Link encap:Ethernet  HWaddr F8:D1:11:54:50:F9  
  78.           inet6 addr: fe80::fad1:11ff:fe54:50f9/64 Scope:Link
  79.           UP BROADCAST RUNNING MULTICAST  MTU:1500  Metric:1
  80.           RX packets:615 errors:0 dropped:0 overruns:0 frame:0
  81.           TX packets:1331 errors:0 dropped:0 overruns:0 carrier:0
  82.           collisions:0 txqueuelen:1000
  83.           RX bytes:574629 (561.1 KiB)  TX bytes:143572 (140.2 KiB)
  84.           Interrupt:5
  85.  
  86. eth0.1    Link encap:Ethernet  HWaddr F8:D1:11:54:50:F9  
  87.           UP BROADCAST RUNNING MULTICAST  MTU:1500  Metric:1
  88.           RX packets:0 errors:0 dropped:0 overruns:0 frame:0
  89.           TX packets:301 errors:0 dropped:0 overruns:0 carrier:0
  90.           collisions:0 txqueuelen:0
  91.           RX bytes:0 (0.0 B)  TX bytes:28240 (27.5 KiB)
  92.  
  93. eth0.2    Link encap:Ethernet  HWaddr F8:D1:11:54:50:F9  
  94.           inet6 addr: fe80::fad1:11ff:fe54:50f9/64 Scope:Link
  95.           UP BROADCAST RUNNING MULTICAST  MTU:1500  Metric:1
  96.           RX packets:615 errors:0 dropped:0 overruns:0 frame:0
  97.           TX packets:1022 errors:0 dropped:0 overruns:0 carrier:0
  98.           collisions:0 txqueuelen:0
  99.           RX bytes:563559 (550.3 KiB)  TX bytes:109352 (106.7 KiB)
  100.  
  101. root@a:~# batctl ll all ; batctl l
  102. [4294926086] Sending own packet (originator f8:d1:11:54:50:f9, seqno 825689268, TQ 255, TTL 50, IDF off, ttvn 2) on interface eth0.2 [f8:d1:11:54:50:f9]
  103. [4294927066] Sending own packet (originator f8:d1:11:54:50:f9, seqno 825689269, TQ 255, TTL 50, IDF off, ttvn 2) on interface eth0.2 [f8:d1:11:54:50:f9]
  104. [4294928046] Sending own packet (originator f8:d1:11:54:50:f9, seqno 825689270, TQ 255, TTL 50, IDF off, ttvn 2) on interface eth0.2 [f8:d1:11:54:50:f9]
  105.  
  106. root@a:~# batctl td eth0.2 -p1
  107. 21:04:18.784492 BAT f8:d1:11:54:50:f9: OGM IV via neigh f8:d1:11:54:50:f9, seq 825689268, tq 255, ttvn 2, ttcrc 54337, ttl 50, v 14, flags [...F.], length 26
  108. 21:04:18.918908 BAT f8:d1:11:3b:78:df: OGM IV via neigh f8:d1:11:3b:78:df, seq 644031917, tq 255, ttvn 3, ttcrc 38490, ttl 50, v 14, flags [...F.], length 42
  109. 21:04:19.764398 BAT f8:d1:11:54:50:f9: OGM IV via neigh f8:d1:11:54:50:f9, seq 825689269, tq 255, ttvn 2, ttcrc 54337, ttl 50, v 14, flags [...F.], length 26
  110. 21:04:19.898897 BAT f8:d1:11:3b:78:df: OGM IV via neigh f8:d1:11:3b:78:df, seq 644031918, tq 255, ttvn 3, ttcrc 38490, ttl 50, v 14, flags [...F.], length 42
  111. 21:04:20.744420 BAT f8:d1:11:54:50:f9: OGM IV via neigh f8:d1:11:54:50:f9, seq 825689270, tq 255, ttvn 2, ttcrc 54337, ttl 50, v 14, flags [...F.], length 26
  112. 21:04:20.898856 BAT f8:d1:11:3b:78:df: OGM IV via neigh f8:d1:11:3b:78:df, seq 644031919, tq 255, ttvn 3, ttcrc 38490, ttl 50, v 14, flags [...F.], length 42
Advertisement
Add Comment
Please, Sign In to add comment
Advertisement