IBM Mainframe Forum Index
 
Log In
 
IBM Mainframe Forum Index Mainframe: Search IBM Mainframe Forum: FAQ Register
 

SSH - known_hosts file configuration


IBM Mainframe Forums -> All Other Mainframe Topics
Post new topic   Reply to topic
View previous topic :: View next topic  
Author Message
vasanthz

Global Moderator


Joined: 28 Aug 2007
Posts: 1689
Location: Tiruppur, India

PostPosted: Wed Jul 26, 2017 2:10 am
Reply with quote

Hi,

We are trying to configure SSH on Unix System Services. We have a file called /.ssh/known_hosts
This file has an entry of public key for remote servers.

Currently the /.ssh/known_hosts file resides in the same mount file as the root. And the root is mounted as RO mode.
Since it is mounted in RO mode, we cannot add anymore entries to the file. We are hesitant to make the root RW mode just for editing /.ssh/known_hosts each time.

Is it possible to make SSH look for known_hosts in some other directory location and not /.ssh/known_hosts?

Regards,
Vasanth.S
Back to top
View user's profile Send private message
Robert Sample

Global Moderator


Joined: 06 Jun 2008
Posts: 8569
Location: Dubuque, Iowa, USA

PostPosted: Wed Jul 26, 2017 2:57 am
Reply with quote

The manual talks about having /etc/ssh/ssh_known_hosts and ~/.ssh/known_hosts files so you should be able to update /etc/ssh/ssh_known_hosts since /etc is generally on its own mount point and definitely RW.
Back to top
View user's profile Send private message
vasanthz

Global Moderator


Joined: 28 Aug 2007
Posts: 1689
Location: Tiruppur, India

PostPosted: Wed Jul 26, 2017 5:03 am
Reply with quote

Hi Robert,
You are correct that /etc/ is RW and it has ssh_known_hosts file.

But when I try to connect from Mainframe to a remote server interactively. I get the below error.

Code:
The authenticity of host 'host server' can't be established.
RSA key fingerprint is xx:xx:xx.
Are you sure you want to continue connecting (yes/no)? yes
FOTS2190 Failed to add the host to the list of known hosts (/.ssh/known_hosts).
WELLS@HOST's password:


My colleague suggested that I can try to create a mount point on /.ssh and make it RW. I am planning on copying the contents of /.ssh/ to a temporary directory. Then mount a file to the path and copy the files from temp to the new directory.

Regards,
Vasanth.S
Back to top
View user's profile Send private message
View previous topic :: :: View next topic  
Post new topic   Reply to topic View Bookmarks
All times are GMT + 6 Hours
Forum Index -> All Other Mainframe Topics

 


Similar Topics
Topic Forum Replies
No new posts Compare the file record count percent... DFSORT/ICETOOL 0
No new posts compare two file to find position/dat... SYNCSORT 2
No new posts Converting a file from PD to display ... SYNCSORT 4
No new posts Record count of RECFM=U tape file DFSORT/ICETOOL 17
This topic is locked: you cannot edit posts or make replies. Write Character to Hexadecimal file w... COBOL Programming 8
Search our Forums:

Back to Top