LinuxQuestions.org
Review your favorite Linux distribution.
Go Back   LinuxQuestions.org > Forums > Linux Forums > Linux - Software
User Name
Password
Linux - Software This forum is for Software issues.
Having a problem installing a new program? Want to know which application is best for the job? Post your question in this forum.

Notices


Reply
  Search this Thread
Old 03-13-2017, 02:43 AM   #1
WaterCatapult
Member
 
Registered: Jan 2017
Location: Germany
Distribution: Kubuntu 20.04, openSUSE Tumbleweed, Solus
Posts: 85

Rep: Reputation: 17
Unhappy Midnight Commander can not establish SSH connections


Good morning,

I have the strange issue on one of my systems that midnight commander can't establish a connection to other systems using SSH.
Trying to do so results in the standard feedback message that access got denied although I certainly entered the correct IP address and port number.

Can't mc by any chance handle keys properly?
All my Linux using computers are set to allow connections from systems when using the correct SSH key.

Doing a Startpage research don't help much, it seems like I'm in an unique situation that no one else encountered before
 
Old 03-13-2017, 03:26 AM   #2
Turbocapitalist
LQ Guru
 
Registered: Apr 2005
Distribution: Linux Mint, Devuan, OpenBSD
Posts: 5,655
Blog Entries: 3

Rep: Reputation: 2901Reputation: 2901Reputation: 2901Reputation: 2901Reputation: 2901Reputation: 2901Reputation: 2901Reputation: 2901Reputation: 2901Reputation: 2901Reputation: 2901
I'm not sure which version handles keys, but I think it was a while back and anything recent will work. Version 4.8.13 at least handles keys at least. You do have to have the agent available to mc however. Can you connect using keys with your regular SSH client from the same shell as you would launch mc?

Code:
ssh 203.0.113.48
If not, then the problem is not with mc and lies elsewhere. Which desktop environment are you using mc in?
 
Old 03-13-2017, 04:33 AM   #3
WaterCatapult
Member
 
Registered: Jan 2017
Location: Germany
Distribution: Kubuntu 20.04, openSUSE Tumbleweed, Solus
Posts: 85

Original Poster
Rep: Reputation: 17
Quote:
Originally Posted by Turbocapitalist View Post
I'm not sure which version handles keys, but I think it was a while back and anything recent will work. Version 4.8.13 at least handles keys at least. You do have to have the agent available to mc however. Can you connect using keys with your regular SSH client from the same shell as you would launch mc?
Any other programs show no problems connecting, no matter what machine, no matter what DE.
As a workaround of some sort I'm using either scp or sftp to achieve my goals but depending on what these are or where I am connecting from this can be quite annoying.

Quote:
Originally Posted by Turbocapitalist View Post
If not, then the problem is not with mc and lies elsewhere. Which desktop environment are you using mc in?
Depending on the system it's either Plasma5 or MATE... at least when using GNU/Linux.
 
Old 03-13-2017, 04:39 AM   #4
Turbocapitalist
LQ Guru
 
Registered: Apr 2005
Distribution: Linux Mint, Devuan, OpenBSD
Posts: 5,655
Blog Entries: 3

Rep: Reputation: 2901Reputation: 2901Reputation: 2901Reputation: 2901Reputation: 2901Reputation: 2901Reputation: 2901Reputation: 2901Reputation: 2901Reputation: 2901Reputation: 2901
What version of Midnight Commander do you have? How are you launching it? What is the content of the relevant environment variables?

Code:
set | grep '^SSH'
With SSH_AUTH_SOCK set automatically, I can launch mc from a terminal in XFCE, for example, and it will connect using the key I have already loaded into the agent.
 
Old 03-13-2017, 03:26 PM   #5
WaterCatapult
Member
 
Registered: Jan 2017
Location: Germany
Distribution: Kubuntu 20.04, openSUSE Tumbleweed, Solus
Posts: 85

Original Poster
Rep: Reputation: 17
Quote:
Originally Posted by Turbocapitalist View Post
What version of Midnight Commander do you have? How are you launching it? What is the content of the relevant environment variables?
As Debian Stable is the oldest base, at least v4.8.13 - always installed from official repos.
In case of Raspbian and Mint 18.1 it might be newer but is still from their repository.

Quote:
Code:
set | grep '^SSH'
I don't know what the expected results are, as my system's are German all I can say is that the output is mentioning matches in the binary file.

Nothing else otherwise.

Quote:
Originally Posted by Turbocapitalist View Post
With SSH_AUTH_SOCK set automatically, I can launch mc from a terminal in XFCE, for example, and it will connect using the key I have already loaded into the agent.
Call me stupid but where to set said parameters?


Kind regards,
WaterCatapult
 
Old 03-14-2017, 01:52 AM   #6
Turbocapitalist
LQ Guru
 
Registered: Apr 2005
Distribution: Linux Mint, Devuan, OpenBSD
Posts: 5,655
Blog Entries: 3

Rep: Reputation: 2901Reputation: 2901Reputation: 2901Reputation: 2901Reputation: 2901Reputation: 2901Reputation: 2901Reputation: 2901Reputation: 2901Reputation: 2901Reputation: 2901
The variable names have have nothing to do with localization to German. The output should have been something like this, or at least the bottom line:

Code:
$ set | grep '^SSH'
SSH_AGENT_PID=2672
SSH_AUTH_SOCK=/tmp/ssh-nICxD7RuiTti/agent.2619
If your desktop environment doesn't have at least $SSH_AUTH_SOCK set, then that is the problem, not mc itself.

Under normal circumstances your desktop environment sets launches an agent and sets the variable(s) needed to connect to it before it starts up.

I suppose since the other programs can connect that your desktop environment has an agent running?

I'm not so familiar with MATE. Which terminal emulators do you have available for it and do you have the same lack of $SSH_AUTH_SOCK in all of them?
 
  


Reply

Tags
midnight commander, network, problems, ssh


Thread Tools Search this Thread
Search this Thread:

Advanced Search

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
midnight commander shows funny characters when using terminal to ssh into ubuntu box sunbelt57 Linux - Newbie 1 11-27-2013 01:31 PM
midnight commander ssh over unusual port nomikos Linux - Server 5 02-13-2011 06:06 PM
Midnight Commander graphics under WinXP SSH tatacalu Linux - Software 5 05-21-2008 02:55 PM
Midnight Commander - SSH trames Linux - Software 1 04-06-2004 08:56 PM
midnight commander enigma1 Linux - Software 6 12-10-2003 02:47 PM

LinuxQuestions.org > Forums > Linux Forums > Linux - Software

All times are GMT -5. The time now is 03:22 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