RRDtool graphs errors in notification mails

The strange thing is that the error message not comes directly from the notification script itself.
It is possible that this is a problem with your PHP version. The mail script generates an system call for PHP to fetch the graph from inside PNP4Nagios.
Is your PNP4Nagios front end working without errors?