Oracle + PHP

From: Date: Thu, 29 Jan 2004 08:39:45 +0000
Subject: Oracle + PHP
Groups: php.db php.general 
Request: Send a blank email to php-db+get-32690@lists.php.net to get a copy of this message
Hello.... I have Oracle 9 + RedHat 7 + PHP 4.3.4 + Apache 1.3.29..... I've compiled apache and php.... I've compiled PHP using the documentation and activating OCI. I've build the typical script for starting apache, it's like this: $ORACLE_HOME=blablahblah... .... more oracle variables .... case "$1" in start) /opt/apache/bin/apachectl startssl ;; stop)
    /opt/apache/bin/apachectl stop
;; esac But the problem is the next: When I login as root (on a console or an xterm) and run that script (/etc/init.d/apache start) everything works fine..... So I've created a link from /etc/rc5.d/S99apache to /etc/init.d/apache for starting it during boot process...... But when I reboot the system and apache is started on boot (oracle is launche thru S20oracle), it start. If you request a php page or other kind of webpage it works fine, until you request a php page that connects to oracle.... Then the instance that is serving that request dies, raise an error that says something like "Couldn't connect to database" and no more php+oracle pages can be requested... But php and apache still works..... If I stop apache and launch it again from console using /etc/init.d/apache start.... It works again and works fine, all connections are successfull..... User apache belongs to oinstall group and have read and execution access to all the oracle directories. Where can be the problem???? Why it works if I launch it from a console or xterm and not if the system starts it??? Thank you

« previous php.db (#32690) next »