Contact US

Log In

Come Join Us!

Are you a
Computer / IT professional?
Join Tek-Tips Forums!
  • Talk With Other Members
  • Be Notified Of Responses
    To Your Posts
  • Keyword Search
  • One-Click Access To Your
    Favorite Forums
  • Automated Signatures
    On Your Posts
  • Best Of All, It's Free!

*Tek-Tips's functionality depends on members receiving e-mail. By joining you are opting in to receive e-mail.

Posting Guidelines

Promoting, selling, recruiting, coursework and thesis posting is forbidden.

Students Click Here

SSH on the System i

SSH on the System i

SSH on the System i

Hello everyone. I've been having a lot of difficulty trying to use the scp command to securely transfer a file from one System i machine to another. I've used the following redbook as a guide:


I've followed chapter 4 to a tee, over and over again, but cannot seem to get this to work. The summary of the whole process is as follows:

1. Create the key pair on the local machine (the guide says to generate an RSA2 keypair which appears to be the default when using ssh-keygen -t rsa...I've tried RSA2, RSA1, and DSA)

2. Manually send the public key (id_rsa.pub) to the remote system via FTP and append it to the authorized_keys file in ~/.ssh using the cat command.

3. On the local mahine, enter "ssh-agent $SHELL", then issue the ssh-add command to add the identities to memory.

4. Use the scp command as such: "scp /home/userdir/file username@remotesys:/home/userdir/file"

I've been using the "-vvv" flag with this command to see what's been going on, and it's always mixed results. When I use an RSA2 key, it's telling me that it's not an RSA1 key:

debug1: identity file /home/JGLISTA/.ssh/id_rsa type 1
debug3: Not a RSA1 key file /home/JGLISTA/.ssh/id_dsa.
debug2: key_type_from_name: unknown key type '-----BEGIN'

Also, further down, it appears as though it's attempting to send my private key as a public key? Why would it do this?

debug1: userauth_pubkey_agent: testing agent key /home/JGLISTA/.ssh/id_rsa

When I generated and used an RSA1 keypair instead, it still didn't work. Does anyone have a clue as to what I'm doing wrong here?


RE: SSH on the System i

1. Generate the key pair on the local machine


ssh-keygen -t rsa

2. Copy the key to the server


scp /home/[usermame]/.ssh/id_rsa.pub username@server_ip:~/.ssh/authorized_keys
That was how I did it on Cygwin and Ubuntu server

Red Flag This Post

Please let us know here why this post is inappropriate. Reasons such as off-topic, duplicates, flames, illegal, vulgar, or students posting their homework.

Red Flag Submitted

Thank you for helping keep Tek-Tips Forums free from inappropriate posts.
The Tek-Tips staff will check this out and take appropriate action.

Reply To This Thread

Posting in the Tek-Tips forums is a member-only feature.

Click Here to join Tek-Tips and talk with other members! Already a Member? Login

Close Box

Join Tek-Tips® Today!

Join your peers on the Internet's largest technical computer professional community.
It's easy to join and it's free.

Here's Why Members Love Tek-Tips Forums:

Register now while it's still free!

Already a member? Close this window and log in.

Join Us             Close