Update to 5.1.1.

Fix for Linux servers and improvements. Special thanks to PowerLord for
the recommendations.