httpd-users mailing list archives

Site index · List index
Message view « Date » · « Thread »
Top « Date » · « Thread »
From Joshua Slive <>
Subject Re: [users@httpd] Default Index File as CGI script
Date Thu, 11 Sep 2003 19:37:04 GMT

On Thu, 11 Sep 2003, Brian Leader wrote:

> OK, some progress I think.
> I changed the permission of the fake404.cgi file to 755.  It still gives
> the same error in the browser, but now in the error log I get:
> [error] (8)Exec format error: exec of /var/www/cgi-bin/fake404.cgi failed

Don't bother running it from apache until it works from the command line.

> When I run it from the command line I get:
> : No such file or directory
> : command not found
> Content-Type: text/html
> Status: 404 Not Found

> Perhaps it is related to the first line of the file?
> !/bin/sh

Yes.  It would be very unusual to have a unix system without a functioning
/bin/sh, but it appears that you might have one.  What happens when you
simply type "/bin/sh"?

In any case, the script will probably run if you simply remove the first


The official User-To-User support forum of the Apache HTTP Server Project.
See <URL:> for more info.
To unsubscribe, e-mail:
   "   from the digest:
For additional commands, e-mail:

View raw message