OCSInventory-NG / OCSInventory-Docker-Image

Docker image for OCSInventory Server

Geek Repo:Geek Repo

Github PK Tool:Github PK Tool

Failed opening required 'install.php'

90er opened this issue · comments

Docker host's operating system : CentOS 7.7.1908 (Core)
Mysql Server version : mysql:5.7.29

Docker informations

Docker compose version : docker-compose version 1.25.0, build 0a186604
Docker version : Docker version 19.03.7, build 7141c199a2

Problem's description

I will get the following error trying to start a blank instance of OCS Inventory (
https://raw.githubusercontent.com/OCSInventory-NG/OCSInventory-Docker-Image/master/2.6/docker-compose.yml):

Mon Mar 09 20:42:25.153375 2020] [php7:warn] [pid 175] [client 10.27.3.3:58771] PHP Warning:

require(install.php): failed to open stream: No such file or directory in /usr/share/ocsinventory-reports/ocsreports/require/header.php on line 168
[Mon Mar 09 20:42:25.153399 2020] [php7:error] [pid 175] [client 10.27.3.3:58771] PHP Fatal error:  require(): Failed opening required 'install.php' (include_path='.:/opt/remi/php73/root/usr/share/pear:/opt/remi/php73/root/usr/share/php:/usr/share/pear:/usr/share/php') in /usr/share/ocsinventory-reports/ocsreports/require/header.php on line 168

Fix

"wget https://raw.githubusercontent.com/OCSInventory-NG/OCSInventory-ocsreports/master/install.php" in "/usr/share/ocsinventory-reports/ocsreports/"

This error is posted quite often. I can't confirm that it's fixed with the Docker Image Release 2.6.

Hi @90er,

You shouldn't need the install.php file with compose file since the database is populated on docker start. Did you check the documentation here : http://wiki.ocsinventory-ng.org/13.Docker-documentation/Using-the-docker-image/

Also, are you sure you properly setup the env variables before running the image ?

Regards,
Gilles Dubois.

same error for me, fix helped, using standalone mariadb and docker without compose

I had the exact same issue today, so issue is still not fixed

I now understand what happened: the file ocsbase.sql must be in the sql subfolder, otherwise the SQL database is not set up.

Docker host's operating system : CentOS 7.7.1908 (Core)
Mysql Server version : mysql:5.7.29

Docker informations

Docker compose version : docker-compose version 1.25.0, build 0a186604
Docker version : Docker version 19.03.7, build 7141c199a2

Problem's description

I will get the following error trying to start a blank instance of OCS Inventory (
https://raw.githubusercontent.com/OCSInventory-NG/OCSInventory-Docker-Image/master/2.6/docker-compose.yml):

Mon Mar 09 20:42:25.153375 2020] [php7:warn] [pid 175] [client 10.27.3.3:58771] PHP Warning:

require(install.php): failed to open stream: No such file or directory in /usr/share/ocsinventory-reports/ocsreports/require/header.php on line 168
[Mon Mar 09 20:42:25.153399 2020] [php7:error] [pid 175] [client 10.27.3.3:58771] PHP Fatal error:  require(): Failed opening required 'install.php' (include_path='.:/opt/remi/php73/root/usr/share/pear:/opt/remi/php73/root/usr/share/php:/usr/share/pear:/usr/share/php') in /usr/share/ocsinventory-reports/ocsreports/require/header.php on line 168

Fix

"wget https://raw.githubusercontent.com/OCSInventory-NG/OCSInventory-ocsreports/master/install.php" in "/usr/share/ocsinventory-reports/ocsreports/"

This error is posted quite often. I can't confirm that it's fixed with the Docker Image Release 2.6.

Thanks!

And don't forget to use MySQL 5.7. V8.0 doesn't work with standard settings. Maybe it works with mysql_native_password ? Didn't try it.
See also: https://stackoverflow.com/a/49953657/8398149

Fix

"wget https://raw.githubusercontent.com/OCSInventory-NG/OCSInventory-ocsreports/master/install.php" in "/usr/share/ocsinventory-reports/ocsreports/"

I had the same problem. This workaround is still needed. Thx.