Bug #16741 Updated: mysql_connect maps localhost to localhost.localdomain

From: Date: Thu, 25 Apr 2002 21:26:54 +0000
Subject: Bug #16741 Updated: mysql_connect maps localhost to localhost.localdomain
References: 1  Groups: php.bugs 
Request: Send a blank email to php-bugs+get-6004@lists.php.net to get a copy of this message
ID: 16741 Updated by: edink@php.net Reported By: koonyin@siukoon.com -Status: Duplicate +Status: Closed Bug Type: MySQL related Operating System: Redhat 7.2 PHP Version: 4.2.0 New Comment: See http://bugs.php.net/bug.php?id=16768 Previous Comments: ------------------------------------------------------------------------ [2002-04-23 11:36:48] franco@i-m-c.it Same with debian potato with php 4.2.0 and mysql 4.23.49a ------------------------------------------------------------------------ [2002-04-23 04:23:50] sander@php.net Dupe of #16285 ------------------------------------------------------------------------ [2002-04-23 02:01:50] fmouse@fmp.com Same thing happens on Debian testing. Same php.ini, same web server, same script. "Can't connect to MySQL server on 'localhost' (111) in /var/www/index.php" etc. etc. No problem with 4.1.2. ------------------------------------------------------------------------ [2002-04-23 00:57:38] koonyin@siukoon.com It happens in 4.2.0, not 4.1.2. mysql_connect("localhost", "username", "password") maps the host from "localhost" to "localhost.localdomain". It results "Warning: Host 'localhost.localdomain' is not allowed to connect to this MySQL server in /blah/blah/blah/db_connect.php on line N". Current resolution: Grant localhost.localdomain in MySQL. ------------------------------------------------------------------------ -- Edit this bug report at http://bugs.php.net/?id=16741&edit=1

« previous php.bugs (#6004) next »