You are viewing a plain text version of this content. The canonical link for it is here.
Posted to modperl@perl.apache.org by Doug MacEachern <do...@covalent.net> on 2001/06/14 19:04:23 UTC

Re: /dev/null problems

On 28 Mar 2001, Matthew Kennedy wrote:

> Hello,
> 
> >From the mod_perl guide:
> 
>   syntax error at /dev/null line 1, near "line arguments:"
>   Execution of /dev/null aborted due to compilation errors.
>   parse: Undefined error: 0
>   There is a chance that your /dev/null device is broken. Try:
>   % sudo echo > /dev/null
> 
> This is exactly the problem I have been getting when starting Apache
> mod_perl, however the suggested fix does not work for me. We're on a
> HPUX 11 machine. Is there another way to solve this problem? As I
> understand it, if /dev/null is being used as the $0 argument to the
> handler, perhaps I could somehow explicitly set it to another (empty)
> file? How would I go about that?

you can use this patch.  -e0 used to be the default, but caused some
problems related to suexec or something.

--- src/modules/perl/mod_perl.c~        Wed Jun 13 22:17:51 2001
+++ src/modules/perl/mod_perl.c Thu Jun 14 10:02:15 2001
@@ -670,7 +670,7 @@
 #ifdef WIN32
     argv[argc++] = "nul";
 #else
-    argv[argc++] = "/dev/null";
+    argv[argc++] = "-e0";
 #endif
 
     MP_TRACE_g(fprintf(stderr, "perl_parse args: "));