LinuxQuestions.org
LinuxAnswers - the LQ Linux tutorial section.
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 07-29-2007, 02:25 PM   #1
Vanyel
Member
 
Registered: Jul 2007
Location: NY, NY
Distribution: RHEL, CentOS, FC, Ubuntu
Posts: 113

Rep: Reputation: 17
Some help with a new version of SSH under RHEL 4


After reading about the Controlmaster features of OpenSSH 4, <http://www.debian-administration.org/articles/290>
<http://www.cyberciti.biz/tips/howto-improve-ssh-session-performance-by-reusing-an-existing-connection-to-a-remote-openssh-server.html>

I decided I want to try it out. But I see RHEL 4 only has OpenSSH 3.9 installed.

So I d/l'd and installed the latest OpenSSH in a /test directory so I'll have all my distro-supplied stuff to revert to just in case.

How do I tell my system to use the ssh server binaries in /test instead of the default one?
 
Old 07-30-2007, 10:13 AM   #2
cconstantine
Member
 
Registered: Dec 2005
Distribution: RedHat, Ubuntu
Posts: 101

Rep: Reputation: 15
the following will mess up your RedHat installed start/stop script. So RedHat will probably complain the next time you try to do an update -- it'll see you have the RH sshd package, but your start/stop script will be altered... you need to understand what you're doing when you try the following:

look at the /etc/init.d/sshd shell script. On RHEL, this is the "controller" script used by init to start/stop ssh. There are several variables set at the top. I would create a *new* directory -- don't use /etc/sshd, the standard RHEL config location -- to hold the config of your freshly installed sshd. Maybe /etc/sshd_v1.4 or something...

stop the sshd (as root '# /etc/init.d/sshd stop') before you edit the script. DANGER: if you are connecting to the system remotely, keep an extra login screen off to the side. If you stop sshd and log out, you will need to go to the console. Refer to chkconfig(1) for info on how sshd is auto start/stopped at boot/shutdown.

Then adjust your init.d/sshd shell script. Change the KEYGEN and SSHD variables to point to the new ones you installed. Update all the instances of /etc/sshd/ to reflect the new config dir containing your configs for your new installation. (I would start by copying the entire /etc/sshd/ directory if your new install didn't make you a new config dir somewhere.)

after adjusting, start it up: '/etc/init.d/sshd start'

-c
 
Old 08-10-2007, 10:15 AM   #3
Vanyel
Member
 
Registered: Jul 2007
Location: NY, NY
Distribution: RHEL, CentOS, FC, Ubuntu
Posts: 113

Original Poster
Rep: Reputation: 17
Thanks cconstantine.

I waited a bit to see if anyone else might chime in. Then it occured to me to rename /usr/sbin/sshd as /usr/sbin/sshd.old and then hard link my /test/sbin/sshd from its install dir to be /usr/sbin/sshd. A "service sshd restart" and I was up and running with the new sshd (I can tell it's the new one because when I log in I'm notified that my server's rsa key has changed). Seems simpler.

GOOD ADVICE about keeping an extra login off to the side. I didn't need it, but that's always good advice if messing remotely with sshd. And just in case, I didn't do this from home, so if worst came to worst, I could walk over to the server room.
 
  


Reply

Tags
openssh, 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
Secondary RHEL 4 OS Version Install - Possible? rkmason Red Hat 1 06-18-2007 05:21 AM
libssl version for RHEL 4.4 dinhn Linux - General 1 06-13-2007 01:35 PM
how to play songs in RHEL 4.0 ES version surapaneni Red Hat 2 03-22-2006 08:04 AM
Latest version of RHEL? Cheeseboy Red Hat 1 11-24-2004 08:42 AM
RHEL 2.1 is a beefed up version of RH 7.1? ganninu Linux - Software 1 03-30-2004 11:09 AM


All times are GMT -5. The time now is 07:50 AM.

Main Menu
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
identi.ca: @linuxquestions
Facebook: linuxquestions Google+: linuxquestions
Open Source Consulting | Domain Registration