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.11.1 available

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

Windows Agent fail to send inventory

Hi everyone, my agent ( on Win 10 ) does not seem to sent inventory to the OCS server, however, i cant determine where en when does the error occurs ...

This is ocsinventory.ini:

[OCS Inventory Agent]
ComProvider=ComHTTP.dll
Debug=2
Local=
NoSoftware=0
HKCU=0
NoTAG=0
IpDisc=
[HTTP]
Server=http://"MY_OCS_SERVER_IP"/
SSL=1
CaBundle=cacert.pem
AuthRequired=0
User=
Pwd=
ProxyType=0
Proxy=
ProxyPort=0
ProxyAuthRequired=0
ProxyUser=
ProxyPwd=
[OCS Inventory Service]
TTO_WAIT=35760
INVENTORY_ON_STARTUP=0
PROLOG_FREQ=10
OLD_PROLOG_FREQ=10

 en there is the OCS log :

==============================================================================
Starting OCS Inventory NG Agent on Wednesday, March 01, 2017 16: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)
    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 without server authentication
    COM SERVER => Disabling cURL proxy support
    COM SERVER => Enabling cURL SSL server validation support using CA Bundle <C:\ProgramData\OCS Inventory NG\Agent\cacert.pem>
    COM SERVER => Sending fileGet request to URL <http://192.168.10.195//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 <DESKTOP-QII1OJ2-2017-03-01-15-01-21> and MACs <5C:51:4F:92:0D:D35C:51:4F:92:0D:D428:D2:44:4C:1A:0A00:50:56:C0:00:0100:50:56:C0:00:08> in file <ocsinventory.dat>
    COM SERVER => Initializing cURL library for sendRequest
    COM SERVER => Using cURL without server authentication
    COM SERVER => Disabling cURL proxy support
    COM SERVER => Enabling cURL SSL server validation support using CA Bundle <C:\ProgramData\OCS Inventory NG\Agent\cacert.pem>
    COM SERVER => Sending HTTP Post request to URL <http://192.168.10.195/>
    COM SERVER => HTTP Post response received <HTTP Status Code #200>
    COM SERVER => Cleaning cURL library
================= TRACE START ===============

================= TRACE STOP ===============
AGENT => Prolog successfully sent
SUPPORT => No support detected, Registration key : N/A
    AGENT => Prolog Frequency set to 10 hour(s)
    AGENT => Inventory on startup option set to  
AGENT => Unloading communication provider
AGENT => Unloading plug-in(s)
AGENT => Execution duration: 00:00:00.

If anyone can provide help i would be very thankfull,

Thanks !
in OCS Inventory NG agent for Windows by (330 points)
edited by

12 Answers

0 votes
Hi ,

first , sorry for the very late answer, unfortunately i was unable to reply sooner...

@vincent_n : here is the apache.conf as you requested, minus the #comments:

Mutex file:${APACHE_LOCK_DIR} default

PidFile ${APACHE_PID_FILE}

Timeout 300

KeepAlive On

MaxKeepAliveRequests 100

KeepAliveTimeout 5

User ${APACHE_RUN_USER}
Group ${APACHE_RUN_GROUP}

HostnameLookups Off

ErrorLog ${APACHE_LOG_DIR}/error.log

LogLevel warn

IncludeOptional mods-enabled/*.load
IncludeOptional mods-enabled/*.conf

Include ports.conf

<Directory />
    Options FollowSymLinks
    AllowOverride None
    Require all denied
</Directory>

<Directory /usr/share>
    AllowOverride None
    Require all granted
</Directory>

<Directory /var/www/>
    Options Indexes FollowSymLinks
    AllowOverride None
    Require all granted
</Directory>

#<Directory /srv/>
#    Options Indexes FollowSymLinks
#    AllowOverride None
#    Require all granted
#</Directory>

AccessFileName .htaccess

<FilesMatch "^\.ht">
    Require all denied
</FilesMatch>

LogFormat "%v:%p %h %l %u %t \"%r\" %>s %O \"%{Referer}i\" \"%{User-Agent}i\"" vhost_combined
LogFormat "%h %l %u %t \"%r\" %>s %O \"%{Referer}i\" \"%{User-Agent}i\"" combined
LogFormat "%h %l %u %t \"%r\" %>s %O" common
LogFormat "%{Referer}i -> %U" referer
LogFormat "%{User-agent}i" agent

IncludeOptional conf-enabled/*.conf

IncludeOptional sites-enabled/*.conf

@frank : yes i restarted apache and even rebooted the server,

z-ocsinventory-server.conf is in the conf-available directory, is this the wrong place ?

a2enmod z-ocsinventory-server returns :" ERROR: module z-ocsinventory-server does not exist! "

Thanks to you both, and sorry again for the delay,

Best,
by (330 points)
edited by
0 votes

Hi,

As z-ocsinventory-server is located in the conf-available directory you should run a2enconf z-ocsinventory-server

I've had the same problem than you and I've been struggling with it for  a week and I've just found where my problem was. I had copied the ocsinventory-reports and the z-ocsinventory-server from conf-available to conf-enabled.

In fact you must use the a2enconf command. I admit I'm not  very trained on Apache so I didn't know this command. 

Anyway, the official documentation is not enough detailed on this point.

I hope you'll manage to make it work.

by (150 points)
edited by
 
Powered by Question2Answer
...