I'm starting to use the wmii windows manager and I want certain pieces of information to display on a status bar. If I were to want to display the ESSID for the network, I would have to find it through some shell command. I already know I can find the ESSID by issuing the command

iwconfig wlan0 | grep -o "ESSID:\"[a-zA-Z]*\""

but that requires you to be a super user?

So my questions are:

  1. how can I find the ESSID without any superuser privileges?

  2. is there some terminal command which gives me some gui for selecting the wireless connections? Or do I always have to do something like

    iwconfig wlan0 essid X key Y


I'm looking for some simple interface like the one that exists on gnome.

edit: i messed up the regex

1 Answer 1


I think that the permissions required to get the wireless information depends on the driver. When I was using the wl driver non-root users could not get information using iwconfig, but I'm now using the b43 driver and non-root users can. I don't know of anywhere else where the ESSID is available. Your options are to either use sudo to give non-root users permission to run iwconfig wlan0 without a password, or setup a crontab which regularly saves the output of iwconfig wlan0 to a file which users can access.

If you want to use a GUI to manage the wireless interface you'll pretty much have to run NetworkManager and use one of the GUI clients, like the GNOME system tray applet.

If you want to manage the wireless interface from the CLI you have two options. You can either run NetworkManager and use the CLI client, cnetworkmanager, or you can run wpa_supplicant from /etc/network/interfaces. To do that, add the following to /etc/network/interfaces:

auto wlan0
iface wlan0 inet dhcp
    wpa-conf /etc/wpa_supplicant/wpa_supplicant.conf

Then configure your networks in wpa_supplicant.conf, which will look something like this:


You can also configure networks with WEP keys, but you really shouldn't be using WEP. If you need to select between multiple networks available in the same location, you can use wpa_cli (although you sometimes have to manually trigger dhclient to do DHCP).

You must log in to answer this question.

Not the answer you're looking for? Browse other questions tagged .