On Mon, 2004-11-22 at 14:01, Faisal Nasim wrote: > It compiles and it runs great but for no reason it all the scripts randomly > gives > a 500 error! I was using XML::Simple so I realized I might have some unclosed > file handles which cause a 500 after several hits. This is what I found in > the logs: > > [error] Couldn't create file parser context for file > "/home/.../xml/Test.xml": No such file or directory at /usr/../LibXML.pm line > 427.\n at /usr/../LibXML/SAX.pm line 63\nCompilation failed in require a ...
Sometimes this means that you've had a problem earlier in the request with a module that has XS code, and now things are screwed up for the memory space of that particular child process. I'd suggest you learn to debug with the -X option, as shown here: http://perl.apache.org/docs/1.0/guide/porting.html#Sometimes_it_Works__Sometimes_it_Doesn_t > There's just one more problem. I am now getting occassional 200 OK message > with this in the error log: > > [error] PerlRun: `Undefined subroutine > &Apache::ROOTwww_2..._2ecom::testmod::testmod_search_2epl::GetMakes called at > /home/.../testmod_search.pl line 19.\n' > > You hit refresh and it works great! Sometimes I get that 200 OK error > consecutively > for 4-5 times and then it works. Again, use -X to debug. This is probably caused by using a library that doesn't contain a package declaration. See this for more: http://perl.apache.org/docs/1.0/guide/porting.html#Name_collisions_with_Modules_and_libs > I've tried PerlFreshRestart On/Off Keep it off. > both and I've also tried using both Apache::Registry > and Apache::PerlRun. Use PerlRun until you have it working smoothly, then try to get it running under Registry. PerlRun clears out globals and subs after each request, so it's slower but safer for ugly code. > Can somebody give some pointers? What about that XML::Simple's XMLin() call? > Should I report that? I doubt there's a problem with XML::Simple, because lots of people use it. It is probably caused by something else. - Perrin -- Report problems: http://perl.apache.org/bugs/ Mail list info: http://perl.apache.org/maillist/modperl.html List etiquette: http://perl.apache.org/maillist/email-etiquette.html