guix-devel
[Top][All Lists]
Advanced

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

Re: /var/guix/gcroot/profiles points to non-existing /mnt subdirectory


From: Ludovic Courtès
Subject: Re: /var/guix/gcroot/profiles points to non-existing /mnt subdirectory
Date: Mon, 29 Aug 2016 00:14:04 +0200
User-agent: Gnus/5.13 (Gnus v5.13) Emacs/24.5 (gnu/linux)

Hello,

address@hidden (Carlos Sánchez de La Lama) skribis:

> In my Guix SD installation, I have the following contents inside
> /var/guix/gcroots:
>
> lrwxrwxrwx 1 root root 18 ago 24 16:45 booted-system -> /run/booted-system
> lrwxrwxrwx 1 root root 19 ago 24 16:45 current-system -> /run/current-system
> lrwxrwxrwx 1 root root 52 ago 24 16:45 grub.cfg -> 
> /gnu/store/rvcr64gcqvay3g68bsrbcp9kahsnh7an-grub.cfg
> lrwxrwxrwx 1 root root 22 ago 24 16:44 profiles -> /mnt/var/guix/profiles
>
> However, /mnt/var/guix/profiles does not exist (there is nothing in
> /mnt). Shouldn't it point to /var/guix/profiles?

Indeed.  Having a dangling symlink in there does sound scary since this
is the directory that specifies garbage collector (GC) roots.

Fortunately, the GC automatically looks for roots in /var/guix/profiles
as well:

--8<---------------cut here---------------start------------->8---
Roots LocalStore::findRoots()
{
    Roots roots;

    /* Process direct roots in {gcroots,manifests,profiles}. */
    nix::findRoots(*this, settings.nixStateDir + "/" + gcRootsDir, DT_UNKNOWN, 
roots);
    if (pathExists(settings.nixStateDir + "/manifests"))
        nix::findRoots(*this, settings.nixStateDir + "/manifests", DT_UNKNOWN, 
roots);
    nix::findRoots(*this, settings.nixStateDir + "/profiles", DT_UNKNOWN, 
roots);

    return roots;
}
--8<---------------cut here---------------end--------------->8---

… so this dangling symlink is harmless.

Nevertheless, I went ahead and fixed it in commit
334bda9a9e01b73b772b3f30b04abea35e5391f8.  You can fix it manually on
your system, or delete it.

Thanks!

Ludo’.



reply via email to

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