Config » Historial » Versió 10
Pau Escrich, 09-01-2013 17:44
1 | 1 | Pau Escrich | h1. Config |
---|---|---|---|
2 | |||
3 | 10 | Pau Escrich | The file /etc/config/qmp is the central configuration file (based on UCI). |
4 | |||
5 | 7 | Pau Escrich | h3. Network interfaces |
6 | |||
7 | 2 | Pau Escrich | <pre> |
8 | 1 | Pau Escrich | config 'qmp' 'interfaces' |
9 | # option 'configure_switch' 'eth0' # (uncomment line if available, e.g. WGT634U) |
||
10 | 4 | Pau Escrich | option 'lan_devices' 'eth0 wlan1 dummy0' # LAN (dhcp server) |
11 | option 'wan_devices' 'eth1' # WAN (dhcp client) |
||
12 | option 'mesh_devices' 'wlan0 wlan2 eth0 eth1' # Mesh devices, will be extended by VLAN tag! |
||
13 | option 'no_vlan_devices' '' # Network devices where we do not want to use VLAN tag (not recommended!) |
||
14 | 6 | Pau Escrich | </pre> |
15 | 1 | Pau Escrich | |
16 | 7 | Pau Escrich | h3. Node information |
17 | |||
18 | 6 | Pau Escrich | <pre> |
19 | 1 | Pau Escrich | config 'qmp' 'node' |
20 | 9 | Pau Escrich | option 'primary_device' 'eth0' |
21 | option 'community_id' 'qMp' |
||
22 | option 'community_node_id' '' |
||
23 | option 'key' '/tmp/qmp_key' |
||
24 | 1 | Pau Escrich | </pre> |
25 | 6 | Pau Escrich | |
26 | 7 | Pau Escrich | |
27 | h3. Upgrade firmware |
||
28 | |||
29 | 5 | Pau Escrich | <pre> |
30 | 1 | Pau Escrich | config 'qmp' 'update' |
31 | option 'url' 'http://fw.qmp.cat/testing' |
||
32 | option 'images' 'IMAGES' |
||
33 | option 'devices' 'DEVICES' |
||
34 | option 'filter' 'sysupgrade' |
||
35 | 6 | Pau Escrich | option 'preserve' '/etc/config/qmp /etc/shadow /etc/passwd /etc/rc.local /etc/firewall.user /etc/dropbear/* /etc/config/b6m-spread' |
36 | 4 | Pau Escrich | </pre> |
37 | 1 | Pau Escrich | |
38 | 7 | Pau Escrich | h3. DHCP overlapping (Roaming) |
39 | |||
40 | This is for Roaming mode, each node assings a non-overlapping DHCP IPv4 ranges over a /16 network on LAN device |
||
41 | 5 | Pau Escrich | <pre> |
42 | 1 | Pau Escrich | config 'qmp' 'non_overlapping' |
43 | 4 | Pau Escrich | option 'ignore' '0' |
44 | 1 | Pau Escrich | option 'dhcp_offset' '2' |
45 | option 'qmp_leasetime' '1h' |
||
46 | </pre> |
||
47 | |||
48 | 7 | Pau Escrich | h3. Network (layer3) |
49 | |||
50 | 6 | Pau Escrich | <pre> |
51 | 1 | Pau Escrich | config 'qmp' 'networks' |
52 | option 'dns' '141.1.1.1 85.126.4.170 202.83.95.227' |
||
53 | option 'lan_address' '172.30.22.1' |
||
54 | option 'lan_netmask' '255.255.255.0' |
||
55 | 4 | Pau Escrich | |
56 | # means olsr6 use vlantag 10+1, bmx6 use vlantag 10+2 |
||
57 | option 'mesh_protocol_vids' 'olsr6:1 bmx6:2' |
||
58 | 3 | Pau Escrich | option 'mesh_vid_offset' '10' |
59 | |||
60 | 4 | Pau Escrich | # rescue network prefix, the 16 missing bits are taken from device MAC |
61 | 8 | Pau Escrich | option 'rescue_prefix24' '169.254' |
62 | 3 | Pau Escrich | |
63 | 4 | Pau Escrich | # OLSR (backup protocol) only supports IPv6 |
64 | 3 | Pau Escrich | option 'olsr6_mesh_prefix48' 'fd01:0:0' |
65 | option 'olsr6_ripe_prefix48' '2011:0:0' |
||
66 | |||
67 | # BMX6 (main protocol) runs IPv6 backbone and IPv4 tunneled |
||
68 | option 'bmx6_mesh_prefix48' 'fd02:0:0' |
||
69 | option 'bmx6_ripe_prefix48' '2012:0:0' # suffix is autoconfigured based on community_node_id |
||
70 | option 'bmx6_ipv4_prefix24' '10.202' |
||
71 | # option 'bmx6_ipv4_address' '10.202.9.01/24' # if commented out then option is autoconfigured based on |
||
72 | # community_node_id and bmx6_ipv4_prefix |
||
73 | 8 | Pau Escrich | option 'bmx6_tablePrefTuns' '7000' |
74 | option 'bmx6_tableTuns' '70' |
||
75 | option 'bmx6_throwRules' '1' |
||
76 | 3 | Pau Escrich | |
77 | option 'babel_mesh_prefix48' 'fd03:0:0' |
||
78 | 9 | Pau Escrich | option 'netserver' '1' |
79 | 1 | Pau Escrich | </pre> |
80 | |||
81 | 7 | Pau Escrich | h3. Tunnels (gateways) |
82 | |||
83 | Offer/Fetch networks in the Mesh |
||
84 | |||
85 | 3 | Pau Escrich | <pre> |
86 | config 'qmp' 'tunnels' |
||
87 | option 'search_ipv4_tunnel' '0.0.0.0/0' |
||
88 | option 'search_ipv6_tunnel' '::/0' |
||
89 | # option 'offer_ipv4_tunnel' '0.0.0.0/0' |
||
90 | 1 | Pau Escrich | # option 'offer_ipv6_tunnel' '::/0' |
91 | </pre> |
||
92 | |||
93 | 7 | Pau Escrich | h3. WiFi |
94 | |||
95 | Main wireless configuration (common for all wifi devices) |
||
96 | 3 | Pau Escrich | <pre> |
97 | config 'qmp' 'wireless' |
||
98 | option 'driver' 'mac80211' |
||
99 | option 'country' 'SP' |
||
100 | option 'bssid' '02:CA:FF:EE:BA:BE' |
||
101 | |||
102 | # First wifi device |
||
103 | config 'wireless' |
||
104 | 9 | Pau Escrich | option 'mode' 'adhoc' |
105 | option 'name' 'qMp.lab104' |
||
106 | option 'txpower' '14' |
||
107 | option 'channel' '140-' |
||
108 | option 'mac' '90:a4:de:c0:bb:c3' |
||
109 | option 'device' 'wlan0' |
||
110 | 3 | Pau Escrich | |
111 | # Second wifi device |
||
112 | config 'wireless' |
||
113 | 9 | Pau Escrich | option 'mode' 'ap' |
114 | option 'name' 'qMp' |
||
115 | option 'txpower' '17' |
||
116 | option 'channel' '9+' |
||
117 | option 'mac' '00:80:48:78:75:23' |
||
118 | option 'device' 'wlan1' |
||
119 | 1 | Pau Escrich | </pre> |