Unix Technical Forum

Where could $PATH be set?

This is a discussion on Where could $PATH be set? within the Sun Solaris Administration forums, part of the Solaris Operating System category; --> The system admin at work asked me today if I knew where $PATH for a user could be set ...


Go Back   Unix Technical Forum > Unix Operating Systems > Solaris Operating System > Sun Solaris Administration

Register FAQ Members List Calendar Search Today's Posts Mark Forums Read
  #1 (permalink)  
Old 01-16-2008, 08:38 AM
Dave
 
Posts: n/a
Default Where could $PATH be set?

The system admin at work asked me today if I knew where $PATH for a user
could be set on Solaris.

I'm not 100% sure of the facts, but I think the problem is that some
users have as part of their $PATH something relating to /usr/local (i.e.
a non Sun path) but he was unable to find where it was being set. (He
inherited a Solaris system, set up by someone else).

There is no .profile, .cshrc or any other dot files.

/etc/default/login does not contain /usr/local
nor does /etc/profile.

Is there any other way the path can be set?

The shell was the restricted shell (rsh).

I could have some of the facts wrong, but just a list of each and every
place a path could be set would be useful.

dave k

Digg this Post!Add Post to del.icio.usBookmark Post in TechnoratiFurl this Post!
Reply With Quote
  #2 (permalink)  
Old 01-16-2008, 08:38 AM
Scott Packard
 
Posts: n/a
Default Re: Where could $PATH be set?

On Wed, 18 May 2005 23:11:37 +0100, Dave wrote:

> The system admin at work asked me today if I knew where $PATH for a user
> could be set on Solaris.
>
> I'm not 100% sure of the facts, but I think the problem is that some
> users have as part of their $PATH something relating to /usr/local (i.e.
> a non Sun path) but he was unable to find where it was being set. (He
> inherited a Solaris system, set up by someone else).
>
> There is no .profile, .cshrc or any other dot files.
>
> /etc/default/login does not contain /usr/local
> nor does /etc/profile.
>
> Is there any other way the path can be set?
>
> The shell was the restricted shell (rsh).
>
> I could have some of the facts wrong, but just a list of each and every
> place a path could be set would be useful.
>
> dave k


man restricted_shell


Digg this Post!Add Post to del.icio.usBookmark Post in TechnoratiFurl this Post!
Reply With Quote
  #3 (permalink)  
Old 01-16-2008, 08:38 AM
Dave
 
Posts: n/a
Default Re: Where could $PATH be set?

Scott Packard wrote:
> On Wed, 18 May 2005 23:11:37 +0100, Dave wrote:
>
>
>>The system admin at work asked me today if I knew where $PATH for a user
>> could be set on Solaris.
>>
>>I'm not 100% sure of the facts, but I think the problem is that some
>>users have as part of their $PATH something relating to /usr/local (i.e.
>>a non Sun path) but he was unable to find where it was being set. (He
>>inherited a Solaris system, set up by someone else).
>>
>>There is no .profile, .cshrc or any other dot files.
>>
>>/etc/default/login does not contain /usr/local
>>nor does /etc/profile.
>>
>>Is there any other way the path can be set?
>>
>>The shell was the restricted shell (rsh).
>>
>>I could have some of the facts wrong, but just a list of each and every
>>place a path could be set would be useful.
>>
>>dave k

>
>
> man restricted_shell
>
>

Thanks, although it did not help. I was not aware the man page could be
found that way, but did determine that man -s 1m rsh found it.

But I could still see no other place mentioned where the user's path
could have been set.

Digg this Post!Add Post to del.icio.usBookmark Post in TechnoratiFurl this Post!
Reply With Quote
  #4 (permalink)  
Old 01-16-2008, 08:38 AM
Scott Packard
 
Posts: n/a
Default Re: Where could $PATH be set?

On Fri, 20 May 2005 08:14:03 +0100, Dave wrote:

> Scott Packard wrote:
>> On Wed, 18 May 2005 23:11:37 +0100, Dave wrote:
>>
>>
>>>The system admin at work asked me today if I knew where $PATH for a user
>>> could be set on Solaris.
>>>
>>>I'm not 100% sure of the facts, but I think the problem is that some
>>>users have as part of their $PATH something relating to /usr/local (i.e.
>>>a non Sun path) but he was unable to find where it was being set. (He
>>>inherited a Solaris system, set up by someone else).
>>>
>>>There is no .profile, .cshrc or any other dot files.
>>>
>>>/etc/default/login does not contain /usr/local
>>>nor does /etc/profile.
>>>
>>>Is there any other way the path can be set?
>>>
>>>The shell was the restricted shell (rsh).
>>>
>>>I could have some of the facts wrong, but just a list of each and every
>>>place a path could be set would be useful.
>>>
>>>dave k

>>
>>
>> man restricted_shell
>>
>>

> Thanks, although it did not help. I was not aware the man page could be
> found that way, but did determine that man -s 1m rsh found it.
>
> But I could still see no other place mentioned where the user's path
> could have been set.


So, the man page says it can't be set, after .profile is read.
I'll assume it is also set within the system-wide /etc/profile.
Well, if you are very sure that you have no $PATH changes within
..profile|/etc/profile and you've pulled your hair out trying to find
where it's being changed and can't find it, then the only other
obvious thing is the person whom first set up this system and restricted
shell for you didn't do it correctly. Read the man page very closely
and trace the exact steps for the restricted shell's invocation.
You'll probably find a mistake somewhere.
Or, the man page is wrong and you'll have to file a bug with Sun.

Regards, Scott

Digg this Post!Add Post to del.icio.usBookmark Post in TechnoratiFurl this Post!
Reply With Quote
Reply


Thread Tools
Display Modes

Posting Rules
You may not post new threads
You may not post replies
You may not post attachments
You may not edit your posts

vB code is On
Smilies are On
[IMG] code is On
HTML code is Off
Trackbacks are On
Pingbacks are On
Refbacks are On
Forum Jump


All times are GMT. The time now is 09:12 AM.


Powered by vBulletin® Version 3.6.5
Copyright ©2000 - 2008, Jelsoft Enterprises Ltd.
Search Engine Optimization by vBSEO 3.2.0
www.UnixAdminTalk.com