package App::MadEye::Plugin::Agent::Perlbal; use strict; use warnings; use IO::Socket::INET; use App::MadEye::Plugin::Agent::Base; my $req = <<'...'; GET / HTTP/1.0 Host: invalidhostname.example.com ... sub is_dead { my ($self, $host) = @_; my $conf = $self->config->{config}; my $port = $conf->{port} || 80; my $timeout = $conf->{timeout} || 10; my $sock = IO::Socket::INET->new( PeerAddr => $host, PeerPort => $port, Timeout => $timeout, ) or return "cannot open socket"; $sock->write($req); my $content = join '', <$sock>; if ($content =~ m{Server: Perlbal.+