I had around 400 or so .tmp folders in the root of my C drive and could only delete them by changing their permissions one-by-one. Getting annoyed at this, I looked up some solutions and ran a couple of commands in the command prompt. While I successfully deleted the files, I realized that I accidentally forgot to specify only changing permissions and ownership for the .tmp files, and instead changed everything in my boot drive that the command prompt could.
While I'm not too worried about this as I have good anti virus and I'm the only one that uses this computer, I would like to change everything back to default if possible. Is there any way to do this? I don't know the original permissions and ownership for everything so I can't do it manually.
Here were the commands I ran:
To change ownership of the files I used: takeown /f . /r /a /d y
To change the permissions I used: icacls *.tmp /grant everyone:F /t /q
While I'm not too worried about this as I have good anti virus and I'm the only one that uses this computer, I would like to change everything back to default if possible. Is there any way to do this? I don't know the original permissions and ownership for everything so I can't do it manually.
Here were the commands I ran:
To change ownership of the files I used: takeown /f . /r /a /d y
To change the permissions I used: icacls *.tmp /grant everyone:F /t /q
Last edited: