kckclass
01-28-2004, 04:02 AM
[Wed Jan 28 00:05:27 2004] [crit] [Wed Jan 28 00:05:27 2004] file .\server\mpm\winnt\child.c, line 1043, assertion "(rv >= 0) && (rv < threads_created)" failed
anyone know what this message means? doesn't look good to me.
kckclass
01-28-2004, 02:06 PM
Here is what I found:
1. I read up on the crash (choon beat stdunbar to the google description by about 10 seconds and stdunbar beat choon to the fix/patch method and beat me to it by about 30 minutes but I had found it by the time I read his reply and his reply confirmed what I found...hey, kids computer kamp always values SPEEEEEEED and these guys are johnny on it...) THANKS GUYS!!!!
Anyway I read choon's link and figured it had to do with spawned processes not being unloaded before I restarted apache. my test loop used an apache -k restart and never gave me problems until I started testing the PERL scripts and apache's +ExecCGI option.
What I did to eliminate the error was change my testing loop/script to do an apache -k stop, then wait 5 seconds, then apache -k start so that Windows could close all threads and catch up to the processes. That stopped the Apache has generated errors and will be closed by windows error message.
But it still didn't make my perl script run. I tried the .htaccess file in the directory, and since my directory is /userscripts/ (repeated/mirrored individually under each virtual host) I had to include a ScriptAlias /cgi-bin/ c:/hosting/adomain.com/web/userscripts/ and a ScriptAlias /userscripts/ c:/adomain.com/web/userscripts/ in each virtual host block and NOTICE THE FWD SLASH at the end of the userscripts above. usually you don't do that but until I did I couldn't FIND the directory. Apache does NOT recommend you use it but I was testing access to the area by trying to find test.html in that folder and it only appeared (on screen and in error log as non executable) when I added the trailing slash.
Onward:
I was still getting page not found messages until I added the slash and AllowOverride +ExecCGI but then the error message in error.log changed to cannot spawn... hmmmm...
So I checked and up above that I had IncludesNoExec so in the userscript block I put a -IncludesNoExec and still got a could not spawn but the good news was my test.html was now coming up as internal server error (it found it) and the error log was saying test.html was not an executable...so I knew I was CLOSE
Hmmmm... it could find the file in the directory but couldn't spawn a hello.pl 3 line program...
So I figured it had a problem finding my perl.exe bin and changed the shebang at the top of the program from /usr/bin to /perl/bin which is kind of like stdunbar's find below. in his patch they moved the entire perl bins to a /usr/bin area and in my patch i moved the shebang pointer at the top of the program to point to where my perl installation is. I will probably use his method and make a new installation of my perl in /usr so the code remains universal.
Anyway, here is what stdunbar found... and it matches what I dug through and NOW MY PERL AND APACHE WORKS!
Re: ever seen this crash before?
quote:
--------------------------------------------------------------------------------
kckclass wrote on 01-28-2004 01:18 AM:
[Wed Jan 28 00:05:27 2004] [crit] [Wed Jan 28 00:05:27 2004] file .\server\mpm\winnt\child.c, line 1043, assertion "(rv >= 0) && (rv < threads_created)" failed
trying to get perl and apache to work together and now this is happening and she just shuts down... any ideas?
--------------------------------------------------------------------------------
CHOON:
Google is your best friend
http://www.google.com.sg/search?q=....earch&meta=
STDUNBAR:
Well, I haven't but someone else has. I Google'd it and found the following. I don't know if it will help you or not but it sounds similar to what you're seeing.
Google quote:
It now works, barring a "ls" command in one of the perl scripts.
The solution was.
Uninstall perl from the default directory c:/perl/ and install to c:/usr/,
this makes the shebangs work
(from http://www.ricocheting.com/server/cgi.html thanks heskyttberg http://www.experts-exchange.com/Web....jsp?mid=972771 )
In my httpd.conf I have added for perl
LoadFile "c:/usr/bin/perl58.dll"
LoadModule perl_module modules/mod_perl.so
<Files *.pl>
Options ExecCGI
PerlSendHeader On
allow from all
</Files>
Note I did not need an AddHandler line
thanks to dbunder http://www.experts-exchange.com/Web...jsp?mid=1359841 for the <files> direction
I still don't know why, but it works!
Unchanged was
<VirtualHost *>
DocumentRoot "C:/Documents and Settings/User/ttc.org"
<Directory "C:/Documents and Settings/User/ttc.org">
AllowOverride FileInfo AuthConfig Limit
Options MultiViews Indexes SymLinksIfOwnerMatch Includes
SetOutputFilter INCLUDES
</Directory>
<Directory "C:/Documents and Settings/User/ttc.org/cgi-bin">
AllowOverride None
Order allow,deny
Allow from all
Options +ExecCGI
</Directory>
ScriptAlias /cgi-bin/ "C:/Documents and Settings/User/ttc.org/cgi-bin/"
ServerName ttc
</VirtualHost>
note SetOutputFilter to allow SSI to work
and ExecCGI
:D
also (from kck) don't forget to read up on
http://httpd.apache.org/docs/howto/cgi.html#configuringapachetopermitcgi for the basic stuff you need.