~alpine/users

3 3

[alpine-user] Launching udhcpc through wpa_cli actions

Gert de Best <bmartes@hotmail.com>
Details
Message ID
<AM6PR0602MB359263D6EC2A893E121EB1E4B1800@AM6PR0602MB3592.eurprd06.prod.outlook.com>
Sender timestamp
1547480318
DKIM signature
missing
Download raw message
Hi All,

The wiki says:

With the above configuration, udhcpc will only run once at boot. If the Wifi isn't available then, or the network changes in between, it needs to be notified. This is done through the wpa_cli action script in /etc/wpa_supplicant/wpa_cli.sh

rc-update add wpa_cli boot

But when I do this I get the next error messages when rebooting:

Failed to connect to non-global ctrl_ifname: (nill) error: No such file or directory

  *   Start-stop-deamon: failed to start /sbin/wpa_cli
  *   Failed to start wpa_cli
  *   Error: wpa_cli failed to start

Can anyone point me in the right direction to fix this?

Thanks in advance
Gert.
PICCORO McKAY Lenz <mckaygerhard@gmail.com>
Details
Message ID
<CALci+FRdFj7A7erQVh_iFTKPLjo8t2F0Ak5KaEcPmBA5RHHh9g@mail.gmail.com>
In-Reply-To
<AM6PR0602MB359263D6EC2A893E121EB1E4B1800@AM6PR0602MB3592.eurprd06.prod.outlook.com> (view parent)
Sender timestamp
1547480900
DKIM signature
missing
Download raw message
i have also some related problems configuring my wifi.. in my case
passwordless ssid wifi!

at cli when i try to use the device said to me "device busy", network
manager can scan but said "device not ready"

El lun., 14 de ene. de 2019 a la(s) 11:38, Gert de Best (bmartes@hotmail.com)
escribió:

> Hi All,
>
> The wiki says:
>
> With the above configuration, udhcpc will only run once at boot. If the
> Wifi isn't available then, or the network changes in between, it needs to
> be notified. This is done through the wpa_cli action script in
> /etc/wpa_supplicant/wpa_cli.sh
>
> rc-update add wpa_cli boot
> But when I do this I get the next error messages when rebooting:
>
> Failed to connect to non-global ctrl_ifname: (nill) error: No such file or
> directory
>
>    - Start-stop-deamon: failed to start /sbin/wpa_cli
>    - Failed to start wpa_cli
>    - Error: wpa_cli failed to start
>
> Can anyone point me in the right direction to fix this?
>
> Thanks in advance
> Gert.
>
Cosmo Borsky <me@cosmoborsky.com>
Details
Message ID
<6e05cd18-5022-a6c8-b8bf-5b593d767281@cosmoborsky.com>
In-Reply-To
<CALci+FRdFj7A7erQVh_iFTKPLjo8t2F0Ak5KaEcPmBA5RHHh9g@mail.gmail.com> (view parent)
Sender timestamp
1547490902
DKIM signature
missing
Download raw message
Hi Gert,

Try adding the following to the top of your
`/etc/wpa_supplicant/wpa_supplicant.conf`
```
ctrl_interface=DIR=/var/run/wpa_supplicant GROUP=wheel
```

You may also configure `udhcpd_opts` in your `/etc/network/interfaces`
file like so:
`/etc/network/interfaces`
```
# ...
iface wlan0 inet dhcp
    udhcpc_opts -t 0 -T 10 -A 20 -S &
```

The `udhcpc_opts` parameters were taken from the following post:
https://unix.stackexchange.com/a/285930

Piccoro,
As for passwordless wifi, try setting `key_mgmt=NONE` in your
wpa_supplicant network entry.

On 1/14/19 10:48 AM, PICCORO McKAY Lenz wrote:
> i have also some related problems configuring my wifi.. in my case
> passwordless ssid wifi!
>
> at cli when i try to use the device said to me "device busy", network
> manager can scan but said "device not ready"
>
> El lun., 14 de ene. de 2019 a la(s) 11:38, Gert de Best
> (bmartes@hotmail.com <bmartes@hotmail.com>) escribió:
>
>
>           Hi All,
>
>
>           The wiki says:
>
>     With the above configuration, udhcpc will only run once at boot.
>     If the Wifi isn't available then, or the network changes in
>     between, it needs to be notified. This is done through the wpa_cli
>     action script in /etc/wpa_supplicant/wpa_cli.sh
>
>     rc-update add wpa_cli boot
>
>     But when I do this I get the next error messages when rebooting:
>
>     Failed to connect to non-global ctrl_ifname: (nill) error: No such
>     file or directory
>
>       * Start-stop-deamon: failed to start /sbin/wpa_cli
>       * Failed to start wpa_cli
>       * Error: wpa_cli failed to start
>
>     Can anyone point me in the right direction to fix this?
>
>     Thanks in advance
>     Gert.
>
Chloe Kudryavtsev <toast@toastin.space>
Details
Message ID
<99c1b250-4700-0b25-bde2-2420b2320391@toastin.space>
In-Reply-To
<AM6PR0602MB359263D6EC2A893E121EB1E4B1800@AM6PR0602MB3592.eurprd06.prod.outlook.com> (view parent)
Sender timestamp
1547515018
DKIM signature
missing
Download raw message
On 1/14/2019 10:38 AM, Gert de Best wrote:
> Hi All,

Heya!

> The wiki says:
> With the above configuration, udhcpc will only run once at boot. If the Wifi isn't available then, or the network changes in between, it needs to be notified. This is done through the wpa_cli action script in /etc/wpa_supplicant/wpa_cli.sh

There are currently many issues with wpa_supplicant-related init scripts.

> Failed to connect to non-global ctrl_ifname: (nill) error: No such file or directory

One of them is what wpa_cli and wpa_supplicant actually do not interact, 
and there's no other init script to run.

> Can anyone point me in the right direction to fix this?

You have a couple of options:
1. You can wait until I (or someone else) get(s) around to fixing this, 
and the fix gets merged (though the situation will likely look different 
at that point).
2. You can write your own init scripts (and/or configure the existing 
ones heavily) to provide the mentioned functionality.
3. Use a smarter network manager (not necessarily NetworkManager in 
particular, but any sort of non-constant wireless connection usually 
benefits from one). In this scenario, I'm told connman is highly 
recommended for CLI usage.

The issue with 1 is that that wait may take a long time (for instance, I 
am currently working on getting Alpine's user (and developer) official 
documentation up from 0 to full, which will take a while).

The issue with 2 is you need to thoroughly understand wireless 
networking (e.g copy pasting something someone on the ML writes may 
work, or it may not, and you'll need the knowledge regardless in the 
latter scenario, to understand what went wrong).

The issue with 3 is that the smarter network manager may give you other 
problems.
For instance, as my understanding goes, connman expects that 
wpa_supplicant will be started by itself, but I don't know whether or 
not it provides a specific configuration file, nor how it handled a 
restart of the daemon.

> or the network changes in between
Based on this statement, and the fact that you *connect* to wifi, I'm 
going to assume that your device is not permanently rooted in one spot.

As such I'm going to recommend option 3.

P.S. Technically, wpa_supplicant is currently being replaced by iwd (an 
intel daemon).
We do not currently have a package for it, but adding one is high on my 
todo list (once I finish up with the documentation, which, again, could 
take a while, still).


---
Unsubscribe:  alpine-user+unsubscribe@lists.alpinelinux.org
Help:         alpine-user+help@lists.alpinelinux.org
---
Reply to thread Export thread (mbox)