LinuxQuestions.org
Review your favorite Linux distribution.
Go Back   LinuxQuestions.org > Forums > Linux Forums > Linux - Distributions > SUSE / openSUSE
User Name
Password
SUSE / openSUSE This Forum is for the discussion of Suse Linux.

Notices


Reply
  Search this Thread
Old 02-14-2007, 09:48 AM   #1
swampdog2002
Member
 
Registered: Jul 2005
Distribution: Slackware 12.2, 13.0, openSUSE 11.2
Posts: 397

Rep: Reputation: 33
Editing User Path openSuSE 10.2


I was wondering how to properly edit a path for both a specific user and for all users. I read the document in /etc/profiles that stated not to edit that file, but rather create a profile for each user. I need to add a path to my profile, and saw that in ~/.profile there were some path statements. I'm not too familiar with the syntax in /etc/profiles, but I need to add a path to /usr/local/sbin at least for my account, but possibly for all users as well. I saw a statement in /etc/profiles similar to the following:

PATH=/usr/bin:/usr/local/bin: (and so forth)

but it was preceded by a few statements that appeared to be setting the paths if certain conditions were met, so I am not sure about this. Any assistance is greatly appreciated.

Last edited by swampdog2002; 02-14-2007 at 09:49 AM.
 
Old 02-14-2007, 11:23 AM   #2
bigrigdriver
LQ Addict
 
Registered: Jul 2002
Location: East Centra Illinois, USA
Distribution: Debian stable
Posts: 5,898

Rep: Reputation: 353Reputation: 353Reputation: 353Reputation: 353
To see what is currently in the users path, from the command line, do

echo $PATH

to add to the path, do

PATH=$PATH:/usr/bin:/usr/local/bin
export PATH
 
Old 02-14-2007, 08:15 PM   #3
swampdog2002
Member
 
Registered: Jul 2005
Distribution: Slackware 12.2, 13.0, openSUSE 11.2
Posts: 397

Original Poster
Rep: Reputation: 33
Thanks for the reply. This seemed to work, however it did not save the changes once I exited from the console and started a new one. Do I have to use the sudo command in order to save the cahnges? Also, does this attempt to update the local user path, or system-wide?
 
  


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
editing $PATH resist_r Linux - Newbie 3 07-09-2005 10:33 PM
Editing Path and LD_LIBRARY_PATH Nappa Slackware 5 11-24-2003 12:14 AM
Editing my $PATH variable bml Linux - General 6 03-25-2003 09:14 PM
PATH editing... Jester888 Linux - Newbie 2 01-23-2002 09:13 PM
Editing the PATH Cichlid Linux - General 3 01-06-2002 08:47 PM

LinuxQuestions.org > Forums > Linux Forums > Linux - Distributions > SUSE / openSUSE

All times are GMT -5. The time now is 10:25 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
Facebook: linuxquestions Google+: linuxquestions
Open Source Consulting | Domain Registration