Hi, I have use NS M2 which is integrated with local AmprNET gateway which have 2 ethernet cards one to internet connected and second to NS M2 main gateway local Mesh Node to get access all nodes to wide AmprNet network. My local nodes use subnet 44.165.33.128 /255.255.255.128 Amprnet gateway on eth1 computer has 44.165.33.1 Ip with connected to NS M2 with LAN IP 44.165.33.2 (255.255.255.252) nad WIFI 44.165.33.254
On NS M2 I have made manually changes via SSH in following:
cd /usr/local/bin vi olsrd-config
= add suffix ampr.org ===============
push @file, qq( PLParam "suffix" ".ampr.org"\n); push @file, qq( PLParam "dns-server" ""\n); push @file, qq( PlParam "timeout" "300"\n);
===================
cd /www/cgi-bin/ vi status
======== add suffix ampr,org c===============
if($config eq "mesh") { print " "; print "<button type=button onClick='window.location=\"mesh\"' title='See what is on the mesh'>Mesh Status</button>\n"; print " "; print "<button type=button onClick='window.location=\"http://$node.ampr.org:1978/\"' title='See the OLSR routing details'";
=============================
cd /etc/config/ vi network
======change LAN IP to Ampr Net and add LAN gateway to AmprNet===========
config interface loopback option ifname "lo" option proto static option ipaddr 127.0.0.1 option netmask 255.0.0.0 #### LAN configuration config interface lan option ifname "eth0" option proto static option ipaddr 44.165.33.2 option netmask 255.255.255.252 option dns "44.165.33.1 " option gateway 44.165.33.1 #### WAN configuration config interface wan option ifname "eth0.1" option proto disabled option ipaddr option netmask option gateway #### WIFI configuration config interface wifi option ifname "wlan0" option proto static option ipaddr 44.165.33.1 option netmask 255.255.255.128 #### device to device configuration config interface dtdlink option ifname "eth0.2" option proto disable option ipaddr 10.7.57.177 option netmask 255.0.0.0 config interface wifi_mon option proto none
========================
vi olsrd
=========add HNA info about 44/8 network ======
#### Loopback configuration config olsrd # uncomment the following line to use a custom config file instead: #option config_file '/etc/olsrd.conf'
option IpVersion '4' #option MainIp '44.165.33.1' option RtTable '30' option RtTableDefault '31' option LinkQualityAlgorithm 'etx_ffeth'
config LoadPlugin option library 'olsrd_arprefresh.so.0.1'
config LoadPlugin option library 'olsrd_httpinfo.so.0.1' option port '1978' list Net '0.0.0.0 0.0.0.0' option Resolve 'true'
config LoadPlugin option library 'olsrd_txtinfo.so.0.1' option accept '0.0.0.0'
#config LoadPlugin # option library 'olsrd_secure.so.0.6' # option keyfile '/etc/olsrd.d/olsrd_secure_key'
config LoadPlugin option library 'olsrd_dot_draw.so.0.3' option accept '127.0.0.1' option port '2003'
config LoadPlugin option library 'olsrd_watchdog.so.0.1' option file '/tmp/olsrd.watchdog' option interval '5'
config Interface list interface 'wifi'
config Hna4 option netaddr 44.0.0.0 option netmask 255.0.0.0
============================================
cd /etc/init.d vi nntpclient
========ad local NTP server link =================
#!/bin/sh /etc/rc.common START=70
start() { { while ! ping -c1 44.165.33.1 >/dev/null 2>&1; do sleep 60; done /usr/sbin/ntpclient -s -l -h 44.165.33.1 >/dev/null 2>&1; } & }
stop() { killall ntpclient } ========================
After this changes my NS M2 working as local Mesh Node gateway to AmprNet and I can use SETUP via web interface because it will be overwrite my manually changes. I have switch off firewall and DHCP on LAN because my local network is only part of AmprNet network and we don't have access from 44/8 to -> aaal only 44net<->44net
73 Waldek SP2ONG
|