You may follow the below steps to upgrade the OpenSSH on a Centos 5 server.
Download the OpenSSH source tarball from the vendor and unpack it. You can find the tarballs athttp://www.openssh.com/portable.html
1 2 3 |
cd /usr/local/src wget <a class="external free" href="http://mirror.esc7.net/pub/OpenBSD/OpenSSH/portable/openssh-6.0p1.tar.gz" rel="nofollow">http://mirror.esc7.net/pub/OpenBSD/OpenSSH/portable/openssh-6.0p1.tar.gz</a> tar -xvzf openssh-6.0p1.tar.gz |
Copy the spec file and tarball:
1 2 |
cp ./openssh-6.0p1.tar.gz/contrib/redhat/openssh.spec /usr/src/redhat/SPECS/ cp openssh-6.0p1.tar.gz /usr/src/redhat/SOURCES/ |
Do a little magic:
1 2 |
cd /usr/src/redhat/SPECS perl -i.bak -pe ‘s/^(%define no_(gnome|x11)_askpass)\s+0$/$1 1/’ openssh.spec |
Build your RPM:
1 |
rpmbuild -bb openssh.spec |
Now if you go back into /usr/src/redhat/RPMS/<arch> , you should see three RPMs. Go ahead and install them:
1 |
rpm -Uvh *.rpm |
To verify the installed version, just type ‘ssh -v localhost’ and you should see the banner come up, indicating the new version.
If you face any issues while trying to update OpenSSH, feel free to open a ticket to Veeble.