Forums / Install & configuration / ezpublish3.9 problem w/php CGI on 1and1 hosting services

ezpublish3.9 problem w/php CGI on 1and1 hosting services

Author Message

julien b

Wednesday 13 June 2007 10:59:45 am

Hello,

I'm looking for informations, testing etc since 2 days about my first ez publish install..

unfortunatly, ez publish doesn't seem to be able to run with php - cgi.
am I right? is there any tips/tricks to do that even if php is in cgi??

I found that: http://ez.no/community/forum/inst...ot_beyond_the_opening_screen_problem
but it doesn't work with my 1and1 hosting.

when I activate the debug mode as it is written in the doc (http://ez.no/doc/ez_publish/techn...al/3_9/installation/troubleshooting), I just have these results:

___
Warning: mysql_connect() [function.mysql-connect]: Can't connect to local MySQL server through socket '/var/lib/mysql/mysql.sock' (2) in /homepages/40/ blabla bla bla /lib/ezdb/classes/ezmysqldb.php on line 131

Timing: Jun 13 2007 14:59:07
Script start
Timing: Jun 13 2007 14:59:07
Module start 'setup'
Timing: Jun 13 2007 14:59:07
End
Timing: Jun 13 2007 14:59:07
Module end 'setup'
Timing: Jun 13 2007 14:59:07
End
Error: eZMySQLDB Jun 13 2007 14:59:07
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/lib/mysql/mysql.sock' (2)
Warning: Jun 13 2007 14:59:07
User not found, returning anonymous
Warning: Jun 13 2007 14:59:07
Anonymous user not found, returning NoUser
__

I also believed in a bad version for mysql... but it's 4.0.25 (>3.23 thus ok!)
or even I believe in my own error about dbuser, dbserver etc etc ... checked, I'm right too.

install/Setup works fine...
but when I try to get this url: http://myserver/index.php/admin/ or http://myserver/index.php?/admin/... I mean the right name I precised just before this last test=> it brings me to the setup again ...
and with my debug mode, I get the messages I already write above!

help me, please?!

I'd appreciate some informations :-)

JulienB

Egil Fujikawa Nes

Wednesday 13 June 2007 2:06:50 pm

Hi Julien

I'm not familiar with the 1and1 hosting environment, but I have two possible reasons for this socket problem.

<b>1.</b> If you are connecting to the database with socket, try to use TCP connection. This can be done by disable the socket connection in site.ini

[DatabaseSettings]
DatabaseImplementation=ezmysql
Socket=disabled

<b>2.</b> If you are using TCP and not socket already, you should try to change from using localhost as your MySQL server to using 127.0.0.1. We been have experience with some issues using eZ publish and Linux jail that don't allow TCP connections to localhost, only to 127.0.0.1, alternatively the public IP address of your server.

[DatabaseSettings]
DatabaseImplementation=ezmysql
Server=127.0.0.1
User=root
Password=
Database=nextgen

Hope this can help you on your way :)

Best regards
Egil Fujikawa Nes

Try out Free eZ Publish 4.0 Trial Hosting for 14 days:
http://webdealhosting.com/ez-publish-trial-hosting

High quality eZ Publish Hosting since 2001!

Pascal Specht

Thursday 14 June 2007 12:08:19 am

Hi Julien,

just a thought: some ISP's group several customers on the same MySQL database server, in other words: your database server is not necessarily on 127.0.0.1, but may well be on another server. This is common for non dedicated hosting. Maybe you just are trying to connect the wrong database server?

Maybe analyzing the behaviour of a simple connection to your server

<?php
      $db = mysql_pconnect("db_host", "db_user", "db_pass") ;
?>

could shed some light if this is a SQL problem at all?

Pascal

julien b

Thursday 14 June 2007 2:40:25 am

Hello,

thanks a lot for these tests.

I also got an answer from the french ez publish forum:

http://www.ezpublish-france.com/index.php/fr/forums/questions_techniques/probleme_3_9_sur_1and1_fr

"Le seul moyen qu j'ai trouvé pour palier à ce problème est de remplacer le fichier /kernel/classes/ezscript.php par celui qui se trouve à cette adresse: http://pubsvn.ez.no/community/trunk/kernel/classes/ezscript.php "

I can translate that if you want me to:

"The only possibility I found to fix this problem seem to be the replacement of /kernel/classes/ezscript.php by the other one that you can find there: http://pubsvn.ez.no/community/trunk/kernel/classes/ezscript.php"

I'll try it and your tests tonight!

Ciao !!

JulienB

julien b

Thursday 14 June 2007 6:09:58 am

Hello,

I tested!
It works.

What I did:
- in settings/override/site.ini.append.php
I put this config under [DatabaseSettings]:
DatabaseImplementation=ezmysql
Server=TheDBServer
User=MyUser
Password=MyPassword
Database=TheDB
Socket=TCP <======================

My socket is TCP... because the DBServer is different of the Apache server on 1and1.com !!

- I also do that:
replace /kernel/classes/ezscript.php by this one: http://pubsvn.ez.no/community/trunk/kernel/classes/ezscript.php

Now I have another problem (!!!!) but I think I'll find the solution
(dark problem of admin login that doesn't work for the moment .... grrrrr²)

big thanks for you for my solution!

JulienB

julien b

Friday 15 June 2007 3:36:03 pm

error 500 sometimes.............

probably link (rewrite) problem!
I'm despaired... I'll open another thread :-(