View Issue Details

IDProjectCategoryView StatusLast Update
0000155WackoWikiinstallerpublic2009-08-19 09:38
Reporterebal Assigned ToTann San  
PrioritynormalSeveritymajorReproducibilityalways
Status resolvedResolutionfixed 
Product Version4.2 
Target Version4.3.rcFixed in Version4.3.rc 
Summary0000155: database port number is bypassed
DescriptionI tried a lot of times this and i think this is a bug.

at svn version 326 i configure the Database Port to another port number rather 3306 to test a different mysql version and everytime it continues the installation to port 3306

any ideas ?
TagsNo tags attached.

Activities

ebal

2008-04-21 21:06

developer   ~0000322

After a lot of debugging and reading i came across with this :

at setup/install.php, line: 233
this line :

$port = trim($wakkaConfig["database_port"]);

should be ( i think ) :

$port = trim($config2["database_port"]);

I found also that at files db/mysql.php (32 line) and db/mysqli.php (29 line) the port in function connect is declare as port = "" and i dont understand the reason.

Anyway another reason that the database port is ignored is because if the MySQL is being access through a socket file the port option is ignored as the host is localhost.

The only way to the change the port option is to connect to mysql through tcp and not through socket.

the below msg is from MySQL Manual

The default hostname is localhost. For client programs on Unix, the hostname localhost is special. It causes the client to connect to the MySQL server through a Unix socket file. This occurs even if a --port or -P option is given to specify a port number. To ensure that the client makes a TCP/IP connection to the local server, use --host or -h to specify a hostname value of 127.0.0.1, or the IP address or name of the local server. You can also specify the connection protocol explicitly, even for localhost, by using the --protocol=tcp option.

the examples are from my computer :

[ebal@gutsy:~]$ mysql -P 234212 -h 127.0.0.1
ERROR 2003 (HY000): Can't connect to MySQL server on '127.0.0.1' (111)

[ebal@gutsy:~]$ mysql -P 234212 -h localhost
mysql> status;
...
Connection: Localhost via UNIX socket
...
mysql> quit

[ebal@gutsy:~]$ mysql -P 234212
mysql> status;
...
Connection: Localhost via UNIX socket
...
mysql> quit

[ebal@gutsy:~]$ mysql -P 234212 -p --protocol=tcp
ERROR 2003 (HY000): Can't connect to MySQL server on 'localhost' (111)

[ebal@gutsy:~]$ mysql -P 3306 -p --protocol=tcp
mysql> status;
...
Connection: localhost via TCP/IP
...

Tann San

2008-06-04 21:26

manager   ~0000348

Fixed the reported issue as well as another in the mysqli implementation.

Issue History

Date Modified Username Field Change
2008-03-27 16:28 ebal New Issue
2008-03-27 16:28 ebal Legacy => NEW
2008-04-21 21:06 ebal Note Added: 0000322
2008-04-22 01:29 administrator Target Version => 5.0.0
2008-05-15 09:49 Tann San Status new => assigned
2008-05-15 09:49 Tann San Assigned To => Tann San
2008-06-04 21:26 Tann San Status assigned => resolved
2008-06-04 21:26 Tann San Fixed in Version => 5.0.0
2008-06-04 21:26 Tann San Resolution open => fixed
2008-06-04 21:26 Tann San Note Added: 0000348
2008-08-27 01:00 administrator Category Installation => Installer
2009-08-19 09:25 administrator Fixed in Version 5.0.0 => 4.3.rc
2009-08-19 09:38 administrator Target Version 5.0.0 => 4.3.rc
2010-03-08 10:14 administrator Category Installer => installer