The UNIX and Linux Forums  

Go Back   The UNIX and Linux Forums > Top Forums > UNIX for Dummies Questions & Answers
Google UNIX.COM


UNIX for Dummies Questions & Answers If you're not sure where to post a UNIX or Linux question, post it here. All UNIX and Linux newbies welcome !!

More UNIX and Linux Forum Topics You Might Find Helpful
Thread Thread Starter Forum Replies Last Post
Modifying a variable value kartikkumar84@g UNIX for Dummies Questions & Answers 6 05-22-2008 11:19 PM
echo $PATH doesn't match $HOME/.profile Veestan UNIX for Dummies Questions & Answers 1 04-17-2008 11:15 AM
full path of .profile in unix dba UNIX for Dummies Questions & Answers 6 02-22-2008 02:12 AM
Edited Path in Profile File thewetch UNIX for Dummies Questions & Answers 4 03-08-2006 03:01 AM
Profile and environment variable unclefab SUN Solaris 2 05-12-2005 06:57 AM

Closed Thread
 
Submit Tools LinkBack Thread Tools Display Modes
  #1 (permalink)  
Old 03-11-2001
Registered User
 

Join Date: Mar 2001
Posts: 2
Question

In my /etc/profile, my $PATH variable is set as follows:

$PATH =/sbin:/usr/sbin:/usr/bin:/etc

Then how do I add an additional directory to it? say
/export/home/abd/rose

Please advise.

Thanks!

Deepali
Forum Sponsor
  #2 (permalink)  
Old 03-11-2001
mib mib is offline
Registered User
 

Join Date: Jan 2001
Location: Calicut
Posts: 228

$PATH =/sbin:/usr/sbin:/usr/bin:/etc:/export/home/abd/rose

Add a ":" and new directory path

  #3 (permalink)  
Old 03-12-2001
Registered User
 

Join Date: Dec 2000
Location: Greater Dallas area
Posts: 405
Actually it should be;
Code:
PATH=/sbin:/usr/sbin:/usr/bin:/etc:/export/home/abd/rose 
export PATH
If you want is to search /export/home/abd/rose first, use;
Code:
PATH=/export/home/abd/rose:/sbin:/usr/sbin:/usr/bin:/etc
export PATH
I'm not sure why you would have /etc in your search path though?
  #4 (permalink)  
Old 03-12-2001
PxT's Avatar
PxT PxT is offline
Registered User
 

Join Date: Oct 2000
Location: Sacramento, CA
Posts: 909
Quote:
I'm not sure why you would have /etc in your search path though?
Because some lame distributions (HP-UX for one) put binaries (or links to binaries) in /etc
Google The UNIX and Linux Forums
Closed Thread

Thread Tools
Display Modes




All times are GMT -7. The time now is 07:04 AM.


Powered by: vBulletin, Copyright ©2000 - 2006, Jelsoft Enterprises Limited.
The UNIX and Linux Forums Content Copyright ©1993-2008. All Rights Reserved.Ad Management by RedTyger Visit The Global Fact Book

Content Relevant URLs by vBSEO 3.2.0