guix-devel
[Top][All Lists]
Advanced

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

Re: [PATCH] gnu: Mark /gnu/store as needed for boot.


From: John Darrington
Subject: Re: [PATCH] gnu: Mark /gnu/store as needed for boot.
Date: Sun, 15 Jan 2017 07:32:27 +0100
User-agent: Mutt/1.5.23 (2014-03-12)

On Sat, Jan 14, 2017 at 10:30:43PM +0100, Ludovic Court??s wrote:
     
     > * gnu/system/file-systems.scm (all-subpaths): New procedure.
     > (file-system-needed-for-boot?): Use it to check for ancestors
     > of %store-directory.
     
     I guess the idea is to have ???needed-for-boot???? automatically set for
     users who store /gnu or /gnu/store on a separate partition, right?

Correct.
     
     The problem is that we need to exclude bind mounts, as done in
     ???store-file-system??? in (gnu system).

Thanks for pointing that out.
     
     What about:
     
       (define (file-system-needed-for-boot? fs)
         (or (%file-system-needed-for-boot? fs)
             (and (string-prefix? (file-system-mount-point fs) 
(%store-directory))
                  (not (memq 'bind-mount (file-system-flags fs))))))
     

Perhaps I am misunderstanding something, but

     (string-prefix? (file-system-mount-point fs) (%store-directory))
     
will erroneously return #t when (file-system-mount-point fs) evaluates
to "/gn"  and (%store-directory) to "/gnu/store".  Will it not???

That is why I wrote a procedure to fix that problem.

J'

-- 
Avoid eavesdropping.  Send strong encrypted email.
PGP Public key ID: 1024D/2DE827B3 
fingerprint = 8797 A26D 0854 2EAB 0285  A290 8A67 719C 2DE8 27B3
See http://sks-keyservers.net or any PGP keyserver for public key.

Attachment: signature.asc
Description: Digital signature


reply via email to

[Prev in Thread] Current Thread [Next in Thread]