Kemin Zhou wrote: [...]
[...]SetEnv LD_LIBRARY_PATH /usr/local/pgsql/lib PassEnv LD_LIBRARY_PATH
While restarting the server:
Stopping httpd: [ OK ]
Starting httpd: [Sun Oct 17 15:41:42 2004] [warn] PassEnv variable LD_LIBRARY_PATH was undefined
So the warning tells you that the shell you start apache from doesn't haveStas,
LD_LIBRARY_PATH defined (which means that you probably not using the same environment to run your plain perl tests and modperl tests, e.g. because one is run as root and the other as another user).
So either set it in the shell you running and use PassEnv, e.g.:
LD_LIBRARY_PATH=/usr/local/pgsql/lib ./httpd
or just set it in httpd.conf:
SetEnv LD_LIBRARY_PATH /usr/local/pgsql/lib
Thaks again for the help. You solved my problem (I can take a break now).
Good to hear that ;)
Just a add a note:
The SetEnv .. Methods works fine without much effort.
The PassEnv ... depends on the environment of the apache user. My apache server use the appache
username, and it is not a login shell. Therefore this mechanism does not seem to work. Only after
I make apache a login shell and add the .bashrc file to the home directory of apache (in my case
I used the default /usr/local/apache2). I am not sure about the security issues this may bring.
in the .bashrc file I added one line . /etc/profile ( in my case I defined the LD_LIBRARY_PATH in
the /etc/profile file). This way, when apache starts the httpd daemon, it has LD_LIBRARY_PATH
defined so that the PassEnv will not get a undefined variable.
Further info: my httpd was started with the Linux daemon shell function locaated in the /etc/init.d/function
file.
Hope these will be helpful to others.
It's probably the safest to add it explicitly in httpd.conf with SetEnv/PerlSetEnv and not rely on the shell settings.
If you submit the above as a doc patch against the PassEnv entry in http://perl.apache.org/docs/1.0/guide/config.pod.orig I'd gladly commit it. Thanks.
-- __________________________________________________________________ Stas Bekman JAm_pH ------> Just Another mod_perl Hacker http://stason.org/ mod_perl Guide ---> http://perl.apache.org mailto:[EMAIL PROTECTED] http://use.perl.org http://apacheweek.com http://modperlbook.org http://apache.org http://ticketmaster.com
-- 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