0

Previously I used have Ubuntu on my laptop, but currently I am using Windows 8.

I found .trash-1000 file appearing in my drive. I knew that this is due to deleting few files while using Ubuntu.

How to delete that file in Windows 8?

Braiam
  • 67,791
  • 32
  • 179
  • 269
user260351
  • 9
  • 1
  • 1
  • 2

3 Answers3

3

If a trash folder is created in Ubuntu on a volume that Windows can read from and write to, then you can delete it in Windows like any other folder.

That is, in Windows Explorer (the Windows file browser, not to be confused with the related Internet Explorer, a web browser):

  1. Select the file(s) and/or folder(s) you want to permanently delete. In this case, that's the .trash-1000 folder. (This is almost certainly a folder rather than a file. But if it were a file, this would still work.)
  2. Make sure no other files or folders are selected, to avoid accidentally deleting something you don't want to delete.
  3. Press Shift+Delete.

This will delete the selected items. It does not send them to the Recycle Bin first. So be careful! It's still sometimes possible to recover data deleted in this way--that is, this is not a secure delete. But it's often not possible to recover data deleted in this way.

permanently deleting a trash folder from Ubuntu, in Windows

That procedure also works in Ubuntu. In almost any file browser (such as Nautilus, the default file browser; or Thunar, Xubuntu's file browser; or PCManFM, Lubuntu's file browser), you can select items and use Shift+Delete to delete them without first sending them to the trash. (But if you're in Ubuntu and wish to clear out the contents of a trash folder, you can typically just empty the trash.)

permanently deleting a trash folder from Ubuntu, in Ubuntu

In Ubuntu, files and folders whose names start with a . are hidden by default. In just about any file browser in Ubuntu, you can press Ctrl+H to show hidden files. Pressing it again hides them again. As an alternative to the Ctrl+H shortcut key combination, you may instead check (and uncheck) View > Show Hidden Files in the menu bar.

showing hidden files in Ubuntu

You can see .trash-1000 in Windows, suggesting either that Windows is not treating it as a hidden file (Windows doesn't automatically do this for "dotfiles") or that you have Windows Explorer configured to show hidden files by default.

However, if you know (or believe) a hidden file is present but you can't see it in Windows, you can tell Windows Explorer to show hidden files. One way to do this, which will apply inside all folders, is to open Folder Options in the Control Panel, click the View tab, and under Advanced settings, select the "Show hidden files, folders, and drives" option button under "Hidden files and folders." (Then click Apply and OK.)

showing hidden files in Windows

Note that you do not generally have to uncheck the separate "Hide protected operating system files (Recommended)" box, and you shouldn't uncheck that unless you know what you're doing.

Eliah Kagan
  • 117,780
2

To expand a bit on Eliah Kagan's answer:

  • The 1000 in .trash-1000 is the UID of the user who deleted the files. 1000 is the typical UID of the user who installed the system in Debian and Ubuntu.
  • You can, and probably should, browse the .trash-1000/files directory to look for files you may want to keep.
LiveWireBT
  • 28,763
0

These .Trash folders appear in any operating system used when files are deleted using Linux to delete. All our computers run both Windows & Linux, accessing the same Archive, Data & Storage drives, regardless of operating system.

If deleting is difficult, try renaming the folder to a simple name, then try again. On a Linux system, try emptying the Trash Bin. On any Windows system, sometimes Shot-Del sometimes works. Otherwise third-part "shredder" applications sometimes work. In Windows, the best luck we consistently have is the freeware version of "Advanced SystemCare".

user37991
  • 331