You are viewing a plain text version of this content. The canonical link for it is here.
Posted to users@tomcat.apache.org by Nikolas List <Ni...@gmx.de> on 2003/08/31 02:28:09 UTC
DBCP Problems after restart : Server connection failure during
transaction
Hi!
I have (better had) a working web-application running on my debian
system (stable/woody, Tomcat 4.0.4, Mysqld 3.23.49, j2sdk 1.4.1,
mysql-connector-java-3.0.8).
After a reboot of the system (patched the kernel) I now get the
following error message:
java.sql.SQLException: Server connection failure during transaction.
Attempted reconnect 3 times. Giving up.
It seems like the connection pooling doesn't even try to contact my
mysqld - at least I can't see any entry in my logs.
Desperatly playing around I found out, that if I disable
autoreconnecting in the server.xml I get at least another error
(java.sql.SQLException: Server configuration denies access to data
source). Any other change - even obviously wrong username,ports -
doesn't have any effect.
Since I didn't change anything in my configuration files (the
application worked in public for about 4 weeks now) I'm not sure where
to search the error. Googling I found hints on too many open connections
- but too many open connections? After completly rebooting the server?
Does anybody have a glue where to search the problem? Or any hints how
to anlayze/debug the malicious interaction beetwen my application, the
DataSourceFactory and the mysqld?
I'm attaching the relevant parts of my server.xml:
Thanks in advance.
Niko
Re: DBCP Problems after restart : Server connection failure during
transaction
Posted by Nikolas List <Ni...@gmx.de>.
Me again,
I did luckily "solve" my problem - at least it vanished :-)
Just for the ones who seem to have the same problems I'm trying to describe what I did:
Am So, 2003-08-31 um 02.28 schrieb Nikolas List:
> After a reboot of the system (patched the kernel) I now get the
> following error message:
>
> java.sql.SQLException: Server connection failure during transaction.
> Attempted reconnect 3 times. Giving up.
>
It seems that there is no connection to the DBCP or the Connector/J as I expected.
In some newsgroups I found hints (sorry - didn't save the links) that
the problem could be related to name lookup problems.
My guess is - and it's just a guess - that this has been true in my
case. At least we had problems "relaying" mail from this host later the
week, which seemed to have a related reason.
What I did is the following:
I changed the <url>-value to http://[hostname]/[dbname]
It seems to be important to switch of the autoreconnect at least for one
connect.
After that it worked again and I could reactivate the autoreconnect to
yes.
(Remark: I think this have been the "important" steps I did - I did
quite a lot things that night and the following, desperatly trying to
reestablish this webapp, so I might have overseen a crucial action!)
If I am right the deeper reason is a denial of connect to the mysqld
which is not able to lookup the correct hostname mentioned in his
mysql/user-table. But why didn't I find any log entry in mysql.log?
This denial of connect seems to be hidden through the connection pool
autoreconnect-feature (as I described switching this of and connecting
showed the denial of connect.)
Good Luck - and enlighten me, if anybody comes to a deeper insight on
that problem.
Bye,
Niko