LinuxQuestions.org
Latest LQ Deal: Latest LQ Deals
Home Forums Tutorials Articles Register
Go Back   LinuxQuestions.org > Forums > Linux Forums > Linux - Server
User Name
Password
Linux - Server This forum is for the discussion of Linux Software used in a server related context.

Notices


Reply
  Search this Thread
Old 10-07-2018, 06:50 PM   #1
sniper8752
Member
 
Registered: Oct 2012
Posts: 564

Rep: Reputation: Disabled
Unable to ssh into server via key


I am trying to use sshfs, but it asks me for a passphrase (there is none), then a password. I followed this top rated answer: https://unix.stackexchange.com/quest...tication/55481 but it still seems to be prompting me for a password. When I try to ssh into the server with verbose on, this is what I get:
Code:
debug1: Authentications that can continue: publickey,password
 
Old 10-07-2018, 07:30 PM   #2
michaelk
Moderator
 
Registered: Aug 2002
Posts: 25,760

Rep: Reputation: 5931Reputation: 5931Reputation: 5931Reputation: 5931Reputation: 5931Reputation: 5931Reputation: 5931Reputation: 5931Reputation: 5931Reputation: 5931Reputation: 5931
That is a normal debug message if you have both publickey and password authentication methods enabled.

Without knowing the specific steps you used to create the key it is difficult to provide help. It is also important that the directories and keys have the correct permissions set.
 
Old 10-07-2018, 08:00 PM   #3
sniper8752
Member
 
Registered: Oct 2012
Posts: 564

Original Poster
Rep: Reputation: Disabled
Quote:
Originally Posted by michaelk View Post
Without knowing the specific steps you used to create the key it is difficult to provide help. It is also important that the directories and keys have the correct permissions set.
I copied it to the server.
I followed the linked guide to make sure everything has the right permissions.
 
Old 10-07-2018, 08:15 PM   #4
michaelk
Moderator
 
Registered: Aug 2002
Posts: 25,760

Rep: Reputation: 5931Reputation: 5931Reputation: 5931Reputation: 5931Reputation: 5931Reputation: 5931Reputation: 5931Reputation: 5931Reputation: 5931Reputation: 5931Reputation: 5931
While the thread does contain some what a guide what exact steps did you follow? If your still prompted for a password then something is still not correct. There are more debug messages after the one you posted that might indicate a problem.
 
Old 10-08-2018, 12:31 AM   #5
Turbocapitalist
LQ Guru
 
Registered: Apr 2005
Distribution: Linux Mint, Devuan, OpenBSD
Posts: 7,334
Blog Entries: 3

Rep: Reputation: 3730Reputation: 3730Reputation: 3730Reputation: 3730Reputation: 3730Reputation: 3730Reputation: 3730Reputation: 3730Reputation: 3730Reputation: 3730Reputation: 3730
Quote:
Originally Posted by sniper8752 View Post
I followed the linked guide ...
There's no guide there, just some back-and-forth on stackexchange. Most guides are wrong or out of date on this topic anyway. The debug message you were looking for talks about which keys were tried, but if the error is on the server end the client won't say what's wrong, only that the key won't work.

On the client, set up a key pair and get the public key over to the server:

Code:
cd ~/.ssh/
ssh-keygen -t ed25519 -f server01.key.ed25519 -C "sniper8752 from the desktop"
ssh-copy-id -i server01.key.ed25519.pub server01.example.com
Then test the setup:

Code:
cd
ssh-add ~/.ssh/server01.key.ed25519
ssh  -i ~/.ssh/server01.key.ed25519 -l sniper8752 server01.example.com
If that works, then you can try sshfs. And if sshfs works, put something in your ~/.ssh/config file to make a shortcut for your key and remote user.
 
  


Reply



Posting Rules
You may not post new threads
You may not post replies
You may not post attachments
You may not edit your posts

BB code is On
Smilies are On
[IMG] code is Off
HTML code is Off



Similar Threads
Thread Thread Starter Forum Replies Last Post
LXer: What is SSH Key? How To Generate SSH Key in Linux? LXer Syndicated Linux News 0 04-30-2017 07:42 AM
new ssh server - problem with key authentication (maybe) aristosv Linux - Networking 9 03-06-2017 06:37 PM
SSH skips public key authentication for a key, but works with another key simopal6 Linux - General 1 07-06-2011 08:33 AM
Unable to ssh to linux server after key changes in authorized keys Voyager7 Linux - Newbie 6 01-18-2011 06:09 AM
Putty/SSH login failed when using RSA public key: 'Server refused our key' itsecx@gmail.com Linux - Server 10 10-04-2010 01:19 PM

LinuxQuestions.org > Forums > Linux Forums > Linux - Server

All times are GMT -5. The time now is 09:38 PM.

Main Menu
Advertisement
My LQ
Write for LQ
LinuxQuestions.org is looking for people interested in writing Editorials, Articles, Reviews, and more. If you'd like to contribute content, let us know.
Main Menu
Syndicate
RSS1  Latest Threads
RSS1  LQ News
Twitter: @linuxquestions
Open Source Consulting | Domain Registration