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.

Client does not update Server (after server migration)


I have been using OCS-Inventory for several years. Some months ago, I have installed a new server with OCS through Debian Jessie repositories (OCS 2.0.5). As the computers within the network have the agent installed (version pointing to the former server, I have used same IP/DNS in the newly installed. By doing so, all of the machines began to report to the new server perfectly. Now I have prepared a new OCS inventory server with version 2.2.1 installed manually using the tar.gz file and following the setup.sh instructions. The installation process was successful, again I use same IP/DNS to let the clients report to the new server. But, In this case, no client has made contact with the server so far. I thought that, perhaps, there was an incompatibility issue between server v 2.2.1 and clients In order to test this hypothesis, I installed OCSNG-Windows-Agent- on a machine with my server configuration (http://myserver/ocsinventory). But still, no communication. I have also tried using the deployment tool (I have followed all the configuration steps described in http://wiki.ocsinventory-ng.org/index.php?title=Documentation:DeployTool ) but I got a "**ERROR** Connecting remote host: Access Denied" message.

Does anyone have any clue? Thanks

Information about the server

O.S.: Debian 8.5 Jessie

OCS Server 2.2.1

Information about the clients

O.S.: Windows 7

OCS Agent version:OCSNG_WINDOWS_AGENT_4061.1 and OCSNG-Windows-Agent-

in OCS Inventory NG server for Unix by (140 points)

1 Answer

0 votes

Can you check the configuration of database in apache configuration and db config in ocs report ?

by (6.9k points)

Hello Valentin,

The configuration for both files is the following

Apache: /etc/apache2/conf-available/z-ocsinventory-server.conf

  # Master Database settings
  # Replace localhost by hostname or ip of MySQL server for WRITE
  PerlSetEnv OCS_DB_HOST localhost
  # Replace 3306 by port where running MySQL server, generally 3306
  PerlSetEnv OCS_DB_PORT 3306
  # Name of database
  PerlSetEnv OCS_DB_NAME ocsweb
  PerlSetEnv OCS_DB_LOCAL ocsweb
  # User allowed to connect to database
  PerlSetEnv OCS_DB_USER ocs
  # Password for user
  PerlSetVar OCS_DB_PWD ocs

  # Slave Database settings
  # Replace localhost by hostname or ip of MySQL server for READ
  # Useful if you handle mysql slave databases
  # PerlSetEnv OCS_DB_SL_HOST localhost
  # Replace 3306 by port where running MySQL server, generally 3306
  # PerlSetEnv OCS_DB_SL_PORT_SLAVE 3306
  # User allowed to connect to database
  # PerlSetEnv OCS_DB_SL_USER ocs
  # Name of the database
  # PerlSetEnv OCS_DB_SL_NAME ocsweb
  # Password for user
  # PerlSetVar OCS_DB_SL_PWD ocs

OCS: /usr/share/ocsinventory-reports/ocsreports/dbconfig.inc.php 

define("DB_NAME", "ocsweb");

As you can see, I still haven't change the default configuration. OCS server Is MySQL server. It is very strange. I have done this same installation with previous versions without any difficulties.



The database is not the same on two configuration.
# Name of database
  PerlSetEnv OCS_DB_NAME ocsweb
  PerlSetEnv OCS_DB_LOCAL ocsweb

  define("DB_NAME", "ocsweb");

the name of the database is ocsweb (default). All the configuration that you see is the default (right after running setup.sh from OCS package). I don't understand what is the difference that you are seeing.

Thanks again Valentin
Hello, can you test install clean agent on one computer and test send inventory to server ?

I got a "conecction error in ocs inventory service" message.

Disregards my last comment. I have installed OCS agent in a different machine and service was funcional. Nevertheless, the server never received the update.

The log file of the agent showed the following message:

ERROR *** AGENT => Failed to send Prolog <HTTP Status Code #404

Powered by Question2Answer