GNU bug report logs - #40682
Installer hangs while connecting to WiFi network

Previous Next

Package: guix;

Reported by: SergioBG BG <sergiobgar <at> gmail.com>

Date: Fri, 17 Apr 2020 15:51:02 UTC

Severity: important

Tags: moreinfo

Done: Mathieu Othacehe <othacehe <at> gnu.org>

Bug is archived. No further changes may be made.

Full log


View this message in rfc822 format

From: Ludovic Courtès <ludo <at> gnu.org>
To: SergioBG BG <sergiobgar <at> gmail.com>
Cc: Mathieu Othacehe <m.othacehe <at> gmail.com>, 40682 <at> debbugs.gnu.org
Subject: bug#40682: frozen installer in WiFi section -guix 1.1.0
Date: Sun, 19 Apr 2020 01:30:47 +0200
[Message part 1 (text/plain, inline)]
Hi,

SergioBG BG <sergiobgar <at> gmail.com> skribis:

> Here the screenshot of Frozen.

Thanks.  Looking at the screenshot, it would seem that the installer is
stuck somewhere in ‘connman-connect-with-auth’, but it’s hard to tell
why/where.

I was able to reproduce it in ‘guix system vm’ with the patch below.

Cc: Mathieu in case they have an idea…

To be continued…

Thanks,
Ludo’.

PS: Nyacc contains libdbus bindings as an example of its FFI tooling,
    perhaps we should give it a try and use it here.  It could be more
    robust than piping through ‘connmanctl’.

[Message part 2 (text/x-patch, inline)]
diff --git a/gnu/system/install.scm b/gnu/system/install.scm
index 0965c4d237..826f6d356d 100644
--- a/gnu/system/install.scm
+++ b/gnu/system/install.scm
@@ -322,6 +322,52 @@ the user's target storage device rather than on the RAM disk."
     "Load the @code{uvesafb} kernel module with the right options.")
    (default-value #t)))
 
+(define (simulated-wifi-shepherd-services hostapd)
+  (define config
+    (plain-file "hostapd.conf" "\
+interface=wlan1
+ssid=Test Net
+channel=1\n"))
+
+  (list (shepherd-service
+         (provision '(hostapd))
+         (requirement '(mac-sim-module unblocked-wifi))
+         (start #~(make-forkexec-constructor
+                   (list #$(file-append hostapd "/sbin/hostapd")
+                         #$config)
+                   #:log-file "/var/log/hostapd.log"))
+         (stop #~(make-kill-destructor)))
+        (shepherd-service
+         (provision '(unblocked-wifi))
+         (requirement '(mac-sim-module))
+         (start #~(lambda _
+                    (invoke #$(file-append util-linux "/sbin/rfkill")
+                            "unblock" "0")
+                    (invoke #$(file-append util-linux "/sbin/rfkill")
+                            "unblock" "1")))
+         (one-shot? #t))
+        (shepherd-service
+         (provision '(mac-sim-module))
+         (requirement '(term-tty3))
+         (modules '((guix build utils)))
+         (start #~(lambda _
+                    ;; XXX: We can't use 'load-linux-module*' here because it
+                    ;; expects a flat module directory.
+                    (setenv "LINUX_MODULE_DIRECTORY"
+                            "/run/booted-system/kernel/lib/modules")
+                    (invoke #$(file-append kmod "/bin/modprobe")
+                            "mac80211_hwsim")))
+         (one-shot? #t))))
+
+(define simulated-wifi-service-type
+  (service-type
+   (name 'simulated-wifi)
+   (extensions
+    (list (service-extension shepherd-root-service-type
+                             simulated-wifi-shepherd-services)))
+   (default-value hostapd)
+   (description "Run hostapd to simulate WiFi connectivity.")))
+
 (define %installation-services
   ;; List of services of the installation system.
   (let ((motd (plain-file "motd" "
@@ -366,6 +412,8 @@ Access documentation at any time by pressing Alt-F2.\x1b[0m
           ;; The usual services.
           (syslog-service)
 
+          (service simulated-wifi-service-type)
+
           ;; The build daemon.  Register the default substitute server key(s)
           ;; as trusted to allow the installation process to use substitutes by
           ;; default.

This bug report was last modified 2 years and 196 days ago.

Previous Next


GNU bug tracking system
Copyright (C) 1999 Darren O. Benham, 1997,2003 nCipher Corporation Ltd, 1994-97 Ian Jackson.