5

Im trying to connect to my Wireless router but not having any luck. Could someone give me a few pointers?

skay@raspberrypi ~ $ sudo wpa_supplicant -iwlan0 -c/etc/wpa_supplica/wpa_supplicant.conf
rfkill: Cannot open RFKILL control device
ioctl[SIOCSIWENCODEEXT]: Invalid argument
ioctl[SIOCSIWENCODEEXT]: Invalid argument
wlan0: Trying to associate with xx:xx:xx:xx:xx:xx (SSID='Cerberus' freq=2462 MHz)
wlan0: Associated with 00:00:00:00:00:00
wlan0: CTRL-EVENT-DISCONNECTED bssid=xx:xx:xx:xx:xx:xx reason=0

This is my wpa_supplicants config:

ctrl_interface=DIR=/var/run/wpa_supplicant GROUP=netdev
update_config=1
ap_scan=1 


network={
    ssid="Cerberus"
    #psk="XXXXXX"
    psk=XXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXX
}
3
sudo -H gedit /etc/wpa_supplicant.conf

Inside the file add the following for WPA2

ctrl_interface=/var/run/wpa_supplicant
network={
        ssid="ESSID_IN_QUOTES"
        psk="ASCII PSK Password in Quotes"
        key_mgmt=WPA-PSK
        proto=RSN WPA
        pairwise=CCMP TKIP
        group=CCMP TKIP
}

My Example : ssid="A-B-C-D" & Password is = psk="abc12345"

Then Remove network-manager-gnome

sudo apt-get purge network-manager-gnome

Setting the Wireless Interface to Connect at Boot

sudo -H gedit /etc/rc.local

Add the following lines

ifconfig eth0 down
ifconfig wlan0 down
dhclient -r wlan0
iwconfig wlan0 essid "A-B-C-D"
iwconfig wlan0 mode Managed
ifconfig wlan0 up
dhclient wlan0

Then restart networking... I did a reboot

Note: I have already configured my router for Static IP (Reserved IP from Router) & DNS

For more help see this post on Ubuntu Forums

| improve this answer | |
  • Hi Insafian, thanks for the answer, Can you explain me this "ASCII PSK Password in Quotes" from the file /etc/wpa_supplicant.. Do I need wpa_passphrase of my network here? – Mujtaba Haider Nov 13 '13 at 3:34
  • Didn't understand ... – Qasim Nov 13 '13 at 11:14

Your Answer

By clicking “Post Your Answer”, you agree to our terms of service, privacy policy and cookie policy

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