Windows: Cancel Bits transfers from other user

Hi,

if you try to remove bits transfers initialted from SYSTEM or from other users you get an Access Denied (Unable to cancel job – 0x80070005) error.

If you want to remove such jobs change to the local SYSTEM contex by Microsoft Sysinternals psexec. Start a cmd as administrator:

C:\> psexec -s -h cmd.exe
C:\> whoami
nt authority\system

List all jobs

C:\> bitstransfer /LIST /ALLUSERS 
..
{AA2C6C92-131F-41A8-A112-2B0444FB14E3} 'WU Client Download' TRANSIENT_ERROR 0 / 1 0 / UNKNOWN
...

To cancel all jobs

C:\> bitsadmin /reset /allusers
{9E10CC99-8A3F-4E07-8088-87B8E26D93AB} canceled.
{DD1FB08A-DC3E-4DE5-B84C-AE7319C9F3C8} canceled.
{509DAE19-A434-4088-9761-AD2C9E3CC682} canceled.

Or a specfic job

C:\> bitsadmin /cancel {509DAE19-A434-4088-9761-AD2C9E3CC682}

The Powershell way

C:\> psexec -s -h cmd.exe
C:\> whoami
nt authority\system
C:\> powershell.exe
Windows PowerShell
Copyright (C) 2016 Microsoft Corporation. All rights reserved.
$ENV:USERNAME
YourComputer$
PS C:\> Get-BitsTransfer -Allusers|Remove-BitsTransfer

Michael

Advertisment to support michlstechblog.info

Leave a Reply

Your email address will not be published. Required fields are marked *

Time limit is exhausted. Please reload CAPTCHA.