Latest LQ Deal: Linux Power User Bundle
Go Back > Forums > Linux Forums > Linux - Newbie
User Name
Linux - Newbie This Linux forum is for members that are new to Linux.
Just starting out and have a question? If it is not in the man pages or the how-to's this is the place!


  Search this Thread
Old 03-18-2004, 10:45 PM   #1
Registered: Mar 2004
Distribution: Debian 'Sarge'
Posts: 168

Rep: Reputation: 30
How to edit default PATH?

[root@branch etc]# echo $PATH
[root@branch etc]# /usr/kerberos/sbin:/usr/kerberos/bin:/usr/local/bin:/usr/bin:/bin:/usr/X11R6/bin

I could not find this path string in either /etc/profile, /etc/bash_profile, ~/.bash_profile, or ~/bashrc. What is the file that contains the above PATH string from which I can edit?

Using Fedora distro.
Old 03-18-2004, 11:33 PM   #2
LQ Addict
Registered: Dec 2003
Location: Maine, USA
Distribution: Slackware/SuSE/DSL
Posts: 1,320

Rep: Reputation: 45
It's probably in a system-wide startup script...maybe in multiple scripts. You don't need to edit that script to modify your path...just add PATH=$PATH:/new/path:/another/new/path to one of the files you mentioned and your new paths will be appended.
Personally I put everything in ~/.bashrc and source that from ~/.bash_profile, and I haven't had any trouble yet.
Old 03-20-2004, 06:34 AM   #3
LQ Guru
Registered: Aug 2001
Location: Fargo, ND
Distribution: SuSE AMD64
Posts: 15,733

Rep: Reputation: 677Reputation: 677Reputation: 677Reputation: 677Reputation: 677Reputation: 677
Adding to the PATH variable should be done in ~/.bash_profile. This will run when you log in. You don't want it to run everytime that you open up a new shell, which ~/.bashrc would do.


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
edit value of PATH permanently rsumbeling Linux - General 2 12-13-2004 11:57 AM
How do I edit my path? Echo Kilo Linux - General 3 12-12-2004 02:50 PM
How to edit the value of $PATH? ICO Slackware 1 02-07-2004 05:38 AM
how do i edit my echo$PATH Laptop2250 Linux - Newbie 6 11-15-2003 12:33 PM
Install problems/Do I edit the path? Toker Linux - Newbie 15 10-24-2003 02:33 AM > Forums > Linux Forums > Linux - Newbie

All times are GMT -5. The time now is 02:21 PM.

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