NeuroAgent

How to Fix Standalone Package Creation Error in KSC 15.1.0.20748

Fixing errors when creating standalone packages in Kaspersky Security Center 15.1.0.20748 after deleting old packages. Step-by-step guide for cleaning the repository and restoring the database.

Question

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?

NeuroAgent

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

The error when creating a standalone package in Kaspersky Security Center occurs due to several key factors:

  1. 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.

  2. Corrupted repositories: Lack of disk space during deletion could have led to partial repository file corruption.

  3. Cached data: The Kaspersky Security Center console may use cached information about packages that doesn’t update automatically.

  4. 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):

  1. Stop Kaspersky Security Center services:

    net stop "Kaspersky Security Center Administration Server"
    net stop "Kaspersky Security Center Web Console"
    
  2. 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:

  1. Open the Kaspersky Security Center console
  2. Go to AdvancedUpdate Repositories
  3. Right-click on Updates for antivirus bases and software modules
  4. 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

  1. In the Kaspersky Security Center console, select AdvancedFile Anti-Virus Scan
  2. Run a scan of the repository folder for corrupted files
  3. Delete any corrupted files found

Method 2: Through the Unused Data Cleanup Wizard

  1. In the Kaspersky console, select ToolsUnused Data Cleanup Wizard
  2. Follow the wizard instructions to clean up old packages

Method 3: Manual Cleanup

If automatic methods don’t work, perform manual cleanup:

  1. Stop Kaspersky services
  2. Navigate to the repository folder: C:\ProgramData\Application Data\Kaspersky\Kaspersky Security Center\ distribution\packages\
  3. Manually delete unnecessary package folders
  4. 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

  1. Use the Kaspersky database utility:

    "C:\Program Files\Kaspersky\Kaspersky Security Center Administration Server\klnapi.exe" --checkdb
    
  2. If errors are found, perform recovery:

    "C:\Program Files\Kaspersky\Kaspersky Security Center Administration Server\klnapi.exe" --rebuilddb
    

Force Cache Update

  1. Clear the console cache:

    • Delete the contents of the folder %APPDATA%\Kaspersky\Kaspersky Security Center\
    • Restart the management console
  2. Update package information:

    • In the KSC console, select AdvancedDistributionInstallation Packages
    • Right-click and select Refresh

Preventive Measures

To avoid similar problems in the future:

  1. Regular Package Management:

    • Periodically delete old package versions
    • Use automatic deletion of outdated versions
  2. Disk Space Monitoring:

    • Set warnings when reaching 80% disk capacity
    • Regularly clean logs and reports
  3. Automated Cleanup:

    • Schedule automatic runs of the unused data cleanup wizard
    • Use scripts for periodic repository cleanup
  4. 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:

  1. Download the utility from the official website
  2. Run it as an administrator
  3. Follow the instructions to remove data about old packages

Repository Cleanup Script

You can create your own script for periodic cleanup:

batch
@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

  1. 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.

  2. 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.

  3. Prevention of regular disk space monitoring and use of automated cleanup tools will help avoid similar problems in the future.

  4. 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

  1. Troubleshooting common problems when uploading updates to the Kaspersky Security Center repository
  2. Installation Package removal problem - Kaspersky Support Forum
  3. How to clear the updates repository in Kaspersky Security Center
  4. The utility for removing data concerning installation of Kaspersky Security Center
  5. Cleaning up unused data
  6. Creating a stand-alone installation package