The fbhosted_log database log file (and why is it increasing)



FogBugz uses Microsoft SQL Server (MSSQL) database to store its data. The database's default name for On-Premises instances is fbhosted.

An MSSQL database usually has two files:

  • the transaction log (fbhosted_log.ldf)
  • the data file (fbhosted.mdf)


The transaction log file is where the database transactions (updates, inserts, deletes) are tracked. This is to ensure the possibility of a quick roll back to a previous state of the database in case of failure.
These transaction logs are cleared when a full backup of the database is executed (the data has been persisted in a backup, so no point in storing them further "temporary" in the transaction log).

But if the database is not backed up for a long time, the transaction log can reach a huge size, sometimes even consuming all of the available disk space, resulting in FogBugz features not working as expected (eg: Mail Queue - There Are Pending Messages).

This is why it is recommended to backup your FogBugz database regularly (eg: every week) because when you backup your database, the transaction log file is cleared. The space occupied by the log file it is not immediately freed up, but if needed, you can force the MSSQL server to free it up by executing a transaction log file shrink. Read our article Reduce Transaction Log File Size - Backup vs Shrink vs Truncate on how to do it.

For more technical information read the Microsoft documentation about The Transaction Log (SQL Server).