Welcome to OCS Inventory NG community support, where you can ask questions and receive answers from other members of the community.

Please ask questions only in English or French.

Release 2.3 available

The official documentation can be found on http://wiki.ocsinventory-ng.org. Read it before asking your question.

Agent windows error http 405

Hello,

Hi have a server OCS and i have install the agent windows on my server, the sync with the server doesn't work and in the file OCSInventory.conf

I have this error :

Starting OCS Inventory NG Agent on Thursday, February 23, 2017 13:36:57.
AGENT => Running OCS Inventory NG Agent Version 2.3.0.0
AGENT => Using OCS Inventory NG FrameWork Version 2.3.0.0
AGENT => Loading plug-in(s)
AGENT => Using network connection with Communication Server
AGENT => Using Communication Provider <OCS Inventory NG cURL Communication Provider> Version <2.3.0.0>
AGENT => Sending Prolog
ERROR *** AGENT => Failed to send Prolog <HTTP Status Code #405>
AGENT => Unloading communication provider
AGENT => Unloading plug-in(s)
AGENT => Execution duration: 00:00:00.
asked Feb 23 in OCS Inventory NG agent for Windows by castous (760 points)

12 Answers

+1 vote
Hello,

In your ini file -> DEBUG=2 and launch the agent then give the logs

+ show me the conf of your agent

+ check apache access and errors log + ocsinventory activity logs
answered Feb 23 by vincent_n (4,810 points)
0 votes
==============================================================================
Starting OCS Inventory NG Agent on Thursday, February 23, 2017 16:30:00.
AGENT => Running OCS Inventory NG Agent Version 2.3.0.0
AGENT => Using OCS Inventory NG FrameWork Version 2.3.0.0
AGENT => Loading plug-in(s)
    DLL PLUGIN => Searching for Plug-in DLL(s) in folder <C:\Program Files (x86)\OCS Inventory Agent\plugins>
    DLL PLUGIN => 0 DLL Plug-in(s) successfully loaded on 0 DLL(s) found
AGENT => Using network connection with Communication Server
    COM PROVIDER => Loading Communication Provider <C:\Program Files (x86)\OCS Inventory Agent\ComHTTP.dll>
AGENT => Using Communication Provider <OCS Inventory NG cURL Communication Provider> Version <2.3.0.0>
    AGENT => Sending getLabel request
    COM SERVER => Initializing cURL library for getFile
    COM SERVER => Using cURL with server authentication
    COM SERVER => Disabling cURL proxy support
    COM SERVER => Disabling cURL SSL server validation support
    COM SERVER => Sending fileGet request to URL <http://192.168.1.205:8080/ocs/ocsreports/deploy/label>
    COM SERVER => fileGet response received <HTTP Status Code #404>
    COM SERVER => Cleaning cURL library
    AGENT => Failed to retrieve Label <HTTP Status Code #404>
AGENT => Sending Prolog
    DID_CHECK => Read DeviceID <SRV-GLPI-2017-02-23-10-17-50> and MACs <00:15:5D:01:24:19> in file <ocsinventory.dat>
    COM SERVER => Initializing cURL library for sendRequest
    COM SERVER => Using cURL with server authentication
    COM SERVER => Disabling cURL proxy support
    COM SERVER => Disabling cURL SSL server validation support
    COM SERVER => Sending HTTP Post request to URL <http://192.168.1.205:8080/ocs/ocsreports>
    COM SERVER => HTTP Post response received <HTTP Status Code #405>
    COM SERVER => Cleaning cURL library
================= TRACE START ===============

================= TRACE STOP ===============
ERROR *** AGENT => Failed to send Prolog <HTTP Status Code #405>
AGENT => Unloading communication provider
AGENT => Unloading plug-in(s)
AGENT => Execution duration: 00:00:00.
answered Feb 23 by castous (760 points)
0 votes

   COM SERVER => Disabling cURL proxy support
    COM SERVER => Disabling cURL SSL server validation support
    COM SERVER => Sending HTTP Post request to URL <http://192.168.1.205:8080/ocs/ocsreports>
    COM SERVER => HTTP Post response received <HTTP Status Code #405>
    COM SERVER => Cleaning cURL library

URL for inventory must be : http(s)://yourIPorHOSTNAME:portifnot80/ocsinventory

So for you : http://192.168.1.205:8080/ocsinventory

Change it in the agent conf file and try again :)

answered Feb 23 by vincent_n (4,810 points)
0 votes
Starting OCS Inventory NG Agent on Thursday, February 23, 2017 16:43:31.
AGENT => Running OCS Inventory NG Agent Version 2.3.0.0
AGENT => Using OCS Inventory NG FrameWork Version 2.3.0.0
AGENT => Loading plug-in(s)
    DLL PLUGIN => Searching for Plug-in DLL(s) in folder <C:\Program Files (x86)\OCS Inventory Agent\plugins>
    DLL PLUGIN => 0 DLL Plug-in(s) successfully loaded on 0 DLL(s) found
AGENT => Using network connection with Communication Server
    COM PROVIDER => Loading Communication Provider <C:\Program Files (x86)\OCS Inventory Agent\ComHTTP.dll>
AGENT => Using Communication Provider <OCS Inventory NG cURL Communication Provider> Version <2.3.0.0>
    AGENT => Sending getLabel request
    COM SERVER => Initializing cURL library for getFile
    COM SERVER => Using cURL with server authentication
    COM SERVER => Disabling cURL proxy support
    COM SERVER => Disabling cURL SSL server validation support
    COM SERVER => Sending fileGet request to URL <http://192.168.1.205:8080/ocsreports/deploy/label>
    COM SERVER => fileGet response received <HTTP Status Code #404>
    COM SERVER => Cleaning cURL library
    AGENT => Failed to retrieve Label <HTTP Status Code #404>
AGENT => Sending Prolog
    DID_CHECK => Read DeviceID <SRV-GLPI-2017-02-23-10-17-50> and MACs <00:15:5D:01:24:19> in file <ocsinventory.dat>
    COM SERVER => Initializing cURL library for sendRequest
    COM SERVER => Using cURL with server authentication
    COM SERVER => Disabling cURL proxy support
    COM SERVER => Disabling cURL SSL server validation support
    COM SERVER => Sending HTTP Post request to URL <http://192.168.1.205:8080/ocsreports>
    COM SERVER => HTTP Post response received <HTTP Status Code #404>
    COM SERVER => Cleaning cURL library
================= TRACE START ===============

================= TRACE STOP ===============
ERROR *** AGENT => Failed to send Prolog <HTTP Status Code #404>
AGENT => Unloading communication provider
AGENT => Unloading plug-in(s)
AGENT => Execution duration: 00:00:00.
answered Feb 23 by castous (760 points)
0 votes

 COM SERVER => Sending HTTP Post request to URL <http://192.168.1.205:8080/ocsreports>
    COM SERVER => HTTP Post response received <HTTP Status Code #40

Not ocsreports but ocsinventory...

+ are you sure to be in 8080 ? And http or https ?

answered Feb 23 by vincent_n (4,810 points)
0 votes
oups sorry,

==============================================================================
Starting OCS Inventory NG Agent on Thursday, February 23, 2017 16:54:20.
AGENT => Running OCS Inventory NG Agent Version 2.3.0.0
AGENT => Using OCS Inventory NG FrameWork Version 2.3.0.0
AGENT => Loading plug-in(s)
    DLL PLUGIN => Searching for Plug-in DLL(s) in folder <C:\Program Files (x86)\OCS Inventory Agent\plugins>
    DLL PLUGIN => 0 DLL Plug-in(s) successfully loaded on 0 DLL(s) found
AGENT => Using network connection with Communication Server
    COM PROVIDER => Loading Communication Provider <C:\Program Files (x86)\OCS Inventory Agent\ComHTTP.dll>
AGENT => Using Communication Provider <OCS Inventory NG cURL Communication Provider> Version <2.3.0.0>
    AGENT => Sending getLabel request
    COM SERVER => Initializing cURL library for getFile
    COM SERVER => Using cURL with server authentication
    COM SERVER => Disabling cURL proxy support
    COM SERVER => Disabling cURL SSL server validation support
    COM SERVER => Sending fileGet request to URL <http://192.168.1.205:8080/ocsinventory/deploy/label>
    COM SERVER => fileGet response received <HTTP Status Code #404>
    COM SERVER => Cleaning cURL library
    AGENT => Failed to retrieve Label <HTTP Status Code #404>
AGENT => Sending Prolog
    DID_CHECK => Read DeviceID <SRV-GLPI-2017-02-23-10-17-50> and MACs <00:15:5D:01:24:19> in file <ocsinventory.dat>
    COM SERVER => Initializing cURL library for sendRequest
    COM SERVER => Using cURL with server authentication
    COM SERVER => Disabling cURL proxy support
    COM SERVER => Disabling cURL SSL server validation support
    COM SERVER => Sending HTTP Post request to URL <http://192.168.1.205:8080/ocsinventory>
    COM SERVER => HTTP Post response received <HTTP Status Code #404>
    COM SERVER => Cleaning cURL library
================= TRACE START ===============

================= TRACE STOP ===============
ERROR *** AGENT => Failed to send Prolog <HTTP Status Code #404>
AGENT => Unloading communication provider
AGENT => Unloading plug-in(s)
AGENT => Execution duration: 00:00:00.
answered Feb 23 by castous (760 points)
0 votes
Your OCS server is in http or https ? The port is good ?

Check this topic : http://ask.ocsinventory-ng.org/6242/windows-agent-data-not-inventoried-logs-ok

I gave several solutions maybe it will help you !
answered Feb 23 by vincent_n (4,810 points)
0 votes
The ocs server is in http
answered Feb 23 by castous (760 points)
0 votes
for the port on my server is 8080 for connect in my browsers
answered Feb 23 by castous (760 points)
0 votes
for the port I put the one I put in IIS where is GLPI and OCS installed (OCS in linux version)
answered Feb 24 by castous (760 points)
 
Powered by Question2Answer
...