Help with SSH | Unix Linux Forums | Shell Programming and Scripting

  Go Back    


Shell Programming and Scripting Post questions about KSH, CSH, SH, BASH, PERL, PHP, SED, AWK and OTHER shell scripts and shell scripting languages here.

Help with SSH

Shell Programming and Scripting


Closed Thread    
 
Thread Tools Search this Thread Display Modes
    #1  
Old 12-11-2012
karumudi7 karumudi7 is offline
Registered User
 
Join Date: Mar 2011
Last Activity: 14 November 2013, 2:17 PM EST
Location: India
Posts: 109
Thanks: 19
Thanked 1 Time in 1 Post
IBM Help with SSH

Hi,

I have a special scenario with SSH. I need to sftp a file with in the server for different user. Say I have User Scott in Server A who created a file. Now Scott needs to transfer the file to John who is also a user of Server A.

Here you may ask why don't you use cp command, but due to permissions of Destination folder we are unable to copy that file.

I tried with creating the id_rsa.pub file for Scott and appended to John's Authorized_keys. But still it is asking password while connecting.

To cross verify, I setup'ed a SSH connection from Server A to Server B. It is fine. Also tested the above mentioned scenario in another environment. It is also running fine.

We can't do SSH with in the server ? I don't think so (Correct me).

Any solutions for this ? Also alternatives.

Thanks.
Sponsored Links
    #2  
Old 12-11-2012
michaelrozar17's Avatar
michaelrozar17 michaelrozar17 is offline
Registered User
 
Join Date: Jul 2010
Last Activity: 17 March 2014, 1:43 AM EDT
Location: IN
Posts: 892
Thanks: 14
Thanked 182 Times in 173 Posts
To my knowledge SSH/SFTP/SCP could be executed on a remote machine or between 2 hosts, it does not work within a same host/ip/machine. Though you have 2 users the server is the same, hence you need to use cp command. Since there is some permission issue while copying files, create a common directory where both the users can access the files and proceed further..
Sponsored Links
    #3  
Old 12-11-2012
karumudi7 karumudi7 is offline
Registered User
 
Join Date: Mar 2011
Last Activity: 14 November 2013, 2:17 PM EST
Location: India
Posts: 109
Thanks: 19
Thanked 1 Time in 1 Post
IBM

Quote:
Originally Posted by michaelrozar17 View Post
To my knowledge SSH/SFTP/SCP could be executed on a remote machine or between 2 hosts, it does not work within a same host/ip/machine. Though you have 2 users the server is the same, hence you need to use cp command. Since there is some permission issue while copying files, create a common directory where both the users can access the files and proceed further..
Both the users are from different groups. If I give permissions to Scott group then all others will also get. This directory actually contains important files and the permissions are set as 744, only John have complete access.
    #4  
Old 12-11-2012
michaelrozar17's Avatar
michaelrozar17 michaelrozar17 is offline
Registered User
 
Join Date: Jul 2010
Last Activity: 17 March 2014, 1:43 AM EDT
Location: IN
Posts: 892
Thanks: 14
Thanked 182 Times in 173 Posts
Then you would need to create a new group and add Scott and John as the only members to it and then place files in a common place
Sponsored Links
    #5  
Old 12-11-2012
prithvirao17 prithvirao17 is offline
Registered User
 
Join Date: Mar 2012
Last Activity: 11 December 2012, 4:28 AM EST
Posts: 18
Thanks: 8
Thanked 1 Time in 1 Post
I think ACL can come to your help in this case.
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
SSH SSH encountered 1 errors during the transfer Computergal2104 UNIX for Dummies Questions & Answers 1 08-10-2012 10:08 AM
Using ssh to add register key on ssh server leaftree Shell Programming and Scripting 9 12-22-2009 01:55 PM
could not send commands SSH session with Net::SSH::Expect hansini Shell Programming and Scripting 0 08-28-2009 12:56 AM
What's the difference between an SSH Client and an SSH Server? PSC Security 1 07-19-2004 03:24 PM



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