LinuxQuestions.org
Visit Jeremy's Blog.
Go Back   LinuxQuestions.org > Forums > Linux Forums > Linux - Distributions > Debian
User Name
Password
Debian This forum is for the discussion of Debian Linux.

Notices


Reply
  Search this Thread
Old 01-07-2005, 08:53 PM   #1
dezert_fox
LQ Newbie
 
Registered: Mar 2004
Distribution: Debian (sarge)
Posts: 23

Rep: Reputation: 15
Sarge, KDE 3.2.3: modifying /etc/profile doesn't change path


So, I'm trying to add /usr/java/bin and /usr/java/jre/bin to my path. I've edited /etc/profile, so it looks like this:

# /etc/profile: system-wide .profile file for the Bourne shell (sh(1))
# and Bourne compatible shells (bash(1), ksh(1), ash(1), ...).

if [ "`id -u`" -eq 0 ]; then
PATH="/usr/local/sbin:/usr/local/bin:/usr/sbin:/usr/bin:/sbin:/bin:/usr/bin/X11"
else
PATH="/usr/local/bin:/usr/bin:/bin:/usr/bin/X11:/usr/games:/usr/java/bin:/usr/java/jre/bin"
fi

if [ "$PS1" ]; then
if [ "$BASH" ]; then
PS1='\u@\h:\w\$ '
else
if [ "`id -u`" -eq 0 ]; then
PS1='# '
else
PS1='$ '
fi
fi
fi

export PATH

umask 022

However, when I echo $PATH, I get:
/usr/local/bin:/usr/bin:/bin:/usr/bin/X11:/usr/games
which is obviously missing what I added.
Shell is /bin/bash, and modifying .bash_profile in my user directory doesn't seem to do anything either... any ideas what's up?
 
Old 01-08-2005, 12:23 PM   #2
rbochan
Member
 
Registered: Dec 2004
Location: Central New York
Distribution: Debian
Posts: 218

Rep: Reputation: 30
Are you making sure to log out? Changes won't take effect until you do.
 
Old 01-08-2005, 09:11 PM   #3
dezert_fox
LQ Newbie
 
Registered: Mar 2004
Distribution: Debian (sarge)
Posts: 23

Original Poster
Rep: Reputation: 15
Yeah, I log out and back in and nothing changes. My /etc/profile has been like that for weeks actually, but I still don't have the appropriate path.
 
Old 01-11-2005, 07:40 AM   #4
vesal
LQ Newbie
 
Registered: Jan 2005
Posts: 1

Rep: Reputation: 0
same problem

I have the same problem...

do something like
rgrep "<part of your $PATH variable that seems default>" /etc

for me it matches
/etc/kde3/kdm/kdmrc:# Default is "/usr/local/bin:/usr/bin:/bin:/usr/X11R6/bin:/usr/games"

I guess by setting the UserPath in that file, it might work...
Also, it seems to me that /etc/profile works if you login outside X...
 
Old 01-11-2005, 08:22 AM   #5
kostian
Member
 
Registered: Jul 2004
Location: LT
Posts: 150

Rep: Reputation: 15
look for files .bashrc .bash_profile .profile in your home folder. they override system wide settings for a user.
 
Old 01-11-2005, 10:22 PM   #6
f1dave
Member
 
Registered: Jan 2005
Location: Kinross, Western Australia
Distribution: Kubuntu 5.04 (Hoary)
Posts: 114

Rep: Reputation: 15
I at one stage had the same problem, however there are two really great tutorials (one of which from memory is by Sun) freely available on the net. I don't have the addresses on hand, but I'm sure a quick trip to google searching for 'installing java linux' will yield more than enough results. They helped me out no end.
 
  


Reply


Thread Tools Search this Thread
Search this Thread:

Advanced Search

Posting Rules
You may not post new threads
You may not post replies
You may not post attachments
You may not edit your posts

BB code is On
Smilies are On
[IMG] code is Off
HTML code is Off



Similar Threads
Thread Thread Starter Forum Replies Last Post
Modifying the PATH environment variable brunnopessoa Linux - Newbie 11 11-03-2004 10:23 PM
How to change Fedoras PATH in profile Lawful Linux - Newbie 1 04-30-2004 08:19 PM
Modifying system-wide include path in Fedora Ross Clement Fedora 0 02-21-2004 03:14 AM
modifying $PATH in bashrc gargamel237 Linux - Software 4 08-13-2003 12:10 PM
How to change PATH in KDE chem1 Linux - General 3 10-09-2002 10:14 PM

LinuxQuestions.org > Forums > Linux Forums > Linux - Distributions > Debian

All times are GMT -5. The time now is 08:58 AM.

Main Menu
Advertisement
My LQ
Write for LQ
LinuxQuestions.org is looking for people interested in writing Editorials, Articles, Reviews, and more. If you'd like to contribute content, let us know.
Main Menu
Syndicate
RSS1  Latest Threads
RSS1  LQ News
Twitter: @linuxquestions
Open Source Consulting | Domain Registration