Linux/Doppelte Dateien

Aus Foxwiki

Find and Remove Duplicate Files

Whether you’re using Linux on your desktop or a server, there are good tools that will scan your system for duplicate files and help you remove them to free up space.

  • Solid graphical and command-line interfaces are both available.

Duplicate files are an unnecessary waste of disk space.

  • After all, if you really need the same file in two different locations you could always set up a symbolic link or hard link, storing the data in only one location on disk.

FSlint

FSlint

fdupes

fdupes

dupeGuru

DupeGuru

How To Find And Delete Duplicate Files In Linux

I always backup the configuration files or any old files to somewhere in my hard disk before edit or modify them, so I can restore them from the backup if I accidentally did something wrong.

  • But the problem is I forgot to clean up those files and my hard disk is filled with a lot of duplicate files after a certain period of time.
  • I feel either too lazy to clean the old files or afraid that I may delete an important files.
  • If you’re anything like me and overwhelming with multiple copies of same files in different backup directories, you can find and delete duplicate files using the tools given below in Unix-like operating systems.
A word of caution

Please be careful while deleting duplicate files.

  • If you’re not careful, it will lead you to accidental data loss.
  • I advice you to pay extra attention while using these tools.

Find And Delete Duplicate Files In Linux

For the purpose of this guide, I am going to discuss three utilities namely

  1. Rdfind
  2. Fdupes
  3. FSlint

These three utilities are free, open source and works on most Unix-like operating systems.

Rdfind

Rdfind

How to Find Duplicate Files in Linux and Remove Them

Brief: FSlint is a great GUI tool to find duplicate files in Linux and remove them.

  • FDUPES also find the files with same name in Linux but in the command line way. 

If you have this habit of downloading everything from the web like me, you will end up having multiple duplicate files.

  • Most often, I can find the same songs or a bunch of images in different directories or end up backing up some files at two different places.
  • It’s a pain locating these duplicate files manually and deleting them to recover the disk space.

If you want to save yourself from this pain, there are various Linux applications that will help you in locating these duplicate files and removing them.

  • In this article, we will cover how you can find and remove these files in Ubuntu.

Note: You should know what you are doing.

  • If you are using a new tool, it’s always better to try it in a virtual directory structure to figure out what it does before taking it to root or home folder.
  • Also, it’s always better to backup your Linux system!

Quellen