OUTDATED. See bottom.
Recently I made an update my ocsinventoryng server on CentOS via yum from remi repo. Server has installed following packages:
ocsinventory-agent-2.1.1-1.el5.remi
ocsinventory-reports-2.1.2-3.el5.remi
ocsinventory-2.1.2-3.el5.remi
ocsinventory-server-2.1.2-3.el5.remi
Important: agent version is lower than server 2.1.1 < 2.1.2
Everything works fine after update, but ocs agent installed on ocs server doesn't report. I found in logs these entries:
OCS Agent log installed on ocs server:
[Wed Sep 17 07:01:01 2014] Running ocsinventory-agent --wait 100 --tag=TAG --lazy --nolocal --server=http://ocsinventory-ng/ocsinventory
[Wed Sep 17 07:01:02 2014][info] Going to sleep for 21 second(s)
[Wed Sep 17 07:01:24 2014][error] Cannot establish communication : 400 Bad Request
[Wed Sep 17 07:01:24 2014][info] Previous PROLOG_FREQ found (24)
[Wed Sep 17 07:01:24 2014] End of cron job (/sbin:/bin:/usr/sbin:/usr/bin)
and OCS Server log:
Wed Sep 17 07:01:24 2014;31721;310;centos-2009-10-23-15-01-18;127.0.0.1;OCS-NG_unified_unix_agent_v2.1.1;handler;trusted_computer
Wed Sep 17 07:01:24 2014;31721;310;centos-2009-10-23-15-01-18;127.0.0.1;OCS-NG_unified_unix_agent_v2.1.1;handler;trusted_computer
Wed Sep 17 07:01:24 2014;31721;400;centos-2009-10-23-15-01-18;127.0.0.1;OCS-NG_unified_unix_agent_v2.1.1;useragent;Bad agent or agent version too recent for server !!
Wed Sep 17 07:01:24 2014;31721;106;centos-2009-10-23-15-01-18;127.0.0.1;OCS-NG_unified_unix_agent_v2.1.1;prolog;stopped by module
Wed Sep 17 07:01:24 2014;31721;515;centos-2009-10-23-15-01-18;127.0.0.1;OCS-NG_unified_unix_agent_v2.1.1;end;bad_request
In this log is important text: "Bad agent or agent version too recent for server !!"
The same is with agent for Windows version 2.1.1.1 (current from OCS website)
OCS Agent log on windows:
Starting OCS Inventory NG Agent on Wednesday, September 17, 2014 09:49:58.
AGENT => Running OCS Inventory NG Agent Version 2.1.1.1
AGENT => Using OCS Inventory NG FrameWork Version 2.1.1.1
AGENT => Loading plug-in(s)
AGENT => Using network connection with Communication Server
AGENT => Using Communication Provider <OCS Inventory NG cURL Communication Provider> Version <2.1.1.1>
AGENT => Sending Prolog
ERROR *** AGENT => Failed to send Prolog <HTTP Status Code #400>
AGENT => Unloading communication provider
AGENT => Unloading plug-in(s)
AGENT => Execution duration: 00:00:00.
and OCS Server log:
Wed Sep 17 09:49:59 2014;31717;511;NA;192.168.53.13;OCS-NG_WINDOWS_AGENT_v2.1.1.1;deploy;no_file
Wed Sep 17 09:49:59 2014;31717;515;NA;192.168.53.13;OCS-NG_WINDOWS_AGENT_v2.1.1.1;end;bad_request
Wed Sep 17 09:49:59 2014;31720;400;TEST04-2014-09-15-13-46-05;192.168.53.13;OCS-NG_WINDOWS_AGENT_v2.1.1.1;useragent;Bad agent or agent version too recent for server !!
Wed Sep 17 09:49:59 2014;31720;106;TEST04-2014-09-15-13-46-05;192.168.53.13;OCS-NG_WINDOWS_AGENT_v2.1.1.1;prolog;stopped by module
Wed Sep 17 09:49:59 2014;31720;515;TEST04-2014-09-15-13-46-05;192.168.53.13;OCS-NG_WINDOWS_AGENT_v2.1.1.1;end;bad_request
And again the same text: "Bad agent or agent version too recent for server !!"
Other computers with ocs agents (version 2.0.5.0 and 2.0.5.3), communicating properly with the same server.
Can anyone help me please ??
Thanks a lot.
EDIT
Everything work fine. Problem was caused by old Perl modules existing on OCS Server.