Cacti (home)ForumsDocumentation
Cacti: offical forums and support
It is currently Tue Jun 18, 2019 11:57 am

All times are UTC - 5 hours




Post new topic Reply to topic  [ 2 posts ] 
Author Message
 Post subject: Automation - Network addresses calculation
PostPosted: Mon Apr 29, 2019 3:53 pm 
Offline

Joined: Fri Mar 08, 2019 11:39 am
Posts: 8
Hello,

The IP addresses calculated of hosts to be scanned are (I believe) wrong when the input is something different from xx.xx.xx.0/xx

for example:

Network: 172.21.66.192/28
IPs scanned: 172.21.66.192 - 172.21.66.206
While:
Code:
ipcalc 172.21.66.192/28             
Address:   172.21.66.192        10101100.00010101.01000010.1100 0000
Netmask:   255.255.255.240 = 28 11111111.11111111.11111111.1111 0000
Wildcard:  0.0.0.15             00000000.00000000.00000000.0000 1111
=>
Network:   172.21.66.192/28     10101100.00010101.01000010.1100 0000
HostMin:   172.21.66.193        10101100.00010101.01000010.1100 0001
HostMax:   172.21.66.206        10101100.00010101.01000010.1100 1110
Broadcast: 172.21.66.207        10101100.00010101.01000010.1100 1111


Quote:
2019-04-29 20:42:26 - AUTOM8 [PID: 26656] Device: 172.21.66.194, Checking DNS: Not found, Status: Already in Cacti
2019-04-29 20:42:20 - AUTOM8 [PID: 26652] Network 172.21.66.192/28 Thread 1 Finished, 3 IPs Scanned, 1 IPs Responded to Ping, 0 Responded to SNMP, 0 Device Added, 0 Graphs Added to Cacti
2019-04-29 20:42:20 - AUTOM8 [PID: 26652] Device: 172.21.66.192, Checking DNS: Not found, Status: Not in Cacti, Ping: Responded, SNMP: XX1, Skipping sysName 'XX1' already in Cacti!
2019-04-29 20:42:20 - AUTOM8 [PID: 26658] Network 172.21.66.192/28 Thread 4 Finished, 3 IPs Scanned, 1 IPs Responded to Ping, 0 Responded to SNMP, 0 Device Added, 0 Graphs Added to Cacti
2019-04-29 20:42:20 - AUTOM8 [PID: 26658] Device: 172.21.66.193, Checking DNS: Not found, Status: Not in Cacti, Ping: Responded, SNMP: XX2' Skipping sysName 'XX2' already in Cacti!
2019-04-29 20:42:20 - AUTOM8 [PID: 26654] Network 172.21.66.192/28 Thread 2 Finished, 3 IPs Scanned, 0 IPs Responded to Ping, 0 Responded to SNMP, 0 Device Added, 0 Graphs Added to Cacti
2019-04-29 20:42:20 - AUTOM8 [PID: 26654] Device: 172.21.66.195, Checking DNS: Not found, Status: Not in Cacti, Ping: No response
2019-04-29 20:42:19 - AUTOM8 [PID: 26660] Network 172.21.66.192/28 Thread 5 Finished, 2 IPs Scanned, 0 IPs Responded to Ping, 0 Responded to SNMP, 0 Device Added, 0 Graphs Added to Cacti
2019-04-29 20:42:19 - AUTOM8 [PID: 26660] Device: 172.21.66.196, Checking DNS: Not found, Status: Not in Cacti, Ping: No response
2019-04-29 20:42:19 - AUTOM8 [PID: 26652] Device: 172.21.66.197, Checking DNS: Not found, Status: Not in Cacti, Ping: No response
2019-04-29 20:42:19 - AUTOM8 [PID: 26658] Device: 172.21.66.198, Checking DNS: Not found, Status: Not in Cacti, Ping: No response
2019-04-29 20:42:19 - AUTOM8 [PID: 26656] Device: 172.21.66.199, Checking DNS: Not found, Status: Not in Cacti, Ping: No response
2019-04-29 20:42:19 - AUTOM8 [PID: 26654] Device: 172.21.66.200, Checking DNS: Not found, Status: Not in Cacti, Ping: No response
2019-04-29 20:42:18 - AUTOM8 [PID: 26660] Device: 172.21.66.201, Checking DNS: Not found, Status: Not in Cacti, Ping: No response
2019-04-29 20:42:18 - AUTOM8 [PID: 26652] Device: 172.21.66.202, Checking DNS: Not found, Status: Not in Cacti, Ping: No response
2019-04-29 20:42:18 - AUTOM8 [PID: 26658] Device: 172.21.66.203, Checking DNS: Not found, Status: Not in Cacti, Ping: No response
2019-04-29 20:42:18 - AUTOM8 [PID: 26656] Device: 172.21.66.204, Checking DNS: Not found, Status: Not in Cacti, Ping: No response
2019-04-29 20:42:18 - AUTOM8 [PID: 26654] Device: 172.21.66.205, Checking DNS: Not found, Status: Not in Cacti, Ping: No response


But if i do:

Network: 172.20.84.0/28
IPs scanned: 172.20.84.1 - 172.20.84.14
This is correct.

OS: Debian 9
Cacti: 1.2.2
MariaDB: 10.1
PHP: 7.0

Any help would be appreciated.
Thanks,
IGN.


Top
 Profile  
 
 Post subject: Re: Automation - Network addresses calculation
PostPosted: Tue Apr 30, 2019 3:31 am 
Offline
Cacti Guru User

Joined: Sun Aug 27, 2017 12:05 am
Posts: 2499
This is a bug with the automation code, could you open that as an issue on the GitHub repo?

_________________
Official Cacti Developer

Cacti Resources:
Cacti Website (including releases)
Cacti Issues
Cacti Development Releases
Cacti Development Documentation

My resources:
How to submit Pull Requests
Development Wiki and How To's
Updated NetSNMP Memory template for Cacti 1.x
Cisco SFP template for Cacti 0.8.8


Top
 Profile  
 
Display posts from previous:  Sort by  
Post new topic Reply to topic  [ 2 posts ] 

All times are UTC - 5 hours


Who is online

Users browsing this forum: No registered users and 11 guests


You cannot post new topics in this forum
You cannot reply to topics in this forum
You cannot edit your posts in this forum
You cannot delete your posts in this forum
You cannot post attachments in this forum

Search for:
Jump to:  

Protected by Anti-Spam ACP Powered by phpBB © 2000, 2002, 2005, 2007 phpBB Group