Enable wifi-iface needed?

Hello,

is this required for OpenWrt to enable WiFi (among enabling wifi-device)?

uci set wireless.@wifi-iface[0].disabled='0'

Was this every required?

If you're talking about enabling the wifi from a default config -- yes, it is required and has been for a very long time. Wifi is disabled by default because if it were enabled, it would be a security vulnerability (i.e. a known SSID + no password or a known password).

You should set the following from the default config:

  • country code
  • SSID (default is OpenWrt; it is recommended that you rename it, although this is optional)
  • Encryption type (default is open/none; it is highly recommended that you select WPA2 or WPA3 encrpytion)
  • Passphrase (based on the above encryption option)
  • and then enable wifi.

Hi, thank you for your reply. Maybe I should add context: The OpenWrt Firmware Selector - #570 by basyirstar

This one is obvious to enable WiFi:

uci set wireless.@wifi-device[0].disabled='0'

But I do not know about wifi-iface. Was that ever something that had to be done?

As far as I can trace the code, hostapd disables only interfaces, not devices:

@vgaetera interesting

I wonder why this wiki page advises to set it then:

That's a page created 3.5 years ago:
Creating a wiki page - #3 by izi
It may require optimization and scaling.

1 Like

@izi can you give us some information if enabling wifi-device was ever needed?

As far as I can remember; after the first boot in an unmodified image, when wifi is getting enabled (by the standard openwrt mechanism) those two lines are added to the config.

That's how openwrt does it. So to simulate it I recommend to replicate this behaviour.

1 Like

That line is actually only for station modus (when the router connects to somewhere else).

This topic was automatically closed 10 days after the last reply. New replies are no longer allowed.