From 2bcd6c35b01e81fc7dde8f73f57f56faa38b0399 Mon Sep 17 00:00:00 2001 From: Patrick Neumann Date: Mon, 18 Jun 2018 10:02:55 +0200 Subject: [PATCH] just ping another machine --- perl/ping.pl | 13 +++++++++++++ 1 file changed, 13 insertions(+) create mode 100755 perl/ping.pl diff --git a/perl/ping.pl b/perl/ping.pl new file mode 100755 index 0000000..ae8807c --- /dev/null +++ b/perl/ping.pl @@ -0,0 +1,13 @@ +#!/usr/bin/perl + +use warnings; +use strict; +use Net::Ping; + +while ( 0 == 0 ) { + my $host = "10.0.0.1"; + my $p = Net::Ping->new(); + system( "/usr/local/bin/truecrypt --text --dismount --force > /dev/null 2>&1" ) if ( ! $p->ping( $host ) ); + $p->close(); + sleep(1); +}