B1300 as Wifi client not getting DHCP IP

Hi,

I am trying to have my B1300 connect to an existing Wifi as a client.
Steps done:

  • Installed: OpenWrt only / 15.05.1-r48067
  • Factory reset
  • Network → Wifi → Generic Atheros bgn (wifi0) → Scan
  • Selected wifi with “Join”
  • Enter WPA passphrase
  • Name of new network: “wwan”
  • Assigned firewall zone: wan
  • Submit → Save & Apply

Up to this point everything is working as expected.
95% Signal strength, BSSID from AP, Mode: Client

The issue is, that under “Network” → “Interfaces”, no IP is assigned to “WWAN”, despite being set to “DHCP Client”
Wierd is the WWAN MAC of 00:00:00:00:00:00
Also wierd is, that “iwconfig” shows:
wifi0 no wireless extensions.
ath0 IEEE 802.11ng ESSID:“MyWifi”

Shouldn´t wifi0 show my wifi connection and not ath0?
This is not behaving, as I would expect from OpenWRT.

So I changed /etc/network:
config interface ‘wwan’
option ifname ‘ath0’ # I added this line
option proto ‘dhcp’

This seems like a bug that needs to be fixed.
It should not be required to edit /etc/config/network manually to achive Wifi client functionality.

Regards,
Marc

Why are you assigning this too the WAN aside if the firewall?

Both your client and your device connected to it should get a DHCP IP address from the central DHCP server.

The wwan interface doesn’t need specific ifname. Are you using our official firmware? Why don’t you configure it on our webui?

If you use luci, you have to specific interface name such as “wlan-sta” in Interface Configuration → Advanced Settings.

@klaberte
I intend to use this with NAT.
Example use case: Hotel Wifi access with only one allowed MAC address per paid Wifi voucher.

@kyson-lok
I am using the “OpenWrt only” firmware directly from GL.iNet. Version is mentioned above.

Why don’t you configure it on our webui?
It doens´t work.
See above: " The issue is, that under “Network” -> “Interfaces”, no IP is assigned to “WWAN”, despite being set to “DHCP Client”"

If so, I believe that you are trying to configure a WISP repeater, not a client.

Yes, just tried it to be sure. Reset your B1300 to factory conditions, then follow: Internet Settings - GL.iNet Docs

Don’t worry about the details of the Blue and Black router in the figure. That is the hotel’s router which you do not control, but you can connect to. You will connect your phone to the B1300 by connecting to that SSID (pw=goodlife), then use your phone browser to browse to 192.168.8.1. Then, “Click Repeater tab in Internet Settings , the router will search for the available Wi-Fi networks automatically. Then, choose a SSID [of the hotel’s wireless] and enter its password [blank if there is none]. Choose WISP in mode and click Submit .”

After a minute or two, your B1300 will be connected to the hotel’s wifi, but your phone will be safely on the LAN side of the firewall. You can then connect multiple devices to the B1300. If you wish, before you start connecting your devices, you can change the default wireless password for your private wireless network, either in luci or using the GL-inet interface.

If you plan on using the B1300 in this mode (Repeater WISP), I suggest you use the default GL-inet firmware, as it makes the setup of a WISP Repeater trivial (as shown above).