executing .profile with ssh | Unix Linux Forums | UNIX for Advanced & Expert Users

  Go Back    


UNIX for Advanced & Expert Users Expert-to-Expert. Learn advanced UNIX, UNIX commands, Linux, Operating Systems, System Administration, Programming, Shell, Shell Scripts, Solaris, Linux, HP-UX, AIX, OS X, BSD.

executing .profile with ssh

UNIX for Advanced & Expert Users


Closed Thread    
 
Thread Tools Search this Thread Display Modes
    #1  
Old 12-21-2004
rein rein is offline
Registered User
 
Join Date: Dec 2004
Last Activity: 31 January 2011, 2:32 PM EST
Location: Zürich
Posts: 151
Thanks: 0
Thanked 1 Time in 1 Post
executing .profile with ssh

Hi, How do I get all my profile settings when connecting with ssh?
Sponsored Links
    #2  
Old 12-21-2004
moxxx68's Avatar
moxxx68 moxxx68 is offline
Registered User
 
Join Date: Mar 2004
Last Activity: 17 December 2005, 5:40 AM EST
Posts: 301
Thanks: 0
Thanked 0 Times in 0 Posts
Bug

quote:
executing .profile with ssh

Hi, How do I get all my profile settings when connecting with ssh?
------------------------------------------------------------------------------------------------

are you using a remote account or are you accessing your own machine?? secondly are you trying to access it or perform a command line function.. if you are using ssh on a remote account try the "nano" edittor for editting profile file (pico).. if you are accessing your own machine just use any edittor as you would if you were on your machine... .... but if you want to perform a command line execution try rcp (man rcp) to simply send a commad to your machine or a remote machine on the command line envoking rcp and the command that you wish to excute and that should save you the hassle of having to get into your account and fiddle about..
moxxx68
ps .hope that!! helps

re:edit.
if you are trying to transfer your setting from one machine to another copy your profile file and ftp it... again you can use ssh or use rcp.

Last edited by moxxx68; 12-21-2004 at 06:59 AM..
Sponsored Links
    #3  
Old 12-21-2004
rein rein is offline
Registered User
 
Join Date: Dec 2004
Last Activity: 31 January 2011, 2:32 PM EST
Location: Zürich
Posts: 151
Thanks: 0
Thanked 1 Time in 1 Post
I'm using a remote machine. I try to access a cvs repository but when connecting to it it can't find the correct environment variables because it doesn't run the .profile. So I need a way to set environment variables with ssh. There's nothing wrong with my profile, ssh just doesn't pick up the environment variables of the user account.
    #4  
Old 12-21-2004
moxxx68's Avatar
moxxx68 moxxx68 is offline
Registered User
 
Join Date: Mar 2004
Last Activity: 17 December 2005, 5:40 AM EST
Posts: 301
Thanks: 0
Thanked 0 Times in 0 Posts
try ssh -Xt
in the man pages there are few options that may let you force the connection to perform otherwise.. try it..
moxxx68
Sponsored Links
    #5  
Old 12-21-2004
rein rein is offline
Registered User
 
Join Date: Dec 2004
Last Activity: 31 January 2011, 2:32 PM EST
Location: Zürich
Posts: 151
Thanks: 0
Thanked 1 Time in 1 Post
the solution:

enable PermitUserEnvironment in ssh_config
add environment file with VAR=VALUE in .ssh directory

--> http://www.openbsd.org/cgi-bin/man.cgi?query=ssh
Sponsored Links
    #6  
Old 12-21-2004
moxxx68's Avatar
moxxx68 moxxx68 is offline
Registered User
 
Join Date: Mar 2004
Last Activity: 17 December 2005, 5:40 AM EST
Posts: 301
Thanks: 0
Thanked 0 Times in 0 Posts
you know i wouldn't doubt it if the man pages had options that could override the problem that you were having staticaly rather than the global changes that you made.. even though configuring the confi.files should be the first place to search.. that way if you decide to keep the changes you are not constantly messing with options..
thanx for the update
moxxx68
Sponsored Links
Closed Thread

Thread Tools Search this Thread
Search this Thread:

Advanced Search
Display Modes

More UNIX and Linux Forum Topics You Might Find Helpful
Thread Thread Starter Forum Replies Last Post
trap in etc/profile and user .profile Smith Infrastructure Monitoring 4 09-01-2009 08:58 PM
Difference between .profile and .~/.profile maneesh mehta SCO 3 12-14-2005 03:35 AM
Executing .profile from perl script prekida Shell Programming and Scripting 1 09-29-2005 01:51 PM
changed .profile but didnt ./.profile, yet reflected changes yls177 UNIX for Dummies Questions & Answers 4 12-05-2002 10:21 AM
executing .profile jalburger UNIX for Dummies Questions & Answers 6 11-13-2002 10:34 AM



All times are GMT -4. The time now is 09:50 AM.