[nos-bbs] ARP

Jay Nugent jjn at nuge.com
Thu Mar 5 08:05:43 EST 2020


Greetings,
    For a nice clean method of setting up the TUN and creating the routes 
to go along with it, see the AUTOEXEC.NOS example file that is on the ARRL 
Michigan Section "Digital Radio Group" (DRG) website:

    http://www.MI-DRG.org/AUTOEXEC.NOS

    The file has built-in comments and instructions for setting up JNOS for 
use just on your LAN (under NAT), or accessable via a 'NAT'ed IP address 
via your routers 'DMZ Host' feature, as well as if your Linux box and JNOS 
instance have Publicly Routable IP addresses.

    It accomplishes the task by making the JNOS end of the TUN address 
'appear' to be on the ETH0/WLAN0 interface by using 'Proxy ARP'.

    The example is configured as W1AW, so please edit it to use your own 
callsign, please :)

       --- Jay Nugent  WB8TKL
           o ARRL Michigan Section ASM for Digital Technologies
           o Chair, Michigan Section "Digital Radio Group" (DRG)
             [ www.MI-DRG.org ]


On Wed, 4 Mar 2020, jerome schatten wrote:

> Long ago, someone gave me two arp statements which solved two jnos 
> problems: 1. I couldn’t make jnos talk to my router from the jnos> 
> prompt; and 2. I couldn’t get into jnos via telnet from other machines 
> on my lan. These two statements are embedded now in a shell script that 
> I run prior to executing jnos.
>
> The two statements are:
>
> 1. arp -i eth0 -Ds 192.168.0.149 eth0 pub   #jnos side of tun0
> 2. arp -i eth0 -Ds 192.168.0.107 eth0 pub   #linux side of tun0
>
> In fact, these two addresses are the jnos side of tun0 and the linux 
> side of tun0 respectively. So both sides of tun0 appear in the arp 
> table:
>
> pi at raspberrypi3:~ $ arp
> Address                  HWtype  HWaddress           Flags Mask            Iface
> 192.168.0.1              ether   60:2a:d0:75:0a:9b   C                     wlan0
> 192.168.0.102            ether   6c:40:08:be:24:80   C                     eth0
> 192.168.0.120            ether   b8:27:eb:12:28:da   C                     eth0
> 192.168.0.1              ether   60:2a:d0:75:0a:9b   C                     eth0
> 192.168.0.149            *       <from_interface>    MP                    eth0
> 192.168.0.107            *       <from_interface>    MP                    eth0
>
> All this works fine.
>
> Now what I would like to do is to use wlan0 instead of eth0. To this 
> end, I replaced all instances of eth0 with wlan0, and in 2. above, 
> changed the address to reflect the ip address for wlan0, so now have:
>
> 3. arp -i wlan0 -Ds 192.168.0.149 wlan0 pub
> 4. arp -i wlan0 -Ds 192.168.0.130 wlan0 pub
>
> So now I’m stuck — I can’t ping the router from inside jnos and thus 
> there’s no contact into or out of jnos. I can ping both sides of tun0 
> and the tun module is loaded and ip_forward=1. The arp table now looks 
> like:
>
> pi at raspberrypi3:~ $ arp
> Address                  HWtype  HWaddress           Flags Mask            Iface
> 192.168.0.102            ether   6c:40:08:be:24:80   C                     wlan0
> 192.168.0.120            ether   b8:27:eb:12:28:da   C                     wlan0
> 192.168.0.1              ether   60:2a:d0:75:0a:9b   C                     wlan0
> 192.168.0.149            *       <from_interface>    MP                    wlan0
> 192.168.0.130            *       <from_interface>    MP                    wlan0
>
> Just for completeness:
> .102 is my mac;
> .120 is my pi running BPQ
> .1   is the router
> .149 is the jnos side of tun0 and in the DMZ
> .130 is the linux side of tun0
>
> What am I not seeing?
> Thanks,
> jerome - ve7ass
> Vancouver



More information about the nos-bbs mailing list