[prev in list] [next in list] [prev in thread] [next in thread] 

List:       pkg-shadow-devel
Subject:    [Pkg-shadow-devel] Bug#918754: PATH is missing sbin
From:       David Lawyer <davylawyer1 () gmail ! com>
Date:       2019-09-06 18:33:32
Message-ID: CA+Ec_uMfxuTHo8n4NgAKC8Ztk+2p3tjoUh=SkZd-g0KH-Xb+OA () mail ! gmail ! com
[Download RAW message or body]

[Attachment #2 (multipart/alternative)]


I installed Debian 10 from a usb drive, had this problem, and solved it..
The PATH environment variable is set in /etc/profile but since /etc/profile
is only run by a login shell and there is no login shell, /etc/profile
never runs and it never has a chance to set PATH.  I use the lxde GUI.
Booting the PC takes me to the login to lxde and I login.  However I don't
get any shell.  Then from the desktop I start xterm (or the like).  This
starts a shell but it's not a login shell since I'm already logged in.  So
there is no login shell and /etc/profile is never run.

There are at least a couple of ways to solve this.  One is to type su
--login (instead of just su) to create a login shell and become the su.
Another is to set PATH in /etc/bash.bashrc.  But don't copy the contents of
/etc/profile to /etc/bash.bashrc for if you do you will create an infinite
loop since /etc/profile calls /etc/bash.bashrc which make the bashrc file
call itself creating an infinite loop.  You have to be selective in what
you copy to bashrc.  The fix that's needed is perhaps to modify
/etc/bash,bashrc for the bash package.

[Attachment #5 (text/html)]

<div dir="ltr">I installed Debian 10 from a usb drive, had this problem, and solved \
it..   The PATH environment variable is set in /etc/profile but since /etc/profile is \
only run by a login shell and there is no login shell, /etc/profile never runs and it \
never has a chance to set PATH.   I use the lxde GUI.   Booting the PC takes me to \
the login to lxde and I login.   However I don&#39;t get any shell.   Then from the \
desktop I start xterm (or the like).   This starts a shell but it&#39;s not a login \
shell since I&#39;m already logged in.   So there is no login shell and /etc/profile \
is never run.<div><br></div><div>There are at least a  couple  of ways to solve this. \
One is to type su --login (instead of just su) to create a login shell and become the \
su.   Another is to set PATH in /etc/bash.bashrc.   But don&#39;t copy the contents \
of /etc/profile to /etc/bash.bashrc for if you do you will create an infinite loop \
since  /etc/profile calls /etc/bash.bashrc which  make the bashrc file call itself \
creating an infinite loop.   You have to be selective in what you copy to bashrc.   \
The fix that&#39;s needed is perhaps to modify /etc/bash,bashrc for the bash \
package.</div></div>


[Attachment #6 (text/plain)]

_______________________________________________
Pkg-shadow-devel mailing list
Pkg-shadow-devel@alioth-lists.debian.net
https://alioth-lists.debian.net/cgi-bin/mailman/listinfo/pkg-shadow-devel

[prev in list] [next in list] [prev in thread] [next in thread] 

Configure | About | News | Add a list | Sponsored by KoreLogic