How to delete trustedinstaller files on Windows 8

24

9

When deleting certain files from the Program Files directory using the Administrator account, I got the following pop-up:

Folder Access Denied

How should I work around this? Why am I asked to require permission from "TrustedInstaller", despite using an Administrator's account?

A.Antri

Posted 2012-10-31T17:09:07.070

Reputation: 505

Are you trying to delete Windows.old ? – HackToHell – 2012-10-31T17:11:01.590

Trying to delete some files under "Program File", left after un unstallation of software. Windows.old is something left after upgrade to Windows 8 ? – A.Antri – 2012-10-31T17:15:27.177

There were some extension files that seemed a little delete resistant, but that was solved by cutting and moving the files to my Dropbox and then deleting them from there. I suppose there could be different variations of that type of maneuver. – None – 2013-01-21T14:03:12.297

Answers

21

You need to take the ownership of this folder and recursive files:

Many times you need to take ownership of a file or folder in Windows. For example, when you want to customize Windows UI and need to replace existing system files with a new one. You have to follow no. of steps to take ownership and grant yourself full permission to access the file or folder. But now you can do it in a single step.

Basically, follow these steps:

  1. Enter into the folder properties:

enter image description here

  1. Go to "Security" and edit (with the Advanced button) the "CREATOR OWNER" owner to your user:

enter image description here enter image description here enter image description here enter image description here

Here you can also find a how-to video.

Diogo

Posted 2012-10-31T17:09:07.070

Reputation: 28 202

1This did not help in my case where the Owner is showed in a link separated from Permissions, Auditing and Separate Permissions. And there was no clear way visible that could help me achieve the desired result. – MycrofD – 2015-06-06T16:41:48.623

@MycrofD This link might help you. Click on change in the owner tab, advanced in the next window, then find now and find your account.

– Bprodz – 2015-06-12T19:11:44.053

If someone fancies to do the same from the command line, i.e. for batch automatization, here is (disclaimer: my) recipe: http://superuser.com/a/951764/75914

– Frank Nocke – 2015-09-07T10:22:39.183

22

http://cdn3.howtogeek.com/wp-content/uploads/TakeOwnership.zip

This requires a TakeOwnership registry hack. The files are in the link above.

In order to install the hack just execute the InstallTakeOwnership.reg file. Then restart the explorer.exe process. (You can do this in Task Manager) Now when you right click a file you should see an option to "Take Ownership".

Here is what it should look similar to:

enter image description here

Matthew Wong

Posted 2012-10-31T17:09:07.070

Reputation: 3 908

4

The URL appears to have been changed to http://cdn3.howtogeek.com/wp-content/uploads/TakeOwnership.zip

– Hans Kesting – 2015-01-28T09:58:41.783

1Yes. This actually helped. – MycrofD – 2015-06-06T16:39:27.340

1Nice, thank you. This used to bug me all the time, the "Take Ownership" registry hack completely solves this problem! – akalucas – 2013-05-02T11:58:42.863

4

TrustedInstaller is the built-in user account which Windows uses to install updates and Windows App.

The folder you're trying to open is owner by TrustedInstaller and no one else has read access. Being Administrator, you can change the permissions but only after you make yourself the owner.

If you're sure, you can become the owner and then delete the folder.

Alexey Ivanov

Posted 2012-10-31T17:09:07.070

Reputation: 3 900

0

There are files that you cannot delete even if you have the TrustedInstaller rights (obtained via Joakim's RunAsTI console). Even as administrator you cannot set the owner of some directories and files.
With trurstedInstaller rights you can however move the directory around. But that too not to another drive.
The only way to nuke the directory is to move it within a folder that will later be deleted by TrustedInstaller.

WindowsApps is the right contender for this. When you delete the app the corresponding directory is also deleted by TrustedInstaller.

  1. Start a console with TrustedInstaller rights (you can user Joakim's RunAsTI
  2. Copy the directory name of the app you are about to delete. Begin installing an app if required from Windows store in order to create the directory if required. Then pause the download.
  3. Create a parent directory at the root of the drive. X:\<app_directory_name>
  4. Move the rogue directory to delete into this X:\<app_directory_name> directory
  5. Move the original also to the X:\<app_directory_name>
  6. Now move the X:\<app_directory_name> into the WindowsApps directory.
  7. Finally delete the app (cancel if download was midway) to nuke them all

Ujjwal Singh

Posted 2012-10-31T17:09:07.070

Reputation: 1 550