Ubuntu: Folders showing lock icon


Whenever I open my documents, all the folders in it are displayed with a lock icon. Therefore, I cannot delete any file or folder in it.

I tried changing the root access using sudo chmod user:directory/ but it fails. I am not able to delete or perform any file action with it.

What action should I perform to fix it?


Run the following to fix your home directory permissions:

sudo chown -R $USER: $HOME  


sudo chmod 777 -R /path to folder you want to delete- This would give all permissions (Read, Write, Execute) to you

The permissions (in this case 777) are as follow:

  • 7 - Full (Read, Write & Execute)
  • 6 - read and write
  • 5 - read and execute
  • 4 - read only
  • 3 - write and execute
  • 2 - write only
  • 1 - execute only
  • 0 - none

after changing the permission, try and delete the folder


Open terminal and type

gksudo nautilus

Browse to the location of documents. Goto properties and set the permission for owner as well as group as read and write. Now try to delete the folder from another nautilus window (one without root privileges).

Don't forget to close that super user nautilus as soon as you don't need it any more!


This would happen probably because you downloaded something from the web. And you don't have the write access to the folders. If you are sure that the files are virus free, try the following command.

chmod -R +rw *  

This will remove the lock icon from the nautilus.


I had this problem as I had set everything to chmod 755 to get back into my system after messing with /var permissions.

sudo chown -R $USER:$USER ~  

solved it for me, eventually. I had to delete some files I'd downloaded first.


Change the file permissions of lock file via CHMOD command:

user@pc:~$ sudo chmod 754 /var/lib/lock *  

Note: 754 is access permission and path to the directory of lock file present if 754 doesn't, do try 777. Once done you can delete the file.

Note:If u also have question or solution just comment us below or mail us on toontricks1994@gmail.com
Next Post »