Welcome to the most active Linux Forum on the web.
Go Back > Forums > Linux Forums > Linux - General
User Name
Linux - General This Linux forum is for general Linux questions and discussion.
If it is Linux Related and doesn't seem to fit in any other forum then this is the place.


  Search this Thread
Old 12-12-2004, 04:27 AM   #1
LQ Newbie
Registered: Aug 2004
Posts: 25

Rep: Reputation: 15
export PATH disappears

I am having a problem exporting a new PATH. In a shell I entered as root;
so as to get the executable file acoread.
While in the same shell I check the PATH via echo $PATH and the new row shows up.
Now I try to make the change permanent via;
export PATH

After exiting the shell and starting a new one the recently entered PATH has disappeared.

Anybody have any ideas why this is happening?

I am running Mandrake 10.1 with KDE.

Old 12-12-2004, 04:34 AM   #2
LQ Guru
Registered: Mar 2002
Location: Salt Lake City, UT - USA
Distribution: Gentoo ; LFS ; Kubuntu
Posts: 12,612

Rep: Reputation: 68
export PATH does not maintain across new bash sessions. To make permanent changes to your PATH you have to place them in a location that bash will execute every time it's launched, for example, ~/.bash_profile or globally /etc/profile

Old 12-12-2004, 10:46 AM   #3
LQ Newbie
Registered: Aug 2004
Posts: 25

Original Poster
Rep: Reputation: 15
But I thought that was exactly what the "export PATH" command did.
I do not need to use that command as long as I am still running the same shell where I wrote the PATH=$PATH.... command.
There must be a way of making it permanent without editing one or more files.


Old 12-12-2004, 11:01 PM   #4
Senior Member
Registered: Nov 2003
Location: Perth, Western Australia
Distribution: Ubuntu, Debian, Various using VMWare
Posts: 2,088

Rep: Reputation: 62
There must be a way of making it permanent without editing one or more files.
No, theres not. As MasterC said, you need to add the line:
export PATH=$PATH:/usr/local/whatever
to the ~/.bash_profile file.

Alternatively, since there is only one executable in the Acrobat5 bin directory, simply make a symbolic link to acroread somewhere in your PATH:
ln -s /usr/local/Acrobat5/bin/acroread /usr/bin
Then you can start acrobat by typing "acroread" in the xterm.

I hope this helps
Old 12-13-2004, 03:57 AM   #5
LQ Newbie
Registered: Aug 2004
Posts: 25

Original Poster
Rep: Reputation: 15
I will try both ways.

Thank you both for your help!


Last edited by twallstr; 12-13-2004 at 03:58 AM.


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 On
HTML code is Off

Similar Threads
Thread Thread Starter Forum Replies Last Post
Image Path reference in Linux (Absolute path) javabuddy Linux - General 7 06-05-2006 08:45 AM
PATH export in etc/profile.local adds dir twice tongar Linux - Newbie 3 06-16-2005 04:56 PM
export $PATH inside script gmitra Programming 3 02-01-2005 09:34 AM
'export PATH' does not work lemuel Linux - Newbie 7 01-30-2005 12:39 PM
How to Chnage Python's module search path (sys.path)? lramos85 Linux - Software 1 05-02-2004 07:10 PM > Forums > Linux Forums > Linux - General

All times are GMT -5. The time now is 10:26 AM.

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