Results 1 to 3 of 3
Thread: ssh - export a variable
|
Enjoy an ad free experience by logging in. Not a member yet? Register.
|
|
-
03-17-2010 #1
ssh - export a variable
From client1:
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 #2and created a file environment under ssh with following entry
Hi=Hello
-
03-17-2010 #3First 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