Managing OpenWRT » History » Revision 12

Revision 11 (Nico Schottelius, 09/08/2020 01:34 PM) → Revision 12/25 (Nico Schottelius, 11/17/2020 06:07 PM)


 h1. Managing OpenWRT 

 h2. Installing and configuring Jool 

 * You can use one of the known NAT64 prefixes from our networks (LINK!) 
 ** In the example below this is 2a0a:e5c0:2:10::/96 
 * You need to have a /96 (or better: /64) routed to the openwrt 
 ** In the example below this is 2a0a:e5c0:17:1::/96 

 opkg install kmod-jool 
 opkg install jool-tools 

 # Load the kernel module 
 modprobe jool_siit 

 # The range which will be the target for the 2nd NAT (if needed to reach a v4 ip) 
 jool_siit -6 2a0a:e5c0:2:10::/96 

 # Pick a v6 range to translate TO and a v4 range to translate from 
 jool_siit -e -a 2a0a:e5c0:17:1::/96 

 # Accept Router Advertisements to keep the default address 
 sysctl -w net.ipv6.conf.all.accept_ra=2 
 sysctl -w net.ipv6.conf.default.accept_ra=2 
 sysctl -w net.ipv6.conf.eth0.accept_ra=2 
 sysctl -w 


 h2. Enabling routing with router advertisements 

 * By default ipv6 forwarding is on (good!) 
 * By default accept_ra is 0 
 ** This does not set the route properly into the kernel -> routing is broken 
 * Need to modify accept_ra to 2 

 h2. Enabling SSH access on wan  

 Enable it in the web interface 
 <pre> $URL/cgi-bin/luci/admin/system/admin/dropbear </pre> 


 Dropbear uci var (not tested): 

 <pre> 	 option GatewayPorts 'on' </pre> 

 h2. Resetting to factory default 

 * See 

 firstboot -y && reboot now 

 h2. Installing and configuring an APU as a PIB with OpenWRT 

 * Get the x86 64 SQUASHFS image 
 ** combined-squashfs.img.gz 
 * Gunzip it 
 * dd it it an usb stick 
 * Boot the usb stick on the APU 
 * When booted, wget it on the APU and write it over /dev/sda 

 wget ... -O - | gunzip > /dev/sda 

 * Configure it using from ungleich-tools 
 * Create a network on the VPN server 

 h3. Installing openwrt (squashfs) on APU details 

 opkg update 

 * Install SSL certifaicates 

 opkg install libustream-openssl ca-bundle ca-certificates 

 * check the time and date if it is not correct, modify the time and date as follows  

 * Flashing the squashfs openwrt image into the APUs SSD (adjust to the correct version) 

 wget -O - 
 x86/64/openwrt-19.07.3-x86-64-combined-squashfs.img.gz | gunzip > /dev/sda  

 h3. Defaults after Openwrt installation  

 * eth0 = WAN 
 * eth1&2 = LAN 

 h2. Setting up the GL-INET GL-MT300N-V2 

 * Go to advanced and flash the standard image 
 * Link: