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.

Cannot establish communication : 302 Found

I installed agent on CentOS 7.3 server. It doesn't show any errors, but when cron job runs, I see following error in agent logs and also in GUI of CS server, the computer doesn't show up.

[Thu 28 Jun 2018 11:45:17 AM +04] Running ocsinventory-agent --wait 100 --lazy --nolocal --server=xxxxx.xxxx.com
[Thu Jun 28 11:45:17 2018][info] Going to sleep for 1 second(s)
[Thu Jun 28 11:45:19 2018][error] Cannot establish communication : 302 Found
[Thu Jun 28 11:45:19 2018][info] No previous PROLOG_FREQ found - using fallback delay(3600 seconds)
[Thu 28 Jun 2018 11:45:19 AM +04] End of cron job (/sbin:/bin:/usr/sbin:/usr/bin)

Commands I used to install agent is below:

# yum install ocsinventory-agent
# ocsinventory-agent --server=servername.domain.com

This is a new setup and this server I am trying to install is the first computer to be added. I have no other computers yet in OCS server. OCS server is also CentOS 7.3.
in OCS Inventory NG agent for Unix by (310 points)
retagged by

6 Answers

+1 vote

Hi,

Your command (# ocsinventory-agent --server=servername.domain.com) is incomplete. .You must use # ocsinventory-agent --server=http://servername.domain.com/ocsinventory

Regards

Frank

by (88.5k points)
0 votes
still the error exist.

[Thu Jun 28 15:44:01 2018][debug] sending: <?xml version="1.0" encoding="UTF-8"?>
<REQUEST>
  <DEVICEID>xxxxxx-2017-11-06-11-59-10</DEVICEID>
  <QUERY>PROLOG</QUERY>
</REQUEST>
[Thu Jun 28 15:44:01 2018][error] Cannot establish communication : 302 Found
[Thu Jun 28 15:44:01 2018][info] No previous PROLOG_FREQ found - using fallback delay(3600 seconds)
[Thu 28 Jun 2018 03:44:01 PM +04] End of cron job (/sbin:/bin:/usr/sbin:/usr/bin)
by (310 points)
edited by
0 votes
I suggest You should try to add any other device (even android phone) to OCS inventory if it work's you have to work with your agent PC if not check OCS server and routers configuration port forwarding etc...
by (2.9k points)
0 votes
I tried agent installation on Redhat 6, Debian 8 servers and still error is same. There is no port or IP restriction in OCSNG server.

Anything else I need to check to troubleshoot the issue?
by (310 points)
0 votes
Hi,

Do you have enabled the apache redirection on the OCS server?

Regards

Frank
by (88.5k points)
0 votes
Thanks for the hint. But still issue is there with a different error.

Cannot establish communication : 400 Bad Request

OCSserver and agents are 2.4.1 version.
by (310 points)
 
Powered by Question2Answer
...