How to monitor Firebird server activity?
This depends on the server version you are using:
- Firebird 2.5 and above provides full Audit and Trace capability
- Firebird 2.1 and above provides monitoring tables
- for earlier versions you can use some 3rd-party applications
Firebird 2.5 has a complete Audit and Trace Services API, which allows you to monitor database activity continuously. More information on this monitoring approach is available in Firebird 2.5 Release Notes and the following article:
Firebird project only provides the API and a crude command line tool as a demo implementation. Implementing a slick desktop or server application is left to 3rd party developers. The tool that does this well is Upscene's FB TraceManager:
Firebird 2.1 and above features server-side monitoring via special system tables. This way you can monitor your server by using SQL statements. Those system tables all have prefix MON$ in their name. To use them, you need to make sure your database file is created with Firebird 2.1 or higher (ODS version 11.1). If you have a database that is created with earlier versions, you need to do backup and subsequent restore with Firebird 2.1 to have those tables.
For detailed information about each monitoring table, read the file README.monitoring_tables in 'doc' directory of your Firebird installation.
Please note that monitoring tables just offer the data, but you'll probably need some way to aggregate those and spot the problems. A tool that does this well is Sinatica Monitor:
Sinatica Monitor (freeware beta version available for download)
Here are some tools worth checking out for Firebird 2.0 and lower:
UIB SQL Monitor