Bug #44354 | DriverManager.getConnection() needs several minutes to connect | ||
---|---|---|---|
Submitted: | 18 Apr 2009 16:11 | Modified: | 7 May 2009 11:13 |
Reporter: | f6bfc445c2d2@754b4224a789.anonbo f6bfc445c2d2@754b4224a789.anonbo | Email Updates: | |
Status: | Can't repeat | Impact on me: | |
Category: | Connector / J | Severity: | S3 (Non-critical) |
Version: | 5.1.6+dfsg-1 | OS: | Linux (Debian 5.0 x86_64) |
Assigned to: | CPU Architecture: | Any | |
Tags: | MySQL Connector Java libmysql-java |
[18 Apr 2009 16:11]
f6bfc445c2d2@754b4224a789.anonbo f6bfc445c2d2@754b4224a789.anonbo
[19 Apr 2009 0:11]
Mark Matthews
Is "localhost" defined in your /etc/hosts? If so, what IP addresses does it map to? This smells like broken DNS of some sort.
[22 Apr 2009 9:51]
f6bfc445c2d2@754b4224a789.anonbo f6bfc445c2d2@754b4224a789.anonbo
Yes, localhost points to 127.0.0.1. Even if I use the ip and port number in getConnection() nothing changes. In my.cnf: bind-connection=127.0.0.1, port=3306. Switching to the latest Connector (5.1.7) didn't help too. From mysql.log: 090422 07:37:47 37 Connect username@localhost on test 37 Query /* mysql-connector-java-5.1.7 ( Revision: ${svn.Revision} ) */SHOW VARIABLES WHERE Variable_name ='language' OR Variable_name = 'net_write_timeout' OR Variable_name = 'interactive_timeout' OR Variable_name = 'wait_timeout' OR Variable_name = 'character_set_client' OR Variable_name = 'character_set_connection' OR Variable_name = 'character_set' OR Variable_name = 'character_set_server' OR Variable_name = 'tx_isolation' OR Variable_name = 'transaction_isolation' OR Variable_name = 'character_set_results' OR Variable_name = 'timezone' OR Variable_name = 'time_zone' OR Variable_name = 'system_time_zone' OR Variable_name = 'lower_case_table_names' OR Variable_name = 'max_allowed_packet' OR Variable_name = 'net_buffer_length' OR Variable_name = 'sql_mode' OR Variable_name = 'query_cache_type' OR Variable_name = 'query_cache_size' OR Variable_name = 'init_connect' 37 Query /* mysql-connector-java-5.1.7 ( Revision: ${svn.Revision} ) */SELECT @@session.auto_increment_increment 37 Query SHOW COLLATION 37 Query SET NAMES latin1 37 Query SET character_set_results = NULL 37 Query SET autocommit=1 37 Query SET sql_mode='STRICT_TRANS_TABLES' 37 Query select * from tel
[7 May 2009 11:13]
Tonci Grgin
Sorry but I really don't know what to do with this report... I have never seen such delays on any of the systems I used (none Debian though). It would be wise from you to start debugging your environment for cause as I'm closing the report on the grounds that it's not repeatable.