--- check_portaudit.orig	2007-06-07 11:54:21.000000000 +0400
+++ check_portaudit	2008-08-19 21:23:03.000000000 +0400
@@ -56,6 +56,7 @@
 my %ERRORS=('DEPENDENT'=>4,'UNKNOWN'=>3,'OK'=>0,'WARNING'=>1,'CRITICAL'=>2);
 my $state="UNKNOWN";
 my $msg="FAILURE";
+my $perfdata="";
 
 #################LOCATION OF IMPORTANT FILES#######################
 my $portauditloc="/usr/local/sbin/portaudit";
@@ -192,6 +193,7 @@
 }
 
 ### take this message to Nagios
-$msg = sprintf "%s : %s %s %s\n", $command, $packcount, $pkgtype, $msglist;
-print $state, " ", $msg;
+$msg = sprintf "%s : %s %s %s", $command, $packcount, $pkgtype, $msglist;
+$perfdata = sprintf "%s=%d;1;;0;", $pkgtype, $packcount;
+print $state, " ", $msg, "|", $perfdata,"\n";
 exit ($ERRORS{$state});
