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: no automatic election. Works only if manually forced #356
Comments
Ideas, anyone? |
Same thing happens to me with default settings. |
Did you managet to make it work? Cause I tried all possible settings in the admin interface with no luck. |
No, I still can't get it to work. |
A silly solution (for me) is altering So I've copied this file:
At line 199 of print "\n\n##################\n";
print "PROCESSING SUBNETS \n";
print "##################\n\n";
for(@subnet){
print "Processing $_->[1] (".$_->[0]."/".$_->[3]."). ".(keys(%subnet)-$i)." networks left.\n";
open OUT, ">$path/ipd/".$_->[0].".ipd" or die $!;
unless(flock(OUT, LOCK_EX|LOCK_NB)){
if($xml){
print "<ERROR><MESSAGE>345</MESSAGE></ERROR>";
exit(0);
}else{
die "An other analyse is in progress\n";
}
}
print("./ipdiscover-util.pl -net=".$_->[0]." -network=".$_->[0]."/".((()=$_->[3] =~ /255/g)*8)." -a -scantype=nmap > $path/ipd/'".$_->[0].".ipd'\n");
system("./ipdiscover-util.pl -net=".$_->[0]." -network=".$_->[0]."/".((()=$_->[3] =~ /255/g)*8)." -a -scantype=nmap > $path/ipd/'".$_->[0].".ipd'");
$i++;
} Result of changes with
After I've add this line to my
(Friday at 2:00) This changes run IP Discovery and persists changes to database. |
I changed the lines you mentioned, but the error below appears Can't use string ("172.18.10.0") as an ARRAY ref while "strict refs" in use at ipdiscover-util-cron.pl line 202. |
Hi @iuri-iurcenco , This bug has been fixed with PR #415. Best regards, |
General informations
Operating system : Ubuntu 20.04.3 LTS
Server informations
Perl version : v5.30.0
Mysql / Mariadb / Percona version : Ubuntu 20.04 version 10.3.31-MariaDB-0ubuntu0.20.04.1
OCS Inventory informations
Ocs server version : 2.9.1
Problem's description
ipdiscover: no automatic election. Works only if manually forced
Srver runs on Ubuntu 20.04.3 LTS
Ocs server Linux/Unix Server 2.9.1
Windows Agent 2.9.0.0 (64 bits)
Already tried everething possible.
my settings:
IPDISCOVER
Max number of computers per gateway retrieving IP on the network
ON
2
computers
IPDISCOVER_BETTER_THRESHOLD
Specify the minimal difference to replace an ipdiscover agent
1
day(s)
(Must be greater than or equal to 1)
IPDISCOVER_LATENCY
Ipdiscover latency
100
milisecond(s)
(Must be greater than or equal to 10)
IPDISCOVER_MAX_ALIVE
Maximum number of day before an ipdiscover computer is replaced
1
day(s)
(Must be greater than or equal to 1)
IPDISCOVER_NO_POSTPONE
Disable the time before a first election (not recommended)
ON
IPDISCOVER_USE_GROUPS
Enable groups for ipdiscover (for example, you might want to prevent some groups to be ipdiscover agents)
OFF
IPDISCOVER_LINK_TAG_NETWORK
Link Ipdiscover network to computer TAG
Logout / Login after updating this configuration
OFF
IPDISCOVER_PURGE_OLD
Purge old IPDiscover data
OFF
IPDISCOVER_PURGE_VALIDITY_TIME
Validity time (in days) of an IPDiscover data
30
day(s)
(Must be greater than or equal to 1)
It used to work with my old cenots server with ocs 2.2Rc..and 2.4 win 32 client if I am not mistaken.
I don't know if it's related or not. I have also an apache warning: apachectl[203268]: ocsinventory-server: Bad setting.
IPDISCOVER_LINK_TAG_NETWORK
is not set. Default:0
Ideas? Thanks!
The text was updated successfully, but these errors were encountered: