Home
About
Search
Welcome to M-Files Empower – our new support experience. We'd love to hear what you think!Give feedback

Last updated on 27 November 2026

Admin

The Optimize Database (Thorough) operation consists of up to 13 steps. M-Files Admin shows the progress of the operation with a step number and name.

The steps that run depend on the vault database engine, vault settings, and whether the optimization starts manually or by a schedule.

Steps that run in each context

The following table shows which steps run with different database engines and optimization methods.

Not all steps run during every optimization. Therefore, the step numbers shown in M-Files Admin can skip some values. For example, with Microsoft SQL Server, the operation proceeds from step 7 to step 10.

Step Name in M-Files Admin Firebird, manual Firebird, scheduled SQL server, manual SQL server, scheduled
1 Taking the vault offline Yes Yes Conditional* Conditional*
2 Rebuilding metadata indexes Yes Yes Yes Yes
3 Recalculating relevance scores for objects Yes Yes Yes Yes
4 Cleaning out unused access control lists Yes Yes Yes Yes
5 Clearing the change logs of object types Yes Yes Yes Yes
6 Checking the full-text search compatibility of views Yes Yes Yes Yes
7 Upgrading the vault database for improving performance Yes Yes Yes Yes
8 Backing up the metadata Yes Yes No No
9 Restoring the metadata Yes Yes No No
10 Rebuilding database indexes No No Yes Yes
11 Updating the statistics for database objects No No Yes Yes
12 (not shown) Not shown Not shown Not shown Not shown
13 Finalizing the operation Yes Yes Yes Yes
* With Microsoft SQL Server, step 1 runs only if both conditions are met:
  • Delete the files of destroyed objects is enabled.
  • The file data is not stored in the vault database.

Optimization steps

The following sections describe the tasks that M-Files performs during each step.
  1. Taking the vault offline
    M-Files takes the vault offline.
    • Firebird: This step always runs.
    • Microsoft SQL Server: This step runs only if Delete the files of destroyed objects is enabled and the file data is not saved in the vault database.
  2. Rebuilding metadata indexes
    M-Files performs these tasks:
    • Clears old entries from the quick indexing table of external repositories.
    • Resets the help tables.
    • Deletes uncommitted temporary file data.
    • Resets the next file ID for uploads.
    • Changes the local time zone of the vault. This task runs only during manual optimization with Firebird.
    • Rebuilds the metadata indexes.
  3. Recalculating relevance scores for objects

    M-Files recalculates the relevance scores for objects.

    With Microsoft SQL Server, the behavior depends on the default search engine:
    • dtSearch: The vault goes offline and comes back online during this step.
    • Smart Search or IDOL: The vault stays online.
  4. Cleaning out unused access control lists

    M-Files removes unused access control lists.

  5. Clearing the change logs of object types

    M-Files removes old records from the change logs of object types.

  6. Upgrading the vault database for improving performance

    M-Files upgrades the vault database to improve performance. With Microsoft SQL Server, the vault goes offline and comes back online during this step if the database structure must change.

  7. Backing up the metadata
    M-Files backs up the metadata.
    Note: This step runs only with Firebird.
  8. Restoring the metadata
    M-Files restores the metadata.
    Note: This step runs only with Firebird.
  9. Rebuilding database indexes
    M-Files rebuilds the database indexes.
    Note: This step runs only with Microsoft SQL Server.
  10. Updating the statistics for database objects
    M-Files updates the statistics for database objects.
    Note: This step runs only with Microsoft SQL Server.
  11. Step not shown

    M-Files Admin does not show step 12. The operation continues to step 13.

  12. Finalizing the operation
    M-Files performs these tasks:
    • Optimizes the process memory.
    • Brings the vault online.
    • Starts the compression of the full-text search indexes.

Still need help?