OpenSpace has asked for the wisdom of the Perl Monks concerning the following question:
Hi
I have installed perl 5.20.3 using perlbrew on a Centos 7 machine. The new version of Perl sits in a user account at /home/grunt103/perl5/perlbrew/perls/perl-5.20.3/bin/perl
I can run a hello world script in the Apache cgi-bin (./var/www/cgi-bin/hello_brew.pl) from the command line without any issues. The version command $^X in the script shows it is using perl 5.20.3
I can also run a hello world script from the command line using the default instal at /usr/bin/perl
However if I try to run the scripts through the browser (271.0.0.1/cgi-bin/) the script using the default instal works fine, but the script using the 5.20.3 instal gives a server 500 error and the following entries in the apache error log;
[error] [client 127.0.0.1] (13) Permission denied: exec of '/var/www/c +gi-bin/perl_brew.pl' failed [error] [client 127.0.0.1] Premature end of script headers:
I get the same result for both root user and the grunt103 user.
I have tried issuing the command 'perlbrew use perl-5.20.3' before running the script but to no avail.
I have disabled selinux but this has made no difference.
I have tried a variety of permissions, owners, groups, setuid and setgid settings but none have worked.
Can any body advise on how I might gain access to the new perl version via localhost?
Thanks
|
|---|
| Replies are listed 'Best First'. | |
|---|---|
|
Re: localhost cannot access new perl version
by hippo (Archbishop) on Jun 13, 2016 at 12:54 UTC | |
by OpenSpace (Novice) on Jun 13, 2016 at 13:31 UTC |