]> git.llucax.com Git - z.facultad/75.43/tp2.git/commitdiff
Scriptería para simplificar las cosas.
authorLeandro Lucarella <llucax@gmail.com>
Wed, 13 Jul 2005 04:00:27 +0000 (04:00 +0000)
committerLeandro Lucarella <llucax@gmail.com>
Wed, 13 Jul 2005 04:00:27 +0000 (04:00 +0000)
pingall [new file with mode: 0755]
propagate [new file with mode: 0755]
tracerouteall [new file with mode: 0755]

diff --git a/pingall b/pingall
new file mode 100755 (executable)
index 0000000..6186a48
--- /dev/null
+++ b/pingall
@@ -0,0 +1,14 @@
+#!/bin/sh
+hosts="www alf3 friends65 csi193 action1 action2 brigada34 brigada33 seinfeld2 trfs194 hosta hostb hostc trfs193 swat37 swat38 heman130 dukes196 dukes193 dukes194 simpsons2 simpsons1 simpsons129 heman130 host hostt telnet seinfeld1 hosf hostf ftp"
+
+for host in $hosts
+do
+       echo -n "Pingueando $host: "
+       res=`ping -c1 $host | grep from`
+       if [ -z "$res" ]
+       then
+               echo 'ERROR!'
+       else
+               echo "$res"
+       fi
+done
diff --git a/propagate b/propagate
new file mode 100755 (executable)
index 0000000..9bce94c
--- /dev/null
+++ b/propagate
@@ -0,0 +1,15 @@
+#!/bin/sh
+hosts="alf3 action2 seinfeld2 hosta hostb hostc telnet trfs193 heman130 simpsons2 simpsons1"
+
+if [ $# -gt 0 ]
+then
+       hosts="$@"
+fi
+
+for host in $hosts
+do
+       echo "Copiando a $host:"
+#      ssh $host 'mkdir -p grupo13'
+       scp * $host:grupo13
+       echo
+done
diff --git a/tracerouteall b/tracerouteall
new file mode 100755 (executable)
index 0000000..de710e5
--- /dev/null
@@ -0,0 +1,9 @@
+#!/bin/sh
+hosts="www alf3 friends65 csi193 action1 action2 brigada34 brigada33 seinfeld2 trfs194 hosta hostb hostc trfs193 swat37 swat38 heman130 dukes196 dukes193 dukes194 simpsons2 simpsons1 simpsons129 heman130 host hostt telnet seinfeld1 hosf hostf ftp"
+
+for host in $hosts
+do
+       echo -n "Tracerouteando $host: "
+       traceroute $host
+       echo
+done