RE: Activity of the $HOME/.kshrc



Glad to discuss with you again.

You probably mean Red Hat Enterprise, not Red Hat.
You are right. It should be "Red Hat Enterprise Linux".

Check the user's shell and make sure it's actually ksh.
It is ksh:
Localhost$ ssh server1 echo $SHELL
/usr/bin/ksh
Localhost$ ssh server2 echo $SHELL
/usr/bin/ksh

Jialing

-----Original Message-----
From: Greg Wooledge [mailto:wooledg@xxxxxxxxxxx]
Sent: Thursday, March 05, 2009 10:56 AM
To: Jialing Liang
Cc: secureshell@xxxxxxxxxxxxxxxxx
Subject: Re: Activity of the $HOME/.kshrc

On Wed, Mar 04, 2009 at 04:38:18PM -0700, Jialing Liang wrote:
I have ssh login to two Linux - Openssh server. They share one $Home
directory. server1 runs Redhat 3 with Openssh 3.6.1 and sever2 runs
Redhat 5 with Openssh 4.3

You probably mean Red Hat Enterprise, not Red Hat. Red Hat 5.x
(December
1997) is unlikely to have such a new version of OpenSSH, and Red Hat 3.x
is pretty ancient (May 1996).

The problem is: If I type "ssh server1 set" in a local host it shows
the
variable defined in $HOME/.kshrc. However, the "ssh server2 set" does
not show the variable defined in the same $HOME/.kshrc file.

Check the user's shell and make sure it's actually ksh.

$ cat $HOME/.ssh/environment
ENV=$HOME/.kshrc

If the user's shell is (for example) bash or sh or csh, this variable
won't have any effect.



Relevant Pages