Steps:
- Check database connection for each request
- Check database connection:
- sleep the process for 10 seconds
- display a custom 500 page.
- The custom 500 page shows "loading..." and will reload the page automatically.
Make a 500 error page which shows "loading" and will reload page in 5 seconds.
Related: Restart php5-fpm without stopping service