Got a weird symptom:
Just notice our devices stop updating to inventory (Last Inventory) like one month ago; however, they are contacting back to OCS server (Last Contact)
-Existing devices are having trouble update inventory.
-New device will be added to inventory; however, after the first insert, it will not update inventory, only contacting.
Here is our setup:
OCS Inventory NG Server version: 2.1.2
OS: Windows Server 2012 R2
Client Agent version: 22.214.171.124 and 126.96.36.199
Here are some discoveries:
Found some repeated entries in "C:\xampp\apache\logs\error.log":
Issuing rollback() due to DESTROY without explicit disconnect() of DBD::mysql::db handle database=ocsweb;host=localhost;port=3306 at C:/xampp/perl/site/lib/Apache/Ocsinventory.pm line 64.
Also, check the PerlSetEnv OCS_DB_USER in "C:\xampp\apache\conf\extra\ocsinventory-server.conf" and verify it can connect to the mySQL database.
It logged Error entry in Application Event log: Service encounter error <OCS Inventory NG Agent encounter an error (exit code is 4 => Failed to talk with Communication Server)>.
Also checked the ocsinventory.log:
Starting OCS Inventory NG Agent on Wednesday, August 01, 2018 13:29:46.
AGENT => Running OCS Inventory NG Agent Version 188.8.131.52
AGENT => Using OCS Inventory NG FrameWork Version 184.108.40.206
AGENT => Loading plug-in(s)
AGENT => Using network connection with Communication Server
AGENT => Using Communication Provider <OCS Inventory NG cURL Communication Provider> Version <220.127.116.11>
AGENT => Sending Prolog
AGENT => Prolog successfully sent
SUPPORT => No support detected, Registration key : N/A
AGENT => Inventory required
AGENT => Launching hardware and software checks
AGENT => Sending Inventory
INVENTORY => Inventory changed since last run
ERROR *** AGENT => Failed to send Inventory <HTTP Status Code #500>
AGENT => Communication Server ask for Package Download
AGENT => Unloading communication provider
AGENT => Unloading plug-in(s)
AGENT => Execution duration: 00:00:15.
For the Error 500, we checked the PerlSetEnv OCS_DB_USER in "C:\xampp\apache\conf\extra\ocsinventory-server.conf" and verify it can connect to the mySQL database.
Need some guidance to troubleshoot further.