I am setting up a complete online backup for my (Ubuntu 20.04) computer using Duplicati (to restore to a new machine in case of theft, fire etc). I am currently deciding which parts of my home directory /home/drubbels/ to include - trying to get all irreplaceable personal files, while excluding as much as possible application data (which would just waste space, and is probably easier to re-download and reinstall from source than to restore from a backup).

Originally, I thought I should exclude all home folder files starting with . and include all the rest, but that turned out not to work - the Steam folder includes game data for all Steam games (shouldn't be in the backup), while the .minecraft folder includes such as things as single-player savegames (should be in the backup). In addition, I don't know whether important personal settings for some applications end up outside the home folder entirely (in /etc/, in /usr/...). Ideally, I would like for a restore to include my custom Nautilus bookmarks, my choice of terminal bell sound...

Obviously, the Steam and .minecraft game directories mentioned above are a rather specific example, and it may not be possible to give a 100% correct answer for the general case, but, broadly speaking, which directories should (and which shouldn't) be in a complete backup of a Linux install?

  • 5
    Pretty much everything in your home will be user-specific stuff and not "application data" you can re-download. There will be some default settings yes, but they would take up a tiny amount of space. I don't think this is worth bothering with: just back up the entire home dir.
    – terdon
    Nov 14 '20 at 18:46
  • Duplicate of these: askubuntu.com/questions/545655/… & askubuntu.com/questions/40992/…
    – oldfred
    Nov 14 '20 at 20:54
  • This is not an answer, it's a warning. Your /home folder contains a lot of your personal data, often including things like passwords for different applications. I hope you're encrypting the data before you upload it.
    – KGIII
    Nov 14 '20 at 23:00
  • 1
    @KGIII Not to worry - I'm using Duplicati's AES setting with a 64-bit passphrase.
    – Drubbels
    Nov 15 '20 at 10:21

I don't think it's possible to answer this. Application can store their data anywhere they want in the home directory so it's hard to tell what is important and what not. I'd say backup everything. The only obvious folders to omit are IMHO .cache and .local/share/Trash. Applications should save their data to .local, GNOME settings should be in .gnome (and KDE in .kde) but Firefox uses .mozilla, if you are using Wine it saves all data in .wine, flatpak applications store data in .var etc.

I don't know whether important personal settings for some applications end up outside the home folder entirely (in /etc/, in /usr/...)

Applications you run as "normal" user can't write outside of your home so they can't store data in /etc, /etc contains system configuration.

Your Answer

By clicking “Post Your Answer”, you agree to our terms of service, privacy policy and cookie policy

Not the answer you're looking for? Browse other questions tagged or ask your own question.