Server Fault is a question and answer site for system and network administrators. It's 100% free, no registration required.

Sign up
Here's how it works:
  1. Anybody can ask a question
  2. Anybody can answer
  3. The best answers are voted up and rise to the top

I have a centos server that recently needed a fsck repair on it's main hard drive. After fixing a bunch of inode issues (booting from a system rescue disk), the box booted clean. Most of the services are running fine, however the sshd service immediately core dumps when I try to start it.

Running gdb /usr/sbin/sshd, the last line before it dumps the core is:

Reading symbols from /lib/ ... (no debugging available)
Loaded symbols for /lib/
Core was generated by `/usr/sbin/sshd'.
Program terminated with signal 11, Segmentation fault
#0 0x00a0dffc in PEM_read_bio () from /lib/

I've tried reinstalling sshd by (yum reinstall openssh), but no luck.

* Update * I was able to get it working. In case it helps anyone else, here was the critical clue:

rpm -Va openssl prints out:

prelink: /lib/ prelinked file was modified
S.?...... /lib/

Obviously something is messed up with libcrypto (the gdb core dump also pointed to libcrypto). Looking at /lib/libcrypto* I figured out what version it was running. There is no way that I know of to have yum force reinstall the dependencies, so in the end, I had to copy the from another working server (using wget because scp did not work). After replacing that file, all was well.

share|improve this question
Can you add the output of bt run inside gdb? bt will show the stack trace at the time of the core dump. – Mircea Vutcovici Apr 23 '12 at 2:00
Thanks - that would have given another important clue. The backtrace also pointed to the library – John P Apr 23 '12 at 2:05
up vote 3 down vote accepted

This is a CentOS system. You were not reinstalling the entire suite. The relevant packages for OpenSSH are: openssh, openssh-server and openssh-clients. The sshd binary is part of the openssh-servers package.

Try yum reinstall openssh openssh-server openssh-clients and see if that works.

In general, to check the consistency of the packages on the system, you can use rpm verify.

rpm -vV packagename for an individual package.


rpm -vVa to check consistency of all installed packages.

share|improve this answer
Besides the binaries, that are easy to check and recover, he has to check the consistency of the data that is stored on the same fs (e.g. database files, web sites etc.). – Mircea Vutcovici Apr 23 '12 at 2:20
The "yum reinstall" did not reinstall the libraries - I had to manually update the so file – John P Apr 23 '12 at 13:08

I think that one of the libraries used by sshd or may be pamlib are corrupted. Best is to check the signatures of all packages, then verify your data/configuration integrity. If you can build the system from scratch and use a fresh backup.

share|improve this answer
You're right - turned out to be libcrypto. For bonus points, is there any way to have rpm/yum check the signatures of all installed packages? Just in case something else is corrupted that I just have not triggered yet. – John P Apr 23 '12 at 2:07

Your Answer


By posting your answer, you agree to the privacy policy and terms of service.

Not the answer you're looking for? Browse other questions tagged or ask your own question.