manifoldcf-user mailing list archives

Site index · List index
Message view « Date » · « Thread »
Top « Date » · « Thread »
From Nigel Thomas <>
Subject Re: ManifoldCF 1.0.1 MySQL setup : Error getting connection: Access denied for user
Date Mon, 05 Nov 2012 12:00:24 GMT
Hi Karl,

Thank you for the prompt response.

I had run a tcp dump on the connection to get more details on the
error, which is a mysql :42000 - Access denied for user" error and
looking at the source code, the problem is not that it isn't
connecting to the database but, it doesn't have the privileges to
create the database and grant access to users. We run a shared mysql
services, where the user, database and privileges are granted
separately, and unfortunately super user access isn't permitted.

I guess in this context the initialise script will not work without
some modification to check if database and users already exist.

I have reverted to using postgres instance with full privileges for
the moment and may revisit the code later.

Thanks for the help.

Nigel Thomas

On 2 November 2012 15:35, Karl Wright <> wrote:
> Hi Nigel,
> I'm not a MySQL expert, but I seem to recall there was something
> interesting about the way MySQL authenticated remote connections.
> There are two properties that the MySQL driver looks at:
>   /** MySQL server property */
>   public static final String mysqlServerProperty =
> "org.apache.manifoldcf.mysql.server";
>   /** Source system name or IP */
>   public static final String mysqlClientProperty =
> "org.apache.manifoldcf.mysql.client";
> I think you may need to set both of these for the auth to succeed.
> Also, make sure your MySQL server is configured to permit connections
> from the source system you are trying to connect from.
> Thanks,
> Karl
> On Fri, Nov 2, 2012 at 11:21 AM, Nigel Thomas <> wrote:
>> Hello,
>> I am having some problems configuring 1.0.1 to use a MySQL database, I
>> have followed steps here :
>> I have set the following db related properties in properties.xml:
>>   <property name="org.apache.manifoldcf.databaseimplementationclass"
>> value="org.apache.manifoldcf.core.database.DBInterfaceMySQL"/>
>>   <property name="org.apache.manifoldcf.mysql.server"
>> value=""/>
>>   <property name="org.apache.manifoldcf.dbsuperusername" value="root"/>
>>   <property name="org.apache.manifoldcf.dbsuperuserpassword" value="password"/>
>>   <property name="" value="manfold_db"/>
>>   <property name="org.apache.manifoldcf.database.username" value="root"/>
>>   <property name="org.apache.manifoldcf.database.password" value="password"/>
>>   <property name="org.apache.manifoldcf.database.maxhandles" value="100"/>
>> On running, the following exception is thrown:
>>  org.apache.manifoldcf.core.interfaces.ManifoldCFException: Error
>> getting connection: Access denied for user 'root'@'%' to database
>> 'mysql'
>>         at org.apache.manifoldcf.core.database.DBInterfaceMySQL.createUserAndDatabase(
>>         at org.apache.manifoldcf.core.system.ManifoldCF.createSystemDatabase(
>>         at org.apache.manifoldcf.crawler.system.ManifoldCF.createSystemDatabase(
>>         at org.apache.manifoldcf.crawler.InitializeAndRegister.doExecute(
>>         at org.apache.manifoldcf.crawler.InitializeAndRegister.main(
>> I am able to connect to the MySQL instance using a command line MySQL
>> client from the same machine using the same credentials, this rules
>> out networking and credentials related issues.
>> Am not sure what I am missing with the setup, I have tried the
>> equivalent with a postgres setup, this seems to work just fine.
>> Thanks,
>> Nigel Thomas

View raw message