To make sure I am understanding correctly, I will try restating your problem:
- You have an existing key pair used by your "old linux machine".
- You created a key pair using PuTTY and PuTTYGen.
- You appended a blank line followed by the public key from PuTTYGen to ~/.ssh/authorized_keys.
- Old key works, new key fails.
Sound about right?
My initial troubleshooting of this issue would be along the following lines:
- First of all, I do not believe the blank line is the issue. (I tested this on my own system, and it did not seem to affect it.) You can also make the blank line a comment with a leading '#', just to see if that makes a difference. (I doubt it will, however.)
- Next, I would verify that the public key you entered into the authorized_keys file is present in its entirety. Assuming you copied the public key from the PuTTYGen interface, make sure that you copied the entire key from the window. (I have seen experienced admins get caught by this.) One way to ensure you all of it is to add a key comment, and verify that it is present in the public key string. (Also not a bad idea, so you can easily identify this key from others.)
- I would then verify that the key is a single line entry in the authorized_keys file. (Personally, I would probably move down the file in vi, but whatever way works for you.)
If that did not work, then I would begin looking at (or talking to someone who could look at) the logs on the server, to see if there is anything there that provided the next clue.
As far as the perl script on the Windows machine accessing the server, it is my understanding that can be problematic at best, so I would start by verifying your new key is working in PuTTY before tackling that.
Hope that helps.
Posts are HTML formatted. Put <p> </p> tags around your paragraphs. Put <code> </code> tags around your code and data!
Titles consisting of a single word are discouraged, and in most cases are disallowed outright.
Read Where should I post X? if you're not absolutely sure you're posting in the right place.
Please read these before you post! —
Posts may use any of the Perl Monks Approved HTML tags:
- a, abbr, b, big, blockquote, br, caption, center, col, colgroup, dd, del, details, div, dl, dt, em, font, h1, h2, h3, h4, h5, h6, hr, i, ins, li, ol, p, pre, readmore, small, span, spoiler, strike, strong, sub, summary, sup, table, tbody, td, tfoot, th, thead, tr, tt, u, ul, wbr
You may need to use entities for some characters, as follows. (Exception: Within code tags, you can put the characters literally.)
| |
For: |
|
Use: |
| & | | & |
| < | | < |
| > | | > |
| [ | | [ |
| ] | | ] |
Link using PerlMonks shortcuts! What shortcuts can I use for linking?
See Writeup Formatting Tips and other pages linked from there for more info.