PHP 5.3.1 failing
Posted by: arnb (---.dyn.optonline.net)
Date: December 03, 2009 06:57AM

Installed PHP 5.3.1. When it attempts to connect to MySql including using PHPMyAdmin I get no output with a perpetual "connecting to localhost" message in Firefox until the script times out.

Anyone have a solution?



Edited 1 time(s). Last edit at 12/03/2009 06:58AM by arnb.

Options: ReplyQuote
Re: PHP 5.3.1 failing
Posted by: arhimede (---.dotboost.net)
Date: December 03, 2009 03:03PM

I can confirm, same situation. Installed 5.3.1 near 5.3.0, phpmyadmin is time-out, also mysql and mysqli extensions are not working, only PDO

Options: ReplyQuote
Re: PHP 5.3.1 failing
Posted by: arnb (---.dyn.optonline.net)
Date: December 03, 2009 03:07PM

Found this at [php.net], but don;'t know the path to use.

For those who manually compiled MySQL, the default
mysqlnd settings may results in error.
Your mysql_error() function may give you this message:

---------------------------
No such file or directory (trying to connect via unix:///tmp/mysql.sock)
---------------------------

This is because your manually compiled MySQL has its own place for socket.
You need to provide PHP a reference for an appropriate mysql socket.
That means you need to edit php.ini and add a section like this:

---------------------------
[mysql]
mysql.default_socket="/your/path/to/mysql.sock"

Options: ReplyQuote
Re: PHP 5.3.1 failing
Posted by: arhimede (---.dotboost.net)
Date: December 03, 2009 03:38PM

those stuff are not very helpful on windows :-(
I am still digging, is obviously a matter of php-mysql connection

Options: ReplyQuote
Re: PHP 5.3.1 failing
Posted by: stevenmartin99 (---.b-ras2.blp.dublin.eircom.net)
Date: December 03, 2009 03:44PM

can i ask what u did to downlaod 5.3.1?

Steven Martin
stevenmartin99@gmail.com
stevenmartin99@hotmail.com
PampServer.com - [pampserver.com]

Options: ReplyQuote
Re: PHP 5.3.1 failing
Posted by: arhimede (---.dotboost.net)
Date: December 03, 2009 03:45PM

Addons, Php, there is an exe that can be downloaded and installed
[www.wampserver.com]

Options: ReplyQuote
Re: PHP 5.3.1 failing
Posted by: arnb (---.dyn.optonline.net)
Date: December 03, 2009 03:46PM

[www.wampserver.com]
click addons
click PHP
click 5.3.1 and installed it

Options: ReplyQuote
Re: PHP 5.3.1 failing
Posted by: stevenmartin99 (---.b-ras2.blp.dublin.eircom.net)
Date: December 03, 2009 03:46PM

ok... you should have jsut deleted wamp and installed version 2.0i

5.3.1 doesnt come with all the extentsions as they are not built yet



but mysql extentions do work


add me to msn if you want me to take a look

stevenmartin99@hotmail.com

Steven Martin
stevenmartin99@gmail.com
stevenmartin99@hotmail.com
PampServer.com - [pampserver.com]

Options: ReplyQuote
Re: PHP 5.3.1 failing
Posted by: arnb (---.dyn.optonline.net)
Date: December 03, 2009 03:49PM

Don't understand "ok... you should have jsut deleted wamp and installed version 2.0i "
It was already installed and working

Options: ReplyQuote
Re: PHP 5.3.1 failing
Posted by: arnb (---.dyn.optonline.net)
Date: December 03, 2009 04:23PM

Workaround found for my scripts, phpMyAdmin continues to fail

Changed my connection script
from
mysql_connect ('localhost', 'userid', 'password')

to
mysql_connect ('127.0.0.1', 'userid', 'password')



Edited 1 time(s). Last edit at 12/03/2009 04:24PM by arnb.

Options: ReplyQuote
Re: PHP 5.3.1 failing
Posted by: arhimede (---.dotboost.net)
Date: December 03, 2009 04:26PM

yes, using 127.0.0.1 instead of localhost is working fine now
thanks

Options: ReplyQuote
Re: PHP 5.3.1 failing
Posted by: arnb (---.dyn.optonline.net)
Date: December 03, 2009 04:37PM

Workaround for phpMyAdmin
edit C:\wamp\apps\phpmyadmin3.2.0.1\config.inc.php

change as follows
//$cfg['Servers'][$i]['host'] = 'localhost';
$cfg['Servers'][$i]['host'] = '127.0.0.1';

This works until someone figures out the solution using php.ini. I tried setting mysql.default_socket = 127.0.0.1 but it did not work, perhaps it needed quotes. I'll try that later.

BTW I can confirm the bug with Mysql_Close is fixed in 5.3.1



Edited 1 time(s). Last edit at 12/03/2009 04:38PM by arnb.

Options: ReplyQuote
Re: PHP 5.3.1 failing
Posted by: arnb (---.dyn.optonline.net)
Date: December 03, 2009 11:12PM

Higher level workaround found and tested.

comment out ::1 localhost from the Windows host file which was added for IPV6.

You must run your editor in Administrator mode (Right click, select run as administrator) then edit
C:\Windows\System32\drivers\etc\hosts

Full bug information at
[bugs.php.net]

No, it's a bug in the PHP stream transport. (mysqlnd is using PHP
streams for the connection)

-->
If PHP is asking the OS for the IP for the host "localhost", it gets a
list with 2 addrinfo structures (one for ::1 and the other for
127.0.0.1), but PHP is only trying a connection to the first one. Well,
the MySQL server don't know IPV6, and thus the connection fails.



Edited 1 time(s). Last edit at 12/03/2009 11:27PM by arnb.

Options: ReplyQuote
Re: PHP 5.3.1 failing
Posted by: stevenmartin99 (---.b-ras2.blp.dublin.eircom.net)
Date: December 03, 2009 11:23PM

not at all


::localhost simply menas dont ever use this


so even if 127.0.0.1 localhost is before it it is now told to ignore..

u cant run localhost while :localhost is in the hosts file


you must then use 127.0.0.1 which means modifying mysql/phpmyadmin to only to conenct on ip address

Steven Martin
stevenmartin99@gmail.com
stevenmartin99@hotmail.com
PampServer.com - [pampserver.com]

Options: ReplyQuote
Re: PHP 5.3.1 failing
Posted by: toumimi (---.111.116-78.rev.gaoland.net)
Date: December 03, 2009 11:47PM

Nope. :::1 localhost is the same as 127.0.0.1 localhost but in IPV6.

There is a problem with this syntax in windows, which try to use IPV6 and fails.
So it need to be removed or modified to :::1 (three : ), in order wamp to work.

But you can use this url to use IPV6 to access wamp homepage if you want : http://[::1]/index.php

Florian

WampServer Patch (Screenshots)
Topic EN : www.wampserver.com
Topic FR : www.wampserver.com



Edited 1 time(s). Last edit at 12/03/2009 11:48PM by toumimi.

Options: ReplyQuote
Re: PHP 5.3.1 failing
Posted by: arnb (---.dyn.optonline.net)
Date: December 04, 2009 12:52AM

toumimi wrote:
>So it need to be removed or modified to :::1 (three : ), in order wamp to work.

Changed my hosts file to :::1 localhost

and all is functioning normally.

Thank you for the explanation and the solution.

Arn

Options: ReplyQuote


Sorry, only registered users may post in this forum.