Hello,
I'm running Plesk Onyx 17.8.11 Update #7 on CentOs 7.4.1708.
When I run the PHP function file_get_contents() in my code, I'm getting an error:
When running a php script from CLI, it is working fine.
What have I checked and done:
I'm running Plesk Onyx 17.8.11 Update #7 on CentOs 7.4.1708.
When I run the PHP function file_get_contents() in my code, I'm getting an error:
Code:
file_get_contents(): php_network_getaddresses: getaddrinfo failed: Name or service not known in /var/www/...
When running a php script from CLI, it is working fine.
What have I checked and done:
- I have 'allow_url_fopen' enabled (was already enabled)
- I tried to disable the firewall, no success
- I tried to disable selinux, no success
- I tried to add nameserver 8.8.8.8 and 4.4.4.4 to /etc/resolv.conf, did `service httpd restart`, no success