Page 1 of 2 12 LastLast
Results 1 to 10 of 15

Thread: cant delete a locked file

  1. #1
    Join Date
    Aug 2012
    Beans
    7

    cant delete a locked file

    tried everything i could to delete this file ..
    it has a lock over it
    it has r-r-r permissions tried to change permissions not permitted
    tried to use nautilus to delete it again same answer not permitted
    please help gotta get rid of this junk file

  2. #2
    Join Date
    Sep 2009
    Location
    surrey uk
    Beans
    2,057
    Distro
    Ubuntu 11.04 Natty Narwhal

    Re: cant delete a locked file

    Hi

    It might be an idea to mention what this file is and where it is before deleting
    DUAL BOOT XP & Natty, Trying LFS

  3. #3
    Join Date
    Aug 2012
    Beans
    7

    Re: cant delete a locked file

    i was trying to do shell scripting its a .sh extension file
    in my home foder

  4. #4
    Join Date
    Aug 2012
    Beans
    7

    Re: cant delete a locked file

    i am trying to delete this 1.sh file
    Attached Images Attached Images

  5. #5
    Join Date
    Sep 2009
    Location
    surrey uk
    Beans
    2,057
    Distro
    Ubuntu 11.04 Natty Narwhal

    Re: cant delete a locked file

    Have you tried
    Code:
    sudo rm -v 1.sh
    DUAL BOOT XP & Natty, Trying LFS

  6. #6
    Join Date
    Aug 2012
    Beans
    7

    Re: cant delete a locked file

    operation not permitted

  7. #7
    Join Date
    Apr 2007
    Location
    Saddleworth (UK)
    Beans
    784
    Distro
    Ubuntu

    Re: cant delete a locked file

    Or.....

    you could try it the graphical way with a small bit of terminal!

    sudo nautilus
    Enter your password and the Admin or Root version of Nautilus will open.

    Navigate to the file and delete!

    Let us know.....
    Alan

    Saddleworth, Manchester (UK).

  8. #8
    Join Date
    Apr 2008
    Location
    LOCATION=/dev/random
    Beans
    5,767
    Distro
    Ubuntu Development Release

    Re: cant delete a locked file

    Quote Originally Posted by AlanR8 View Post
    Or.....

    you could try it the graphical way with a small bit of terminal!



    Enter your password and the Admin or Root version of Nautilus will open.

    Navigate to the file and delete!

    Let us know.....
    You shouldn't use sudo with graphical applications. Instead it should be:
    Code:
    gksudo nautilus
    Cheesemill

  9. #9
    Join Date
    Aug 2012
    Beans
    7

    Re: cant delete a locked file

    i have tried that as well
    opened nautilus
    a box appears there i searched my respective file it was expected this time file will come up with no lock by its side but still there was lock on it and again operation denied popped up
    i think somehow i changed its permission and now cant undo them was trying octal codes with chmod
    and i think i did chmod 011 1.sh it is locked since then and tried to give it full excess or null excess but not letting me change it anymore

  10. #10
    Join Date
    Jun 2011
    Beans
    54
    Distro
    Ubuntu 12.04 Precise Pangolin

    Re: cant delete a locked file

    what you've tried already should have worked......I'm thinking maybe a corrupt file.

    I remember having those from my windows day's and proved neigh on impossible to remove.

    Can you move it to another directory or a hidden folder perhaps....just to hide it away somewhere?

Page 1 of 2 12 LastLast

Bookmarks

Posting Permissions

  • You may not post new threads
  • You may not post replies
  • You may not post attachments
  • You may not edit your posts
  •