-----Original Message-----
From: Trevor Joerges [mailto:[EMAIL PROTECTED]]
Sent: Tuesday, January 02, 2001 12:22 PM
To: Schiza, Apostolia (ISS Atlanta); 'Ron Grabowski'; perl-win32-web@listserv. ActiveState. com (E-mail)
Subject: RE: problem running cli program from perl cgi script..I'd suggest using single quotes around the $get_events string or if you need variable interpolation of "machine1" then change the system call to something like:
@args = ("get_events.exe","--sensor machine1","--save event.txt");
system(@args) == 0 or die "system @args failed: $?";Just off the top of my head. I did not debug your code. The above code is much more reliable when executing system commands. You might also have to fully qualify the path to "get_events.exe" if it is not in the system path.
Trevor J. Joerges
http://members.home.net/tjoerges
________________________________
$_=q;KvtuyboopuifeyQQfeemyibdlfee;;
y.e.s. ;y+B-x+A-w+s; ;y;y; ;;print;;
________________________________
-----Original Message-----
From: Schiza, Apostolia (ISS Atlanta) [mailto:[EMAIL PROTECTED]]
Sent: January 2, 2001 11:52 AM
To: 'Ron Grabowski'; perl-win32-web@listserv. ActiveState. com (E-mail)
Subject: RE: problem running cli program from perl cgi script..
Ok this is the code... it's only couple of lines calling the command line
program...#!/usr/bin/perl -w
my $get_events = "get_events.exe --sensor machine1 --save
event.txt";
system($get_events);
print "This is the system result $?";
When I run the script from command line the value I get from the system call
is 0, which means that get_events executed fine.
Nothing happens though when I run the script through cgi... it just hungs
there... on the task manager i see get_events.exe running...Thanks again!
-Lia-
-----Original Message-----
From: Ron Grabowski [mailto:[EMAIL PROTECTED]]
Sent: Tuesday, January 02, 2001 11:08 AM
To: perl-win32-web@listserv. ActiveState. com (E-mail)
Subject: Re: problem running cli program from perl cgi script..
> Any ideas why this is happening? Is it a permission problem?
Its hard to tell without some source code. What does $! say? Are you
checking the return status of the system call?_______________________________________________
Perl-Win32-Web mailing list
[EMAIL PROTECTED]
http://listserv.ActiveState.com/mailman/listinfo/perl-win32-web
_______________________________________________
Perl-Win32-Web mailing list
[EMAIL PROTECTED]
http://listserv.ActiveState.com/mailman/listinfo/perl-win32-web
RE: problem running cli program from perl cgi script..
Schiza, Apostolia (ISS Atlanta) Tue, 02 Jan 2001 10:10:43 -0800
Title: RE: problem running cli program from perl cgi script..
Unfortunately the script still acts
funny!
It
executes fine from command line, but when I pull it on the web browser it just
hungs there...
the
task manager shows perl.exe, cmd.exe and get_events.exe running till who knows
when... I have to kill them to make them stop... It does create the event.txt
file but it is empty.
If
you guys have any more ideas on this I would really really appreciate
it...
Thank you
-Lia-
- problem running cli program from perl cgi ... Schiza, Apostolia (ISS Atlanta)
- Re: problem running cli program from ... Ron Grabowski
- RE: problem running cli program from ... Schiza, Apostolia (ISS Atlanta)
- RE: problem running cli program from ... Trevor Joerges
- RE: problem running cli program from ... Schiza, Apostolia (ISS Atlanta)
- RE: problem running cli program from ... Naftel, Bill S
