* `guix pull` fails after fresh install
@ 2021-07-18 21:13 Gabriel Wicki
2021-08-19 22:56 ` Gabriel Wicki
0 siblings, 1 reply; 3+ messages in thread
From: Gabriel Wicki @ 2021-07-18 21:13 UTC (permalink / raw)
To: help-guix
Hello Guix Community!
I ran into an issue after freshly installing Guix System. When logged in
as a normal user, `guix pull` printed the following output:
Migrating profile generations to '/var/guix/profiles/per-user/user'...
guix pull: error: symlink: File exists: "/var/guix/profiles/per-user/user/current-guix"
`guix pull` was invoked before by root, but guix has not been called by the
unprivileged user before.
$ ls -l /var/guix/profiles/per-user/user/
total 0
lrwxrwxrwx 1 user users 19 Jul 18 22:13 current-guix -> current-guix-0-link
lrwxrwxrwx 1 user users 19 Jul 18 22:43 guix-profile -> guix-profile-2-link
lrwxrwxrwx 1 user users 51 Jul 18 22:23 guix-profile-1-link -> /gnu/store/skvmv3zpzd06pj0jq57m0xjvx0hdjnkr-profile
lrwxrwxrwx 1 user users 51 Jul 18 22:43 guix-profile-2-link -> /gnu/store/mzn60p0kd8kiwdj9qqan73664yn6b0s0-profile
-rw-r--r-- 1 user users 0 Jul 18 22:40 guix-profile.lock
I tried:
* guix gc
* guix gc -R
* guix gc --referrers
* guix gc --verify
* guix gc --verify=repair
but to no avail.
Should I just delete current-guix? Link it to my current profile? Or the
system's profile?
Thanks in advance for your advice,
Gabriel
^ permalink raw reply [flat|nested] 3+ messages in thread
* Re: `guix pull` fails after fresh install
2021-07-18 21:13 `guix pull` fails after fresh install Gabriel Wicki
@ 2021-08-19 22:56 ` Gabriel Wicki
2021-08-19 23:00 ` Gabriel Wicki
0 siblings, 1 reply; 3+ messages in thread
From: Gabriel Wicki @ 2021-08-19 22:56 UTC (permalink / raw)
To: help-guix
I was able to fix it!
Because this mailing list is a resource for people seeking help I'll
feel free to describe how i tracked the issue down and fixed it.
I added a new user (through a change in the system config and `guix
system reconfigure) to figure out if the problem also exists for new
users, and if not, what the differences to my profile were.
and found the following differences:
^ permalink raw reply [flat|nested] 3+ messages in thread
* Re: `guix pull` fails after fresh install
2021-08-19 22:56 ` Gabriel Wicki
@ 2021-08-19 23:00 ` Gabriel Wicki
0 siblings, 0 replies; 3+ messages in thread
From: Gabriel Wicki @ 2021-08-19 23:00 UTC (permalink / raw)
To: help-guix
Please ignore my previous message in this thread, i sent the wrong
version... Here's the right one:
I was able to fix it! Yay
Because this mailing list is a resource for people seeking help I'll
hereby take the liberty to document how I tracked the issue down and
fixed it.
I added a new user to find out if the problem was reproducible and
whether the system was to blame. This was luckily not the case.
`guix pull` worked for the freshly added user 'test'. But I found
the following differences: both
/var/guix/profiles/per-user/user/current-guix
and
/home/user/.config/guix/current
were real directories, whereas for the new 'test' user at the
corresponding paths there were symlinks: the former pointing to
current-guix-1-link in the same directory while the latter pointed to
the former. Also, there is no file called `current-guix-0-link` in
/var/guix/profiles/per-user/user/, but `current-guix` in the same
directory points to that. I guessed this was most probably causing
the issue.
If I understand correctly guix stores two kinds of of symlinks in
user-profiles (which live in /var/guix/profiles/per-user/):
1. current-guix-N-link: links to guix profiles (which contain guix
and guix-daemon executables and info files),
2. guix-profile-N-link: links to package profile generations
(which contain all installed programs including libraries,
executables and documentation)
and for each of those link-types one special link (current-guix and
guix-profile) pointing to the currently active one of their kind.
My guix-profile links seemed to be fine, but my suspicion grew that
I'd have to replace the aforementioned directories with symlinks to
the right places. Only problem: I did't know which is the "right"
current-guix profile to link to. But since my installation is just
some days old I figured there shouldn't be too much of a difference
between the different guix versions on my machine and just linked to
the one which
/var/guix/profiles/per-user/test/current-guix-0-link
pointed to.
I tested with `guix pull` which worked just fine. Pleased with the
outcome I happily `guix package upgrade`d my profile.
^ permalink raw reply [flat|nested] 3+ messages in thread
end of thread, other threads:[~2021-08-19 23:01 UTC | newest]
Thread overview: 3+ messages (download: mbox.gz follow: Atom feed
-- links below jump to the message on this page --
2021-07-18 21:13 `guix pull` fails after fresh install Gabriel Wicki
2021-08-19 22:56 ` Gabriel Wicki
2021-08-19 23:00 ` Gabriel Wicki
This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox;
as well as URLs for read-only IMAP folder(s) and NNTP newsgroup(s).