Drupal database not found after running update.php after installing a module I run update.php and then click take me to front page or take me to admin pages the page takes a while to load and eventually gives me the following error:

PDOException: SQLSTATE[HY000] [2002] No route to host in lock_may_be_available() (line 167 of /code/includes/lock.inc).


This seems to happen even if there are no pending updates. There was no changes to settings.php, This also happens if i try and open to many pages to the site at the same time.

the only way to get the site back up and running is to restart the container(Kalabox.)

Any insight on how i can fix this or at least how to trouble shoot it would be great.
"No route to host" looks like something related to DNS. If you're not, try using an IP for your database server in settings.php

If it's localhost, use 127.0.0.1