summaryrefslogtreecommitdiffstats
diff options
context:
space:
mode:
authoreuer <root@euer.krebsco.de>2012-11-28 09:48:06 +0100
committereuer <root@euer.krebsco.de>2012-11-28 09:48:06 +0100
commitf629c9e0c216150ef8f5c868eacd10507846d766 (patch)
treec14ec730917994d1d9dcab8501fa2a87022a5346
parent50d63b50779bca78978d5ac1049604a4c6d37c69 (diff)
parent105cff1f36a13e76013309e928a2704bdea2de7e (diff)
Merge branch 'master' of github.com:krebscode/painload
-rw-r--r--retiolum/doc/highping2
-rw-r--r--retiolum/hosts/casino11
-rw-r--r--retiolum/hosts/juhulian11
-rw-r--r--retiolum/scripts/adv_graphgen/find_super14
-rw-r--r--temper/Makefile8
-rwxr-xr-xtemper/collectd-temper.sh9
6 files changed, 52 insertions, 3 deletions
diff --git a/retiolum/doc/highping b/retiolum/doc/highping
new file mode 100644
index 00000000..e3d9a47c
--- /dev/null
+++ b/retiolum/doc/highping
@@ -0,0 +1,2 @@
+in der tinc.conf darf nicht zu einem Host connectet werden der einen DNS namen benutzt.
+wenn ein nicht erreichbarer DNS name versucht wird zu erreichen pausiert tinc jedesmal alle transfers bis der DNS-Request einen Timeout hat.
diff --git a/retiolum/hosts/casino b/retiolum/hosts/casino
new file mode 100644
index 00000000..e35691c3
--- /dev/null
+++ b/retiolum/hosts/casino
@@ -0,0 +1,11 @@
+Subnet = 10.243.0.233
+Subnet = 42:3c1f:ea16:e181:7ab2:c51a:8892:7fb7/128
+
+-----BEGIN RSA PUBLIC KEY-----
+MIIBCgKCAQEAzmZ7x4HVpW8RC3ZkwmNKY/6VGlMKQbpBQtmrUzV1XFxKWZRhH3VI
+NOqlfVpTEaRTorht7R8F1aw9psDDUcg7yuQFcUdoXxBJxwbc1h0FKyZZr5kAIfpS
+ObE0rbBRRqJVAWgztpQAalWC95D73y/+tpHnQ+LRFq9IWeX5+QobaSym1oG4Y0Jz
+STSbw2ksjH8CuWHS5TjZr50Nyx6cH99HABDnadxhLBtQriJPSYRYdWyp7tYrW3jd
+As28mxkyFj0sFV3IJ/bYfZD9KSGg1KjQu+c73xKOBUhNtSHFjUzN5myYGd/nWCw8
+0PUReLrWC1ZHYPzqiwelTHcNJ3UcojpO9wIDAQAB
+-----END RSA PUBLIC KEY-----
diff --git a/retiolum/hosts/juhulian b/retiolum/hosts/juhulian
new file mode 100644
index 00000000..eca4e873
--- /dev/null
+++ b/retiolum/hosts/juhulian
@@ -0,0 +1,11 @@
+Subnet = 10.243.0.38
+Subnet = 42:449f:b00a:e973:514c:3e9f:97ed:aac2/128
+
+-----BEGIN RSA PUBLIC KEY-----
+MIIBCgKCAQEAnNyOsNItOzNQndheZ3ppOMWvIOuO1wgLXArINS1ORcgIAJmLpqDI
+whsZFCVifwAXsdeBJyyZOPZrc2PQ4F3KB9ByX6PQ9jqAhun1aE9SDDqp+woOrTlP
+BtJ/8zAmRhrfak61TxpeTndLk95xOLaCwvS2P4SJLIcyutTbbFdBCqpu7cFUGOOP
+qCKLX7/mv2L+GNmQAnWZ5HwXQzBS6gNaNIcQ8mPCUAIZgRU2T83x/tnyH1RlATK2
+lYUWRM0ie+dRMhiDcwmmZrwYl8wzyvuBPEr/p8ZBM2tua8GlQzJUJl44AiAcx3w9
+0EB5MIRL5Qb0yBvXD0yR+bDizqvhd40LvQIDAQAB
+-----END RSA PUBLIC KEY-----
diff --git a/retiolum/scripts/adv_graphgen/find_super b/retiolum/scripts/adv_graphgen/find_super
new file mode 100644
index 00000000..c89a94fb
--- /dev/null
+++ b/retiolum/scripts/adv_graphgen/find_super
@@ -0,0 +1,14 @@
+#!/bin/sh
+cd /etc/tinc/retiolum/hosts
+ls -1 . | while read fname;
+do
+ for i in `sed -n 's/Address\s*=\s*\(.*\)/\1/p' $fname`;do
+ if nc -zw 5 $i 655 2>/dev/null; then
+ echo "$fname - $i reachable"
+ #else
+ #echo -n
+ #echo "$fname - $i unreachable"
+
+ fi
+ done
+done
diff --git a/temper/Makefile b/temper/Makefile
index 79dc3216..80c0206f 100644
--- a/temper/Makefile
+++ b/temper/Makefile
@@ -1,15 +1,17 @@
all: infest
-infest: temper
+infest: temper rules-install
CFLAGS = -O2 -Wall
-temper: temper.c rules-install
+temper: temper.c
${CC} -DUNIT_TEST -o $@ $^ -lusb
chmod +s temper
cp -a temper /usr/bin
clean:
rm -f temper *.o
-rules-install: # must be superuser to do this
+
+rules-install: /etc/udev/rules.d/99-tempsensor.rules
+/etc/udev/rules.d/99-tempsensor.rules:
cp 99-tempsensor.rules /etc/udev/rules.d
debian-prereq:
apt-get install libusb-dev
diff --git a/temper/collectd-temper.sh b/temper/collectd-temper.sh
new file mode 100755
index 00000000..f66e9acc
--- /dev/null
+++ b/temper/collectd-temper.sh
@@ -0,0 +1,9 @@
+HOSTNAME="${COLLECTD_HOSTNAME:-localhost}"
+INTERVAL="${COLLECTD_INTERVAL:-30}"
+TEMPERNAME="${TEMPERNAME:-external}"
+TEMPERBIN="${TEMPERBIN:-/krebs/temper/temper}"
+#while sleep "$INTERVAL"; do
+ VALUE=`$TEMPERBIN`
+ echo "PUTVAL \"$HOSTNAME/sensors-temper/temperature-$TEMPERNAME\" N:$VALUE" #interval=$INTERVAL
+ logger "PUTVAL \"$HOSTNAME/sensors-temper/temperature-$TEMPERNAME\" N:$VALUE" #interval=$INTERVAL
+#done