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.

SNMP not working / ne fonctionne pas

Configuration OCS :  Debian 8.9 / OcsInventory version 2.3

J'ai un problème je n'arrive pas à remonter mon matériel (switch, imprimante...) via le SNMP. Il m'indique 0 périphériques SNMP remontés. IpDiscover est bien activé sur certain poste.

I have a problem I can not get back my hardware (switch, printer ...). It tells me 0 SNMP devices reassembled. iP DISCOVER it's ok.

LOG server :

/var/log/ocs_agent.log

[Wed Apr 10 12:00:11 2019][error] Cannot establish communication : 400 Bad Request
[Wed Apr 10 13:15:01 2019][error] Cannot establish communication : 400 Bad Request
[Wed Apr 10 13:15:01 2019][info] No previous PROLOG_FREQ found - using fallback delay(3600 seconds)
 

ocsinventory-agent --debug --logfile=/tmp/agent.log

[Thu Apr 11 11:47:32 2019][debug]  - LWP::Protocol::https loaded
[Thu Apr 11 11:47:32 2019][debug] Compress::Zlib is available.
[Thu Apr 11 11:47:32 2019][debug] Calling handlers : `prolog_writer'
[Thu Apr 11 11:47:32 2019][debug] sending XML
[Thu Apr 11 11:47:32 2019][debug] sending: <?xml version="1.0" encoding="UTF-8"?>
<REQUEST>
  <DEVICEID>OCSSERVER2019-01-02-21-21-20</DEVICEID>
  <QUERY>PROLOG</QUERY>
</REQUEST>
[Thu Apr 11 11:47:32 2019][error] Cannot establish communication : 400 Bad Request

LOG CLIENT :

C:\ProgramData\OCS Inventory NG\Agent\Ocsinventory.log

Starting OCS Inventory NG Agent on Thursday, April 11, 2019 01:52:11.
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 #403>
AGENT => Unloading communication provider
AGENT => Unloading plug-in(s)
AGENT => Execution duration: 00:00:00.

Fichier ocsinventory.ini

[OCS Inventory Agent]
ComProvider=ComHTTP.dll
Debug=0
Local=
NoSoftware=0
HKCU=0
NoTAG=0
IpDisc=
[HTTP]
Server=http://10.0.0.1/ocsreports
SSL=1
CaBundle=ca.pem
AuthRequired=0
User=
Pwd=
ProxyType=0
Proxy=
ProxyPort=0
ProxyAuthRequired=0
ProxyUser=
ProxyPwd=
[OCS Inventory Service]
PROLOG_FREQ=168
INVENTORY_ON_STARTUP=0
OLD_PROLOG_FREQ=168
TTO_WAIT=13380

Je ne sais pas si cela peut aider mais sur la configuration PC j'ai SNMP_WITCH  j'ai un point rouge et c'est noté 1 inactif

Merci pour votre aide.

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

3 Answers

+1 vote
Bonjour,

L'url indiquée dans le fichier ocsinventory.ini est incorrecte. Il faut mettre Server=http://10.0.0.1/ocsinventory et non server=http://10.0.0.1/osreports.

Est-ce que le certificat est correct?

Cordialement

Frank
by (88.5k points)
0 votes

Bonjour Franck et un grand merci pour ton retour !

Parfait la correction a été apporté à mon fichier, ocsinventory.ini

Voici le fichier OCSInventory.log dorénavant ça a l'air d'etre ok.

==============================================================================
Starting OCS Inventory NG Agent on Friday, April 12, 2019 09:48:07.
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 => Local mode activated by /LOCAL argument: No network connection
AGENT => Sending Prolog
AGENT => Prolog successfully sent
SUPPORT => No support detected, Registration key : N/A
AGENT => Inventory required
AGENT => Launching hardware and software checks
AGENT => Sending Inventory
INVENTORY => Inventory changed since last run
AGENT => Inventory successfully sent
AGENT => Unloading communication provider
AGENT => Unloading plug-in(s)
AGENT => Execution duration: 00:00:19.

Dans mes fichiers : C:\Program Files (x86)\OCS Inventory Agent\snmp.txt j'ai un  timeout zt pour le fichier snmplist.txt il me sort bien des ip + adresse mac.

Je pense effectivement que mon certificat est ok, il y a t-il une commande pour vérification.

Pour info :

J'ai modifier les deux lignes de mon fichier /etc/apache2/sites-available/default-ssl.conf avec reboot du server apache2 mon site est bien en https avec mon nom DNS

Encore un grand merci pour ton aide !

Bonjour,

L'url indiquée dans le fichier ocsinventory.ini est incorrecte. Il faut mettre Server=http://10.0.0.1/ocsinventory et non server=http://10.0.0.1/osreports.

Est-ce que le certificat est correct?

Cordialement

Frank

by (350 points)
0 votes
Up please !

Si quelqu'un peut m'aider svp :(
by (350 points)
 
Powered by Question2Answer
...