Thursday, September 24, 2015

[Trouble shooting] How to delete the folders of Cygwin? (permission denied, access is denied)

Problem.

If you couldn't delete the Cygwin folder because of the access problem.



Solution.

1. Run cmd as administrator mode.

2. Go to the disk where the Cygwin is installed. (e.g., C:\)

3. Type the following commands

  • takeown /r /d y /f cygwin
(Above command takes ownership recursive of the folder, without asking anything.)

  • icacls cygwin /t /grant Everyone:F
(It gives full access to everyone recursively in the folder)

  • rmdir /s /q cygwin
(This command deletes cygwin and subfolders)

No comments:

Post a Comment