How to fix the error when creating standalone packages in KSC 15.1.0.20748 after deleting old packages?
On a server with deployed Kaspersky Security Center (KSC) version 15.1.0.20748, free disk space was exhausted (only 60GB total on a single disk). After deleting old packages, errors occurred when creating new standalone packages. How to eliminate these errors and where might references to already deleted packages remain?
Problem Creating Standalone Packages in Kaspersky Security Center 15.1.0.20748 After Removing Old Packages
The problem of creating standalone packages in Kaspersky Security Center 15.1.0.20748 after removing old packages usually occurs due to remaining references in the database and repositories. To fix this error, you need to clean the update repository and perform a database integrity check for Kaspersky Security Center.
Contents
- Causes of the Error
- Where References to Removed Packages Remain
- Step-by-Step Problem Fix
- Update Repository Cleanup
- Database Check and Recovery
- Preventive Measures
- Cleanup Tools
Causes of the Error
The error when creating a standalone package in Kaspersky Security Center occurs due to several key factors:
-
Remaining references in the database: Even after physically deleting packages from the folder
C:\ProgramData\Application Data\Kaspersky\Kaspersky Security Center\ distribution\packages\, the KSC database still contains references to these packages. -
Corrupted repositories: Lack of disk space during deletion could have led to partial repository file corruption.
-
Cached data: The Kaspersky Security Center console may use cached information about packages that doesn’t update automatically.
-
Incorrect access rights: After deleting packages, access rights to remaining files and folders may be compromised.
As noted in the Kaspersky documentation, such problems often occur when working incorrectly with installation repositories.
Where References to Removed Packages Remain
References to removed packages can remain in several places:
1. Kaspersky Security Center Administration Database
- Main database in the folder
C:\ProgramData\Application Data\Kaspersky\Kaspersky Security Center\ database\ - Tables related to distribution and installation packages
2. Update Repository
C:\ProgramData\Application Data\Kaspersky\Kaspersky Security Center\ distribution\packages\C:\ProgramData\Application Data\Kaspersky\Kaspersky Security Center\ distribution\cache\
3. Console Cache
- Management console temporary files
- Cached data configuration files
4. Logs and Reports
- Log files containing references to old packages
- Historical installation data
On the Kaspersky forum, users report similar problems when deleting the \\\Packeges\\\NetAgent_11.0.x.x.x folder leads to constant errors when deploying new packages.
Step-by-Step Problem Fix
Step 1: Check Available Disk Space
Before beginning work, ensure there is enough free space on the drive (recommended minimum 5-10 GB):
-
Stop Kaspersky Security Center services:
net stop "Kaspersky Security Center Administration Server" net stop "Kaspersky Security Center Web Console" -
Check available space in Kaspersky folders.
Step 2: Create a Backup
Important! Before performing cleanup operations, be sure to create backups:
- KSC database
- Configuration files
- Distribution repository
Step 3: Repository Cleanup
Use the built-in cleanup wizard:
- Open the Kaspersky Security Center console
- Go to
Advanced→Update Repositories - Right-click on
Updates for antivirus bases and software modules - Select
Cleanup
Note: If the cleanup wizard is unavailable, you can perform cleanup manually via the command line.
Update Repository Cleanup
To clean the update repository, you can use the following methods:
Method 1: Through the Management Console
- In the Kaspersky Security Center console, select
Advanced→File Anti-Virus Scan - Run a scan of the repository folder for corrupted files
- Delete any corrupted files found
Method 2: Through the Unused Data Cleanup Wizard
- In the Kaspersky console, select
Tools→Unused Data Cleanup Wizard - Follow the wizard instructions to clean up old packages
Method 3: Manual Cleanup
If automatic methods don’t work, perform manual cleanup:
- Stop Kaspersky services
- Navigate to the repository folder:
C:\ProgramData\Application Data\Kaspersky\Kaspersky Security Center\ distribution\packages\ - Manually delete unnecessary package folders
- Clear the cache:
C:\ProgramData\Application Data\Kaspersky\Kaspersky Security Center\ distribution\cache\
As described in the official documentation, manual cleanup requires caution as it may affect system functionality.
Database Check and Recovery
Database Integrity Check
-
Use the Kaspersky database utility:
"C:\Program Files\Kaspersky\Kaspersky Security Center Administration Server\klnapi.exe" --checkdb -
If errors are found, perform recovery:
"C:\Program Files\Kaspersky\Kaspersky Security Center Administration Server\klnapi.exe" --rebuilddb
Force Cache Update
-
Clear the console cache:
- Delete the contents of the folder
%APPDATA%\Kaspersky\Kaspersky Security Center\ - Restart the management console
- Delete the contents of the folder
-
Update package information:
- In the KSC console, select
Advanced→Distribution→Installation Packages - Right-click and select
Refresh
- In the KSC console, select
Preventive Measures
To avoid similar problems in the future:
-
Regular Package Management:
- Periodically delete old package versions
- Use automatic deletion of outdated versions
-
Disk Space Monitoring:
- Set warnings when reaching 80% disk capacity
- Regularly clean logs and reports
-
Automated Cleanup:
- Schedule automatic runs of the unused data cleanup wizard
- Use scripts for periodic repository cleanup
-
Backup:
- Regularly create database backups
- Store copies on a separate drive or in the cloud
Cleanup Tools
Kaspersky Security Center Data Removal Utility
For serious cases, there is a special utility:
- Download the utility from the official website
- Run it as an administrator
- Follow the instructions to remove data about old packages
Repository Cleanup Script
You can create your own script for periodic cleanup:
@echo off
set KSC_PATH="C:\ProgramData\Application Data\Kaspersky\Kaspersky Security Center\ distribution\packages\"
set DAYS=30
forfiles /P %KSC_PATH% /M *.* /D -%DAYS% /C "cmd /c echo Deleting @file... && del @path"
This script will delete packages older than 30 days from the specified folder.
Conclusion
-
The main problem is that manually deleting old packages doesn’t update references in the Kaspersky Security Center database, which leads to errors when creating new standalone packages.
-
The solution consists of sequential cleanup: first manual deletion of old packages, then repository cleanup through built-in tools, and if necessary, forcing a console cache update.
-
Prevention of regular disk space monitoring and use of automated cleanup tools will help avoid similar problems in the future.
-
In complex cases, it is recommended to use the special Kaspersky Security Center data removal utility or contact technical support for deep database diagnostics and recovery.
Sources
- Troubleshooting common problems when uploading updates to the Kaspersky Security Center repository
- Installation Package removal problem - Kaspersky Support Forum
- How to clear the updates repository in Kaspersky Security Center
- The utility for removing data concerning installation of Kaspersky Security Center
- Cleaning up unused data
- Creating a stand-alone installation package