You are not logged in.

#1 2012-05-28 08:34:06

xorgx3
Member
From: Poland
Registered: 2011-11-29
Posts: 197

[SOLVED]Default PATH is broken

My default PATH is broken and I don't know how fix this. Now I have to using /usr/sbin/useradd instead of useradd etc.
Because of it I can't install for example mysql.


My /etc/profile:

# /etc/profile

#Set our umask
umask 022

# Set our default path
PATH="/usr/local/bin:/usr/bin:/bin:/usr/local/sbin:/usr/sbin:/sbin"
export PATH

# Load profiles from /etc/profile.d
if test -d /etc/profile.d/; then
	for profile in /etc/profile.d/*.sh; do
		test -r "$profile" && . "$profile"
	done
	unset profile
fi

# Source global bash config
if test "$PS1" && test "$BASH" && test -r /etc/bash.bashrc; then
	. /etc/bash.bashrc
fi

# Termcap is outdated, old, and crusty, kill it.
unset TERMCAP

# Man is much better than us at figuring this out
unset MANPATH
$ echo $PATH
/bin:/usr/bin:/usr/local/bin

Last edited by xorgx3 (2012-05-28 10:37:17)

Offline

#2 2012-05-28 08:45:21

skunktrader
Member
From: Brisbane, Australia
Registered: 2010-02-14
Posts: 1,543

Re: [SOLVED]Default PATH is broken

Do you use slim?  If yes, what is the value of default_path in slim.conf?

Last edited by skunktrader (2012-05-28 08:45:35)

Offline

#3 2012-05-28 10:13:31

xorgx3
Member
From: Poland
Registered: 2011-11-29
Posts: 197

Re: [SOLVED]Default PATH is broken

Yes, I am using slim, and:

default_path        /bin:/usr/bin:/usr/local/bin

Offline

#4 2012-05-28 10:16:02

skunktrader
Member
From: Brisbane, Australia
Registered: 2010-02-14
Posts: 1,543

Re: [SOLVED]Default PATH is broken

Don't forget to mark this thread as solved.

Offline

#5 2012-05-28 10:20:48

xorgx3
Member
From: Poland
Registered: 2011-11-29
Posts: 197

Re: [SOLVED]Default PATH is broken

Topic isn't solved yet. I have to change this line? This line should looks like :

/usr/local/bin:/usr/bin:/bin:/usr/local/sbin:/usr/sbin:/sbin

?

EDIT:
OK, I changed this line, and now working, thanks for help.

Last edited by xorgx3 (2012-05-28 10:37:03)

Offline

Board footer

Powered by FluxBB