RE: software.log problem
> I guess it must be a permissions problem i.e. although I am > allowed to connect, create temp files etc. Apache cannot. > Does that make sense and can I fix it? If you're admin on the machine you're trying to run this on (or know who is and can convince him/her to do this) then create a new user with the same access level as you, and set the Apache service on the machine to run as that user. If you can't do anything else, make Apache run as you. Good luck, J-S _ Jean-Sébastien Guay -- Conseiller technique - Administration -- (514) 522-9800 #4840 -- [EMAIL PROTECTED] ___ Perl-Win32-Users mailing list [EMAIL PROTECTED] To unsubscribe: http://listserv.ActiveState.com/mailman/mysubs
Fork/wait generating GPF at 0x0000000c in Perl.exe
Guys, I am running ActiveState Perl v5.8.0 straight out of the box, with the following test piece of code for forking and waiting for child processes. Perl.exe generates a GPF at 0x000c as the child is quitting. Anyone have any ideas what might be going wrong? I based the code on the code extract within the fork documentation in the Camel book. The output up until just before the GPF is as follows: Parent. Child is -108 Child: started: -108 Parent waiting for kiddies... Child: -108 about to exit. Sorry if this topic has already been done to death, but I had a search and couldn't find anything that appeared relevant. Ta. Kev. sub InvokeCmdAsAsyncProcess { my( $exec_line, $dummy ) = @_; my $pid; FORK: { if( $pid = fork ) { # Parent process here. # Child pid in $pid. print "Parent. Child is $pid\n"; } elsif( defined( $pid ) ) { # Child process here. # parent process pid is available with getppid print "Child: started: $$\n"; sleep 10; #system (1, "$exec_line"); print "Child: $$ about to exit.\n"; exit 0; } elsif( $! =~ /No more process/ ) { # EAGAIN, supposedly recoverable fork error print "Forking having problems. Retrying\n"; sleep 2; redo FORK; } else { # Wierd fork error. die "Can't fork: $!\n"; } } return $pid; } # end of InvokeCmdAsAsyncProcess my %pids; my $pid;# pid of most recent child process. foreach $filename (@files) { my $exec_line = "$filename > $filename.log"; print "Executing $exec_line\n"; $pid = InvokeCmdAsAsyncProcess( $exec_line ); if( defined( $pid ) ) { $pids{$pid} = $pid; } } print "Parent waiting for kiddies...\n"; while( ($pid = wait()) != -1 ) { print "Parent: Child $pid exitted with status: $?\n"; } print "Parent after wait.\n"; Kevin Hill AVP Programmer TradeWeb Europe Ltd 99 Gresham Street London EC2V 7NG Tel: +44 (0)20 7776 3200 Fax: +44 (0)20 7776 3201 www.tradeweb.com This e-mail may contain confidential and/or privileged information. If you are not the intended recipient (or have received this e-mail in error) please notify the sender immediately and destroy this e-mail. Any unauthorized copying, disclosure or distribution of the material in this e-mail is strictly forbidden. TradeWeb reserves the right to monitor all e-mail communications through its networks. ___ Perl-Win32-Users mailing list [EMAIL PROTECTED] To unsubscribe: http://listserv.ActiveState.com/mailman/mysubs
RE: Running my perl script in Linux
Hi to all, thank you very much for your help. I've finally made my script run (thanks to the advise of Sir Bill to modify the shebang line since I've uploaded my script from a windoze system). -Original Message- From: Wittrock, Friedel [mailto:[EMAIL PROTECTED] Sent: Wednesday, November 12, 2003 4:53 PM To: [EMAIL PROTECTED] Cc: [EMAIL PROTECTED] Subject: AW: Running my perl script in Linux Hi, you have to insert the "she-bang"-Line as the first line, example: #!/usr/local/bin/perl and then in UNIX-Systems you have to set the path of your script or start it so, example: $ ./myscript.pl regards Friedel Wittrock -Ursprüngliche Nachricht- Von: Bautista, Rodel D.(Digitel-GSM) [mailto:[EMAIL PROTECTED] Gesendet: Mittwoch, 12. November 2003 07:47 An: PERL-WIN32-USERS Betreff: Running my perl script in Linux > Hi and Good Day To All! > > How can I run my perl scripts in Linux without appending "perl" in the > command? > > for example: > > $ myscript.pl> > instead of > > $ perl myscript.pl > > thanks in advance. > > Rodel D. Bautista ___ Perl-Win32-Users mailing list [EMAIL PROTECTED] To unsubscribe: http://listserv.ActiveState.com/mailman/mysubs ___ Perl-Win32-Users mailing list [EMAIL PROTECTED] To unsubscribe: http://listserv.ActiveState.com/mailman/mysubs
Re: Running my perl script in Linux
Bautista, Rodel D.(Digitel-GSM) wrote: > Hi To All! > > I've previously done what you suggested but still I can't run the script as > is. > > Are there any other way to accomplish it? Post a small failing script (10 lines or less) and an ls -l of the script (to show perms) and an ls -l of perl (to prove it's there). > -Original Message- > From: Ben-yaakov Yehuda [mailto:[EMAIL PROTECTED] > Sent: Wednesday, November 12, 2003 3:10 PM > To: 'Bautista, Rodel D.(Digitel-GSM)'; PERL-WIN32-USERS > Subject: RE: Running my perl script in Linux > > > hi, > > make sure that the first line in your script is: > !#/usr/bin/perl [or wherever your perl is installed] > > also make sure that the perl script has execute permition for the user you > are running from. -- ,-/- __ _ _ $Bill LuebkertMailto:[EMAIL PROTECTED] (_/ / )// // DBE CollectiblesMailto:[EMAIL PROTECTED] / ) /--< o // // Castle of Medieval Myth & Magic http://www.todbe.com/ -/-' /___/_<_http://dbecoll.tripod.com/ (My Perl/Lakers stuff) ___ Perl-Win32-Users mailing list [EMAIL PROTECTED] To unsubscribe: http://listserv.ActiveState.com/mailman/mysubs
RE: Running my perl script in Linux
Hi, You also need to give an executing permition to the script by Running : Chmod 755 ypurscript.pl And add the location of the script to the PATH by Export PATH=$PATH: Or run the script as ./yourscript.pl Avi Liani. UNIX System Admin. -Original Message- From: Xu, Qiang (XSSC SGP) [mailto:[EMAIL PROTECTED] Sent: Wednesday, November 12, 2003 9:44 AM To: Bautista, Rodel D.(Digitel-GSM); Ben-yaakov Yehuda; PERL-WIN32-USERS Subject: RE: Running my perl script in Linux Bautista, Rodel D.(Digitel-GSM) wrote: > Hi To All! > > I've previously done what you suggested but still I can't run the > script as is. > > Are there any other way to accomplish it? echo $PATH to see whether your path has included where perl interpreter lies. ___ Perl-Win32-Users mailing list [EMAIL PROTECTED] To unsubscribe: http://listserv.ActiveState.com/mailman/mysubs ___ Perl-Win32-Users mailing list [EMAIL PROTECTED] To unsubscribe: http://listserv.ActiveState.com/mailman/mysubs
RE: Running my perl script in Linux
Bautista, Rodel D.(Digitel-GSM) wrote: > Hi To All! > > I've previously done what you suggested but still I can't run the > script as is. > > Are there any other way to accomplish it? echo $PATH to see whether your path has included where perl interpreter lies. ___ Perl-Win32-Users mailing list [EMAIL PROTECTED] To unsubscribe: http://listserv.ActiveState.com/mailman/mysubs
RE: Running my perl script in Linux
Hi To All! I've previously done what you suggested but still I can't run the script as is. Are there any other way to accomplish it? thanks and regards. -Original Message- From: Ben-yaakov Yehuda [mailto:[EMAIL PROTECTED] Sent: Wednesday, November 12, 2003 3:10 PM To: 'Bautista, Rodel D.(Digitel-GSM)'; PERL-WIN32-USERS Subject: RE: Running my perl script in Linux hi, make sure that the first line in your script is: !#/usr/bin/perl [or wherever your perl is installed] also make sure that the perl script has execute permition for the user you are running from. -Original Message- From: Bautista, Rodel D.(Digitel-GSM) [mailto:[EMAIL PROTECTED] Sent: Wednesday, November 12, 2003 8:47 AM To: PERL-WIN32-USERS Subject: Running my perl script in Linux > Hi and Good Day To All! > > How can I run my perl scripts in Linux without appending "perl" in the > command? > > for example: > > $ myscript.pl > > instead of > > $ perl myscript.pl > > thanks in advance. > > Rodel D. Bautista ___ Perl-Win32-Users mailing list [EMAIL PROTECTED] To unsubscribe: http://listserv.ActiveState.com/mailman/mysubs ___ Perl-Win32-Users mailing list [EMAIL PROTECTED] To unsubscribe: http://listserv.ActiveState.com/mailman/mysubs
RE: Running my perl script in Linux
hi, make sure that the first line in your script is: !#/usr/bin/perl [or wherever your perl is installed] also make sure that the perl script has execute permition for the user you are running from. -Original Message- From: Bautista, Rodel D.(Digitel-GSM) [mailto:[EMAIL PROTECTED] Sent: Wednesday, November 12, 2003 8:47 AM To: PERL-WIN32-USERS Subject: Running my perl script in Linux > Hi and Good Day To All! > > How can I run my perl scripts in Linux without appending "perl" in the > command? > > for example: > > $ myscript.pl > > instead of > > $ perl myscript.pl > > thanks in advance. > > Rodel D. Bautista ___ Perl-Win32-Users mailing list [EMAIL PROTECTED] To unsubscribe: http://listserv.ActiveState.com/mailman/mysubs ___ Perl-Win32-Users mailing list [EMAIL PROTECTED] To unsubscribe: http://listserv.ActiveState.com/mailman/mysubs
RE: Running my perl script in Linux
First of all you must have the perl in the PATH Second, write in the firs line of the script : #! e.g. : #!/usr/bin/perl Avi Liani. UNIX System Admin. -Original Message- From: Bautista, Rodel D.(Digitel-GSM) [mailto:[EMAIL PROTECTED] Sent: Wednesday, November 12, 2003 8:47 AM To: PERL-WIN32-USERS Subject: Running my perl script in Linux > Hi and Good Day To All! > > How can I run my perl scripts in Linux without appending "perl" in the > command? > > for example: > > $ myscript.pl > > instead of > > $ perl myscript.pl > > thanks in advance. > > Rodel D. Bautista ___ Perl-Win32-Users mailing list [EMAIL PROTECTED] To unsubscribe: http://listserv.ActiveState.com/mailman/mysubs ___ Perl-Win32-Users mailing list [EMAIL PROTECTED] To unsubscribe: http://listserv.ActiveState.com/mailman/mysubs
Running my perl script in Linux
> Hi and Good Day To All! > > How can I run my perl scripts in Linux without appending "perl" in the > command? > > for example: > > $ myscript.pl > > instead of > > $ perl myscript.pl > > thanks in advance. > > Rodel D. Bautista ___ Perl-Win32-Users mailing list [EMAIL PROTECTED] To unsubscribe: http://listserv.ActiveState.com/mailman/mysubs