Re: apache 2.2.6 not connecting to oracle with mod_dbd

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

 



On Tue, 08 Jan 2008 09:22:27 +0100
porath@xxxxxx wrote:

> The apache error log just says:
> [Tue Jan 08 08:52:59 2008] [error] (20014)Internal error: DBD: Can't
> connect to oracle [Tue Jan 08 08:52:59 2008] [error] (20014)Internal
> error: DBD: failed to initialise

OK, since you're using APR 1.3, you can get a bit more error message
by patching mod_dbd as follows (modulo my mailer's line wrap):

--- modules/database/mod_dbd.c  (revision 609791)
+++ modules/database/mod_dbd.c  (working copy)
@@ -459,6 +459,7 @@
     apr_pool_t *rec_pool, *prepared_pool;
     ap_dbd_t *rec;
     apr_status_t rv;
+    const char *err = "";
 
     rv = apr_pool_create(&rec_pool, pool);
     if (rv != APR_SUCCESS) {
@@ -502,12 +503,12 @@
         return rv;
     }
 
-    rv = apr_dbd_open(rec->driver, rec->pool, cfg->params,
&rec->handle);
+    rv = apr_dbd_open_ex(rec->driver, rec->pool, cfg->params,
&rec->handle, &err);
     if (rv != APR_SUCCESS) {
         switch (rv) {
         case APR_EGENERAL:
             ap_log_error(APLOG_MARK, APLOG_ERR, rv, cfg->server,
-                         "DBD: Can't connect to %s", cfg->name);
+                         "DBD: Can't connect to %s: %s", cfg->name,
err);
             break;
         default:
             ap_log_error(APLOG_MARK, APLOG_ERR, rv, cfg->server,



> My httpd.conf looks like this:

1.  Is that at top-level or inside a <virtualhost>?
2.  Does dropping DBDMin to 0 make any difference?

-- 
Nick Kew

Application Development with Apache - the Apache Modules Book
http://www.apachetutor.org/

---------------------------------------------------------------------
The official User-To-User support forum of the Apache HTTP Server Project.
See <URL:http://httpd.apache.org/userslist.html> for more info.
To unsubscribe, e-mail: users-unsubscribe@xxxxxxxxxxxxxxxx
   "   from the digest: users-digest-unsubscribe@xxxxxxxxxxxxxxxx
For additional commands, e-mail: users-help@xxxxxxxxxxxxxxxx


[Index of Archives]     [Open SSH Users]     [Linux ACPI]     [Linux Kernel]     [Linux Laptop]     [Kernel Newbies]     [Security]     [Netfilter]     [Bugtraq]     [Squid]     [Yosemite News]     [MIPS Linux]     [ARM Linux]     [Linux Security]     [Linux RAID]     [Samba]     [Video 4 Linux]     [Device Mapper]

  Powered by Linux