Re: Apache2/Modperl2 fails to preload Win32::OLE at server startup

2004-11-30 Thread Thierry Valentin
Hello all the discussion has become a little bit technical for me... What I understand is that I've been lucky to make this work so far and that sooner or later I will end up with some problems. Is there some not-too-complicated way to workaround the problems in the perl scripts or at least

Re: Apache2/Modperl2 fails to preload Win32::OLE at server startup

2004-11-30 Thread Stas Bekman
Thierry Valentin wrote: Hello all the discussion has become a little bit technical for me... What I understand is that I've been lucky to make this work so far and that sooner or later I will end up with some problems. I'm not familiar with win32-perl internals, but based on what Jan explained

RE: Apache2/Modperl2 fails to preload Win32::OLE at server startup

2004-11-30 Thread Jan Dubois
On Tue, 30 Nov 2004, Stas Bekman wrote: What about the solution of ithreads? Originally ithreads were storing their context in ThreadLocalStorage, and this didn't work under mp2, so it was rewritten to store the context in a perl PL_ interpreter global, now ithreads can be run inside the same

Re: Apache2/Modperl2 fails to preload Win32::OLE at server startup

2004-11-30 Thread Stas Bekman
Jan Dubois wrote: On Tue, 30 Nov 2004, Stas Bekman wrote: What about the solution of ithreads? Originally ithreads were storing their context in ThreadLocalStorage, and this didn't work under mp2, so it was rewritten to store the context in a perl PL_ interpreter global, now ithreads can be run

Re: Apache2/Modperl2 fails to preload Win32::OLE at server startup

2004-11-30 Thread Thierry Valentin
Hello, I definitely agree with that. A daemon would solve all the authentication and connection persistence issues. But the problem is that all accesses to the database that I'm using *must* go through a vendor specific API which is only available as a COM library. This explains the choice of

Re: Apache2/Modperl2 fails to preload Win32::OLE at server startup

2004-11-29 Thread Thierry Valentin
Hello, Here is the startup script modified as you recommended: (I replaced the call to warn by Apache-server-log-debug because warn does not log anything - at least under win32) = # mod_perl startup script use Apache2 (); use ModPerl::Util (); use

Re: Apache2/Modperl2 fails to preload Win32::OLE at server startup

2004-11-29 Thread Stas Bekman
Jan, do you have any idea why the CLONE trick doesn't work? CLONE is running inside the newly-clonned perl, so thread-safety shouldn't get on the way, no? Thierry Valentin wrote: Hello, Here is the startup script modified as you recommended: (I replaced the call to warn by

Re: Apache2/Modperl2 fails to preload Win32::OLE at server startup

2004-11-29 Thread Steve Hay
Stas Bekman wrote: Jan, do you have any idea why the CLONE trick doesn't work? CLONE is running inside the newly-clonned perl, so thread-safety shouldn't get on the way, no? Just a guess -- it may be the same problem with CoInitialize() that I experienced not long ago with Win32::Shortcut.

RE: Apache2/Modperl2 fails to preload Win32::OLE at server startup

2004-11-29 Thread Jan Dubois
On Mon, 29 Nov 2004, Stas Bekman wrote: Jan, do you have any idea why the CLONE trick doesn't work? CLONE is running inside the newly-clonned perl, so thread-safety shouldn't get on the way, no? Is CLONE running inside the new *thread* ? It is not good enough to run it in the correct Perl

Re: Apache2/Modperl2 fails to preload Win32::OLE at server startup

2004-11-29 Thread Stas Bekman
Jan Dubois wrote: On Mon, 29 Nov 2004, Stas Bekman wrote: Jan, do you have any idea why the CLONE trick doesn't work? CLONE is running inside the newly-clonned perl, so thread-safety shouldn't get on the way, no? Is CLONE running inside the new *thread* ? It is not good enough to run it in the

RE: Apache2/Modperl2 fails to preload Win32::OLE at server startup

2004-11-29 Thread Jan Dubois
On Mon, 29 Nov 2004, Stas Bekman wrote: If you just call perl_clone it runs in the new perl context, but inside the same thread. At least on Unix. Under ithreads.pm it probably starts a new thread first (but I'm not sure). Under modperl 2, there is no 1:1 relationship between interpreters and

Re: Apache2/Modperl2 fails to preload Win32::OLE at server startup

2004-11-26 Thread Thierry Valentin
Hello, I've tried the My::HappyWorkaround::CLONE trick... But sorry, same punishment as before: = Apache refuses to start + MS Failure Dialog. Jan Dubois was pointing out that win32::OLE was not thread safe. So this could explain why this still fails at startup, whatever the way we try to load

Re: Apache2/Modperl2 fails to preload Win32::OLE at server startup

2004-11-26 Thread Stas Bekman
Thierry Valentin wrote: Hello, I've tried the My::HappyWorkaround::CLONE trick... But sorry, same punishment as before: = Apache refuses to start + MS Failure Dialog. Does this function get to run at all? Add: warn CLONE is running\n; inside this function and check the logs/console while

Re: Apache2/Modperl2 fails to preload Win32::OLE at server startup

2004-11-25 Thread Stas Bekman
Thierry Valentin wrote: Hello, Sorry about the imprecision... The reason why I forgot to send the error log is that there's absolutely nothing in the error log - not a single line even with a LogLevel set to debug. Understood. It's always a good idea to mention that, so we don't need to guess

Re: Apache2/Modperl2 fails to preload Win32::OLE at server startup

2004-11-25 Thread Randy Kobes
On Wed, 24 Nov 2004, Thierry Valentin wrote: Hello, I'm currently using the following configuration: - Perl 5.8.4.810 from Activestate - Apache 2.0.52 installed from the MSI package - mod_perl 1.99_17 installed with ppm from http://theoryx5.uwinnipeg.ca All these 3 packages are frehsly

Re: Apache2/Modperl2 fails to preload Win32::OLE at server startup

2004-11-25 Thread Markus Wichitill
Stas Bekman wrote: Thierry Valentin wrote: Sorry about the imprecision... The reason why I forgot to send the error log is that there's absolutely nothing in the error log - not a single line even with a LogLevel set to debug. Understood. It's always a good idea to mention that, so we don't need

Re: Apache2/Modperl2 fails to preload Win32::OLE at server startup

2004-11-25 Thread Stas Bekman
Markus Wichitill wrote: Stas Bekman wrote: Thierry Valentin wrote: Sorry about the imprecision... The reason why I forgot to send the error log is that there's absolutely nothing in the error log - not a single line even with a LogLevel set to debug. Understood. It's always a good idea to

Re: Apache2/Modperl2 fails to preload Win32::OLE at server startup

2004-11-25 Thread Thierry Valentin
Randy Kobes wrote: On Wed, 24 Nov 2004, Thierry Valentin wrote: Hello, I'm currently using the following configuration: - Perl 5.8.4.810 from Activestate - Apache 2.0.52 installed from the MSI package - mod_perl 1.99_17 installed with ppm from http://theoryx5.uwinnipeg.ca All these 3 packages are

Re: Apache2/Modperl2 fails to preload Win32::OLE at server startup

2004-11-25 Thread Thierry Valentin
Stas Bekman wrote: Markus Wichitill wrote: Stas Bekman wrote: Thierry Valentin wrote: Sorry about the imprecision... The reason why I forgot to send the error log is that there's absolutely nothing in the error log - not a single line even with a LogLevel set to debug. Understood. It's always a

Re: Apache2/Modperl2 fails to preload Win32::OLE at server startup

2004-11-25 Thread Stas Bekman
Thierry Valentin wrote: [...] PerlChildInitHandler 'sub { require Win32::OLE}' Hello I've tried this: the startup still fails but this time I have no MS error dialog saying that Apache had a problem Apache cleanly refuses to start. But there are still no lines in the error.log As Jan has

Re: Apache2/Modperl2 fails to preload Win32::OLE at server startup

2004-11-24 Thread Stas Bekman
Thierry Valentin wrote: Hello, I'm currently using the following configuration: - Perl 5.8.4.810 from Activestate - Apache 2.0.52 installed from the MSI package - mod_perl 1.99_17 installed with ppm from http://theoryx5.uwinnipeg.ca All these 3 packages are frehsly installed and I did no other

Re: Apache2/Modperl2 fails to preload Win32::OLE at server startup

2004-11-24 Thread Aaron Ross
- preload Win32::OLE with a 'use Win32::OLE' in the mod_perl startup script: = Apache2 refuses to start. refuses to start is pretty vague. Can you send us a specific error message from the error log? or the error output of the server process when it tries to start? Aaron -- Report problems:

Re: Apache2/Modperl2 fails to preload Win32::OLE at server startup

2004-11-24 Thread Thierry Valentin
Hello, Sorry about the imprecision... The reason why I forgot to send the error log is that there's absolutely nothing in the error log - not a single line even with a LogLevel set to debug. The only feedback I get is the standard Microsoft error dialog that says: Apache HTTP server has