If you see a database size issue or a drop in performance, the first action is to run through the steps in the below article.
https://www.lansweeper.com/knowledgebase/clearing-tables-to-free-up-space-and-improve-performance/
If, after having performed the above-mentioned steps, the database is still rather big, navigate to the
Configuration\Database Tables tab of the Lansweeper web console. It might be that tblservicesuni is not being cleaned up properly when assets get deleted or cleaned up.
We recommend running the query below on the Lansweeper database to clean that table. After that, your database should shrink significantly.
To run the query, you can use SQL Server Management Studio or DatabaseMaintenance.exe, which you can find in C:\Program Files (x86)\Lansweeper\Tools on your Lansweeper server.
Before running any script on the database, we recommend taking a backup just in case.
https://www.lansweeper.com/knowledgebase/backing-up-your-installation/
The script will delete redundant, orphaned Windows computer services data from tblservices.
USE lansweeperdb
DELETE FROM tblServicesUni WHERE ServiceuniqueID NOT IN (SELECT serviceuniqueid FROM tblservices)