php.net |  support |  documentation |  report a bug |  advanced search |  search howto |  statistics |  random bug |  login
Bug #3516 mysql_connect timeout
Submitted: 2000-02-17 10:37 UTC Modified: 2000-07-22 19:39 UTC
From: joerg dot koenning at gmx dot de Assigned:
Status: Closed Package: MySQL related
PHP Version: 3.0.14 OS: Linux and Windows-NT
Private report: No CVE-ID: None
View Add Comment Developer Edit
Welcome! If you don't have a Git account, you can't do anything here.
You can add a comment by following this link or if you reported this bug, you can edit this bug over here.
(description)
Block user comment
Status: Assign to:
Package:
Bug Type:
Summary:
From: joerg dot koenning at gmx dot de
New email:
PHP Version: OS:

 

 [2000-02-17 10:37 UTC] joerg dot koenning at gmx dot de
Dear people at PHP.net.
We are using PHP and MySQL for our web-services. In some cases the connection from PHP to the MySQL-database might fail using mysql_connect because of the fact that the MySQL-server is down. In that case the mysql_connect tries to connect to the database for a long time (>30 sec.). After this time it comes back with an "connection failed"-error.
Is there a way to set this "mysql_connect-timeout" by script (e.g. to 5 seconds)?
Kind regards,
Joerg Koenning
joerg.koenning@gmx.de

Patches

Add a Patch

Pull Requests

Add a Pull Request

History

AllCommentsChangesGit/SVN commitsRelated reports
 [2000-07-22 19:39 UTC] mrobinso at cvs dot php dot net
You can set the timeout of the script itself, and/or
prepend @ to the mysql_connect() function to disable
the error message and show something a little nicer,
including the rest of the script.

This isn't really a bug though, so closing.
 
PHP Copyright © 2001-2024 The PHP Group
All rights reserved.
Last updated: Fri Mar 29 15:01:28 2024 UTC