List:General Discussion« Previous MessageNext Message »
From:Thomas P. Meyer Date:May 31 1999 2:50am
Subject:flakey connectivity
View as plain text  
I was using postgres on linux for the backend of web applications, and
was
pleased except for speed, so I switched to mySQL.   The performance
did indeed increase dramatically, BUT now the connectivity just a little
flakey.
about 3 per 1000 hits on the database DON'T connect, and my application
ends up with a server error.

I'm using RogueWave as my C++/DB layer, and the error is in the initial
database connection, and doesn't get trapped by try() catch():

RWDBDatabase DBConnect(const RWCString& Name)
{
    RWDBManager::setErrorHandler (genericRWDBHandler);
        try
        {
           RWDBDatabase dbase = RWDBManager::database(
           "ODBC",                 // RW access library name
           "mysql",         // server name
           "user", // user name
           "secret",                     // password
           Name);         // database name
           return dbase;
        }
        catch(RWxmsg x)
        {
           ProgError("Can't Connect");
        }
}

I never experienced this with postgres, so I'm reluctant to blame
RogueWave.

1)  Anyone else experince this?
2)  Any idea how I can fix this?
3)  Any idea how I can dig deeper (mySQL log files, etc...) to get to
the root of
the problem.


I've tried all the obvious, like restarting the database, rebooting,
reinstalling, etc....

here's the output of  mysqladmin extended-status:
+--------------------------+-------+
| Variable_name            | Value |
+--------------------------+-------+
| Aborted_clients          | 0     |
| Aborted_connects         | 7     |
| Created_tmp_tables       | 0     |
| Delayed_insert_threads   | 0     |
| Delayed_writes           | 0     |
| Delayed_errors           | 0     |
| Flush_commands           | 2     |
| Handler_delete           | 0     |
| Handler_read_first       | 0     |
| Handler_read_key         | 0     |
| Handler_read_next        | 0     |
| Handler_read_rnd         | 288   |
| Handler_update           | 9     |
| Handler_write            | 0     |
| Key_blocks_used          | 0     |
| Key_read_requests        | 0     |
| Key_reads                | 0     |
| Key_write_requests       | 0     |
| Key_writes               | 0     |
| Max_used_connections     | 1     |
| Not_flushed_key_blocks   | 0     |
| Not_flushed_delayed_rows | 0     |
| Open_tables              | 1     |
| Open_files               | 2     |
| Open_streams             | 0     |
| Opened_tables            | 1     |
| Questions                | 1915  |
| Running_threads          | 1     |
| Slow_queries             | 0     |
| Uptime                   | 46740 |
+--------------------------+-------+



Thread
flakey connectivityThomas P. Meyer31 May
  • flakey connectivityMichael Widenius3 Jun