Wireless Daemon for Linux
 help / color / mirror / Atom feed
From: Toke =?unknown-8bit?q?H=C3=B8iland-J=C3=B8rgensen?= <toke@toke.dk>
To: iwd@lists.01.org
Subject: iwd crashing when run in different network namespace
Date: Wed, 04 Dec 2019 14:26:37 +0000	[thread overview]
Message-ID: <87a789ph52.fsf@toke.dk> (raw)

[-- Attachment #1: Type: text/plain, Size: 3927 bytes --]

Hi

I have been periodically trying out iwd, but haven't managed to get it
to work yet. After the 1.0 release I thought I'd give it another try,
and finally got around to it now, with my distribution-provided package
(Arch Linux, iwd 1.1-2).

Now, my setup is a bit unusual: I move my physical network adapter to a
separate network namespace, and run the WiFi configuration daemon (thus
far wpa_supplicant) in there. Thus, I want to do the same with iwd,
which doesn't seem to be working.

I added an override file to move the systemd service:

$ cat /etc/systemd/system/iwd.service.d/override.conf
[Unit]
JoinsNamespaceOf=netns(a)physical.service

[Service]
PrivateNetwork=yes


$ sudo ip netns exec physical iw  phy | head -n 1
Wiphy phy1

However, when I try to start iwd, all I get is an error message and a
crash:

Dec 03 16:02:45 my-laptop systemd[1]: Starting Wireless service...
Dec 03 16:02:45 my-laptop iwd[159840]: Wireless daemon version 1.1
Dec 03 16:02:45 my-laptop iwd[159840]: Loaded configuration from /etc/iwd/main.conf
Dec 03 16:02:45 my-laptop systemd[1]: Started Wireless service.
Dec 03 16:02:45 my-laptop audit[1]: SERVICE_START pid=1 uid=0 auid=4294967295 ses=4294967295 ms
g='unit=iwd comm="systemd" exe="/usr/lib/systemd/systemd" hostname=? addr=? terminal=? res=success'
Dec 03 16:02:45 my-laptop iwd[159840]: Can't read /sys/class/ieee80211/phy1/device/driver: No such file or directory
Dec 03 16:02:45 my-laptop audit[159840]: ANOM_ABEND auid=4294967295 uid=0 gid=0 ses=4294967295 pid=159840 comm="iwd" exe="/usr/lib/iwd/iwd" sig=11 res=1
Dec 03 16:02:45 my-laptop systemd[1]: Started Process Core Dump (PID 159841/UID 0).
Dec 03 16:02:45 my-laptop audit[1]: SERVICE_START pid=1 uid=0 auid=4294967295 ses=4294967295 msg='unit=systemd-coredump(a)25-159841-0 comm="systemd" exe="/usr/lib/systemd/systemd" hostname=? addr=? terminal=? res=success'
Dec 03 16:02:45 my-laptop systemd[1]: iwd.service: Main process exited, code=dumped, status=11/SEGV
Dec 03 16:02:45 my-laptop systemd[1]: iwd.service: Failed with result 'core-dump'.
Dec 03 16:02:45 my-laptop audit[1]: SERVICE_STOP pid=1 uid=0 auid=4294967295 ses=4294967295 msg='unit=iwd comm="systemd" exe="/usr/lib/systemd/systemd" hostname=? addr=? terminal=? res=failed'
Dec 03 16:02:45 my-laptop systemd-coredump[159842]: Process 159840 (iwd) of user 0 dumped core.
                                                   
                                                   Stack trace of thread 159840:
                                                   #0  0x00006a95dc9ee6f5 __strlen_avx2 (libc.so.6)
                                                   #1  0x00006a95dc961c34 fnmatch@@GLIBC_2.2.5 (libc.so.6)
                                                   #2  0x0000074127bc397b n/a (iwd)
                                                   #3  0x0000074127bf2f30 n/a (iwd)
                                                   #4  0x0000074127bef804 n/a (iwd)
                                                   #5  0x0000074127bee9ed n/a (iwd)
                                                   #6  0x0000074127beeabe n/a (iwd)
                                                   #7  0x0000074127beece0 n/a (iwd)
                                                   #8  0x0000074127b946c2 n/a (iwd)
                                                   #9  0x00006a95dc8b4153 __libc_start_main (libc.so.6)
                                                   #10 0x0000074127b94e4e n/a (iwd)
Dec 03 16:02:45 my-laptop systemd[1]: systemd-coredump(a)25-159841-0.service: Succeeded.

The file referenced in the error message does exist:

$ sudo ip netns exec physical ls /sys/class/ieee80211/phy1/device/driver -l
lrwxrwxrwx 1 root root 0 Dec  3 16:21 /sys/class/ieee80211/phy1/device/driver -> ../../../../bus/pci/drivers/iwlwifi

Any chance someone could take a look at this?

Thanks!

-Toke

                 reply	other threads:[~2019-12-04 14:26 UTC|newest]

Thread overview: [no followups] expand[flat|nested]  mbox.gz  Atom feed

Reply instructions:

You may reply publicly to this message via plain-text email
using any one of the following methods:

* Save the following mbox file, import it into your mail client,
  and reply-to-all from there: mbox

  Avoid top-posting and favor interleaved quoting:
  https://en.wikipedia.org/wiki/Posting_style#Interleaved_style

* Reply using the --to, --cc, and --in-reply-to
  switches of git-send-email(1):

  git send-email \
    --in-reply-to=87a789ph52.fsf@toke.dk \
    --to=toke@toke.dk \
    --cc=iwd@lists.01.org \
    /path/to/YOUR_REPLY

  https://kernel.org/pub/software/scm/git/docs/git-send-email.html

* If your mail client supports setting the In-Reply-To header
  via mailto: links, try the mailto: link
Be sure your reply has a Subject: header at the top and a blank line before the message body.
This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox