NetBSD-Users archive

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index][Old Index]

Re: modifying default PATH

On Thu, Mar 18, 2010 at 11:06:19AM -0500, Woodchuck wrote:
> On Thu, Mar 18, 2010 at 9:43 AM, Larson, Timothy E. 
> <> wrote:
> > How can I modify the default PATH for all users? ?The daemon user that runs 
> > xscreensaver when nobody's on the console seemingly does not have 
> > /usr/pkg/bin, so there are error messages. ?With no real shell, I don't 
> > think /etc/profile applies.
> >
> >
> > Thanks,
> > Tim
> Supposedly that is governed in /etc/login.conf.  However, my (default)
> version consists of nothing but comments; the comments are nonetheless
> illuminating:
> # The default values
> # Any value changed in the daemon class should be reset in default
> # class.
> #
> #default:\
> #       :path=/usr/bin /bin /usr/sbin /sbin /usr/X11R7/bin
> /usr/X11R6/bin /usr/pkg/bin /usr/pkg/sbin /usr/local/bin:\
> #       :umask=022:\
> #       :datasize-max=512M:\
> #       :datasize-cur=512M:\
> #       :maxproc-max=128:\
> #       :maxproc-cur=64:\
> #       :openfiles-cur=64:\
> #       :stacksize-cur=4M:
> This would suggest that user daemon ought to be seeing  /usr/pkg/*bin.
> (Actually, login class "daemon".  *user* daemon is not assigned to
> any login class in the default /etc/*passwd,  (nor is anyone else).
> So I presume user daemon is assigned by default to class "default"
> and should see the /usr/pkg/*bin.
> Is that a confusing enough use of the word "default"?
> I'm looking at 5.0 (stable) updated as of last week.
> Seeing your specific error messages, of course, would be a big
> help.
> Dave
> -- 
> teh googlez read my emails 'n' STUFF!!!!  LOLZ!!! urz 2!!! LOLZ!!!
login.conf does indeed work. The user class(default, daemon) maps to the
"-L" argument to useradd.

One of the 1st things I do is uncomment login.conf and set up the paths
I want. Unfortunately some of the other settings don't work well with
newer apps and need to be also changed if you run things like gtk-gnutella.

Are your users coming directly into X11? Like xdm, gdm, and their ilk?
That stuff drives me somewhat crazy because it bypasses login.conf
and the path settings are set up differently for each one. The man page
for whichever one you use should explain how to set up the paths.
There are usually two settings in these cases: one for users and one
for root.
SDF Public Access UNIX System -

Home | Main Index | Thread Index | Old Index