Results 1 to 3 of 3
I have client1 and client2 both are linux machines.
From client1:
client1$ssh root@client2 "env"
it displays list of ssh variables from client2.
Things I did on client2:
=================
I want ...
Enjoy an ad free experience by logging in. Not a member yet? Register.
- 03-17-2010 #1
ssh - export a variable
I have client1 and client2 both are linux machines.
From client1:
it displays list of ssh variables from client2.client1$ssh root@client2 "env"
Things I did on client2:
=================
I want to add new variable to client2 . So I edited sshd_config to
PermitUserEnvironment yes
and created a file environment under ssh with following entry
Hi=Hello
then restart sshd
/etc/init.d/sshd
---------
Now from client1 trying the same command
client1$ssh root@client2 "env"
didn't provide the new variable "Hi".
Ref:
Christian thoughts in a tech world: Forcing environment in SSH
Netexpertise Environment Variables and SSHFirst they ignore you,Then they laugh at you,Then they fight with you,Then you win. - M.K.Gandhi
-----
FOSS India Award winning ext3fs Undelete tool www.giis.co.in. Online Linux Terminal http://www.webminal.org
- 03-17-2010 #2Where did you create this entry? In roots profile?and created a file environment under ssh with following entry
Hi=Hello
- 03-17-2010 #3
First they ignore you,Then they laugh at you,Then they fight with you,Then you win. - M.K.Gandhi
-----
FOSS India Award winning ext3fs Undelete tool www.giis.co.in. Online Linux Terminal http://www.webminal.org


Reply With Quote

