Closed TheFiZi closed 3 years ago
After upgrading to 2.9.1 the issue persisted.
I finally found out I can enable MySQL error logging by editing /etc/httpd/conf.d/z-ocsinventory-server.conf
and changing
PerlSetEnv OCS_OPT_DBI_PRINT_ERROR 0
to
PerlSetEnv OCS_OPT_DBI_PRINT_ERROR 1
After enabling that our logs flooded with:
DBD::mysql::st execute failed: Out of range value for column 'ID' at row 1 at /usr/local/share/perl5/Apache/Ocsinventory/Server/Inventory/Software.pm line 56.
According to this (https://ask.ocsinventory-ng.org/10330/error-last-inventory-and-http-status-code-%23-500) I need to do the following:
To correct the problem you have to change id column of table "softwares" from int to bigint. I have one question : do you delete machines (and their softwares associated) that are not more inventoried? Actually this feature is not implemented yet but we are working on it.
After changing ID from int
to bigint
the Out of range value for column 'ID' at row 1
went away along with all "POST /ocsinventory HTTP/1.1" 500
that were randomly appearing at the same time as the MySQL error.
Checking a few random systems that were not reporting software before, they appear to be reporting software now.
The 2.9.1 upgrade caused a different issue though related to displaying All Software
in the WebUI. I will open a separate issue for that if I can't find a solution.
It's hard to solve a problem when important details are missing, that why we added this template, to help you and us.
General informations
Operating system : CentOS Linux release 7.9.2009 (Core)
Server informations
Perl version : v5.16.3 Mysql / Mariadb / Percona version : 5.5.68-MariaDB
OCS Inventory informations
Ocs server version : 2.8.0
Problem's description
We have about a dozen systems (out of 1000+) that are not reporting their installed software to our OCS Inventory Server.
I found the following for one of the clients in the
ssl_error_log
I found this similar issue: https://github.com/OCSInventory-NG/OCSInventory-Server/issues/275 but I do not understand what the bug submitters solution ended up being.