aboutsummaryrefslogtreecommitdiffstats
path: root/collectors/ping.pl
diff options
context:
space:
mode:
authorOle Mathias Aa. Heggem <msbone1995@gmail.com>2018-03-21 13:27:46 +0100
committerGitHub <noreply@github.com>2018-03-21 13:27:46 +0100
commit2b3beb9f93fc6486169e47f96995a97dd64baf2a (patch)
tree7151c023924254d863387f484829b503759359ea /collectors/ping.pl
parent8f1eeeabe7b33d224ed9a8e19cc16825c144a0f6 (diff)
parent5abf053bac220b49539104bfa63805fd0829ca45 (diff)
Merge branch 'master' into network-firstclass
Diffstat (limited to 'collectors/ping.pl')
-rwxr-xr-xcollectors/ping.pl2
1 files changed, 1 insertions, 1 deletions
diff --git a/collectors/ping.pl b/collectors/ping.pl
index 952932a..82c5c42 100755
--- a/collectors/ping.pl
+++ b/collectors/ping.pl
@@ -18,7 +18,7 @@ $dbh->{RaiseError} = 1;
my $influx = nms::influx_connect();
-my $q = $dbh->prepare("SELECT switch,sysname,host(mgmt_v4_addr) as ip,host(mgmt_v6_addr) as secondary_ip FROM switches WHERE mgmt_v4_addr is not null or mgmt_v6_addr is not null ORDER BY random();");
+my $q = $dbh->prepare("SELECT switch,sysname,host(mgmt_v4_addr) as ip,host(mgmt_v6_addr) as secondary_ip FROM switches WHERE switches.deleted = false and (mgmt_v4_addr is not null or mgmt_v6_addr is not null) ORDER BY random();");
my $lq = $dbh->prepare("SELECT linknet,addr1,addr2 FROM linknets WHERE addr1 is not null and addr2 is not null;");
my $last = time();