in reply to Better use of perl print statment for Nagios

Seems like you could use "here docs" (perldoc perlop):
print autoconf <<EOD; # Host $nodename $machine_type check host alive define host{ use generic-host host_name $nodename alias $comment address $IPnumber (yadayadayada) EOD
Liz