LinuxQuestions.org
Download your favorite Linux distribution at LQ ISO.
Home Forums Tutorials Articles Register
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, 08:48 AM   #1
swampdog2002
Member
 
Registered: Jul 2005
Distribution: Slackware 12.2, 13.0, openSUSE 11.2
Posts: 400

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 08:49 AM.
 
Old 02-14-2007, 10:23 AM   #2
bigrigdriver
LQ Addict
 
Registered: Jul 2002
Location: East Centra Illinois, USA
Distribution: Debian stable
Posts: 5,908

Rep: Reputation: 356Reputation: 356Reputation: 356Reputation: 356
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, 07:15 PM   #3
swampdog2002
Member
 
Registered: Jul 2005
Distribution: Slackware 12.2, 13.0, openSUSE 11.2
Posts: 400

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



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

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

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

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