cocoon-users mailing list archives

Site index · List index
Message view « Date » · « Thread »
Top « Date » · « Thread »
From terrac...@mac.com
Subject Re: Cannot get MySQL pool connection
Date Sat, 02 Mar 2002 04:03:40 GMT
Paul,

On Friday, March 1, 2002, at 09:19 AM, Paul Caton wrote:

> Cocoon just doesn't see a connection to my database. I
> have to say I've wasted so much time trying to get Cocoon to do what
> it says it can do that I'm close to abandoning it.

It's not Cocoon. It's appears to be a Mac OSX-Java issue that seems to 
have popped up with OSX 10.1. I had this same problem getting 
MySQL-Cocoon functional. Cocoon's architecture is amazing to work with 
BUT its layers of abstraction sometimes make it harder to get at the 
root problem (server configuration, in this case). To get a more 
detailed exception message, I wrote a simple servlet in java that hit 
the MYSQL database with the same parameters. Same problem, but it 
revealed "Server configuration denies access to data source". (I also 
found a few helpful exception messages in the Catalina/Apache logs in my 
Tomcat 4.0.1/logs directory.) Well this can mean a lot of things (like 
container security issues, etc.) but I narrowed it down to a problem OS 
X has in resolving "localhost" in many instances, and in this case, with 
JDBC. You can read about a hack at

http://sourceforge.net/forum/message.php?msg_id=198555

Basically, I used something like the following when granting privileges 
to the user accessing the database:

mysql -u root -p GRANT (whatever) PRIVILEGES ON (your database) TO 
(user)@'%' IDENTIFIED BY (password).

The key above is the '%' (quotes included) for user's location.

Otherwise, my config is almost identical to yours, except that I do 
specify port number on the dburl, as in:

	<dburl>jdbc:mysql://localhost:3306/data</dburl>

So email back if you need more specifics. I'm sorry I couldn't get this 
too you sooner, but I was away from my desk. Unfortunately, it seems 
like so many things on OSX just take a little more tweaking... but then 
we all learn more from the process, eh?

Diana


> But I'm loath to
> let the time I *have* put in go to waste, so I'll willingly try any
> suggestions that come in today before I adopt another approach on
> Monday!
>
> Paul.
>
>
>
>
> On Fri, 1 Mar 2002, Derek Hohls wrote:
>
>> Have you tried using 'localhost:3306' instead of  'hostname' ?
>> (and restart).
>
> --
> Paul Caton
> Electronic Publications Editor
> Women Writers Project
>
>  e-mail: paul@mail.stg.brown.edu
>     tel: (401) 863-3619
> address: Box 1841, Brown University, Providence RI 02912
>
> 	
>
>
> ---------------------------------------------------------------------
> Please check that your question has not already been answered in the
> FAQ before posting. <http://xml.apache.org/cocoon/faqs.html>
>
> To unsubscribe, e-mail: <cocoon-users-unsubscribe@xml.apache.org>
> For additional commands, e-mail: <cocoon-users-help@xml.apache.org>
>


---------------------------------------------------------------------
Please check that your question has not already been answered in the
FAQ before posting. <http://xml.apache.org/cocoon/faqs.html>

To unsubscribe, e-mail: <cocoon-users-unsubscribe@xml.apache.org>
For additional commands, e-mail: <cocoon-users-help@xml.apache.org>


Mime
View raw message