This site has been archived and you can no longer log in or post new messages. For up-to-date community resources please visit ezplatform.com

eZ Community » Forums » Developer » ezfind installation :...
expandshrink

ezfind installation : updatesearchindexsolr

ezfind installation : updatesearchindexsolr

Monday 20 September 2010 10:56:39 am - 14 replies

Hello !

I am trying to install ezfind on my local ezpublish. I have followed the steps of the provided documentation to do so.The step 5.1 : Updating the search index (page 9) prompts to execute this command :

php extension/ezfind/bin/php/updatesearchindexsolr.php -s <admin siteaccess> --php-exec=php --conc=2

My admin siteaccess is ezwebin_site_admin so I use this one to start the indexation :

php extension/ezfind/bin/php/updatesearchindexsolr.php -s ezwebin_site_admin --php-exec=php --conc=2

All I get is "An unexpected error has occurred. Please contact the webmaster."
This message isn't quite helpful... has anyone ever had this problem and knows how to solve it ?

Thank you !

___

Kévin

Modified on Tuesday 21 September 2010 6:46:24 pm by Kévin S.

Monday 20 September 2010 11:07:24 am

Hello,

Try to look in your var/log/error.log you may get some more usefull information

Monday 20 September 2010 11:38:59 am

Thank you Matthieu ! I should have this reflex !

The log tells me that this is a database connection error :

[ Sep 20 2010 11:32:52 ] [] eZMySQLiDB:Connection error: Couldn't connect to database. Please try again later or inform the system administrator.Can't connect to local MySQL server through socket '/var/mysql/mysql.sock' (2)

[ Sep 20 2010 11:32:52 ] Unexpected error, the message was : Unable to connect to the database server 'localhost' in /Applications/MAMP/htdocs/ezpublish_clean/lib/ezdb/classes/ezmysqlidb.php on line 157

The database connection configuration, in settings/siteaccess/ezwebin_site_admin/site.ini.append is :

[DatabaseSettings]
 
DatabaseImplementation=ezmysqli
 
Server=localhost
 
Port=
 
User=ezadmin_clean
 
Password=admin
 
Database=ezpublish_clean
 
Charset=
 
Socket=disabled

I am looking for the source of the error. If anyone knows it, don't hesitate to post !

___

Kévin

Modified on Monday 20 September 2010 11:50:10 am by Kévin S.

Monday 20 September 2010 11:47:37 am

Is your site access ezwebin_site_admin working ?

Do you have database configuration up to date in your settings/siteaccess/ezwebin_site_admin/site.ini.append.php ?

Monday 20 September 2010 11:53:02 am

Yes, the admin siteaccess is working and its database configuration is OK :

[DatabaseSettings]
 
DatabaseImplementation=ezmysqli
 
Server=localhost
 
Port=
 
User=ezadmin_clean
 
Password=admin
 
Database=ezpublish_clean
 
Charset=
 
Socket=disabled

(Sorry, I have just edited the previous post)

I don't understand why it doesn't want to connect ... I tried to add a port number (8888 on mac os x) and a charset, no result.

Modified on Monday 20 September 2010 11:59:47 am by Kévin S.

Monday 20 September 2010 12:04:44 pm

Oh you use MySQLi, I have never try with it, can't say ...

Maybe if you have a working MySQL server you can try with it, it should work better

Monday 20 September 2010 12:09:19 pm

OK, I have no choice than to try it out with mysql then... it is embarrassing though, because the prod site on which I'll have to install ezfind are working with MySQLi ...

If anyone can help me with that, don't hesitate !

Monday 20 September 2010 12:31:17 pm

I have just tried it out with a MySQL database. I have exactely the same problem, so it doesn't seem to be related to the DB engine.

Monday 20 September 2010 1:08:02 pm

If the admin interface is working, but the scripot is not you should check the differences between your php.ini and php-cli.ini.

Default mysql port is 3306, so if you have some custom, you should put in ini. Maybe your MAMP bundle configured the custom port in php.ini, and not in php-cli.ini (a wild guess)

Monday 20 September 2010 2:32:06 pm

I can't find any php-cli.ini file. What is it supposed to do ?

Monday 20 September 2010 2:52:06 pm

I can't find any php-cli.ini file. What is it supposed to do ?

This is special php.ini for command line php command. But if you can't find it then it should use standard php.ini.

I must say that I don't have a clue what is going on... Did you clear the cache?

Monday 20 September 2010 7:08:02 pm

Yes, I did it several times...

Tuesday 21 September 2010 1:10:50 pm

Did you check what php you are running with: whereis php and php -version?

Maybe you are using some other php then intended...

Tuesday 21 September 2010 6:08:49 pm

The command 'whereis php' returns this :

/usr/bin/php

'php -version' gives me this :

php -versionPHP 5.2.12 (cli) (built: Feb  9 2010 00:34:23) Copyright (c) 1997-2009 The PHP GroupZend Engine v2.2.0, Copyright (c) 1998-2009 Zend Technologies

I think everything is OK here, no ?

What is really strange is that, ezmysql(i).php uses the same identifiers than the administration interface ... those given in settings/siteaccess/ezwebin_site_admin/site.ini.append. I really don't understand why it doesn't manage to connect to the DB !

Maybe this php scripts don't have the same rights than ezpublish ones ... but I wouldn't know why ...

Tuesday 21 September 2010 6:29:58 pm

I finally got this script connect to the database ! It was a problem of mysql socket. All I had to do was create a link /var/mysql/mysql.sock towards the socket /Applications/MAMP/tmp/mysql/mysql.sock

You can find more information here.

Thank you to Ivo & Matthieu for your help !

___

Kévin

expandshrink

You must be logged in to post messages in this topic!

36 542 Users on board!

Forums menu

Proudly Developed with from