unofficial mirror of bug-guix@gnu.org 
 help / color / mirror / code / Atom feed
* bug#32183: New ‘guix pull’ /root/.config/current/bin/guix: Permission denied
       [not found] ` <20180717191554.GA23234@jasmine.lan>
@ 2018-07-17 22:28   ` Ludovic Courtès
  0 siblings, 0 replies; 29+ messages in thread
From: Ludovic Courtès @ 2018-07-17 22:28 UTC (permalink / raw)
  To: Leo Famulari; +Cc: 32183-done

Leo Famulari <leo@famulari.name> skribis:

> On Tue, Jul 17, 2018 at 10:55:41AM +0200, Pjotr Prins wrote:
>> > > Fails to build with below /gnu/store/8ahlc84zaj0iw9jpsdpa9wx4ms0s9cma-guix-daemon-0.15.0-1.4876bc8/libexec/guix/download: line 8: /root/.config/current/bin/guix: Permission denied
>
> There must be a typo in the code somewhere. The path should be
> '/root/.config/guix/current/bin/guix'.Note the extra 'guix' path
> component.

Good catch!  Fixed in 799dc53e9bfe605613cd2e7cb2c584282847fa84.

Thank you Leo & Pjotr.

Ludo’.

^ permalink raw reply	[flat|nested] 29+ messages in thread

* bug#32183: New ‘guix pull’ /root/.config/current/bin/guix: Permission denied
       [not found] <20180717085541.g6nuycopf5kxoin7@thebird.nl>
       [not found] ` <20180717191554.GA23234@jasmine.lan>
@ 2018-07-23 22:28 ` Pjotr Prins
  2018-07-26 13:50   ` Ludovic Courtès
  2018-09-05 15:27 ` bug#32183: Me too! Konrad Hinsen
  2 siblings, 1 reply; 29+ messages in thread
From: Pjotr Prins @ 2018-07-23 22:28 UTC (permalink / raw)
  To: 32183

Not completely sorted. Not sure what is going wrong but now starting
with guix 0.14 daemon and client and running guix pull a few times
successfully, running guix-daemon from $HOME/.config/guix/current/bin
and guix from a fresh git checkout using ./pre-inst-env guix I get

substitute: /gnu/store/x02v3j0h5q1d9bl3lwxavp8m9rpm3b7m-guix-daemon-0.15.0-2.8bbb79c/libexec/guix/substitute: line 8: /root/.config/guix/current/bin/guix: No such file or directory

which is funny for two reasons - 1st this is a guix-daemon that
appears to be older (it is the same) referring to a directory that
does not exist - guix pull is in my $HOME/.config.

Note that it still downloads binaries, but won't do the final
symlinks in the profile.

On this machine I am stuck because whatever I do I get this error.
Only rolling back to 0.14 allows me to install software again
including guix. But then it stops in its tracks with above.

Pj.

^ permalink raw reply	[flat|nested] 29+ messages in thread

* bug#32183: New ‘guix pull’ /root/.config/current/bin/guix: Permission denied
  2018-07-23 22:28 ` Pjotr Prins
@ 2018-07-26 13:50   ` Ludovic Courtès
  2018-09-02 13:55     ` Ludovic Courtès
  0 siblings, 1 reply; 29+ messages in thread
From: Ludovic Courtès @ 2018-07-26 13:50 UTC (permalink / raw)
  To: Pjotr Prins; +Cc: 32183

Hi Pjotr,

Pjotr Prins <pjotr.public12@thebird.nl> skribis:

> Not completely sorted. Not sure what is going wrong but now starting
> with guix 0.14 daemon and client and running guix pull a few times
> successfully, running guix-daemon from $HOME/.config/guix/current/bin
> and guix from a fresh git checkout using ./pre-inst-env guix I get
>
> substitute: /gnu/store/x02v3j0h5q1d9bl3lwxavp8m9rpm3b7m-guix-daemon-0.15.0-2.8bbb79c/libexec/guix/substitute: line 8: /root/.config/guix/current/bin/guix: No such file or directory
>
> which is funny for two reasons - 1st this is a guix-daemon that
> appears to be older (it is the same) referring to a directory that
> does not exist - guix pull is in my $HOME/.config.

Since ‘guix-daemon’ runs as root, the ‘guix-daemon’ package¹ assumes
that ~root/.config/guix/current/bin/guix exists.  In fact, the only way
you can install the ‘guix-daemon’ package is by running ‘guix pull’, and
if you run ‘guix-daemon’ you run it as root, so ~root/.config/guix
necessarily exists.

Or could it be that you’re running ‘guix-daemon’ from
~/.config/guix/current as non-root?  That would indeed fail.

In fact it may be enough to do:

  exec ~/.config/guix/current/bin/guix …

instead of:

  exec ~root/.config/guix/current/bin/guix …

in that ‘install’ phase of ‘guix-daemon’.

Thanks,
Ludo’.

¹ https://git.savannah.gnu.org/cgit/guix.git/tree/gnu/packages/package-management.scm#n301

^ permalink raw reply	[flat|nested] 29+ messages in thread

* bug#32183: New ‘guix pull’ /root/.config/current/bin/guix: Permission denied
  2018-07-26 13:50   ` Ludovic Courtès
@ 2018-09-02 13:55     ` Ludovic Courtès
  2018-09-02 14:28       ` Pjotr Prins
  0 siblings, 1 reply; 29+ messages in thread
From: Ludovic Courtès @ 2018-09-02 13:55 UTC (permalink / raw)
  To: Pjotr Prins; +Cc: 32183

Hi Pjotr,

What was the outcome of this bug?

  https://bugs.gnu.org/32183

If it wasn’t resolved, could you answer the questions below?

Thanks in advance!

Ludo’.

ludo@gnu.org (Ludovic Courtès) skribis:

> Hi Pjotr,
>
> Pjotr Prins <pjotr.public12@thebird.nl> skribis:
>
>> Not completely sorted. Not sure what is going wrong but now starting
>> with guix 0.14 daemon and client and running guix pull a few times
>> successfully, running guix-daemon from $HOME/.config/guix/current/bin
>> and guix from a fresh git checkout using ./pre-inst-env guix I get
>>
>> substitute: /gnu/store/x02v3j0h5q1d9bl3lwxavp8m9rpm3b7m-guix-daemon-0.15.0-2.8bbb79c/libexec/guix/substitute: line 8: /root/.config/guix/current/bin/guix: No such file or directory
>>
>> which is funny for two reasons - 1st this is a guix-daemon that
>> appears to be older (it is the same) referring to a directory that
>> does not exist - guix pull is in my $HOME/.config.
>
> Since ‘guix-daemon’ runs as root, the ‘guix-daemon’ package¹ assumes
> that ~root/.config/guix/current/bin/guix exists.  In fact, the only way
> you can install the ‘guix-daemon’ package is by running ‘guix pull’, and
> if you run ‘guix-daemon’ you run it as root, so ~root/.config/guix
> necessarily exists.
>
> Or could it be that you’re running ‘guix-daemon’ from
> ~/.config/guix/current as non-root?  That would indeed fail.
>
> In fact it may be enough to do:
>
>   exec ~/.config/guix/current/bin/guix …
>
> instead of:
>
>   exec ~root/.config/guix/current/bin/guix …
>
> in that ‘install’ phase of ‘guix-daemon’.
>
> Thanks,
> Ludo’.
>
> ¹ https://git.savannah.gnu.org/cgit/guix.git/tree/gnu/packages/package-management.scm#n301

^ permalink raw reply	[flat|nested] 29+ messages in thread

* bug#32183: New ‘guix pull’ /root/.config/current/bin/guix: Permission denied
  2018-09-02 13:55     ` Ludovic Courtès
@ 2018-09-02 14:28       ` Pjotr Prins
  2018-09-02 20:04         ` Ludovic Courtès
  0 siblings, 1 reply; 29+ messages in thread
From: Pjotr Prins @ 2018-09-02 14:28 UTC (permalink / raw)
  To: Ludovic Courtès; +Cc: 32183

On Sun, Sep 02, 2018 at 03:55:06PM +0200, Ludovic Courtès wrote:
> Hi Pjotr,
> 
> What was the outcome of this bug?
> 
>   https://bugs.gnu.org/32183
> 
> If it wasn’t resolved, could you answer the questions below?

I still face this problem on one or two machines. I am running a
standard setup. Not sure what it is.

But since no one else is reporting I think it must be because I am
running some earlier tree checkout too for deployment. Something got
messed up.

You can close this issue for now. I'll simply reinstall Guix on these
machines and start building a recent tree.

> Thanks in advance!
> 
> Ludo’.
> 
> ludo@gnu.org (Ludovic Courtès) skribis:
> 
> > Hi Pjotr,
> >
> > Pjotr Prins <pjotr.public12@thebird.nl> skribis:
> >
> >> Not completely sorted. Not sure what is going wrong but now starting
> >> with guix 0.14 daemon and client and running guix pull a few times
> >> successfully, running guix-daemon from $HOME/.config/guix/current/bin
> >> and guix from a fresh git checkout using ./pre-inst-env guix I get
> >>
> >> substitute: /gnu/store/x02v3j0h5q1d9bl3lwxavp8m9rpm3b7m-guix-daemon-0.15.0-2.8bbb79c/libexec/guix/substitute: line 8: /root/.config/guix/current/bin/guix: No such file or directory
> >>
> >> which is funny for two reasons - 1st this is a guix-daemon that
> >> appears to be older (it is the same) referring to a directory that
> >> does not exist - guix pull is in my $HOME/.config.
> >
> > Since ‘guix-daemon’ runs as root, the ‘guix-daemon’ package¹ assumes
> > that ~root/.config/guix/current/bin/guix exists.  In fact, the only way
> > you can install the ‘guix-daemon’ package is by running ‘guix pull’, and
> > if you run ‘guix-daemon’ you run it as root, so ~root/.config/guix
> > necessarily exists.
> >
> > Or could it be that you’re running ‘guix-daemon’ from
> > ~/.config/guix/current as non-root?  That would indeed fail.
> >
> > In fact it may be enough to do:
> >
> >   exec ~/.config/guix/current/bin/guix …
> >
> > instead of:
> >
> >   exec ~root/.config/guix/current/bin/guix …
> >
> > in that ‘install’ phase of ‘guix-daemon’.
> >
> > Thanks,
> > Ludo’.
> >
> > ¹ https://git.savannah.gnu.org/cgit/guix.git/tree/gnu/packages/package-management.scm#n301
> 

^ permalink raw reply	[flat|nested] 29+ messages in thread

* bug#32183: New ‘guix pull’ /root/.config/current/bin/guix: Permission denied
  2018-09-02 14:28       ` Pjotr Prins
@ 2018-09-02 20:04         ` Ludovic Courtès
  2018-09-06 21:10           ` Pjotr Prins
  0 siblings, 1 reply; 29+ messages in thread
From: Ludovic Courtès @ 2018-09-02 20:04 UTC (permalink / raw)
  To: Pjotr Prins; +Cc: 32183-done

Hi,

Pjotr Prins <pjotr.public12@thebird.nl> skribis:

> On Sun, Sep 02, 2018 at 03:55:06PM +0200, Ludovic Courtès wrote:
>> Hi Pjotr,
>> 
>> What was the outcome of this bug?
>> 
>>   https://bugs.gnu.org/32183
>> 
>> If it wasn’t resolved, could you answer the questions below?
>
> I still face this problem on one or two machines. I am running a
> standard setup. Not sure what it is.
>
> But since no one else is reporting I think it must be because I am
> running some earlier tree checkout too for deployment. Something got
> messed up.

OK.  Do reopen it if it shows up again.

Thanks,
Ludo’.

^ permalink raw reply	[flat|nested] 29+ messages in thread

* bug#32183: Me too!
       [not found] <20180717085541.g6nuycopf5kxoin7@thebird.nl>
       [not found] ` <20180717191554.GA23234@jasmine.lan>
  2018-07-23 22:28 ` Pjotr Prins
@ 2018-09-05 15:27 ` Konrad Hinsen
  2 siblings, 0 replies; 29+ messages in thread
From: Konrad Hinsen @ 2018-09-05 15:27 UTC (permalink / raw)
  To: 32183

Hi Ludo and Pjotr,

I just ran into this bug as well:

   ./pre-inst-env guix build python-matplotlib
   @ build-started /gnu/store/33hf690qiwrvr0y59g9xwz6rpf3mmbj6-matplotlib-2.2.3.tar.gz.drv - x86_64-linux /var/log/guix/drvs/33//hf690qiwrvr0y59g9xwz6rpf3mmbj6-matplotlib-2.2.3.tar.gz.drv.bz2
   /gnu/store/1w41y8q12r3dw8iphl5rpkr508881y50-guix-daemon-0.15.0-2.8bbb79c/libexec/guix/download: line 8: /root/.config/guix/current/bin/guix: Permission denied
   /gnu/store/1w41y8q12r3dw8iphl5rpkr508881y50-guix-daemon-0.15.0-2.8bbb79c/libexec/guix/download: line 8: exec: /root/.config/guix/current/bin/guix: cannot execute: Permission denied
  ...
  (resulting build failure etc., nothing interesting)

This is on recent source code checkout (commit
fefe17b0888b467383ea91fed73a9586295c49f0) with a small modification
(update of hdf5 to 1.10.3).

My guix-daemon is started via systemd at boot time, so it should run as
root. It's from root's guix, which is about two weeks old and has not
caused any trouble before.

Konrad.

^ permalink raw reply	[flat|nested] 29+ messages in thread

* bug#32183: New ‘guix pull’ /root/.config/current/bin/guix: Permission denied
  2018-09-02 20:04         ` Ludovic Courtès
@ 2018-09-06 21:10           ` Pjotr Prins
  2018-09-09  7:20             ` Pjotr Prins
  2018-09-09 14:44             ` Ludovic Courtès
  0 siblings, 2 replies; 29+ messages in thread
From: Pjotr Prins @ 2018-09-06 21:10 UTC (permalink / raw)
  To: Ludovic Courtès; +Cc: 32183-done

On Sun, Sep 02, 2018 at 10:04:32PM +0200, Ludovic Courtès wrote:
> OK.  Do reopen it if it shows up again.

Just to report that I did a successful install on one of those
machines. Starting with a 0.14 guix as root

  guix pull

restarted daemon using the new one in /root/.config/current/bin/

switched to normal user using the guix pointed in that directory

  /gnu/store/47hhyj0l4nk4na09qx1b66sz1wvpx95i-guix-command pull

Next I could run 

  ~/.config/current/bin/guix ...

everything appeared hunky dory until I need to build a package

	/gnu/store/sf84mb2y5vcykwq9fv02l2nipp34qng2-guix-daemon-0.15.0-3.3d43017/libexec/guix/download: line 8: /root/.config/guix/current/bin/guix: Permission denied
	/gnu/store/sf84mb2y5vcykwq9fv02l2nipp34qng2-guix-daemon-0.15.0-3.3d43017/libexec/guix/download: line 8: exec: /root/.config/guix/current/bin/guix: cannot execute: Permission denied
	builder for `/gnu/store/2q486ivskp2vm2rq10rs4pq949zkcz8h-evaluate_0.11.tar.gz.drv' failed with exit code 126
	cannot build derivation `/gnu/store/qaaf8i893x0ivfnw6q19l0rq5gkmlbmj-r-evaluate-0.11.drv': 1 dependencies couldn't be built
	cannot build derivation `/gnu/store/frxjc6iwwflasmj3wcm5s2934mgziaj6-r-fansi-0.3.0.drv': 1 dependencies couldn't be built
	cannot build derivation `/gnu/store/p3d9km0fi423nl66q5ncvkxcnj2kz6bv-r-rsqlite-2.1.1.drv': 1 dependencies couldn't be built
	guix package: error: build failed: build of `/gnu/store/p3d9km0fi423nl66q5ncvkxcnj2kz6bv-r-rsqlite-2.1.1.drv' failed

Again as root I did another guix pull. It instates the same daemon

  /root/.config/guix/current/bin/guix-daemon -> /gnu/store/sf84mb2y5vcykwq9fv02l2nipp34qng2-guix-daemon-0.15.0-3.3d43017/bin/guix-daemon

Now guix pull fails in $USER

  which guix
  /home/wrk/.config/guix/current/bin/guix

  guix pull

	Updating channel 'guix' from Git repository at 'https://git.savannah.gnu.org/git/guix.git'...
	Building from this channel:
		guix      https://git.savannah.gnu.org/git/guix.git   91cc2a3
	guile: warning: failed to install locale
	substitute: updating substitutes from 'https://mirror.hydra.gnu.org'... 100.0%
	substitute: updating substitutes from 'https://mirror.hydra.gnu.org'... 100.0%
	Downloading https://mirror.hydra.gnu.org/guix/nar/gzip/xw7kc681ivcls1lpp0qy0xljljzd70dr-groff-1.22.3...
	 groff-1.22.3  2.7MiB                                                                   1.2MiB/s 00:02 [##################] 100.0%

	/gnu/store/sf84mb2y5vcykwq9fv02l2nipp34qng2-guix-daemon-0.15.0-3.3d43017/libexec/guix/download: line 8: /root/.config/guix/current/bin/guix: Permission denied
	/gnu/store/sf84mb2y5vcykwq9fv02l2nipp34qng2-guix-daemon-0.15.0-3.3d43017/libexec/guix/download: line 8: exec: /root/.config/guix/current/bin/guix: cannot execute: Permission denied
	builder for `/gnu/store/24ag580271wa640529ycykdwj0lk0g6z-curl-7.61.1.tar.xz.drv' failed with exit code 126
	cannot build derivation `/gnu/store/17lw3svpjqygpj739yynyz6b8abddikx-curl-7.61.1.drv': 1 dependencies couldn't be built
	Backtrace:
						18 (primitive-load "/gnu/store/blfsj798qh4i2pmrcvyaidmsdiz?")
	In ice-9/eval.scm:
			155:9 17 (_ _)

Can you think of a way of getting out of this loop? What am I doing wrong here?

Pj.

^ permalink raw reply	[flat|nested] 29+ messages in thread

* bug#32183: New ‘guix pull’ /root/.config/current/bin/guix: Permission denied
  2018-09-06 21:10           ` Pjotr Prins
@ 2018-09-09  7:20             ` Pjotr Prins
  2018-09-09 14:02               ` Pjotr Prins
  2018-09-09 14:44             ` Ludovic Courtès
  1 sibling, 1 reply; 29+ messages in thread
From: Pjotr Prins @ 2018-09-09  7:20 UTC (permalink / raw)
  To: Pjotr Prins; +Cc: 32183-done

Dear Ludo,

If I understand 'guix pull' correctly below should simply not be
possible, right? I mean, once you do a guix pull you have the latest
and the greatest and there should be no interference? Intriguingly
this does not happen on all my systems, just on 2 - notably my laptop
I am using in Southern France ;)

Pj.

On Thu, Sep 06, 2018 at 11:10:33PM +0200, Pjotr Prins wrote:
> On Sun, Sep 02, 2018 at 10:04:32PM +0200, Ludovic Courtès wrote:
> > OK.  Do reopen it if it shows up again.
> 
> Just to report that I did a successful install on one of those
> machines. Starting with a 0.14 guix as root
> 
>   guix pull
> 
> restarted daemon using the new one in /root/.config/current/bin/
> 
> switched to normal user using the guix pointed in that directory
> 
>   /gnu/store/47hhyj0l4nk4na09qx1b66sz1wvpx95i-guix-command pull
> 
> Next I could run 
> 
>   ~/.config/current/bin/guix ...
> 
> everything appeared hunky dory until I need to build a package
> 
> 	/gnu/store/sf84mb2y5vcykwq9fv02l2nipp34qng2-guix-daemon-0.15.0-3.3d43017/libexec/guix/download: line 8: /root/.config/guix/current/bin/guix: Permission denied
> 	/gnu/store/sf84mb2y5vcykwq9fv02l2nipp34qng2-guix-daemon-0.15.0-3.3d43017/libexec/guix/download: line 8: exec: /root/.config/guix/current/bin/guix: cannot execute: Permission denied
> 	builder for `/gnu/store/2q486ivskp2vm2rq10rs4pq949zkcz8h-evaluate_0.11.tar.gz.drv' failed with exit code 126
> 	cannot build derivation `/gnu/store/qaaf8i893x0ivfnw6q19l0rq5gkmlbmj-r-evaluate-0.11.drv': 1 dependencies couldn't be built
> 	cannot build derivation `/gnu/store/frxjc6iwwflasmj3wcm5s2934mgziaj6-r-fansi-0.3.0.drv': 1 dependencies couldn't be built
> 	cannot build derivation `/gnu/store/p3d9km0fi423nl66q5ncvkxcnj2kz6bv-r-rsqlite-2.1.1.drv': 1 dependencies couldn't be built
> 	guix package: error: build failed: build of `/gnu/store/p3d9km0fi423nl66q5ncvkxcnj2kz6bv-r-rsqlite-2.1.1.drv' failed
> 
> Again as root I did another guix pull. It instates the same daemon
> 
>   /root/.config/guix/current/bin/guix-daemon -> /gnu/store/sf84mb2y5vcykwq9fv02l2nipp34qng2-guix-daemon-0.15.0-3.3d43017/bin/guix-daemon
> 
> Now guix pull fails in $USER
> 
>   which guix
>   /home/wrk/.config/guix/current/bin/guix
> 
>   guix pull
> 
> 	Updating channel 'guix' from Git repository at 'https://git.savannah.gnu.org/git/guix.git'...
> 	Building from this channel:
> 		guix      https://git.savannah.gnu.org/git/guix.git   91cc2a3
> 	guile: warning: failed to install locale
> 	substitute: updating substitutes from 'https://mirror.hydra.gnu.org'... 100.0%
> 	substitute: updating substitutes from 'https://mirror.hydra.gnu.org'... 100.0%
> 	Downloading https://mirror.hydra.gnu.org/guix/nar/gzip/xw7kc681ivcls1lpp0qy0xljljzd70dr-groff-1.22.3...
> 	 groff-1.22.3  2.7MiB                                                                   1.2MiB/s 00:02 [##################] 100.0%
> 
> 	/gnu/store/sf84mb2y5vcykwq9fv02l2nipp34qng2-guix-daemon-0.15.0-3.3d43017/libexec/guix/download: line 8: /root/.config/guix/current/bin/guix: Permission denied
> 	/gnu/store/sf84mb2y5vcykwq9fv02l2nipp34qng2-guix-daemon-0.15.0-3.3d43017/libexec/guix/download: line 8: exec: /root/.config/guix/current/bin/guix: cannot execute: Permission denied
> 	builder for `/gnu/store/24ag580271wa640529ycykdwj0lk0g6z-curl-7.61.1.tar.xz.drv' failed with exit code 126
> 	cannot build derivation `/gnu/store/17lw3svpjqygpj739yynyz6b8abddikx-curl-7.61.1.drv': 1 dependencies couldn't be built
> 	Backtrace:
> 						18 (primitive-load "/gnu/store/blfsj798qh4i2pmrcvyaidmsdiz?")
> 	In ice-9/eval.scm:
> 			155:9 17 (_ _)
> 
> Can you think of a way of getting out of this loop? What am I doing wrong here?
> 
> Pj.
> 

^ permalink raw reply	[flat|nested] 29+ messages in thread

* bug#32183: New ‘guix pull’ /root/.config/current/bin/guix: Permission denied
  2018-09-09  7:20             ` Pjotr Prins
@ 2018-09-09 14:02               ` Pjotr Prins
  0 siblings, 0 replies; 29+ messages in thread
From: Pjotr Prins @ 2018-09-09 14:02 UTC (permalink / raw)
  To: Pjotr Prins; +Cc: 32183-done

It is working now. After a guix pull I did a guix package -i guix in a
new profile. Restarting the daemon from there it stopped complaining!

I don't know why the deamon from guix pull straight was not working,
but at least guix is building again.

Pj.

^ permalink raw reply	[flat|nested] 29+ messages in thread

* bug#32183: New ‘guix pull’ /root/.config/current/bin/guix: Permission denied
  2018-09-06 21:10           ` Pjotr Prins
  2018-09-09  7:20             ` Pjotr Prins
@ 2018-09-09 14:44             ` Ludovic Courtès
  2018-09-11  9:34               ` Konrad Hinsen
  1 sibling, 1 reply; 29+ messages in thread
From: Ludovic Courtès @ 2018-09-09 14:44 UTC (permalink / raw)
  To: Pjotr Prins; +Cc: 32183

Hello,

Pjotr Prins <pjotr.public12@thebird.nl> skribis:

>   guix pull
>
> 	Updating channel 'guix' from Git repository at 'https://git.savannah.gnu.org/git/guix.git'...
> 	Building from this channel:
> 		guix      https://git.savannah.gnu.org/git/guix.git   91cc2a3
> 	guile: warning: failed to install locale
> 	substitute: updating substitutes from 'https://mirror.hydra.gnu.org'... 100.0%
> 	substitute: updating substitutes from 'https://mirror.hydra.gnu.org'... 100.0%
> 	Downloading https://mirror.hydra.gnu.org/guix/nar/gzip/xw7kc681ivcls1lpp0qy0xljljzd70dr-groff-1.22.3...
> 	 groff-1.22.3  2.7MiB                                                                   1.2MiB/s 00:02 [##################] 100.0%
>
> 	/gnu/store/sf84mb2y5vcykwq9fv02l2nipp34qng2-guix-daemon-0.15.0-3.3d43017/libexec/guix/download: line 8: /root/.config/guix/current/bin/guix: Permission denied
> 	/gnu/store/sf84mb2y5vcykwq9fv02l2nipp34qng2-guix-daemon-0.15.0-3.3d43017/libexec/guix/download: line 8: exec: /root/.config/guix/current/bin/guix: cannot execute: Permission denied
> 	builder for `/gnu/store/24ag580271wa640529ycykdwj0lk0g6z-curl-7.61.1.tar.xz.drv' failed with exit code 126
> 	cannot build derivation `/gnu/store/17lw3svpjqygpj739yynyz6b8abddikx-curl-7.61.1.drv': 1 dependencies couldn't be built
> 	Backtrace:
> 						18 (primitive-load "/gnu/store/blfsj798qh4i2pmrcvyaidmsdiz?")
> 	In ice-9/eval.scm:
> 			155:9 17 (_ _)
>
> Can you think of a way of getting out of this loop? What am I doing wrong here?

I don’t think you’re doing anything wrong.  Could anyone of you who
experience this problem strace guix-daemon?  I’ve thought about this and
don’t understand where that EACCES (“Permission denied”) comes from.

Specifically, you’d have to run something along these lines as root:

  strace -f -p $(pidof guix-daemon) -o log

and then, as root or non-root (it doesn’t matter), run, say:

  guix build curl -S --no-substitutes

Thanks in advance!

Ludo’.

^ permalink raw reply	[flat|nested] 29+ messages in thread

* bug#32183: New ‘guix pull’ /root/.config/current/bin/guix: Permission denied
  2018-09-09 14:44             ` Ludovic Courtès
@ 2018-09-11  9:34               ` Konrad Hinsen
  2018-09-11 10:12                 ` Ludovic Courtès
  0 siblings, 1 reply; 29+ messages in thread
From: Konrad Hinsen @ 2018-09-11  9:34 UTC (permalink / raw)
  To: Ludovic Courtès, Pjotr Prins; +Cc: 32183

[-- Attachment #1: Type: text/plain, Size: 901 bytes --]

Hi Ludo,

> I don’t think you’re doing anything wrong.  Could anyone of you who
> experience this problem strace guix-daemon?  I’ve thought about this and
> don’t understand where that EACCES (“Permission denied”) comes from.
>
> Specifically, you’d have to run something along these lines as root:
>
>   strace -f -p $(pidof guix-daemon) -o log
>
> and then, as root or non-root (it doesn’t matter), run, say:
>
>   guix build curl -S --no-substitutes

The log file (compressed) is attached.

In doing this I noticed that I have two guix-daemon processes running:

root      1583  0.0  0.0  33156  2412 ?        Ss   08:55   0:00 /root/.config/guix/current/bin/guix-daemon --build-users-group=guixbuild
root     13003  0.0  0.0  36028  6256 ?        Ss   11:28   0:00 /root/.config/guix/current/bin/guix-daemon 12770

I ran strace on the first one.

Konrad.


[-- Attachment #2: guix-daemon-strace.log.gz --]
[-- Type: application/gzip, Size: 15404 bytes --]

^ permalink raw reply	[flat|nested] 29+ messages in thread

* bug#32183: New ‘guix pull’ /root/.config/current/bin/guix: Permission denied
  2018-09-11  9:34               ` Konrad Hinsen
@ 2018-09-11 10:12                 ` Ludovic Courtès
  2018-09-11 13:23                   ` Pjotr Prins
  0 siblings, 1 reply; 29+ messages in thread
From: Ludovic Courtès @ 2018-09-11 10:12 UTC (permalink / raw)
  To: Konrad Hinsen; +Cc: 32183

Hi Konrad,

Konrad Hinsen <konrad.hinsen@fastmail.net> skribis:

>> Specifically, you’d have to run something along these lines as root:
>>
>>   strace -f -p $(pidof guix-daemon) -o log
>>
>> and then, as root or non-root (it doesn’t matter), run, say:
>>
>>   guix build curl -S --no-substitutes
>
> The log file (compressed) is attached.
>
> In doing this I noticed that I have two guix-daemon processes running:
>
> root      1583  0.0  0.0  33156  2412 ?        Ss   08:55   0:00 /root/.config/guix/current/bin/guix-daemon --build-users-group=guixbuild
> root     13003  0.0  0.0  36028  6256 ?        Ss   11:28   0:00 /root/.config/guix/current/bin/guix-daemon 12770
>
> I ran strace on the first one.

Ooh, I see.  The log shows this:

--8<---------------cut here---------------start------------->8---
13795 setgroups(1, [999])               = 0
13795 setgid(999)                       = 0
13795 getgid()                          = 999
13795 getegid()                         = 999
13795 setuid(499)                       = 0
13795 getuid()                          = 499
13795 geteuid()                         = 499

[...]

13795 execve("/gnu/store/sf84mb2y5vcykwq9fv02l2nipp34qng2-guix-daemon-0.15.0-3.3d43017/libexec/guix/download", ["download", "/gnu/store/j3swd19y4wzv6nrr13bv7"..., "/gnu/store/rdlndkf50sn0jq7bqkbhm"...], 0xa26f60 /* 17 vars */) = 0

[...]

13795 execve("/root/.config/guix/current/bin/guix", ["/root/.config/guix/current/bin/g"..., "perform-download", "/gnu/store/j3swd19y4wzv6nrr13bv7"..., "/gnu/store/rdlndkf50sn0jq7bqkbhm"...], 0x6c0530 /* 19 vars */) = -1 EACCES (Permission denied)
13795 stat("/root/.config/guix/current/bin/guix", 0x7fffffffe1d0) = -1 EACCES (Permission denied)
--8<---------------cut here---------------end--------------->8---

The download process is running as a build user, not as root, hence the
permission issue (silly me!).

Now we need to find a way to use ‘guix’ from root’s
~/.config/guix/current.  A solution may be to expose that profile under
/var/guix/profiles.  Needs more thought…

Thanks for helping out!

Ludo’.

^ permalink raw reply	[flat|nested] 29+ messages in thread

* bug#32183: New ‘guix pull’ /root/.config/current/bin/guix: Permission denied
  2018-09-11 10:12                 ` Ludovic Courtès
@ 2018-09-11 13:23                   ` Pjotr Prins
  2018-09-11 13:58                     ` Pjotr Prins
  2018-09-11 14:26                     ` Ludovic Courtès
  0 siblings, 2 replies; 29+ messages in thread
From: Pjotr Prins @ 2018-09-11 13:23 UTC (permalink / raw)
  To: Ludovic Courtès; +Cc: 32183

On Tue, Sep 11, 2018 at 12:12:15PM +0200, Ludovic Courtès wrote:
> The download process is running as a build user, not as root, hence the
> permission issue (silly me!).
> 
> Now we need to find a way to use ‘guix’ from root’s
> ~/.config/guix/current.  A solution may be to expose that profile under
> /var/guix/profiles.  Needs more thought…

Great! Any quick hacks to fix this? Even when I set all permissions open I get in the latest tree

./pre-inst-env guix package -i r-rqda -p ~/opt/rqda --substitute-urls="https://berlin.guixsd.org" --verbose

Building /gnu/store/nknybsl5a9wnfgd9bs13fzmjwa382ys2-libgcrypt-1.8.3.tar.bz2.drv - x86_64-linux
/gnu/store/sf84mb2y5vcykwq9fv02l2nipp34qng2-guix-daemon-0.15.0-3.3d43017/libexec/guix/download: line 8: /root/.config/guix/current/bin/guix: Permission denied
/gnu/store/sf84mb2y5vcykwq9fv02l2nipp34qng2-guix-daemon-0.15.0-3.3d43017/libexec/guix/download: line 8: exec: /root/.config/guix/current/bin/guix: cannot execute: Permission denied
builder for `/gnu/store/nknybsl5a9wnfgd9bs13fzmjwa382ys2-libgcrypt-1.8.3.tar.bz2.drv' failed with exit code 126
Build failed: /gnu/store/nknybsl5a9wnfgd9bs13fzmjwa382ys2-libgcrypt-1.8.3.tar.bz2.drv - 1 builder for `/gnu/store/nknybsl5a9wnfgd9bs13fzmjwa382ys2-libgcrypt-1.8.3.tar.bz2.drv' failed with exit code

^ permalink raw reply	[flat|nested] 29+ messages in thread

* bug#32183: New ‘guix pull’ /root/.config/current/bin/guix: Permission denied
  2018-09-11 13:23                   ` Pjotr Prins
@ 2018-09-11 13:58                     ` Pjotr Prins
  2018-09-11 14:27                       ` Ludovic Courtès
  2018-10-11 16:32                       ` Ludovic Courtès
  2018-09-11 14:26                     ` Ludovic Courtès
  1 sibling, 2 replies; 29+ messages in thread
From: Pjotr Prins @ 2018-09-11 13:58 UTC (permalink / raw)
  To: Pjotr Prins; +Cc: 32183

On Tue, Sep 11, 2018 at 03:23:13PM +0200, Pjotr Prins wrote:
> On Tue, Sep 11, 2018 at 12:12:15PM +0200, Ludovic Courtès wrote:
> > The download process is running as a build user, not as root, hence the
> > permission issue (silly me!).
> > 
> > Now we need to find a way to use ‘guix’ from root’s
> > ~/.config/guix/current.  A solution may be to expose that profile under
> > /var/guix/profiles.  Needs more thought…
> 
> Great! Any quick hacks to fix this? Even when I set all permissions open I get in the latest tree
> 
> ./pre-inst-env guix package -i r-rqda -p ~/opt/rqda --substitute-urls="https://berlin.guixsd.org" --verbose
> 
> Building /gnu/store/nknybsl5a9wnfgd9bs13fzmjwa382ys2-libgcrypt-1.8.3.tar.bz2.drv - x86_64-linux
> /gnu/store/sf84mb2y5vcykwq9fv02l2nipp34qng2-guix-daemon-0.15.0-3.3d43017/libexec/guix/download: line 8: /root/.config/guix/current/bin/guix: Permission denied
> /gnu/store/sf84mb2y5vcykwq9fv02l2nipp34qng2-guix-daemon-0.15.0-3.3d43017/libexec/guix/download: line 8: exec: /root/.config/guix/current/bin/guix: cannot execute: Permission denied
> builder for `/gnu/store/nknybsl5a9wnfgd9bs13fzmjwa382ys2-libgcrypt-1.8.3.tar.bz2.drv' failed with exit code 126
> Build failed: /gnu/store/nknybsl5a9wnfgd9bs13fzmjwa382ys2-libgcrypt-1.8.3.tar.bz2.drv - 1 builder for `/gnu/store/nknybsl5a9wnfgd9bs13fzmjwa382ys2-libgcrypt-1.8.3.tar.bz2.drv' failed with exit code

Hmmm. It fixed itself when I added the mirror substitute URL again.
After that it successfully built ghostscript. Looks like the building
problem only exists in the pre-building track of guix where it builds
packages for its own use?

^ permalink raw reply	[flat|nested] 29+ messages in thread

* bug#32183: New ‘guix pull’ /root/.config/current/bin/guix: Permission denied
  2018-09-11 13:23                   ` Pjotr Prins
  2018-09-11 13:58                     ` Pjotr Prins
@ 2018-09-11 14:26                     ` Ludovic Courtès
  1 sibling, 0 replies; 29+ messages in thread
From: Ludovic Courtès @ 2018-09-11 14:26 UTC (permalink / raw)
  To: Pjotr Prins; +Cc: 32183

Pjotr Prins <pjotr.public12@thebird.nl> skribis:

> On Tue, Sep 11, 2018 at 12:12:15PM +0200, Ludovic Courtès wrote:
>> The download process is running as a build user, not as root, hence the
>> permission issue (silly me!).
>> 
>> Now we need to find a way to use ‘guix’ from root’s
>> ~/.config/guix/current.  A solution may be to expose that profile under
>> /var/guix/profiles.  Needs more thought…
>
> Great! Any quick hacks to fix this?

A quick workaround is to run ‘guix-daemon’ from the ‘guix’ package.  So,
as root, you’d do:

  guix pull             # if you haven’t done it recently
  guix package -i guix  # to install or upgrade guix

Then make sure your systemd (or whatever) config file returns to
/var/guix/profiles/per-user/root/guix-profile/bin/guix-daemon as it
does when you install Guix from the binary tarball.

HTH!

Ludo’.

^ permalink raw reply	[flat|nested] 29+ messages in thread

* bug#32183: New ‘guix pull’ /root/.config/current/bin/guix: Permission denied
  2018-09-11 13:58                     ` Pjotr Prins
@ 2018-09-11 14:27                       ` Ludovic Courtès
  2018-10-11 16:32                       ` Ludovic Courtès
  1 sibling, 0 replies; 29+ messages in thread
From: Ludovic Courtès @ 2018-09-11 14:27 UTC (permalink / raw)
  To: Pjotr Prins; +Cc: 32183

Pjotr Prins <pjotr.public12@thebird.nl> skribis:

> On Tue, Sep 11, 2018 at 03:23:13PM +0200, Pjotr Prins wrote:
>> On Tue, Sep 11, 2018 at 12:12:15PM +0200, Ludovic Courtès wrote:
>> > The download process is running as a build user, not as root, hence the
>> > permission issue (silly me!).
>> > 
>> > Now we need to find a way to use ‘guix’ from root’s
>> > ~/.config/guix/current.  A solution may be to expose that profile under
>> > /var/guix/profiles.  Needs more thought…
>> 
>> Great! Any quick hacks to fix this? Even when I set all permissions open I get in the latest tree
>> 
>> ./pre-inst-env guix package -i r-rqda -p ~/opt/rqda --substitute-urls="https://berlin.guixsd.org" --verbose
>> 
>> Building /gnu/store/nknybsl5a9wnfgd9bs13fzmjwa382ys2-libgcrypt-1.8.3.tar.bz2.drv - x86_64-linux
>> /gnu/store/sf84mb2y5vcykwq9fv02l2nipp34qng2-guix-daemon-0.15.0-3.3d43017/libexec/guix/download: line 8: /root/.config/guix/current/bin/guix: Permission denied
>> /gnu/store/sf84mb2y5vcykwq9fv02l2nipp34qng2-guix-daemon-0.15.0-3.3d43017/libexec/guix/download: line 8: exec: /root/.config/guix/current/bin/guix: cannot execute: Permission denied
>> builder for `/gnu/store/nknybsl5a9wnfgd9bs13fzmjwa382ys2-libgcrypt-1.8.3.tar.bz2.drv' failed with exit code 126
>> Build failed: /gnu/store/nknybsl5a9wnfgd9bs13fzmjwa382ys2-libgcrypt-1.8.3.tar.bz2.drv - 1 builder for `/gnu/store/nknybsl5a9wnfgd9bs13fzmjwa382ys2-libgcrypt-1.8.3.tar.bz2.drv' failed with exit code
>
> Hmmm. It fixed itself when I added the mirror substitute URL again.
> After that it successfully built ghostscript. Looks like the building
> problem only exists in the pre-building track of guix where it builds
> packages for its own use?

The issue affects downloads only (fixed-output derivations, not
substitutes.)

Ludo’.

^ permalink raw reply	[flat|nested] 29+ messages in thread

* bug#32183: New ‘guix pull’ /root/.config/current/bin/guix: Permission denied
  2018-09-11 13:58                     ` Pjotr Prins
  2018-09-11 14:27                       ` Ludovic Courtès
@ 2018-10-11 16:32                       ` Ludovic Courtès
  2018-10-12  6:59                         ` Konrad Hinsen
  2018-10-14 18:12                         ` Pjotr Prins
  1 sibling, 2 replies; 29+ messages in thread
From: Ludovic Courtès @ 2018-10-11 16:32 UTC (permalink / raw)
  To: Pjotr Prins; +Cc: 32183-done

Hi there!

I believe commit ed9d7cb4d95f8f4776e6fee2778ab52bc2852969 fixes it.

That is, if you run ‘guix pull’ as root and then start
~/.config/guix/current/bin/guix-daemon, everything should be fine.

Thanks,
Ludo’.

^ permalink raw reply	[flat|nested] 29+ messages in thread

* bug#32183: New ‘guix pull’ /root/.config/current/bin/guix: Permission denied
  2018-10-11 16:32                       ` Ludovic Courtès
@ 2018-10-12  6:59                         ` Konrad Hinsen
  2018-10-12 12:57                           ` Ludovic Courtès
  2018-10-14 18:12                         ` Pjotr Prins
  1 sibling, 1 reply; 29+ messages in thread
From: Konrad Hinsen @ 2018-10-12  6:59 UTC (permalink / raw)
  To: Ludovic Courtès, Pjotr Prins; +Cc: 32183-done

Hi Ludo,
> I believe commit ed9d7cb4d95f8f4776e6fee2778ab52bc2852969 fixes it.
>
> That is, if you run ‘guix pull’ as root and then start
> ~/.config/guix/current/bin/guix-daemon, everything should be fine.
Let's say the bug seems to be elsewhere now ;-)

When I try to build something after following your instructions, I get 
the error message

/gnu/store/bkkf11ixn67cwcw05nw9w9yd68i4jf23-guix-daemon-0.15.0-5.1d0be47/libexec/guix/download: 
line 8: /var/guix/profiles/per-user/root/current-guix/bin/guix: No such 
file or directory

And indeed there is no guix at that place. I guess it should be

/var/guix/profiles/per-user/root/guix-profile/bin/guix

I can try fixing the download script and testing again, but not before 
next week, sorry!

Konrad.

^ permalink raw reply	[flat|nested] 29+ messages in thread

* bug#32183: New ‘guix pull’ /root/.config/current/bin/guix: Permission denied
  2018-10-12  6:59                         ` Konrad Hinsen
@ 2018-10-12 12:57                           ` Ludovic Courtès
  2018-10-15 11:59                             ` Konrad Hinsen
  0 siblings, 1 reply; 29+ messages in thread
From: Ludovic Courtès @ 2018-10-12 12:57 UTC (permalink / raw)
  To: Konrad Hinsen; +Cc: 32183-done

Hello,

Konrad Hinsen <konrad.hinsen@fastmail.net> skribis:

>> I believe commit ed9d7cb4d95f8f4776e6fee2778ab52bc2852969 fixes it.
>>
>> That is, if you run ‘guix pull’ as root and then start
>> ~/.config/guix/current/bin/guix-daemon, everything should be fine.
> Let's say the bug seems to be elsewhere now ;-)
>
> When I try to build something after following your instructions, I get
> the error message
>
> /gnu/store/bkkf11ixn67cwcw05nw9w9yd68i4jf23-guix-daemon-0.15.0-5.1d0be47/libexec/guix/download:
> line 8: /var/guix/profiles/per-user/root/current-guix/bin/guix: No
> such file or directory

Hmm you might need to run, say, ‘guix pull -l’, to make this script
magically appear.  :-)

Concretely, the new ‘guix pull’ migrates things from ~/.config/guix to
/var/guix/profiles the first time you run it, but it may be that you
haven’t yet run the *new* ‘guix pull’.

HTH,
Ludo’.

^ permalink raw reply	[flat|nested] 29+ messages in thread

* bug#32183: New ‘guix pull’ /root/.config/current/bin/guix: Permission denied
  2018-10-11 16:32                       ` Ludovic Courtès
  2018-10-12  6:59                         ` Konrad Hinsen
@ 2018-10-14 18:12                         ` Pjotr Prins
  1 sibling, 0 replies; 29+ messages in thread
From: Pjotr Prins @ 2018-10-14 18:12 UTC (permalink / raw)
  To: Ludovic Courtès; +Cc: 32183-done

On Thu, Oct 11, 2018 at 06:32:20PM +0200, Ludovic Courtès wrote:
> Hi there!
> 
> I believe commit ed9d7cb4d95f8f4776e6fee2778ab52bc2852969 fixes it.
> 
> That is, if you run ‘guix pull’ as root and then start
> ~/.config/guix/current/bin/guix-daemon, everything should be fine.

It works on one problematic machine. Thanks!

Pj.

^ permalink raw reply	[flat|nested] 29+ messages in thread

* bug#32183: New ‘guix pull’ /root/.config/current/bin/guix: Permission denied
  2018-10-12 12:57                           ` Ludovic Courtès
@ 2018-10-15 11:59                             ` Konrad Hinsen
  2018-10-15 19:33                               ` Ludovic Courtès
  0 siblings, 1 reply; 29+ messages in thread
From: Konrad Hinsen @ 2018-10-15 11:59 UTC (permalink / raw)
  To: Ludovic Courtès; +Cc: 32183-done

Hi Ludo,

> Hmm you might need to run, say, ‘guix pull -l’, to make this script
> magically appear.  :-)
>
> Concretely, the new ‘guix pull’ migrates things from ~/.config/guix to
> /var/guix/profiles the first time you run it, but it may be that you
> haven’t yet run the *new* ‘guix pull’.

That looks like the right direction, since running "guix pull -l" starts 
by saying

    Migrating profile generations to '/var/guix/profiles/per-user/root'...

Unfortunately, its next statement is just as magic but less pleasant:

Backtrace:
            6 (primitive-load "/root/.config/guix/current/bin/guix")
In guix/ui.scm:
   1583:12  5 (run-guix-command _ . _)
In ice-9/boot-9.scm:
     829:9  4 (catch srfi-34 #<procedure 337dc80 at guix/ui.scm:615:…> …)
     829:9  3 (catch system-error #<procedure 337dd20 at guix/script…> …)
     829:9  2 (catch git-error #<procedure 337dbe0 at guix/scripts/p…> …)
     829:9  1 (catch system-error #<procedure 3391a60 at guix/script…> …)
In unknown file:
            0 (raise #<condition &profile-not-found-error [profile: "…>)

ERROR: In procedure raise:
Wrong type (expecting exact integer): #<condition 
&profile-not-found-error [profile: 
"/var/guix/profiles/per-user/root/current-guix"] 338b460>


This looks like an error in an error-raising procedure, something like  
a meta-error ;-)

Looking at

   ~# ls -l /var/guix/profiles/per-user/root/current-guix
    lrwxrwxrwx 1 root root 14 oct.  15 13:51 
/var/guix/profiles/per-user/root/current-guix -> current-4-link

yields  a link that is indeed missing. What I do have is 
current-guix-4-link, but not a plain current-4-link.

Konrad.

^ permalink raw reply	[flat|nested] 29+ messages in thread

* bug#32183: New ‘guix pull’ /root/.config/current/bin/guix: Permission denied
  2018-10-15 11:59                             ` Konrad Hinsen
@ 2018-10-15 19:33                               ` Ludovic Courtès
  2018-10-16 10:41                                 ` Konrad Hinsen
  0 siblings, 1 reply; 29+ messages in thread
From: Ludovic Courtès @ 2018-10-15 19:33 UTC (permalink / raw)
  To: Konrad Hinsen; +Cc: 32183-done

Hi Konrad,

Konrad Hinsen <konrad.hinsen@fastmail.net> skribis:

> This looks like an error in an error-raising procedure, something
> like  a meta-error ;-)

The horror bug department worked hard to deliver this one.  :-)

> Looking at
>
>   ~# ls -l /var/guix/profiles/per-user/root/current-guix
>    lrwxrwxrwx 1 root root 14 oct.  15 13:51
> /var/guix/profiles/per-user/root/current-guix -> current-4-link
>
> yields  a link that is indeed missing. What I do have is
> current-guix-4-link, but not a plain current-4-link.

Yes, it’s one of the thinkos I made, fixed in
aa227b3be3d7728331a08dbd139c47c9b271dc23.

If you’re familiar with Dired in Emacs, I’d suggest opening
/var/guix/profiles/per-user/root and fixing the symlink targets from
there (with C-c C-q).

If not I can try and come up with a script to do that.

Apologies for the mess!

Ludo’.

^ permalink raw reply	[flat|nested] 29+ messages in thread

* bug#32183: New ‘guix pull’ /root/.config/current/bin/guix: Permission denied
  2018-10-15 19:33                               ` Ludovic Courtès
@ 2018-10-16 10:41                                 ` Konrad Hinsen
  2018-10-17  8:44                                   ` Ludovic Courtès
  0 siblings, 1 reply; 29+ messages in thread
From: Konrad Hinsen @ 2018-10-16 10:41 UTC (permalink / raw)
  To: Ludovic Courtès; +Cc: 32183-done

Hi Ludo,

> If you’re familiar with Dired in Emacs, I’d suggest opening
> /var/guix/profiles/per-user/root and fixing the symlink targets from
> there (with C-c C-q).

Done. And after rebooting, guix seems to work fine for root, including
the download phase. Meaning that I consider this bug fixed.

But there still seems to be some collateral damage, since I could not
use "guix pull" any more on my standard user account:

  $ guix pull
  Migrating profile generations to '/var/guix/profiles/per-user/hinsen'...
  guix pull: error: rename-file: Invalid cross-device link

This looks like guix is trying to use a hard link instead of a symbolic
link somewhere. I found a way around which I describe here for the
benefit of others who might find themselves in the same situation:

 - check out a local copy of the Guix repository 
 - configure and make as described in the manual
 - ./pre-inst-env guix pull

That does the profile migration using the very latest code. After that
the standard guix command seems to work fine again.

Konrad.

^ permalink raw reply	[flat|nested] 29+ messages in thread

* bug#32183: New ‘guix pull’ /root/.config/current/bin/guix: Permission denied
  2018-10-16 10:41                                 ` Konrad Hinsen
@ 2018-10-17  8:44                                   ` Ludovic Courtès
  2018-10-17  9:17                                     ` Konrad Hinsen
  0 siblings, 1 reply; 29+ messages in thread
From: Ludovic Courtès @ 2018-10-17  8:44 UTC (permalink / raw)
  To: Konrad Hinsen; +Cc: 32183-done

Hello Konrad,

Konrad Hinsen <konrad.hinsen@fastmail.net> skribis:

> But there still seems to be some collateral damage, since I could not
> use "guix pull" any more on my standard user account:
>
>   $ guix pull
>   Migrating profile generations to '/var/guix/profiles/per-user/hinsen'...
>   guix pull: error: rename-file: Invalid cross-device link

This was fixed in a subsequent commit:

  https://git.savannah.gnu.org/cgit/guix.git/commit/?id=8036b0942b89022147aaf9cd9940988fdbcc19ef

To work around it, you can pull from an older generation, along these
lines:

  ~/.config/guix/current-42-link/bin/guix pull

(This will work because this older guix won’t attempt to move your
generations to /var/guix/profiles, so it allows you to “jump over” the
bug.)

Let me know how it goes!

It’s terrible that a function like this that looks trivial has been
causing so much trouble.  Sorry about that.  :-/

Ludo’.

^ permalink raw reply	[flat|nested] 29+ messages in thread

* bug#32183: New ‘guix pull’ /root/.config/current/bin/guix: Permission denied
  2018-10-17  8:44                                   ` Ludovic Courtès
@ 2018-10-17  9:17                                     ` Konrad Hinsen
  2018-10-17 23:06                                       ` Ludovic Courtès
  2018-11-02 14:38                                       ` swedebugia
  0 siblings, 2 replies; 29+ messages in thread
From: Konrad Hinsen @ 2018-10-17  9:17 UTC (permalink / raw)
  To: Ludovic Courtès; +Cc: 32183-done

Hi Ludo,

> To work around it, you can pull from an older generation, along these
> lines:
>
>   ~/.config/guix/current-42-link/bin/guix pull
>
> (This will work because this older guix won’t attempt to move your
> generations to /var/guix/profiles, so it allows you to “jump over” the
> bug.)
>
> Let me know how it goes!

I cannot try any more because I already used another workaround, meaning
that my profiles are properly migrated.

> It’s terrible that a function like this that looks trivial has been
> causing so much trouble.  Sorry about that.  :-/

Lesson learned: avoid messing around with mutable state. How about
creating a functional package manager?  ;-)

Konrad.

^ permalink raw reply	[flat|nested] 29+ messages in thread

* bug#32183: New ‘guix pull’ /root/.config/current/bin/guix: Permission denied
  2018-10-17  9:17                                     ` Konrad Hinsen
@ 2018-10-17 23:06                                       ` Ludovic Courtès
  2018-11-02 14:38                                       ` swedebugia
  1 sibling, 0 replies; 29+ messages in thread
From: Ludovic Courtès @ 2018-10-17 23:06 UTC (permalink / raw)
  To: Konrad Hinsen; +Cc: 32183-done

Konrad Hinsen <konrad.hinsen@fastmail.net> skribis:

>> To work around it, you can pull from an older generation, along these
>> lines:
>>
>>   ~/.config/guix/current-42-link/bin/guix pull
>>
>> (This will work because this older guix won’t attempt to move your
>> generations to /var/guix/profiles, so it allows you to “jump over” the
>> bug.)
>>
>> Let me know how it goes!
>
> I cannot try any more because I already used another workaround, meaning
> that my profiles are properly migrated.

Good.

>> It’s terrible that a function like this that looks trivial has been
>> causing so much trouble.  Sorry about that.  :-/
>
> Lesson learned: avoid messing around with mutable state. How about
> creating a functional package manager?  ;-)

That’s an idea worth pondering.  :-)

Ludo’.

^ permalink raw reply	[flat|nested] 29+ messages in thread

* bug#32183: New ‘guix pull’ /root/.config/current/bin/guix: Permission denied
  2018-10-17  9:17                                     ` Konrad Hinsen
  2018-10-17 23:06                                       ` Ludovic Courtès
@ 2018-11-02 14:38                                       ` swedebugia
  2018-11-03 14:13                                         ` Ludovic Courtès
  1 sibling, 1 reply; 29+ messages in thread
From: swedebugia @ 2018-11-02 14:38 UTC (permalink / raw)
  To: Konrad Hinsen, Ludovic Courtès; +Cc: 32183-done

Hi

On 2018-10-17 11:17, Konrad Hinsen wrote:
>
> Lesson learned: avoid messing around with mutable state. How about
> creating a functional package manager?  ;-)
LOL

This whole update to guix pull was somewhat a breaking change, but 
unfortunately it was very hard to imagine the repercussions (horrible 
bugs) down the line...

Could it have been completely avoided by introducing it as such and 
forced people to reinstall/upgrade by reinstall (overwriting all files 
and invalidating the store etc.)?

-- 
Cheers
Swedebugia

^ permalink raw reply	[flat|nested] 29+ messages in thread

* bug#32183: New ‘guix pull’ /root/.config/current/bin/guix: Permission denied
  2018-11-02 14:38                                       ` swedebugia
@ 2018-11-03 14:13                                         ` Ludovic Courtès
  0 siblings, 0 replies; 29+ messages in thread
From: Ludovic Courtès @ 2018-11-03 14:13 UTC (permalink / raw)
  To: swedebugia; +Cc: 32183-done

Hello,

swedebugia <swedebugia@riseup.net> skribis:

> This whole update to guix pull was somewhat a breaking change, but
> unfortunately it was very hard to imagine the repercussions (horrible
> bugs) down the line...
>
> Could it have been completely avoided by introducing it as such and
> forced people to reinstall/upgrade by reinstall (overwriting all files
> and invalidating the store etc.)?

Fundamentally, it’s just about moving files from ~/.config/guix to
/var/guix/profiles/per-user/$USER, which I thought was fairly harmless.

Also, the bug was around for a few days.  Those who were away during
those days didn’t notice.

That said, I agree this was poorly handled.  One way to improve it would
be to have several people run the code on their machine before it goes
to master (it’s the kind of code for which we can hardly write unit
tests, and it’s single-use code.)

Thanks,
Ludo’.

^ permalink raw reply	[flat|nested] 29+ messages in thread

end of thread, other threads:[~2018-11-03 14:14 UTC | newest]

Thread overview: 29+ messages (download: mbox.gz follow: Atom feed
-- links below jump to the message on this page --
     [not found] <20180717085541.g6nuycopf5kxoin7@thebird.nl>
     [not found] ` <20180717191554.GA23234@jasmine.lan>
2018-07-17 22:28   ` bug#32183: New ‘guix pull’ /root/.config/current/bin/guix: Permission denied Ludovic Courtès
2018-07-23 22:28 ` Pjotr Prins
2018-07-26 13:50   ` Ludovic Courtès
2018-09-02 13:55     ` Ludovic Courtès
2018-09-02 14:28       ` Pjotr Prins
2018-09-02 20:04         ` Ludovic Courtès
2018-09-06 21:10           ` Pjotr Prins
2018-09-09  7:20             ` Pjotr Prins
2018-09-09 14:02               ` Pjotr Prins
2018-09-09 14:44             ` Ludovic Courtès
2018-09-11  9:34               ` Konrad Hinsen
2018-09-11 10:12                 ` Ludovic Courtès
2018-09-11 13:23                   ` Pjotr Prins
2018-09-11 13:58                     ` Pjotr Prins
2018-09-11 14:27                       ` Ludovic Courtès
2018-10-11 16:32                       ` Ludovic Courtès
2018-10-12  6:59                         ` Konrad Hinsen
2018-10-12 12:57                           ` Ludovic Courtès
2018-10-15 11:59                             ` Konrad Hinsen
2018-10-15 19:33                               ` Ludovic Courtès
2018-10-16 10:41                                 ` Konrad Hinsen
2018-10-17  8:44                                   ` Ludovic Courtès
2018-10-17  9:17                                     ` Konrad Hinsen
2018-10-17 23:06                                       ` Ludovic Courtès
2018-11-02 14:38                                       ` swedebugia
2018-11-03 14:13                                         ` Ludovic Courtès
2018-10-14 18:12                         ` Pjotr Prins
2018-09-11 14:26                     ` Ludovic Courtès
2018-09-05 15:27 ` bug#32183: Me too! Konrad Hinsen

Code repositories for project(s) associated with this public inbox

	https://git.savannah.gnu.org/cgit/guix.git

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).