Unable to connect using SFTP

 
Thread Tools Search this Thread
Homework and Emergencies Emergency UNIX and Linux Support Unable to connect using SFTP
# 1  
Old 07-11-2010
Unable to connect using SFTP

I shall explain the situation that I am facing to the best extent possible. I require some help, as this situation is an urgent one.
I am trying to automate sending data from one AIX machine to another. A script runs that tries to push data received from an upstream application to another AIX system. However, it fails, as SFTP is failing.
To ensure that it is the SFTP step that's failing, I tried to replace the test server with the development server IP, and the SFTP connects, and the data is also transmitted.
Looks like it is something to do with the public/private key exchange. Can anyone help me, to figure out how to resolve this issue.

---------- Post updated 07-11-10 at 01:06 AM ---------- Previous update was 07-10-10 at 08:55 PM ----------

More details on the above scenario
Code:
Connecting to <the ip address>
OpenSSH_4.1p1, OpenSSL 0.9.7g 11 Apr 2005
debug1: Reading configuration data /home/uvstart/.ssh/config
debug1: Reading configuration data /etc/ssh/ssh_config
debug1: Applying options for *
debug1: Failed dlopen: /usr/krb5/lib/libkrb5.a(libkrb5.a.so): Could not load module /usr/krb5/lib/libkrb5.a(libkrb5.a.so).
System error: No such file or directory

debug1: Error loading Kerberos, disabling Kerberos auth.
debug1: Connecting to <the host name> port 22.
debug1: Connection established.
debug1: identity file /home/uvstart/.ssh/id_rsa type -1
debug1: identity file /home/uvstart/.ssh/id_dsa type 2
debug1: Remote protocol version 2.0, remote software version OpenSSH_4.7
debug1: match: OpenSSH_4.7 pat OpenSSH*
debug1: Enabling compatibility mode for protocol 2.0
debug1: Local version string SSH-2.0-OpenSSH_4.1
debug1: SSH2_MSG_KEXINIT sent
debug1: SSH2_MSG_KEXINIT received
debug1: kex: server->client aes128-cbc hmac-md5 none
debug1: kex: client->server aes128-cbc hmac-md5 none
debug1: SSH2_MSG_KEX_DH_GEX_REQUEST(1024<1024<8192) sent
debug1: expecting SSH2_MSG_KEX_DH_GEX_GROUP
debug1: SSH2_MSG_KEX_DH_GEX_INIT sent
debug1: expecting SSH2_MSG_KEX_DH_GEX_REPLY
debug1: Host 'host name' is known and matches the RSA host key.
debug1: Found key in /home/uvstart/.ssh/known_hosts:19
debug1: ssh_rsa_verify: signature correct
debug1: SSH2_MSG_NEWKEYS sent
debug1: expecting SSH2_MSG_NEWKEYS
debug1: SSH2_MSG_NEWKEYS received
debug1: SSH2_MSG_SERVICE_REQUEST sent
debug1: SSH2_MSG_SERVICE_ACCEPT received
debug1: Authentications that can continue: publickey,password,keyboard-interactive
debug1: Next authentication method: publickey
debug1: Trying private key: /home/uvstart/.ssh/id_rsa
debug1: Offering public key: /home/uvstart/.ssh/id_dsa
debug1: Authentications that can continue: publickey,password,keyboard-interactive
debug1: Next authentication method: keyboard-interactive
debug1: Authentications that can continue: publickey,password,keyboard-interactive
debug1: Next authentication method: password
uvstart@<host name's> password:
debug1: Authentication succeeded (password).
debug1: channel 0: new [client-session]
debug1: Entering interactive session.
debug1: channel 0: free: client-session, nchannels 1
debug1: fd 0 clearing O_NONBLOCK
Connection to <host name> closed by remote host.
debug1: Transferred: stdin 0, stdout 0, stderr 70 bytes in 0.0 seconds
debug1: Bytes per second: stdin 0.0, stdout 0.0, stderr 5106.9
debug1: Exit status -1
Connection closed


Last edited by pludi; 07-11-2010 at 12:45 PM.. Reason: code tags, please...
# 2  
Old 07-11-2010
Check the remote contents of the authorized_keys file. It should contain a line with the contents of the /home/uvstart/.ssh/id_rsa.pub file on the local side.
# 3  
Old 07-12-2010
Did you login using ssh first there is a key exchange that has to be completed. If that does not work I would look at the user set up and permissions
# 4  
Old 07-18-2010
Did you try manual SFTP to that machine?
If it asks for password, then you must do the key exchange.
Configure the public key of source machine in the destination machine.
# 5  
Old 07-19-2010
I tried that and yes, it asks for the password. Any tip on how to configure the keys would be really helpful. Thanks in advance.
# 6  
Old 07-22-2010
assign rsa and dsa keys

to configure rsa

#ssh-keygen -t rsa

to configure dsa
#ssh-keygen -t dsa
# 7  
Old 07-23-2010
Check this link to setup keys.
HOWTO: set up ssh keys
Login or Register to Ask a Question

Previous Thread | Next Thread

10 More Discussions You Might Find Interesting

1. UNIX for Advanced & Expert Users

Connect direct - SFTP - List of servers that I can connect

Greetings Experts, I am working for a bank client and have a question on connect-direct and SFTP. We are using Linux RedHat servers. We use connect-direct to transfer (NDM) files from one server to another server. At times, we manually transfer the files using SFTP from one server to another... (2 Replies)
Discussion started by: chill3chee
2 Replies

2. AIX

Unable to connect ASMI

After following the instructions given by resident moderator Bakunin over here https://www.unix.com/aix/279862-installed-memory-32gb-but-shows-only-16gb.html #1 Connect to ASMI #2 Configure the deconfigured memory #3 Start the machine OK, everything is fine, however now cannot connect to... (5 Replies)
Discussion started by: filosophizer
5 Replies

3. Solaris

Unable to connect using ftp

hi I am having issues when trying to connect using ftp, I am having the following error: User (10.100.48.73:(none)): moz 331 Password required for moza. Password: 530 Login incorrect. Login failed. ftp> by 221 Goodbye. I have created a user like this: useradd -g 10 -d /lam/moza -m -s... (11 Replies)
Discussion started by: fretagi
11 Replies

4. Red Hat

Unable to connect to internet

Hello, I just installed CentOS 7 (Server with GUI) and guess what I could install Virtual Box Guest additions without installing any extra package/software which is great news ! Now bad news or not so great news. My Host OS is Windows 10, Virtual Box is the virtualization software. CentOS7-1... (0 Replies)
Discussion started by: bluemind2005
0 Replies

5. Red Hat

Unable to connect Wireless

I have managed to install Broadcom BCM43228 Wireless adapter on a laptop running CentOS 5.9 using instructions at: wiki.centos.org/HowTos/Laptops/Wireless/Broadcom I had the problem "Error for wireless request "Set Encode" (8B2A): SET failed on device... mentioned on the same page and solved... (0 Replies)
Discussion started by: cooltoad
0 Replies

6. HP-UX

Unable to connect SSH from HP-UX

Hi, I'm trying to connect from an HP-UX with SSH2 client(ssh2 3.1.2 on hppa1.1-hp-hpux11.00) to an SSH2 server on a VxWorks system. The SSH connection is failing with the below connection logs: > /usr/local/bin/ssh2 -v -l testuser 10.10.10.10 debug: Ssh2/ssh2.c:1391: Using file... (4 Replies)
Discussion started by: ysafi
4 Replies

7. UNIX for Dummies Questions & Answers

SFTP error when trying to connect

Hi, I am getting the following error when trying to use SFTP to go from my PROD to DEV. We are running AIX 5.3 64 bit. /home/tcutil/scripts 3720=>sftp -o Cipher=blowfish -o Compression=yes dradmin@xyz Connecting to xyz.... dradmin@xyz's password: buffer_get_ret: trying to get more bytes... (11 Replies)
Discussion started by: ramangill
11 Replies

8. Solaris

Unable to connect to Internet

Hi friends recently i have installed SXDE 1/08 into my machine,and i installed wifi driver also its working fine,Recently i was unable to connect to Internet,I have not changed any configurations and any installations,thing is that i got my iwk0 interface is UP and IP address also and i can... (6 Replies)
Discussion started by: srinivas2828
6 Replies

9. Cybersecurity

sftp client can't connect

Hi. I'm trying to use my sftp client on solaris 9 to connect to an sftp server. ssh is installed correctly and I can see my pub/priv key files in the ~/.ssh directory. When I run sftp -v <target> I get: bash-2.05# sftp -v retsdsa.merlin.mb.ca Connecting to retsdsa.merlin.mb.ca... debug1: SSH... (2 Replies)
Discussion started by: skowal
2 Replies

10. HP-UX

Unable to connect to HP-UX 11.11 via eXceed 7.1

Hello HP-UX Gurus, I am having issues trying to start an x-session via eXceed 7.1. When I bring up eXceed via XDMCP Braodcast I see the host name and IP Address but when I try to connect the X window does not come up. I made the modification to the following file “/etc/dt/config/Xaccess”... (2 Replies)
Discussion started by: smokie
2 Replies
Login or Register to Ask a Question