What is the best way to back up as much as possible of Debian 12 on my laptop to a server that has SSH available? I am currently backing up my users /home/<homedir> folder, but I would like to be able to nuke and restore the system from a backup.

I have ventoy on an external drive if that helps any.

P.S. I would like to be able to do incremental backups too.

  • @[email protected]
    link
    fedilink
    910 months ago

    The standard answer: don’t backup the system, automate its deployment instead. Backup only data.

    • @[email protected]OP
      link
      fedilink
      3
      edit-2
      10 months ago

      Even for a home system? Not a fleet of data center servers. I am currently using rsync to backup /home/<<user>>/ to the ssh server. I tend to make a lot of changes to the base Debian/KDE install.

      • @mipadaitu
        link
        English
        310 months ago

        Yeah, it’s worth it to just start fresh. Keep your user data, nuke the rest and setup from scratch w/automation if it’s extremely customized to your liking.

        I personally try to use the default config as much as possible so there’s not as much to set up after installing from ISO.

      • @[email protected]
        link
        fedilink
        2
        edit-2
        10 months ago

        There will always be gaps, but describing your machine through Ansible is worth it and can be fun if you’re into that sort of thing.

        The first time I set up a freshly installed Debian laptop from my existing Ansible roles was a really enjoyable moment.

        Being able to establish a familiar base on a fresh system at will is a far greater power than pure config/data backups.

      • @[email protected]
        link
        fedilink
        110 months ago

        What kind of changes? Package installation, removal and configuration? Use apt-mark showmanual to save list of manually installed packages, dpkg --get-selections | grep 'deinstall$' to save list of removed packages, debconf --get-selections to save debconf package settings, backup files that you edited in /etc. This should be enough for restoration, wouldn’t take a long time for backup and avoid risk of filesystem inconsistency.

        • @[email protected]OP
          link
          fedilink
          112 days ago

          Installing specific things both from the repo and from elsewhere (Minecraft), Minor UI tweaks - move the panel to the left side (wide monitor), Konsole settings for colors, font(dotted zero), font size (bigger), 80x25 window. Probably others but that’s all I remember for now.

          • @[email protected]
            link
            fedilink
            16 days ago

            User settings are stored in the home directory, so you already have them backed up with rsync. If you didn’t omit dotfiles, of course.

      • @[email protected]
        link
        fedilink
        110 months ago

        You mentioned rsync, then take a look rsnapshot if you haven’t yet. It is based on rsync and doing incremental backup very well.