Results 1 to 2 of 2
Perl commands in an input file to cgi script Forum: CGI Perl ForumReplies: 0
Unix command output displayed 0 in browser Forum: CGI Perl ForumReplies: 0
Running shell commands from Perl Forum: CGI Perl ForumReplies: 1
Need a reliable, full featured unix hosting? Forum: Web Hosting ForumReplies: 0
Cheap Unix Hosting Forum: Web Hosting ForumReplies: 6
05-07-2007, 04:09 AM #1
How to use UNIX commands inside CGI script
I want to establish a SSH connection between one unix box to another. I have included the SSH command inside the cgi script. When i run this script through browser the error "sh: ssh: not found " is being displayed in the browser but the same script works fine when i run in the command prompt with "perl" keyword. Does the Unix command "SSH" given inside cgi script require any special format of representation other than back ticks "`" and system(" ") ? Please let me know if there is any other way to solve this problem!
Thanks & Regards,
05-25-2007, 02:47 PM #2
Re: How to use UNIX commands inside CGI script
Could the problem be related to the user running the script? Apache starts as root on my box and then changes to nobody (I believe). There are some things that just will not run as nobody.