LinuxQuestions.org
Welcome to the most active Linux Forum on the web.
Home Forums Tutorials Articles Register
Go Back   LinuxQuestions.org > Forums > Linux Forums > Linux - General
User Name
Password
Linux - General This Linux forum is for general Linux questions and discussion.
If it is Linux Related and doesn't seem to fit in any other forum then this is the place.

Notices


Reply
  Search this Thread
Old 05-25-2004, 04:20 PM   #1
CarlosSunden
LQ Newbie
 
Registered: May 2004
Location: USA
Distribution: Red Hat
Posts: 17

Rep: Reputation: 0
Openssh: could not load...


Hello
1. Installed latest openssl
2. installed latest openssh (tar.gz)
3. openssh: ./configure, make, make install
4. This says “install the OpenSSH binaries in /usr/local/bin, configuration files in /usr/local/etc, the server in /usr/local/sbin, etc.”
5. Followed this http://www.securetux.com/docs/Securi...p15sec122.html to setup the /usr/local/openssh-3.81p1/sshd_config file
5. was not getting connection. "reset by peer'
6. Looks like this tar.gz install did not use xinetd to start/stop sshd, or the /etc/init.d/sshd restart . since none of these commands work

7. To stop & restart sshd, i used this command: /usr/local/openssh-3.8.1p1/sshd. I have verified this when I do a ps aux | grep sshd

8. Edited the /etc/rc.d/rc.local and added;
echo "Starting sshd ...." /usr/local/sbin/sshd

9. started the sshd again

10. did a search for sshd_config and noticed another file of same name in /usr/local/etc/ There are two locations, one there & one I have been modifying in /usr/local/openssh-3.8.1p1/
11. Made a backup copy of the one in /usr/local/etc and copied the modified & the one I thought was being used in /usr/local/openssh-3.8.1p1 to /usr/local/etc
12. Stop, started sshd using: /usr/local/openssh-3.8.1p1/sshd command and got:
could not load host key: /etc/ssh/ssh_host_rsa_key
disabling protocol version 2. could not load host key
sshd: no hostkeys available -- exiting

13. I did a search for ssh_host_rsa_key and it was found in /usr/local/etc/ and not in the /etc/ssh/ as listed in the sshd_config file

14. so, modifid the sshd_config file to reflect the actual location in: /usr/local/etc/ so the entry is:
Hostkey /usr/local/etc/ssh/ssh_host_rsa_key which is of course uncommented. The HostKey entry was uncommencted to look:
HostKey /usr/local/etc/ssh/sshd_host_key

15. stop. started the sshd daemon and got:

could not load host key: /usr/local/etc/ssh/ssh_host_key
could not load host key: /usr/local/etc/ssh/ssh_ost_rsa_key
disabling protocol versiob 2. could not load host key
sshd: no hostkeys available -- exiting

yes I am confused, thanks for reading & appreciate any input, thanks in advance!

Carlos
 
Old 05-25-2004, 05:00 PM   #2
jschiwal
LQ Guru
 
Registered: Aug 2001
Location: Fargo, ND
Distribution: SuSE AMD64
Posts: 15,733

Rep: Reputation: 682Reputation: 682Reputation: 682Reputation: 682Reputation: 682Reputation: 682
From section 15.1.2 on the same website you quoted:
Now, we must compile and install OpenSSH on the Server: [root@deep ]/openssh-1.2.3#make
[root@deep ]/openssh-1.2.3#make install
[root@deep ]/openssh-1.2.3#make host-key
[root@deep ]/openssh-1.2.3#install -m644 contrib/redhat/sshd.pam /etc/pam.d/sshd

make
command will compile all source files into executable binaries,

make install
will install the binaries and any supporting files into the appropriate locations.

make host-key
command will generate a host key.

install
command will install the PAM support for Red Hat Linux, which is now more functional than the popular packages of commercial ssh-1.2.x.


Did you do the make hostkey step mentioned. I don't know whether you are installing this on redhat or debian. I don't know how debian services are started.
 
Old 05-26-2004, 10:51 AM   #3
CarlosSunden
LQ Newbie
 
Registered: May 2004
Location: USA
Distribution: Red Hat
Posts: 17

Original Poster
Rep: Reputation: 0
OK

I did the ./configure, make, make install on opsnssh-3.8.1p1.tar.gz
and use the gunzip, tar -xvf which installs "OpenSSH binaries in /usr/local/bin, configuration files in /usr/local/etc, the server in /usr/local/sbin, etc.”

Think I have followed the right steps on doing this.

Have not done make host-key and the install command.

Was not aware this needed to be done, since I had used an RPM openssh previously in another RHL8 system & encountered not an issue.

It is an RHL8 system.

I will run the make host-key & install in the /usr/local/openssh-3.8.1p1/

Do let me know of any other issues ,thanks so much!
 
Old 05-26-2004, 12:01 PM   #4
CarlosSunden
LQ Newbie
 
Registered: May 2004
Location: USA
Distribution: Red Hat
Posts: 17

Original Poster
Rep: Reputation: 0
Running make host-key reports in /usr/local/openssh-3.8.1p1/
/usr/local/etc/ssh_hst_key already exists, skipping
/usr/local/etc/ssh_host_dsa_key already exists, skipping
/usr/local/etc/ssh_hosts_rsa_key already exists, skipping

It appears that /usr/local/etc/ is an "official"path or place for this particular install of Openssh.

Ran "install" in the location for PAM but keeps asking for another argument.

How is it possible to uninstall openssh when it was done with a tar.gz package?

Any suggestions welcome, thanks again!
 
  


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 On
HTML code is Off



Similar Threads
Thread Thread Starter Forum Replies Last Post
openssh bong.mau Linux - Software 2 11-09-2005 12:04 PM
OpenSSH gregoryfrancis Linux - General 4 03-02-2003 01:09 PM
openSSH? MrJoshua Linux - General 3 10-09-2002 12:17 PM
openSSH Niphargus Linux - Security 4 08-06-2002 08:46 PM
OpenSSH Tarantismic Yak Linux - Security 2 07-14-2001 04:26 AM

LinuxQuestions.org > Forums > Linux Forums > Linux - General

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