Take the 2-minute tour ×
Ask Ubuntu is a question and answer site for Ubuntu users and developers. It's 100% free, no registration required.

I want to connect to a free open wifi, like Starbucks, but I don't want a full-fledged desktop gui like Unity or GNOME. How can I do this via command-line (pretending my install base is Ubuntu Server + drivers for my wifi card)?

share|improve this question
    
add comment

2 Answers 2

First, run ifconfig wlan0 up. This will enable wireless. You won't get any feedback unless there's a problem. Next, run iwlist wlan0 scan to scan for nearby wireless networks. Once you have looked at the output and know which wireless network you want to connect to, run iwconfig wlan0 essid NETWORK_ID key s:WIRELESS_KEY, replacing NETWORK_ID with the name (essid) of the nework and WIRELESS_KEY with the network passcode. Hope that helps!

share|improve this answer
add comment

you can use iwconfig. I have done it with wep. normally this is enough

iwconfig ethX essid ESSID key open XXXXXXXXXX

and then call the dhcp client with dhclient3 ethx

I'm doing this from memory. But check the manual of iwconfig for more info

man iwconfig

share|improve this answer
add comment

Your Answer

 
discard

By posting your answer, you agree to the privacy policy and terms of service.

Not the answer you're looking for? Browse other questions tagged or ask your own question.