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

Thread: Corrupted .TRASH causes crashes, REFUSES to delete files!

  1. #1
    Join Date
    May 2010
    Location
    Currently sunny FL.
    Beans
    306
    Distro
    Xubuntu 12.04 Precise Pangolin

    Question Corrupted .TRASH causes crashes, REFUSES to delete files!

    I hope that I'm posting this thread in the right place. This involves a very unique problem which has caused the .Trash-1000 folder for my external USB drive to become corrupted, to the point of causing massive heat problems which then causes my system to crash, i.e. become completely inoperable, forcing me to do a hard reset.

    The scenario: Recently I went through all of my backup data which is what I use that external USB drive for. After finding several GB of data files, some dating back 2 - 3 years from a root server that I used to have, I went ahead and tried to delete all of those files. Well, with exception to 3 folders, containing no more than perhaps 35 files which totalled less than 8 MB in space, everything was deleted properly without a hitch. The files that couldn't be deleted prompted some strange "couldn't delete blahblahblah file due to input/output error" message. One message for each file that couldn't be deleted.

    Now mind you, I can open these files, look at them, rename them, copy them, but I cannot delete them. Still being pretty wet as far as Linux is concerned, I tried numerous suggestions that I could find on the internet, all of which had to do with file permissions in one form or another. I've tried everything that made any sense and still can't delete those files.

    All of the data is my own, all of the hardware is mine, and I'm the only one using this machine. I'm not attempting to do anything illegal.

    Then I figured, smart as I am, why don't I just assign ownership of the .Trash folder to myself via the chown -R command, followed by deleting the files afterwards. Okay, the chown command gave me no error, I assumed all was well since it's my USB drive to begin with and since it automounts during every restart anyway. I just figured that this would be something to try. BIG MISTAKE !!!

    My system runs just as perfectly as before, with but one exception. NOW, when I attempt to delete those files that I couldn't delete before, I don't get an error message anymore but the CPU starts hyperventilating during the deletion process which goes on endlessly (remember, we're taking about less than 8 MB of data) ... ultimately causing the system to crash, i.e. become totally unresponsive. NOW, if I delete additional files from that USB drive and then attempt to empty the trash, the newly deleted files take substantially longer too now. Not as long as the original "bad files" but still quite long. The drive itself checks out fine and it's not a dual-boot system with Windows. Just did a virus check recently too and everything checks out in that regard as well.

    Can someone tell me how to reassign whatever original values there were for that external drive .Trash folder? I think if I could restore those values to whatever they used to be before I used the chown -R command, perhaps then everything would be fine again as far as the crashing is concerned. HELP ....
    (Please take a look at the screenshots too)

    The last screenshots shows "preparing to delete" which takes a very long time. Then it takes anywhere from 15 to 45 seconds PER FILE before that miniscule file is actually supposedly deleted. Eventually, after a few files are deleted, the system crashes. I wrote "supposedly deleted" because after a reboot the files are still there ....

    .
    Attached Images Attached Images
    PLEASE ... don't waste anyone's time (your own included) with foolish or utterly useless comments!

  2. #2
    Join Date
    Apr 2006
    Location
    Montana
    Beans
    Hidden!
    Distro
    Kubuntu Development Release

    Re: Corrupted .TRASH causes crashes, REFUSES to delete files!

    Quote Originally Posted by WinRiddance View Post
    .
    The .Trash in your home directory should be owned by your user.

    Honestly, it could well be a bad disk =)

    I would copy any data off the flash drive you wish to keep, reformat the disk, and restore the data.

    If you wish, you can overwrite the disk with zeros first (using dd).

    Code:
    dd if=/dev/zero of=/dev/sdb bs=1M
    Just make sure you specify the correct device in "dev/sdb"
    There are two mistakes one can make along the road to truth...not going all the way, and not starting.
    --Prince Gautama Siddharta

    #ubuntuforums web interface

  3. #3
    Join Date
    May 2010
    Location
    Currently sunny FL.
    Beans
    306
    Distro
    Xubuntu 12.04 Precise Pangolin

    Re: Corrupted .TRASH causes crashes, REFUSES to delete files!

    Thank you. I just had the disk thoroughly checked less than 2 weeks ago and it checks out absolutely fine. This problem is two-fold, of which I can ignore the first part with those weird files not letting themselves be deleted. But I'd think that the other problem, the one that just began when I used ... sudo chown -R winriddance:winriddance /media/Volume/.Trash-000 ... would be something that I can reverse again, no? I think that if I could just reverse whatever impact that command had on my existing USB backup drive, then everything would be okay. When I intially used that command my thinking was that if I owned the drive anyway then the command, if used for no reason, would result in accomplishing nothing at all (worst case) ... as opposed to generating a problem.

    At least it would help save a ton of time over having to back up everything on that disk (about 180 GB of data), followed by copying it all back over once the disk has been cleaned.
    PLEASE ... don't waste anyone's time (your own included) with foolish or utterly useless comments!

  4. #4
    Join Date
    Oct 2009
    Beans
    Hidden!
    Distro
    Ubuntu 12.04 Precise Pangolin

    Re: Corrupted .TRASH causes crashes, REFUSES to delete files!

    What file system is /media/Volume ?
    Come to #ubuntuforums! We have cookies! | Basic Ubuntu Security Guide

    Tomorrow's an illusion and yesterday's a dream, today is a solution...

  5. #5
    Join Date
    May 2010
    Location
    Currently sunny FL.
    Beans
    306
    Distro
    Xubuntu 12.04 Precise Pangolin

    Re: Corrupted .TRASH causes crashes, REFUSES to delete files!

    NTFS ... because that way I can share personal files with Windows users like my Mom.
    PLEASE ... don't waste anyone's time (your own included) with foolish or utterly useless comments!

  6. #6
    Join Date
    Oct 2009
    Beans
    Hidden!
    Distro
    Ubuntu 12.04 Precise Pangolin

    Re: Corrupted .TRASH causes crashes, REFUSES to delete files!

    Quote Originally Posted by WinRiddance View Post
    NTFS ... because that way I can share personal files with Windows users like my Mom.
    Ok. chown and chmod don't work on NTFS.

    Try this:

    Code:
    gksu nautilus
    Browse to the .Trash folder on the NTFS drive and delete it.
    Come to #ubuntuforums! We have cookies! | Basic Ubuntu Security Guide

    Tomorrow's an illusion and yesterday's a dream, today is a solution...

  7. #7
    Join Date
    May 2010
    Location
    Currently sunny FL.
    Beans
    306
    Distro
    Xubuntu 12.04 Precise Pangolin

    Re: Corrupted .TRASH causes crashes, REFUSES to delete files!

    Hi again. If you look at the third screenshot of my original post you'll see that that's another thing that I already tried ... opening Nautilus as root and then deleting that whole darn .Trash-0000 folder. Just tried it again with the same result.

    This is really nuts. As I mentioned before, I can use, copy, and rename those files ... privileges already belong to me, but I can't for whatever weird reason delete them. All of the files in question came off my Linux (Debian) root server from a couple of years ago. All of them belonged to a specific internet domain that I had some custom modifications performed on ... something to the effect of allowing a person to register into a free account with a bunch of different graphical user options (personal homepage, calendar, notebook, photo album, greeting cards, games, etc.) ... which was a process that actually worked similar to a c-panel. My custom panel had two functions, one for the admin to assign individual users, and the second function for those users to enjoy their account with all of the graphical toys that was made available to them. I say that it worked similar to c-panel since it was my own custom design, but more specifically for people who knew nothing about computers or websites ... everything worked strictly via point and click.

    All of the files that can't be deleted came from those custom functions that I had installed on that particular domain. They got onto my hard disk via FTP since everything that we had running on the server was also backed up onto my personal hard disk. The prudent thing to do, just in case that server ever develops serious issues for whatever reason ....

    I had several domains with various different functions and all of them were backed up on my personal system. But it's only those particular custom files from that one specific domain that I can't seem to get rid of when I try to delete them.
    PLEASE ... don't waste anyone's time (your own included) with foolish or utterly useless comments!

  8. #8
    Join Date
    Oct 2009
    Beans
    Hidden!
    Distro
    Ubuntu 12.04 Precise Pangolin

    Re: Corrupted .TRASH causes crashes, REFUSES to delete files!

    That's crazy.

    Does it let you delete the files if you plug it into a Windows box?
    Come to #ubuntuforums! We have cookies! | Basic Ubuntu Security Guide

    Tomorrow's an illusion and yesterday's a dream, today is a solution...

  9. #9
    Join Date
    May 2010
    Location
    Currently sunny FL.
    Beans
    306
    Distro
    Xubuntu 12.04 Precise Pangolin

    Re: Corrupted .TRASH causes crashes, REFUSES to delete files!

    Yeah, I know, this is definitely one of the weirdest things that I've ever dealt with.
    I do have an old WinXP Pro box flying around ... but it won't let me access the drive at all.
    There's only one user set up on the Windows box - ME - but I get "error accessing the drive permission denied" messages when I want to open it up. Don't know why, but I don't have time to goof around with that Windows machine right now.

    There's some kind of setting, and I don't even think that it has anything to do with ownership anymore, which prevents me from deleting only those particular files. I'm beginning to think that when I had that custom work done on the server, perhaps the programmer who hard coded those extra administrative features with options for me inadvertently added something to the hard code that is causing this. A virus would come to mind but that's not it, since nothing else is impacted by those files. The server was a Linux Debian server though, and Ubuntu is also based on Linux Debian. Somehow my system is "recognizing" those few particular files as something that inherently belongs to the inner workings of Linux, hence won't permit me to delete those files, even when I'm using root access. Yup, it's crazy alright ....

    Here's something even crazier ... didn't notice that until now when I physically went to inspect the contents of the .Trash-0000 folder again. Somewhere along the line, yesterday as I was going through several different times of trying to delete those files (I'm assuming this) while waiting on this endless process to complete before the system would crash ... those files were duplicated! No kidding, now those files still exist, but with additional duplicates of the same original folders/contents within the original .Trash-0000 folder. It looks, at least to me, almost like that trash bin is trying to read two different sets of deleted files which would obviously be impossible. But that too, might somehow explain this really weird phenomena that's been going on with those files ... ???
    Last edited by WinRiddance; December 17th, 2010 at 08:30 PM.
    PLEASE ... don't waste anyone's time (your own included) with foolish or utterly useless comments!

  10. #10
    Join Date
    Oct 2009
    Beans
    Hidden!
    Distro
    Ubuntu 12.04 Precise Pangolin

    Re: Corrupted .TRASH causes crashes, REFUSES to delete files!

    I'd probably just copy the data I want to keep off the drive and format it.

    Something is definitely messed up.

    Just the the heck of it, what does this return?

    Code:
    ls -lad /media/Volume/.Trash*
    EDIT: I noticed that you were getting an input/output error in the OP. That's probably the problem - the OS can't read from that area of the drive.
    Last edited by CharlesA; December 17th, 2010 at 08:29 PM.
    Come to #ubuntuforums! We have cookies! | Basic Ubuntu Security Guide

    Tomorrow's an illusion and yesterday's a dream, today is a solution...

Page 1 of 2 12 LastLast

Tags for this Thread

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
  •