Even if I type absolute path in browser
I get 404 error I'm 100% sure the directory exist.
path on server = home/mydomain/
#!/usr/bin/perl
#
print "Content-type: text/html\n\n";
print "Hello World\n";
I ran >perl -c test.cgi
syntax fine
Then >perl - w test.cgi
Hello World
command line works fine returns- Hello World.
/cgi-bin>#perl test.cgi
But running I keep getting internal error 505
Error_log
[error] (2) No such file or directory: exec of /home/mydomain/[error] Premature end of script headers
## httpd.conf - configuration for the Apache web server
#enable cgi-scripts
AddHandler cgi-script .cgi .pl
ScriptAlias /cgi-bin/ "/home/mydomain/cgi-bin/"
<Directory "/home/mydomain/cgi-bin">
Options None
AllowOverride None
Order allow,deny
Allow from from all
</Directory>
# Virtual host mydomain
<VirtualHost x.x.x.x>
DocumentRoot /home/mydomain/www/
ServerName ScriptAlias /cgi-bin/ "/home/mydomain/cgi-bin/"
ServerSignature email
</VirtualHost>
Do I need to add something else to httpd file?
I get 404 error I'm 100% sure the directory exist.
path on server = home/mydomain/
#!/usr/bin/perl
#
print "Content-type: text/html\n\n";
print "Hello World\n";
I ran >perl -c test.cgi
syntax fine
Then >perl - w test.cgi
Hello World
command line works fine returns- Hello World.
/cgi-bin>#perl test.cgi
But running I keep getting internal error 505
Error_log
[error] (2) No such file or directory: exec of /home/mydomain/[error] Premature end of script headers
## httpd.conf - configuration for the Apache web server
#enable cgi-scripts
AddHandler cgi-script .cgi .pl
ScriptAlias /cgi-bin/ "/home/mydomain/cgi-bin/"
<Directory "/home/mydomain/cgi-bin">
Options None
AllowOverride None
Order allow,deny
Allow from from all
</Directory>
# Virtual host mydomain
<VirtualHost x.x.x.x>
DocumentRoot /home/mydomain/www/
ServerName ScriptAlias /cgi-bin/ "/home/mydomain/cgi-bin/"
ServerSignature email
</VirtualHost>
Do I need to add something else to httpd file?