Gentoo Forums
Gentoo Forums
Gentoo Forums
Quick Search: in
Problem when i use wpa_cli command
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
Fulgurance
Veteran
Veteran


Joined: 15 Feb 2017
Posts: 1200

PostPosted: Thu Mar 02, 2017 11:00 am    Post subject: Problem when i use wpa_cli command Reply with quote

Hello, finally my PC come back to SAV and I remade my complete installation of gentoo and I encounter a problem when I want to connect in wifi with wpa_cli:
Code:
wpa_cli
wpa_cli v2.6
Copyright (c) 2004-2016, Jouni Malinen <j@w1.fi> and contributors

This software may be distributed under the terms of the BSD license.
See README for more details.



Interactive mode

Could not connect to wpa_supplicant: (nil) - re-trying
Back to top
View user's profile Send private message
khayyam
Watchman
Watchman


Joined: 07 Jun 2012
Posts: 6227
Location: Room 101

PostPosted: Thu Mar 02, 2017 11:21 am    Post subject: Reply with quote

Fulgurance ...

for wpa_cli to function there has to be a running wpa_supplicant, and the user has to be able to access the wpa_supplicant 'ctrl_interface', for this you need the following in wpa_supplicant.conf:

/etc/wpa_supplicant/wpa_supplicant.conf:
ctrl_interface=DIR=/run/wpa_supplicant GROUP=wheel

This will allow users in the 'wheel' group to access ctrl_interface.

Though I can't see from the above who is running wpa_cli I am assuming the user either isn't in the group specified, or GROUP isn't defined, if this isn't the case then it may be that wpa_supplicant isn't configured correctly (ie, the '-i<interface>, or '-D<driver>') so you should provide details of that confguration.

HTH & best ... khay
Back to top
View user's profile Send private message
Fulgurance
Veteran
Veteran


Joined: 15 Feb 2017
Posts: 1200

PostPosted: Fri Mar 03, 2017 12:28 am    Post subject: Reply with quote

I did that but no change
Back to top
View user's profile Send private message
khayyam
Watchman
Watchman


Joined: 07 Jun 2012
Posts: 6227
Location: Room 101

PostPosted: Fri Mar 03, 2017 7:01 am    Post subject: Reply with quote

Fulgurance wrote:
I did that but no change

Fulgurance ... in which case you'll have to do as I suggested, and provide the configuration (ie, /etc/conf.d/wpa_supplicant or whatever parameters your passing to wpa_supplicant, and various other information relating to your wireless device/driver)

Code:
# lspci -nnkv | awk -v RS= '/(Ether|Network|802.11)/{print $0 "\n"}'
# egrep '(WEXT|(MAC|CFG|NL)80211)' /usr/src/linux/.config
# modinfo <your_wireless_driver>
# dmesg | grep -i firmware

You can also run wpa_supplicant in 'debug' mode, and provide (via pastebin) the log:

Code:
# wpa_supplicant -B -i<wireless_interface> -Dnl80211 -dd -f /var/log/wpa_supplicant.log
# su - <username>
$ wpa_cli -i<interface_name> status
$ wgetpaste /var/log/wpa_supplicant.log

best ... khay
Back to top
View user's profile Send private message
Fulgurance
Veteran
Veteran


Joined: 15 Feb 2017
Posts: 1200

PostPosted: Mon Mar 06, 2017 7:37 pm    Post subject: Reply with quote

Sorry but I completely forgot to answer xD

I am busy right now, I take an apartment and I have plenty of things to do

Code:
(chroot) livecd / # lspci -nnkv | awk -v RS= '/(Ether|Network|802.11)/{print $0 "\n"}'
lspci: Unable to load libkmod resources: error -12
3d:00.0 Ethernet controller [0200]: Qualcomm Atheros Device [1969:e0a1] (rev 10)
        Subsystem: Micro-Star International Co., Ltd. [MSI] Device [1462:11ac]
        Flags: bus master, fast devsel, latency 0, IRQ 133
        Memory at df400000 (64-bit, non-prefetchable) [size=256K]
        I/O ports at d000 [size=128]
        Capabilities: [40] Power Management version 3
        Capabilities: [58] Express Endpoint, MSI 00
        Capabilities: [c0] MSI: Enable+ Count=1/16 Maskable+ 64bit+
        Capabilities: [d8] MSI-X: Enable- Count=16 Masked-
        Capabilities: [100] Advanced Error Reporting
        Capabilities: [180] Device Serial Number ff-80-14-e2-4c-cc-6a-ff
        Kernel driver in use: alx

3e:00.0 Network controller [0280]: Qualcomm Atheros QCA6174 802.11ac Wireless Network Adapter [168c:003e] (rev 32)
        Subsystem: Bigfoot Networks, Inc. QCA6174 802.11ac Wireless Network Adapter [1a56:1535]
        Flags: bus master, fast devsel, latency 0, IRQ 130
        Memory at df200000 (64-bit, non-prefetchable) [size=2M]
        Capabilities: [40] Power Management version 3
        Capabilities: [50] MSI: Enable+ Count=1/8 Maskable+ 64bit-
        Capabilities: [70] Express Endpoint, MSI 00
        Capabilities: [100] Advanced Error Reporting
        Capabilities: [148] Virtual Channel
        Capabilities: [168] Device Serial Number 00-00-00-00-00-00-00-00
        Capabilities: [178] Latency Tolerance Reporting
        Capabilities: [180] L1 PM Substates
        Kernel driver in use: ath10k_pci


Code:
(chroot) livecd / # egrep '(WEXT|(MAC|CFG|NL)80211)' /usr/src/linux/.config
CONFIG_CFG80211=y
# CONFIG_NL80211_TESTMODE is not set
# CONFIG_CFG80211_DEVELOPER_WARNINGS is not set
CONFIG_CFG80211_DEFAULT_PS=y
# CONFIG_CFG80211_DEBUGFS is not set
# CONFIG_CFG80211_INTERNAL_REGDB is not set
CONFIG_CFG80211_CRDA_SUPPORT=y
# CONFIG_CFG80211_WEXT is not set
CONFIG_MAC80211=y
CONFIG_MAC80211_HAS_RC=y
CONFIG_MAC80211_RC_MINSTREL=y
CONFIG_MAC80211_RC_MINSTREL_HT=y
# CONFIG_MAC80211_RC_MINSTREL_VHT is not set
CONFIG_MAC80211_RC_DEFAULT_MINSTREL=y
CONFIG_MAC80211_RC_DEFAULT="minstrel_ht"
# CONFIG_MAC80211_MESH is not set
CONFIG_MAC80211_LEDS=y
# CONFIG_MAC80211_DEBUGFS is not set
# CONFIG_MAC80211_MESSAGE_TRACING is not set
# CONFIG_MAC80211_DEBUG_MENU is not set
CONFIG_MAC80211_STA_HASH_MAX_SIZE=0
# CONFIG_MAC80211_HWSIM is not set


Code:
(chroot) livecd / # dmesg | grep -i firmware
[    0.105707] [Firmware Bug]: ACPI: BIOS _OSI(Linux) query ignored
[    1.812272] psmouse serio1: elantech: assuming hardware version 4 (with firmware version 0x4a5f01)
[   10.206100] Bluetooth: hci0: QCA: patch rome 0x302 build 0x138, firmware rome 0x302 build 0x111
[   10.329508] ath10k_pci 0000:3e:00.0: Direct firmware load for ath10k/cal-pci-0000:3e:00.0.bin failed with error -2
[   70.330773] ath10k_pci 0000:3e:00.0: Direct firmware load for ath10k/QCA6174/hw3.0/firmware-5.bin failed with error -2
[  130.330734] ath10k_pci 0000:3e:00.0: could not fetch firmware file 'ath10k/QCA6174/hw3.0/firmware-5.bin': -11
[  130.406585] ath10k_pci 0000:3e:00.0: firmware ver WLAN.RM.2.0-00180-QCARMSWPZ-1 api 4 features wowlan,ignore-otp,no-4addr-pad crc32 75dee6c5
Back to top
View user's profile Send private message
khayyam
Watchman
Watchman


Joined: 07 Jun 2012
Posts: 6227
Location: Room 101

PostPosted: Mon Mar 06, 2017 11:36 pm    Post subject: Reply with quote

Fulgurance wrote:
Code:
[   10.329508] ath10k_pci 0000:3e:00.0: Direct firmware load for ath10k/cal-pci-0000:3e:00.0.bin failed with error -2
[   70.330773] ath10k_pci 0000:3e:00.0: Direct firmware load for ath10k/QCA6174/hw3.0/firmware-5.bin failed with error -2
[  130.330734] ath10k_pci 0000:3e:00.0: could not fetch firmware file 'ath10k/QCA6174/hw3.0/firmware-5.bin': -11

Fulgurance ... there is your problem, I'm not sure what the error codes mean but it looks as though you're either missing firmware or the driver is builtin (=y) and no CONFIG_EXTRA_FIRMWARE is used. If the later then either add the firmware to the kernel or build as a module (=m).

HTH & best ... khay
Back to top
View user's profile Send private message
Hu
Moderator
Moderator


Joined: 06 Mar 2007
Posts: 21633

PostPosted: Tue Mar 07, 2017 2:31 am    Post subject: Reply with quote

Based on the source of that driver, it looks like those are standard errno codes, albeit following the kernel's quirky pattern of negation. If so, then -2 is ENOENT (No such file or directory) and -11 is EAGAIN (Resource temporarily unavailable).
Back to top
View user's profile Send private message
Fulgurance
Veteran
Veteran


Joined: 15 Feb 2017
Posts: 1200

PostPosted: Tue Mar 07, 2017 10:02 am    Post subject: Reply with quote

I already had this problem under archlinux, they are missing drivers for the QCA6174 (Qualcom Atheros), but normally the wifi worked anyway!
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