If you are running this on Redhat 8/9, you could be running into the
infamous utf-8 LANG problem. If the $LANG environment variable
has a .utf8 on the end, then Perl 5.8.0 treats any input as
being UTF8 encoded, even if it isn't.
If this is the case, include a new setting for LANG in the
script that starts up apache
eg if $LANG is en_US.utf8, then add LANG=en_US to the script.