hostapd_cli will not connect
Michael Baird
Michael.Baird at ecs.vuw.ac.nz
Sun Feb 18 13:59:44 PST 2018
To get hostapd_cli to connect, in the hostapd.conf you need to specify
the option 'ctrl_interface=<path to hostapd socket>'.
from hostapd/hostapd.conf
# Interface for separate control program. If this is specified, hostapd
# will create this directory and a UNIX domain socket for listening to requests
# from external programs (CLI/GUI, etc.) for status information and
# configuration. The socket file will be named based on the interface name, so
# multiple hostapd processes/interfaces can be run at the same time if more
# than one interface is used.
# /var/run/hostapd is the recommended directory for sockets and by default,
# hostapd_cli will use it when trying to connect with hostapd.
ctrl_interface=/var/run/hostapd
I don't follow the rest of your problem.
Michael.
On 19/02/18 10:24, A wrote:
> hostapd_cli will not connect although my android does. My HP Envy
> 5530 printer will not connect either and that's the most important
> issue. ubuntu 16.04 running as an AP, router, firewall, dhcp server,
> DNS and more.
>
> A google search revealed very little of value.
>
> Thank you in advance!!
>
> root at yellow:/etc/hostapd# hostapd_cli
> hostapd_cli v2.4
> Copyright (c) 2004-2015, Jouni Malinen <j at w1.fi> and contributors
>
> This software may be distributed under the terms of the BSD license.
> See README for more details.
>
>
> Could not connect to hostapd - re-trying
>
> ^C
> root at yellow:/etc/hostapd#
> root at yellow:/etc/hostapd# hostapd_cli interface
> Failed to connect to hostapd - wpa_ctrl_open: No such file or directory
>
> root at yellow:/etc/hostapd# tail /var/log/syslog
>
> Feb 18 12:07:04 yellow hostapd: wlp2s0: STA 20:e8:17:02:02:3a WPA:
> group key handshake completed (RSN)
> Feb 18 12:07:04 yellow hostapd: wlp2s0: STA d0:5b:a8:35:28:6e WPA:
> group key handshake completed (RSN)
> Feb 18 12:07:04 yellow hostapd: wlp2s0: STA 24:0d:c2:1a:9b:d5 WPA:
> group key handshake completed (RSN)
> Feb 18 12:07:21 yellow dhcpd[14224]: DHCPREQUEST for 10.1.2.21
> (10.1.2.1) from 24:0d:c2:1a:9b:d5 via wlp2s0
> Feb 18 12:07:21 yellow dhcpd[14224]: DHCPACK on 10.1.2.21 to
> 24:0d:c2:1a:9b:d5 (android-4798b324d3a034e5) via wlp2s0
> Feb 18 12:07:21 yellow dhcpd[14224]: reuse_lease: lease age 0 (secs)
> under 25% threshold, reply with unaltered, existing lease
> Feb 18 12:07:21 yellow dhcpd[14224]: DHCPREQUEST for 10.1.2.21
> (10.1.2.1) from 24:0d:c2:1a:9b:d5 (android-4798b324d3a034e5) via wlp2s0
> Feb 18 12:07:21 yellow dhcpd[14224]: DHCPACK on 10.1.2.21 to
> 24:0d:c2:1a:9b:d5 via wlp2s0
> Feb 18 12:09:01 yellow CRON[26619]: (root) CMD ( [ -x
> /usr/lib/php/sessionclean ] && /usr/lib/php/sessionclean)
> Feb 18 12:15:53 yellow dhcpd[14224]: DHCPREQUEST for 10.1.2.2 from
> 20:e8:17:02:02:3a via wlp2s0
> Feb 18 12:15:53 yellow dhcpd[14224]: DHCPACK on 10.1.2.2 to
> 20:e8:17:02:02:3a via wlp2s0
> Feb 18 12:17:01 yellow CRON[26719]: (root) CMD ( cd / && run-parts
> --report /etc/cron.hourly)
> Feb 18 12:17:04 yellow hostapd: wlp2s0: STA 20:e8:17:02:02:3a WPA:
> group key handshake completed (RSN)
> Feb 18 12:17:04 yellow hostapd: wlp2s0: STA d0:5b:a8:35:28:6e WPA:
> group key handshake completed (RSN)
> Feb 18 12:17:04 yellow hostapd: wlp2s0: STA 24:0d:c2:1a:9b:d5 WPA:
> group key handshake completed (RSN)
> Feb 18 12:27:04 yellow hostapd: wlp2s0: STA 20:e8:17:02:02:3a WPA:
> group key handshake completed (RSN)
> Feb 18 12:27:04 yellow hostapd: wlp2s0: STA d0:5b:a8:35:28:6e WPA:
> group key handshake completed (RSN)
> Feb 18 12:27:04 yellow hostapd: wlp2s0: STA 24:0d:c2:1a:9b:d5 WPA:
> group key handshake completed (RSN)
>
> root at yellow:/etc/hostapd# cat hostapd.conf
> interface=wlp2s0
> driver=nl80211
> hw_mode=g
> channel=9
> ieee80211d=1
> country_code=US
> ieee80211n=1
> wmm_enabled=0
> macaddr_acl=0
> ignore_broadcast_ssid=0
> ssid=Psst
> auth_algs=3
> wpa=2
> wpa_key_mgmt=WPA-PSK WPA-EAP
> wpa_pairwise=TKIP
> rsn_pairwise=CCMP
> wpa_passphrase=XXXXXXXXXXX
>
>
> root at yellow:/etc/hostapd# systemctl status hostapd.service
> ● hostapd.service - LSB: Advanced IEEE 802.11 management daemon
> Loaded: loaded (/etc/init.d/hostapd; *bad*; vendor preset: enabled)
> Active: active (running) since Fri 2018-02-09 13:47:02 PST; 1 weeks
> 1 days ago
> Docs: man:systemd-sysv-generator(8)
> CGroup: /system.slice/hostapd.service
> └─12379 /usr/sbin/hostapd -B -P /run/hostapd.pid
> /etc/hostapd/hostapd.conf
>
> Feb 18 12:17:04 yellow hostapd[12379]: wlp2s0: STA 24:0d:c2:1a:9b:d5
> WPA: group key handshake comple
> Feb 18 12:27:04 yellow hostapd[12379]: wlp2s0: STA 20:e8:17:02:02:3a
> WPA: group key handshake comple
> Feb 18 12:27:04 yellow hostapd[12379]: wlp2s0: STA d0:5b:a8:35:28:6e
> WPA: group key handshake comple
> Feb 18 12:27:04 yellow hostapd[12379]: wlp2s0: STA 24:0d:c2:1a:9b:d5
> WPA: group key handshake comple
> Feb 18 12:37:04 yellow hostapd[12379]: wlp2s0: STA 20:e8:17:02:02:3a
> WPA: group key handshake comple
> Feb 18 12:37:04 yellow hostapd[12379]: wlp2s0: STA d0:5b:a8:35:28:6e
> WPA: group key handshake comple
> Feb 18 12:37:04 yellow hostapd[12379]: wlp2s0: STA 24:0d:c2:1a:9b:d5
> WPA: group key handshake comple
> Feb 18 12:47:04 yellow hostapd[12379]: wlp2s0: STA 20:e8:17:02:02:3a
> WPA: group key handshake comple
> Feb 18 12:47:04 yellow hostapd[12379]: wlp2s0: STA d0:5b:a8:35:28:6e
> WPA: group key handshake comple
> Feb 18 12:47:04 yellow hostapd[12379]: wlp2s0: STA 24:0d:c2:1a:9b:d5
> WPA: group key handshake comple
>
>
>
>
>
>
> _______________________________________________
> Hostap mailing list
> Hostap at lists.infradead.org
> http://lists.infradead.org/mailman/listinfo/hostap
>
More information about the Hostap
mailing list