No Default Gateway w/ Static IP

Ictinike
 
Posts: 20
Joined: Sun Feb 19, 2017 9:37 pm

No Default Gateway w/ Static IP

Sun Feb 26, 2017 5:07 am

Group,

Been trying to figure this out as it seems to have been, or continues to be, an issue in OpenWRT.

Upon configuring AP+STA mode I can completely and 100% get it work in DHCP mode:
Code: Select all
  uci show network.wwan
  network.wwan=interface
  network.wwan.ifname='apcli0'
  network.wwan.proto='dhcp'
 


However, the moment I setup the client STA into a static IP mode [which I prefer here on the compound] I have my issues. See I'm able to configure it and I get connected with the proper IP I've chosen but for some reason OpenWRT won't assign a 'default' gateway' to the routes. For purposes, here is my config if I so go into STATIC mode:

Code: Select all
 uci show network.wwan
 network.wwan=interface
 network.wwan.ifname='apcli0'
 network.wwan.proto='static'
 network.wwan.ipaddr='192.168.1.116'
 network.wwan.netmask='255.255.255.0'
 network.wwan.gateway='192.168.1.1'
 network.wwan.dns='192.168.1.115'
 


This works wonderfully, however, I cannot get out to the Internet at large. If I do a ping, I get 'bad address' since there is no default gateway created upon bootup. Now if I add one in by issuing 'route add default gw 192.168.1.1 apcli0' everything works fine until reboot, wherein I must re-add the route.

I've been searching and have found this issue in OpenWRT all the way about to nearly 8-10 years ago and there were many suggestions, ideas, etc but none that I have tried worked. In fact on one conversation they just asked the person to use DHCP because it was 'easier'. Blarg!

What's even more ridiculous is I have a few Onion Omega2+ from awhile back and they also run OpenWRT LEDE which, if I configure a static IP for it; it acts the *very* *same* *way*! So this is why I'm thinking it's something I'm not doing properly or at all so thought I would present it to the larger audience and see what might come from it.

Thanks!
~Icky

Admin
Site Admin
 
Posts: 15
Joined: Fri Oct 17, 2014 11:26 am

Re: No Default Gateway w/ Static IP

Sun Feb 26, 2017 7:30 am

Check firewall, it is in/etc/config/firewall, normally it blocks.

Ictinike
 
Posts: 20
Joined: Sun Feb 19, 2017 9:37 pm

Re: No Default Gateway w/ Static IP

Sun Feb 26, 2017 3:49 pm

Agreed and I apologize I didn't put that in the original post.

Firewall seems fine as the wan and wwan both have the input, output and forward as ACCEPT among other listed in the Vonger post of AP+STA.

I'm thinking it's something in OpenWRT so I'll keep hacking at it :) Was hoping maybe someone within these forums had seen a rectifying method that I might not have. Overall loving this thing and playing around with it.

Next thing I'll be working with is a portable OpenVPN/TOR routerI can use while not on HOME LAN to protect and anonymize myself..

Return to VoCore2/Lite/Ultimate

Who is online

Users browsing this forum: Google [Bot] and 62 guests