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.

Problème de communication entre l'agent Windows et le serveur [closed]

Bonjour à tous,

J'ai installé un serveur OCS Inventory sur un serveur W2012R2 (avec Xampp).

J'ai déployé l'agent par GPO via OCSPackager, qui s'est correctement déployé sur tous les postes du parc.

Seul problème, les postes ne parviennent pas à remonter dans l'inventaire, et dans le log de l'agent, j'ai l'erreur suivante :

Starting OCS Inventory NG Agent on Monday, September 12, 2016 11:45:18.
AGENT => Running OCS Inventory NG Agent Version 2.1.1.3
AGENT => Using OCS Inventory NG FrameWork Version 2.1.1.3
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.3>
AGENT => Sending Prolog
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.

J'ai lu sur le wiki que cette erreur correspondrait à une erreur de paramétrage du serveur Apache, mais je ne sais pas où chercher.

Merci d'avance de votre aide !
closed with the note: Problème résolu
in OCS Inventory NG server for Windows by (160 points)
closed by

5 Answers

0 votes
Bonjour,

Il faut vérifier que le module perl est bien actif sur apache. Est-ce que le service apache a été redémarré après l'installation de xampp?

Poste le contenu du fichier c:\xampp\apache\logs\error.log

Cordialement

Frank
by (88.5k points)
J'ai bien entendu redémarré le serveur apache, sans effet.

Le fichier error.log est rempli de message d'erreur comme ça :

[Mon Sep 12 11:26:13.557856 2016] [:error] [pid 288:tid 1788] [client 192.168.0.211:49741] PHP Deprecated:  mysql_connect(): The mysql extension is deprecated and will be removed in the future: use mysqli or PDO instead in C:\\xampp\\htdocs\\ocsreports\\backend\\require\\connexion.php on line 10

Il y a également quelques autres messages, mais rien qui ne semble toucher OCS.

Par contre, j'ai ce message qui s'affiche dans access.log provenant d'adresses IP différentes :

192.168.13.147 - - [12/Sep/2016:13:09:26 +0200] "POST /ocsinventory HTTP/1.1" 404 1057 "-" "OCS-NG_WINDOWS_AGENT_v2.1.1.3"
0 votes
Redémarre le serveur apache et poste le contenu du ficher error.log. J'ai besoin de de voir les lignes qui s'affichent au démarrage d'apache.

Cordialement

Frank
by (88.5k points)
Après redémarrage du service Apache, voici les dernières lignes contenues par le error.log :

[Mon Sep 12 14:00:42.103293 2016] [ssl:warn] [pid 2412:tid 404] AH01909: www.example.com:443:0 server certificate does NOT include an ID which matches the server name
[Mon Sep 12 14:00:42.150171 2016] [core:warn] [pid 2412:tid 404] AH00098: pid file C:/xampp/apache/logs/httpd.pid overwritten -- Unclean shutdown of previous Apache run?
[Mon Sep 12 14:00:42.306414 2016] [ssl:warn] [pid 2412:tid 404] AH01909: www.example.com:443:0 server certificate does NOT include an ID which matches the server name
PHP Warning:  PHP Startup: Unable to load dynamic library 'C:\\xampp\\php\\ext\\php_sqlite.dll' - Le module sp\xef\xbf\xbdcifi\xef\xbf\xbd est introuvable.\r\n in Unknown on line 0
[Mon Sep 12 14:00:42.384540 2016] [mpm_winnt:notice] [pid 2412:tid 404] AH00455: Apache/2.4.23 (Win32) OpenSSL/1.0.2h PHP/5.6.24 configured -- resuming normal operations
[Mon Sep 12 14:00:42.384540 2016] [mpm_winnt:notice] [pid 2412:tid 404] AH00456: Apache Lounge VC11 Server built: Jul  7 2016 11:13:22
[Mon Sep 12 14:00:42.384540 2016] [core:notice] [pid 2412:tid 404] AH00094: Command line: 'c:\\xampp\\apache\\bin\\httpd.exe -d C:/xampp/apache'
[Mon Sep 12 14:00:42.400166 2016] [mpm_winnt:notice] [pid 2412:tid 404] AH00418: Parent: Created child process 1856
[Mon Sep 12 14:00:43.181414 2016] [ssl:warn] [pid 1856:tid 404] AH01909: www.example.com:443:0 server certificate does NOT include an ID which matches the server name
[Mon Sep 12 14:00:43.400181 2016] [ssl:warn] [pid 1856:tid 404] AH01909: www.example.com:443:0 server certificate does NOT include an ID which matches the server name
PHP Warning:  PHP Startup: Unable to load dynamic library 'C:\\xampp\\php\\ext\\php_sqlite.dll' - Le module sp\xef\xbf\xbdcifi\xef\xbf\xbd est introuvable.\r\n in Unknown on line 0
[Mon Sep 12 14:00:43.493914 2016] [mpm_winnt:notice] [pid 1856:tid 404] AH00354: Child: Starting 150 worker threads.
0 votes

Bonjour

OpenSSL/1.0.2h PHP/5.6.24 configured -- resuming normal operations indique que le module mod_perl n'est pas actif. Or OCS Inventory Server a besoin de ce module pour récupérer les inventaires. Il faut donc l'installer et l'activer.

Cordialement

Frank

by (88.5k points)
Bonjour,

J'ai installé le mod_perl, mais lorsque je rajoute la ligne

LoadModule perl_module modules/mod_perl

dans le ficher httpd.conf, je ne parviens pas à redémarrer le serveur Apache.
0 votes
Quelles erreurs as-tu dans le fichier error.log? Merci de poster le contenu de ce fichier suite à l'installation du module perl.

Cordialement

Frank
by (88.5k points)
0 votes
Bonjour,

Merci de m'avoir aidé, j'ai finalement résolu le problème. Pour ceux qui auront le même problème que moi, voici ce que j'ai fait.

J'avais installé Xampp avec Apache 2.4 et php 5.5. Ce dernier est indispensable à GLPI 0.90, mais Apache 2.4 n'est apparemment pas compatible avec mod_perl sur Windows (il l'est sur les serveurs Linux). C'est en tout cas ce que j'ai lu sur de nombreux forums.

J'ai donc fait une deuxième installation de Xampp, appelée XamppOCS, avec cette fois-ci Apache 2.2 et php 5.3. J'ai créé une deuxième instance d'Apache, en lui disant d'écouter sur le port 8080.

Le but de la manoeuvre était d'avoir une instance Apache pour GLPI, et une pour OCS, ce qui a marché.

Une fois ceci réalisé, il ne me restait plus qu'à indiquer le bon port de connexion à mes agents OCS, et une fois fait, l'inventaire a commencé sans problème.

Merci en tout cas à frankb, qui m'a bien aidé à voir où se situait mon problème.

Cordialement.
by (160 points)
 
Powered by Question2Answer
...