couldn't connect to hostapd - re-trying

Jouni Malinen j at
Fri Jun 24 08:17:29 PDT 2016

On Thu, Jun 23, 2016 at 09:11:35PM +0430, Aniss Maghsoudlou wrote:
> I'm new to hostapd and now I'm trying to run hostapd_cli which after 2
> days of tracing the error, now I know that its problem is in
> wpa_ctrl_open2 when it's going to connect the socket. connect return
> -1 and sets the errno to 111 which is apparently connection refused.
> to reach where I'm now, I have made a directory named hostapd in
> var/run and made an empty file name aniss.tmp and now running the cli
> using this command: sudo ./hostapd_cli -s /var/run/hostapd. before
> doing these, I had some other errors.
> Btw, it's still showing me the error:
> couldn't connect to hostapd - re-trying

How have you configured hostapd to open the control interface? Is the
socket file in /var/run/hostapd after the hostapd process is started?

Jouni Malinen                                            PGP id EFC895FA

More information about the Hostap mailing list