`guix deploy` permission denied error

  • Done
  • quality assurance status badge
Details
3 participants
  • Ludovic Courtès
  • Tobias Geerinckx-Rice
  • pkill9
Owner
unassigned
Submitted by
pkill9
Severity
normal

Debbugs page

pkill9 wrote 4 years ago
(address . bug-guix@gnu.org)
20210301214319.1f62ac9f@runbox.com
When I run Guix deploy, I get this error:
```
guix deploy: error: open-file: Permission denied:
"/home/itsme/.cache/guix/checkouts/last-expiry-cleanup"
```

I've tried deleting ~/.cache/guix, and creating a chmod 777'd
~/.cache/guix directory, but I still get that error.
Ludovic Courtès wrote 4 years ago
(name . pkill9)(address . pkill9@runbox.com)(address . 46861@debbugs.gnu.org)
87pn0hohc1.fsf@gnu.org
Hi,

pkill9 <pkill9@runbox.com> skribis:

Toggle quote (9 lines)
> When I run Guix deploy, I get this error:
> ```
> guix deploy: error: open-file: Permission denied:
> "/home/itsme/.cache/guix/checkouts/last-expiry-cleanup"
> ```
>
> I've tried deleting ~/.cache/guix, and creating a chmod 777'd
> ~/.cache/guix directory, but I still get that error.

Can you show the ownership of ~itsme/.cache/guix/checkouts and
~itsme/.cache/guix/checkouts/last-expiry-cleanup?

It’s likely been caused by “sudo guix pull”, which changed the ownership
to root. There’s no reason to run ‘guix deploy’ as root.

TIA,
Ludo’.
Tobias Geerinckx-Rice wrote 4 years ago
(name . Ludovic Courtès)(address . ludo@gnu.org)(address . 46861@debbugs.gnu.org)(address . bug-guix@gnu.org)(name . pkill9)(address . pkill9@runbox.com)
87h7ltmtwr.fsf@nckx
Ludovic Courtès 写道:
Toggle quote (4 lines)
> It’s likely been caused by “sudo guix pull”, which changed the
> ownership
> to root. There’s no reason to run ‘guix deploy’ as root.

Ownership of _what_, though?

I thought the same as you at first, hence (on IRC):

Toggle quote (3 lines)
> I've tried deleting ~/.cache/guix, and creating a chmod 777'd
> ~/.cache/guix directory, but I still get that error.

Kind regards,

T G-R
-----BEGIN PGP SIGNATURE-----

iIMEARYKACsWIQT12iAyS4c9C3o4dnINsP+IT1VteQUCYD5gFA0cbWVAdG9iaWFz
LmdyAAoJEA2w/4hPVW1530YA/jplQBsrJxC462ZWdoeoibWfqsBqJaRo3+DL/NCi
EEz/AQDH5fy6O5sv+IwW64K1PfCLX7vJCImQouit0U6Q9t4NAQ==
=rJmq
-----END PGP SIGNATURE-----

pkill9 wrote 4 years ago
(name . Tobias Geerinckx-Rice)(address . me@tobias.gr)(name . Ludovic Courtès)(address . ludo@gnu.org)(address . bug-guix@gnu.org)(address . 46861@debbugs.gnu.org)
20210303010443.6644f018@runbox.com
It does this with guix pull too, and it's on the machine that is doing
the deploying that gui pull causes the error, but guix pull worked fine
on the machine being deployed to.
pkill9 wrote 4 years ago
(name . Ludovic Courtès)(address . ludo@gnu.org)(address . 46861@debbugs.gnu.org)
20210303171122.75e08d39@runbox.com
Ok, I just did `guix pull` on the machine deploying to the remote host,
which had the same problem before, and it created last-expiry-cleanup
and the file is owned by root, and changing it to my user fixed it. Not
sure what happened the first time around, I'm so confused...

My only guess is that I did a guix pull as root, which put that there
like suggested, but that guix deploy also relies on it, so when I
deleted that file, `guix deploy` didn't recreate it because it doesn't
handle it. The thing is, it didn't say no such file or directory, it
said permission denied. I dunno.. I worked myself up into confusion...
Ludovic Courtès wrote 4 years ago
(name . pkill9)(address . pkill9@runbox.com)(address . 46861-done@debbugs.gnu.org)
87lfaxd9ff.fsf@gnu.org
Hi,

pkill9 <pkill9@runbox.com> skribis:

Toggle quote (5 lines)
> Ok, I just did `guix pull` on the machine deploying to the remote host,
> which had the same problem before, and it created last-expiry-cleanup
> and the file is owned by root, and changing it to my user fixed it. Not
> sure what happened the first time around, I'm so confused...

OK, closing!

‘sudo guix’ is an endless source of confusion. :-/

Thanks,
Ludo’.
Closed
?
Your comment

This issue is archived.

To comment on this conversation send an email to 46861@debbugs.gnu.org

To respond to this issue using the mumi CLI, first switch to it
mumi current 46861
Then, you may apply the latest patchset in this issue (with sign off)
mumi am -- -s
Or, compose a reply to this issue
mumi compose
Or, send patches to this issue
mumi send-email *.patch
You may also tag this issue. See list of standard tags. For example, to set the confirmed and easy tags
mumi command -t +confirmed -t +easy
Or, remove the moreinfo tag and set the help tag
mumi command -t -moreinfo -t +help