diff --git a/node/ip-poll.js b/node/ip-poll.js index 99c50d4..0e0f89c 100644 --- a/node/ip-poll.js +++ b/node/ip-poll.js @@ -11,12 +11,11 @@ var IpPoll = function(switchaddr, hostsaddr) { var redisClient = redis.createClient(); var regexp = /\(([0-9]+) hosts* up\)/; - var nmap = "nmap -n -sP -T5 --host-timeout 10ms "; +// var nmap = "nmap -n -sP -T5 --host-timeout 10ms "; + var nmap = "nmap -n -sP -T5 "; redisClient.on("connect", function () { - //redisClient.set(redisprefix + "24:77:03:a9:f3:f4","lucas"); - console.log("connected to redis"); self.emit('ready'); }); diff --git a/node/statusbot.js b/node/statusbot.js index 4bbf1d4..abd7339 100644 --- a/node/statusbot.js +++ b/node/statusbot.js @@ -42,13 +42,13 @@ var snmpMac = new SnmpMac("juni.ctdo.de", "ctdo23"); var ippoll = new IpPoll("switch2.raum.ctdo.de", "195.160.169.20-62 195.160.169.70-126"); snmpMac.on('done', function (res) { - console.log(res); +// console.log(res); simpleanswer.names = res; simpleanswer.lastchange = parseInt((new Date().getTime()) / 1000); }); ippoll.on('doneCount', function (num) { - console.log("there are " + num + " hosts up"); +// console.log("there are " + num + " hosts up"); simpleanswer.count = num; simpleanswer.lastchange = parseInt((new Date().getTime()) / 1000); @@ -56,7 +56,7 @@ ippoll.on('doneCount', function (num) { }); ippoll.on('doneState', function (state) { - console.log("room state is: " + state); +// console.log("room state is: " + state); simpleanswer.state = state; spaceanswer.state.open = state; @@ -81,7 +81,7 @@ function work() { ippoll.pollState(); } -setInterval(work, 10000); +setInterval(work, 60000); app.set('snmpMac', snmpMac); //TODO: wie kann man das schoener machen? (Modul in die Routes reintun) app.set('views', __dirname + '/views');