passwordless authentication of SFTP script

Thread Tools Search this Thread
Top Forums Shell Programming and Scripting passwordless authentication of SFTP script
# 8  
Old 01-11-2008
no, home is the homedirectory. (eg. ~)
# 9  
Old 01-11-2008
Still it's not working !!
# 10  
Old 01-11-2008
What does the ssh-log say on the remote server?
Could you post this?
Second, could you post the output off the following command from the client system (as user informat) to the server system:
ssh -v -v -v B
# 11  
Old 01-11-2008
Hi There
Thanks a lot for helping me out !!!
I am bit novice in Unix, Can u pls tell me where can I get the log of ssh-log
Will be it in server A or B and in which directory ..
I did run a command ssh -v -v -v B
and after that it lists lot of o/p and then prompting for password. I tried to copy the output into the file 'output'. with the below command ..

ssh -v -v -v B > output

But the output file doesn't not contain much. AM I doing something wrong here ..

Thanks a lot for ur effort to help me out !!
# 12  
Old 01-11-2008
Well, it seems to me the output should somewhere say something about offering a key, and failing to do so.

The sshd-log is in your syslog.

It'll say something about the rights of the directory, or about not finding the key.

It could be you need to rename the authorized_keys file to authorized_keys2
# 13  
Old 05-14-2009
Thank you, I was facing same issue, now after changing all permissions it is working fine, i need to set:

chmod -R 700 .ssh/
# 14  
Old 11-04-2009
Hi All,

I need a solution for my issue below.

I have a source and destination, between which i need to connect through SFTP, go to a folder and list files(*.xls) and output that to a file in the destination server location.
We have done this using FTP, but i have to do this through SFTP, I have enabled and put public/private keys in place in both source and destination server.

Please refer to the script that was used with FTP, have to replicate this for SFTP....

ftp -i server_name <<REMOTE_EX
cd folder
ls *.xls temp_ls.dat
Login or Register to Ask a Question

Previous Thread | Next Thread

10 More Discussions You Might Find Interesting

1. UNIX for Beginners Questions & Answers

How to use passwordless sftp in script?

Hi I am trying to do SFTP in shell script in such a way that it should not ask for password. for this is use below script but it prompt for password. here I am not abled to understand where I am making mistake. #!/bin/bash # SFTP TO remote server USER="ITO" PASSWORD="abcd@1234"... (4 Replies)
Discussion started by: scriptor
4 Replies

2. Shell Programming and Scripting

Ssh passwordless authentication

Hey team I have to enable password less authentication betweeen A to B server and A to C server and A to D server. For this I generated a ssh key on server A using ssh-keygen command and copied the key using ssh-copy-id command to B, C and D server. Everything is working fine as of now but... (5 Replies)
Discussion started by: Sandeep_sandy
5 Replies

3. UNIX for Dummies Questions & Answers

Pearl script Net::SFTP authentication error

#!/usr/local/bin/perl -w use Net::SFTP; use File::Copy; my $user=(getpwuid($<)); my $server = "servername"; print "user - $user server - $server \n"; my %args = ( user => "$user", ssh_args => {port=> 'portnum'} ); $args{debug} = 1; $args{user} = "user"; my $sftp=Net::SFTP->new($server,... (1 Reply)
Discussion started by: Yashaswini H L
1 Replies

4. Shell Programming and Scripting

Passwordless Authentication and Anonymous login

Hi, I am in the process FTPing some of my report files from my production server to another FTP server through batch/Shell Script. This is working fine with the password less authentication. Once i place all my report files in the ftp server the end users need to download ... (3 Replies)
Discussion started by: Showdown
3 Replies

5. Ubuntu

Passwordless ssh authentication fails

Unable to set ssh passwordless authentication I am unable to ssh with passwordless authentication from Windows client onto UBuntu server. The ssh version on UBuntu is OpenSSH_5.8p1 Debian-7ubuntu1, OpenSSL 1.0.0e , while SSH on Windows Client is OpenSSH_5.1p1, OpenSSL 0.9.8k. I turned on ssh... (5 Replies)
Discussion started by: tkota
5 Replies

6. Red Hat

ssh private key passwordless authentication

Hello, Need a suggestion to setup private key passwordless authentication. I am not sure this can done or not :wall: here is the sincerio I have two servers, sever1 with a user "user1" and servera with usera here dataflow: usera from servera, will pull/push files to server1 on user1... (2 Replies)
Discussion started by: bobby320
2 Replies

7. Shell Programming and Scripting

Setup multiple passwordless authentication

I have experience in setting up passwordless authentication by sharing ssh public keys manually.Currently I am in the process to the write a script to perform the same functionality from one source(host) to multiple destinations. I have one source host (Host A) whose public keys has to be shared... (9 Replies)
Discussion started by: Lancel0t
9 Replies

8. HP-UX

sftp/scp/ssh script with password as authentication

Hello, Do you guys know set of commands that can incorporate to sftp/scp/ssh to add password in a script to automate file transfer. Our client is not using ssh keys authentication so we are force to create a script to pass the password into the script to transfer files via sftp/scp/ssh. We... (4 Replies)
Discussion started by: james_falco
4 Replies

9. AIX

Passwordless root authentication via SSH

Hello, I would like to issue a couple of commands as root on a remote machine without having to enter the root password. I used "ssh-keygen -t rsa" to generate the encryption keys, copied the public key to the remote machine, etc. I also tried playing around with the sshd_config file and... (3 Replies)
Discussion started by: sphericon
3 Replies

10. AIX

Passwordless authentication via SSH

I am trying to implement passwordless authentication via ssh2. I have used the well documented technique of generating a key pair with a blank passphrase on my client machine, and installing the public key on the destination server (AIX 5.3) in the user's .ssh2 directory. I have used this technique... (1 Reply)
Discussion started by: RegX
1 Replies
Login or Register to Ask a Question