Reducing database size
SES Evolution deletes logs by default when they are 12 months old, or 2 months for SQL Server Express. This setting can be configured in the System panel, as shown in the section Managing the deletion of logs. However, SQL Server will not free up nany allocated disk space and keeps it to reuse it later.
If you think that your SQL Server database is taking up too much space on the disk, you can manually reduce it. This operation is not absolutely essential to the proper operation of the database.
There are two possible levels of reduction:
-
Level 1 is quick and has no adverse impact on how SES Evolution runs, but the database is not reduced to its full extent.
-
Level 2 takes much longer as it depends on the size of the database, and may even make SES Evolution temporarily unavailable.
-
Run the following script:
DBCC SHRINKDATABASE (EsAdministration, 10, TRUNCATEONLY);
GO
DBCC SHRINKDATABASE (EsLogs, 10, TRUNCATEONLY);
GO
This process may make SES Evolution temporarily unavailable and affect its future performance, and is therefore not recommended. If you want to run it anyway, do so outside busy periods.
-
Shut down all agent handlers.
-
Run the following script:
USE EsLogs;
GO
DBCC SHRINKFILE (N'EsLogs_Events');
GO
DBCC SHRINKFILE (N'EsLogs');
GO
CHECKPOINT;
GO
DBCC SHRINKDATABASE (EsLogs, 5, TRUNCATEONLY);
GO - Restart the agent handlers.