mysqli::real_connect(): php_network_getaddresses: getaddrinfo failed: Name or service not known
mojtabaghaseemi opened this issue · comments
Mojtaba Ghasemi commented
hi
your package has a bug
In the first installation, the server works well, but when the server is restarted
It is no longer possible to access the database
And the following error is received:
mysqli::real_connect(): php_network_getaddresses: getaddrinfo failed: Name or service not known
E.L. commented
Hi,
I tried to restart the server, and also docker compose restart
, but no such issue. Could you check if the DB container is running?
What if you run docker compose exec -T mysql su -c "mysql -uroot -p${MYSQL_ROOT_PASSWORD} -e 'status'"
from the host server? Any output? (please replace the MYSQL_ROOT_PASSWORD with your real password)