GNU bug report logs - #36785
'sudo guix pull' failure in the profile migration code

Previous Next

Package: guix;

Reported by: Julien Lepiller <julien <at> lepiller.eu>

Date: Wed, 24 Jul 2019 14:41:02 UTC

Severity: normal

Merged with 37148

Done: Ludovic Courtès <ludo <at> gnu.org>

Bug is archived. No further changes may be made.

Full log


View this message in rfc822 format

From: Maxim Cournoyer <maxim.cournoyer <at> gmail.com>
To: Ludovic Courtès <ludo <at> gnu.org>
Cc: 36785 <at> debbugs.gnu.org, Gábor Boskovits <boskovits <at> gmail.com>
Subject: bug#36785: Impossible to pull on foreign distro
Date: Mon, 23 Sep 2019 23:09:52 +0900
Hello,

Ludovic Courtès <ludo <at> gnu.org> writes:

> Hi Maxim,
>
> Maxim Cournoyer <maxim.cournoyer <at> gmail.com> skribis:
>
>> --- a/doc/guix.texi
>> +++ b/doc/guix.texi
>> @@ -2387,8 +2387,8 @@ Success, you've now booted into Guix System!  From then on, you can update the
>>  system whenever you want by running, say:
>>  
>>  @example
>> -guix pull
>> -sudo guix system reconfigure /etc/config.scm
>> +sudo -i guix pull
>> +sudo -i guix system reconfigure /etc/config.scm
>>  @end example
>>  
>>  @noindent
>> @@ -2396,14 +2396,6 @@ This builds a new system generation with the latest packages and services
>>  (@pxref{Invoking guix system}).  We recommend doing that regularly so that
>>  your system includes the latest security updates (@pxref{Security Updates}).
>>  
>> -@c See <https://lists.gnu.org/archive/html/guix-devel/2019-01/msg00268.html>.
>> -@quotation Note
>> -@cindex sudo vs. @command{guix pull}
>> -Note that @command{sudo guix} runs your user's @command{guix} command and
>> -@emph{not} root's, because @command{sudo} leaves @code{PATH} unchanged.  To
>> -explicitly run root's @command{guix}, type @command{sudo -i guix @dots{}}.
>> -@end quotation
>
> I think these bits were correct.

They are correct when applied to a Guix System; what my commits aim to
do is make them generally true regardless of the Guix System vs foreign
distro situation, in an attempt to negate possible confusion.  It's not
succeeding, obviously :-).

I had modified that bit of the manual because that's apparently the only
place where we mention 'sudo guix pull' in the manual.

In the commit message I wrote:

   Although this section is specific to Guix System, it is likely to be
   read by users of foreign GNU/Linux distributions as well.  Remove the
   note, given that sudo doesn't preserve the user's PATH on foreign
   distributions such as Debian.

> That is, when running “sudo foo”, “foo” is looked up in the user’s
> $PATH, not in root’s $PATH.  That’s what led to this text in commit
> 796a4491fdaa4a0a3d669457b89356f9fbfc966e.
>
> So this part is fine.
>
> Perhaps we need another section for this?  Or perhaps we can drop the
> ball…

Agreed, until more real use cases come so that the proper solution can
be more clear (in regards to what needs to be changed in the manual).

Maxim




This bug report was last modified 5 years and 235 days ago.

Previous Next


GNU bug tracking system
Copyright (C) 1999 Darren O. Benham, 1997,2003 nCipher Corporation Ltd, 1994-97 Ian Jackson.