From mboxrd@z Thu Jan 1 00:00:00 1970 From: Taylan Kammer Subject: bug#31889: Filesystems must not depend on device mappings? Date: Thu, 21 Jun 2018 20:44:42 +0200 Message-ID: <87efh09dyd.fsf@gmail.com> References: <87efh1qhs3.fsf@gnu.org> Mime-Version: 1.0 Content-Type: text/plain; charset=utf-8 Content-Transfer-Encoding: quoted-printable Return-path: Received: from eggs.gnu.org ([2001:4830:134:3::10]:44623) by lists.gnu.org with esmtp (Exim 4.71) (envelope-from ) id 1fW2hn-0003Na-Bv for bug-guix@gnu.org; Thu, 21 Jun 2018 12:45:08 -0400 Received: from Debian-exim by eggs.gnu.org with spam-scanned (Exim 4.71) (envelope-from ) id 1fW2hi-0002O3-F3 for bug-guix@gnu.org; Thu, 21 Jun 2018 12:45:07 -0400 Received: from debbugs.gnu.org ([208.118.235.43]:51430) by eggs.gnu.org with esmtps (TLS1.0:RSA_AES_128_CBC_SHA1:16) (Exim 4.71) (envelope-from ) id 1fW2hi-0002Nx-As for bug-guix@gnu.org; Thu, 21 Jun 2018 12:45:02 -0400 Received: from Debian-debbugs by debbugs.gnu.org with local (Exim 4.84_2) (envelope-from ) id 1fW2hi-0004au-1T for bug-guix@gnu.org; Thu, 21 Jun 2018 12:45:02 -0400 Sender: "Debbugs-submit" Resent-Message-ID: In-Reply-To: <87efh1qhs3.fsf@gnu.org> ("Ludovic \=\?utf-8\?Q\?Court\=C3\=A8s\=22'\?\= \=\?utf-8\?Q\?s\?\= message of "Wed, 20 Jun 2018 23:17:48 +0200") List-Id: Bug reports for GNU Guix List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , Errors-To: bug-guix-bounces+gcggb-bug-guix=m.gmane.org@gnu.org Sender: "bug-Guix" To: Ludovic =?UTF-8?Q?Court=C3=A8s?= Cc: 31889@debbugs.gnu.org ludo@gnu.org (Ludovic Court=C3=A8s) writes: > Hi! > > Taylan Ulrich "Bay=C4=B1rl=C4=B1/Kammer" skribi= s: > >> If in my OS config I define some luks mappings, and define the >> corresponding filesystems with dependencies on the mapped devices, >> I get an error on 'guix system reconfigure'. >> >> Example: >> >> (operating-system >> ... >> (mapped-devices >> (list (mapped-device ... (target "root")))) >> (file-systems >> (list (file-system (mount-point "/") >> ... >> (dependencies mapped-devices)))) >> ...) >> >> This will yield an error like: >> >> file-system-/ depends on device-mapping-root, which is not >> provided by any service > > Could you show the complete =E2=80=98mapped-devices=E2=80=99 and =E2=80= =98file-systems=E2=80=99 fields, > without ellipses? > > The message above suggests that =E2=80=9C/=E2=80=9D was not considered as > needed-for-boot. > > Thanks, > Ludo=E2=80=99. Sorry, looks like my example was wrong. Here is a problematic OS declaration: (operating-system (host-name "guixsd") (timezone "Europe/Berlin") (locale "en_US.utf8") =20=20=20=20=20 (bootloader (bootloader-configuration (bootloader grub-bootloader) (target "/dev/sda"))) =20=20=20=20=20 (mapped-devices (list (mapped-device (source (uuid "b3d059f8-1c4f-4569-88dd-5485825b4373")) (target "guixsd") (type luks-device-mapping)) (mapped-device (source (uuid "550d9258-bbbb-488c-af27-6b1fefa190ee")) (target "home") (type luks-device-mapping)))) =20=20=20=20=20 (file-systems (append (list (file-system (device "/dev/mapper/guixsd") (mount-point "/") (type "ext4") (dependencies mapped-devices)) (file-system (device "/dev/mapper/home") (mount-point "/home") (type "ext4") (dependencies mapped-devices))) %base-file-systems)) =20=20=20=20=20 (users (append (list (user-account (name "taylan") (comment "Taylan Kammer") (group "users") (supplementary-groups '("wheel" "netdev" "audio" "video")) (home-directory "/home/taylan"))) %base-user-accounts)) =20=20=20=20=20 (packages %base-packages) (services %desktop-services) =20=20=20=20=20 ;; Allow resolution of '.local' host names with mDNS. (name-service-switch %mdns-host-lookup-nss)) It results in the error message: guix system: error: service 'file-system-/home' requires 'device-mapping-home', which is not provided by any service (I also got that for '/' rather than '/home' at some point, but can't remember under what conditions.) It works when both '(dependencies mapped-devices)' clauses are simply removed. All in all I can't really figure out the logic behind the whole thing and what exactly is expected. I think the error reporting and relevant section of the documentation may need some improvement. Taylan