linux-initrd: Do not create /etc/resolv.conf.

* guix/build/linux-initrd.scm (configure-qemu-networking): Don't create
  /etc/resolv.conf.
master
Ludovic Courtès 2014-08-15 16:06:21 +02:00
parent 25290d2766
commit c0b9213dbb
1 changed files with 3 additions and 5 deletions

View File

@ -384,11 +384,9 @@ networking values.) Return #t if INTERFACE is up, #f otherwise."
(set-network-interface-address sock interface address) (set-network-interface-address sock interface address)
(set-network-interface-flags sock interface (logior flags IFF_UP)) (set-network-interface-flags sock interface (logior flags IFF_UP))
(unless (file-exists? "/etc") ;; Hello! We used to create /etc/resolv.conf here, with "nameserver
(mkdir "/etc")) ;; 10.0.2.3\n". However, with Linux-libre 3.16, we're getting ENOSPC.
(call-with-output-file "/etc/resolv.conf" ;; And since it's actually unnecessary, it's gone.
(lambda (p)
(display "nameserver 10.0.2.3\n" p)))
(logand (network-interface-flags sock interface) IFF_UP))) (logand (network-interface-flags sock interface) IFF_UP)))