Gentoo Forums
Gentoo Forums
Gentoo Forums
Quick Search: in
Can't get connected with wireless card
View unanswered posts
View posts from last 24 hours

 
Reply to topic    Gentoo Forums Forum Index Networking & Security
View previous topic :: View next topic  
Author Message
relvar
n00b
n00b


Joined: 03 Oct 2014
Posts: 6

PostPosted: Fri Oct 03, 2014 4:32 am    Post subject: Can't get connected with wireless card Reply with quote

Hello all,

First post here. I love Gentoo and while it's been great as a wired music server, I now want to enable wireless to reduce cable clutter.

Problem: wpa_supplicant won't connect with the wireless card I'm using, a TL-WN951N. Perhaps it is yet another problem with wpa_supplicant, of which I've seen a few posts but nothing resolved my situation.


My card has an Atheros chip and supports 64/128 bit WEP, WPA-PSK/WPA2-PSK. (It has worked before with other distros on another network).

My router is broadcasting my SSID and is using WPA2-Personal with AES on the 2.4Ghz frequency. I have no problem connecting other devices to it.

I've been following the guidebook and wiki for wpa_supplicant, but to no avail.

My kernel has

Code:
 grep CONFIG_PACKET /usr/src/linux/.config
CONFIG_PACKET=y
# CONFIG_PACKET_DIAG is not set


/etc/conf.d/net

Code:

##---------- wireless ----------------------

# Prefer wpa_supplicant over wireless-tools
modules="wpa_supplicant"

# It's important that we tell wpa_supplicant which driver we should
# be using as it's not very good at guessing yet
wpa_supplicant_wlp5s9="-Dnl80211"

config_wlp5s9="dhcp"


I have this driver built-in to the kernel.

/etc/wpa_supplicant/wpa_supplicant.conf

Code:

ctrl_interface=/var/run/wpa_supplicant
update_config=1

network={
        ssid="myssid"
        #psk="password"
        psk=passwordscramble
        proto=WPA2
        key_mgmt=WPA-PSK
}


psk scrambled in hex of course, provided by wpa_passphrase

Code:

$ sudo /etc/init.d/net.wlp5s9 restart
 * Bringing down interface wlp5s9
 *   Removing addresses
 *     Stopping wpa_cli on wlp5s9 ...                                                                                                                 [ ok ]
 *     Stopping wpa_supplicant on wlp5s9 ...                                                                                                          [ ok ]
 * Bringing up interface wlp5s9
 *   Starting wpa_supplicant on wlp5s9 ...
Successfully initialized wpa_supplicant                                                                                                               [ ok ]
 *   Starting wpa_cli on wlp5s9 ...                                                                                                                   [ ok ]
 *   Backgrounding ... ...
 * WARNING: net.wlp5s9 has started, but is inactive


Code:

$ sudo ifconfig wlp5s9
wlp5s9: flags=4099<UP,BROADCAST,MULTICAST>  mtu 1500
        ether f8:d1:11:89:76:ac  txqueuelen 1000  (Ethernet)
        RX packets 0  bytes 0 (0.0 B)
        RX errors 0  dropped 0  overruns 0  frame 0
        TX packets 0  bytes 0 (0.0 B)
        TX errors 0  dropped 0 overruns 0  carrier 0  collisions 0


Code:

$ sudo wpa_cli status
Selected interface 'wlp5s9'
wpa_state=DISCONNECTED
p2p_device_address=f8:d1:11:89:76:ac
address=f8:d1:11:89:76:ac


This is likely obvious considering the above.

Code:

$ sudo dhcpcd wlp5s9
dhcpcd[21827]: control_open: Connection refused
dhcpcd[21827]: version 6.4.7 starting
dhcpcd[21827]: wlp5s9: adding address fe80::5767:bccc:b167:3f04
dhcpcd[21827]: wlp5s9: waiting for carrier
dhcpcd[21827]: timed out
dhcpcd[21827]: allowing 8 seconds for IPv4LL timeout
dhcpcd[21827]: timed out
dhcpcd[21827]: exited

Enabled BBCode, given that tags were in use. -- desultory
Back to top
View user's profile Send private message
Roman_Gruber
Advocate
Advocate


Joined: 03 Oct 2006
Posts: 3806
Location: Austro Bavaria

PostPosted: Fri Oct 03, 2014 8:43 am    Post subject: Reply with quote

well i can show you my way how to use wpa_supplicant...


Assumption:

*) kernel configured and booted that kernel
*) basic network knowledge about wireless lan
*) basic bash knowledge
*) have a correct /etc/wpa_supplicant.conf (right spot for this file and right settings, try around different settings as explained on the web until it works)

ifconfig -a
ifconfig eth0 off
repeat this for any other network device
ifconfig wlan0 up



man wpa_supplicant or wpa_supplicant --help

run as help says but with your needed settings, example:
wpa_supplicant -Dnl80211 -iwlan0 -c/etc/wpa_supplicant.conf

dhcp wlan0

should work. I did write it down how i did it a while ago, you need to probe around and read the howtos. Gentoo wiki and other wikis or howtos are a good starting point.

please note, router + kernel settings + binary wlan driver + right wpa_supplicant conf file + right useflags for your box + right invocation of the commands should work
Back to top
View user's profile Send private message
relvar
n00b
n00b


Joined: 03 Oct 2014
Posts: 6

PostPosted: Fri Oct 03, 2014 3:18 pm    Post subject: Reply with quote

Thanks, tw04l124. I will keep trying these things.
Back to top
View user's profile Send private message
relvar
n00b
n00b


Joined: 03 Oct 2014
Posts: 6

PostPosted: Sat Oct 04, 2014 1:08 am    Post subject: solved Reply with quote

I relied on a reboot and wpa_cli, following Arch's wiki

https://wiki.archlinux.org/index.php/WPA_supplicant

I think I had several instances of wpa_supplicant running and thus couldn't make sense of the scan output.

Anyway, problem solved!
Back to top
View user's profile Send private message
ShanaXXII
Apprentice
Apprentice


Joined: 29 Jun 2014
Posts: 281
Location: Canada

PostPosted: Sat Oct 04, 2014 11:32 pm    Post subject: Reply with quote

My wpa_supplicant.conf is different. See if this configuration works
Code:
ctrl_interface=DIR=/run/wpa_supplicant GROUP=wheel

ap_scan=1

network={
   ssid="Wifi_name"
   proto=WPA2
   psk="wifi_password"
   priority=2
}
Back to top
View user's profile Send private message
Display posts from previous:   
Reply to topic    Gentoo Forums Forum Index Networking & Security All times are GMT
Page 1 of 1

 
Jump to:  
You cannot post new topics in this forum
You cannot reply to topics in this forum
You cannot edit your posts in this forum
You cannot delete your posts in this forum
You cannot vote in polls in this forum