Wednesday, May 28, 2014

Apache fails to handle requests with "libgcc_s.so.1 must be installed for pthread_cancel to work"

I recently had an apache2 server go down while I was using it. I still don't know what caused it, but I do know how I fixed it, thanks to this thread on Launchpad. Adding libgcc_s.so.1 to the ld pre-load got me back up and running.

echo "/lib/i386-linux-gnu/libgcc_s.so.1" >> /etc/ld.so.preload
ldconfig
The value echoed is the path to the libgcc_s.so.1 file on your system. It can be found with:
gcc --print-file-name=libgcc_s.so.1
I hope this helps anybody who has a similar problem.