Event ID 4 — BITS Cleanup Task

Applies To: Windows Server 2008 R2

BITS (Background Intelligent Transfer Service) Server limits the number of upload sessions that can exist concurrently for a user. If the number of sessions for a user is more than this limit, Task Scheduler is triggered to perform the BITS Cleanup task. Task Scheduler scans the directory and keeps the first number of sessions it encounters. When the number of encountered sessions equals the configured limit, the rest are deleted. By default, Task Scheduler is set to clean up every 12 hours, an interval that can be configured by the administrator.

 

Event Details

Product: Windows Operating System
ID: 4
Source: BITS Server Extensions
Version: 6.1
Symbolic Name: EVENT_CLEANUP_CANT_REMOVE_SESSION
Message: BITS has encountered %2 error while deleting the job %1 from the virtual directory %3.

Resolve

Check if the GUID corresponding to the session exists

To resolve this issue, check if the GUID corresponding to the session exists:

To perform this procedure, you must have membership in the local Administrators group, or you must have been delegated the appropriate authority.

  1. Ensure the directory corresponding to the vdir exists:
    • On the BITS Upload page, click the Content View tab.
    • Ensure that the BITS Session folder exists in vdir: From the Features view of the BITS Uploads page, expand the inetpub folder. Click wwwroot, and then check if the BITS Session folder exists.
    • Confirm the directory corresponding to vdir exists.
  2. Confirm that the job folder with corresponding GUID name is not in use by any other program.
  3. If the physical directory for the vdir is a remote share, confirm that the connect as user name and password are correct.
  4. Run the CleanUp task again:
    • Click Default Web sites, click vdir, click the Features tab at the bottom of the IIS Manager screen. Click BITS Uploads.
    • Click Run CleanUp Task.

Verify

 To verify that the task scheduler has cleaned up all the stale data in BITS:

  1. Ensure that bitsmgr.dll is present in %windir%\system32.
  2. Open Task Scheduler. From the Start menu, right-click My Computer, and then click Manage. Click Task Scheduler.
  3. Verify that a task with name starting with BITS_{vdirname} exists.

BITS Cleanup Task

BITS Infrastructure