Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

IpDiscover does not find machines on the network #449

Open
cairoapcampos opened this issue Jan 12, 2024 · 4 comments
Open

IpDiscover does not find machines on the network #449

cairoapcampos opened this issue Jan 12, 2024 · 4 comments

Comments

@cairoapcampos
Copy link

cairoapcampos commented Jan 12, 2024

General informations

Operating system : Linux Debian 12

Server informations

Perl version : 5.36.0
Mariadb: 10.11.4

OCS Inventory informations

Ocs server version : 2.12.1

Problem's description

I create the subnet by following the steps below in the web interface:

Manage -> Network scan -> Administer subnet -> ADD.

I run the following command on the VM that has the OCS Server and the OCS Agent:

perl ipdiscover-util.pl -network=192.168.2.0/24 -scantype=nmap -h=localhost  -d=ocsdb -u=ocsuser -p=ocspass

Command output:

output

I noticed that without executing the command no machines are listed. From what I saw in the documentation, some machines that have an agent are elected and scan the network. In my tests, no machine was automatically found by IpDiscover.

I'm using virtualbox to test OCS. The VM with IP 192.168.2.2 is the OCS Server. The gateway 192.168.2.1 does not exist. The machines are on the same network. Could this be the problem? Can you help me?

@cairoapcampos
Copy link
Author

Additional screens as per previous example:

out1
out2
out3

@gillesdubois
Copy link
Member

Hi @cairoapcampos

First, I see you are testing OCS in a virtual / test environement, that might be the reason why you don't have automatic election. Possible reasons are multiple but if you have a infrastructure with agent you trigger from time to time to test, they won't be elected as IPDiscover agent.

OCS need the agent to come regularly to be elected, that's what we call the fidelity score. My first question abou the non election would be :

  • Is IPDiscover enabled in the configuration ?
  • Are your test agent running regularly and not VM that are basically down most of the time ?
  • Are you running the agent with the service (at least for windows agent)
  • You can also force a agent to scan a network in the machine detail > configuration > network scans, did you try that ?

Concerning the script and the output in the webconsole there is two tabs :

  • Inventoried is meant to show computers that have an agent
  • Non Inventory is meant to show computers that don't have an agent

The main issue you encounter is that the 192.168.2.2 machine is reconciliated with its agent entry. This behavior can be normal as the IPDiscover script is more intended to be used in network where there is no agent (network full of net devices for example).

Regards,
Gilles DUBOIS.

@cairoapcampos
Copy link
Author

I recreated the virtualized environment. I installed the server and agent on the Debian VM.

Also create two Windows machines. One is using the agent and the other does not have it.

I configured the bridge network type on the VMs, this way they can use IPs from a real network. Now they have a gateway.

For this new test I did not run the ipdiscover-util.pl script. Now just wait for the nodes to be elected so that network devices are found automatically?

One question I have is knowing the difference between the "Non-Inventored" and "IpDiscover" columns on the second screen. What is the difference between these columns?

Below are some images of the current test environment.

Screen 1:

tela1

Screen 2:

tela2

Screen 3:

tela3

@Lea9250
Copy link
Contributor

Lea9250 commented Jan 29, 2024

Hi @cairoapcampos ,

"Non-inventoried" is pretty much self-explanatory, these are devices that do not have an OCS agent installed. "IpDiscover" refers to Ipdiscover elected devices, i.e. agent's performing the ipdisover scan.

Regards,
Léa

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

No branches or pull requests

3 participants