1

After spending so much time to change the settings to make the system work, I want to clone the system so that when something goes wrong, I can recover the system to its last cloned state. What is the best way to do it?

As for regularly backing up files, what is the best way to do so?

Thanks

3
  • 1
    All your user settings are in /home. Only if you made some system wide settings changes like edit of grub, then you may want to backup /etc. Only if server type install may you have other folders in / to backup. I just back up the few files I manually edit in /etc. And export list of installed apps. Then a new install & restore from backups will work and restore your configurations. That is what a good backup should do anyway.
    – oldfred
    Oct 22, 2018 at 19:12
  • 2
    Possible duplicate of How to back up my entire system?
    – wjandrea
    Oct 23, 2018 at 18:09
  • Possible duplicate of How to make a disk image and restore from it later?
    – karel
    Oct 24, 2018 at 3:59

3 Answers 3

1

I would suggest using clonezilla to clone your OS. youo could also use gparted if you prefer see MovingLinuxPartition.

For backups you can use the Ubuntu "backups" tool and set the location you want to back up to I would suggest a different harddrive. you could instead use rsync running in a cron job if you prefer. But I would suggest just using the normal backup tool.

1
  • I heard clonezilla is good but is there an equally good one with better GUI? Oct 24, 2018 at 4:09
0

From this answer: Bash script to clone Ubuntu to new partition for testing 18.04 LTS upgrade you can create a working clone that you can boot with new options added to from your menu.

The advantage of cloning this way is you can try new upgrades out on the clone or even intentionally destroy parts of the clone. Then later you can clone your live system again.

It uses incremental copying so only files that are different from the last time cloning was done are copied or deleted.

Tricky issues such as creating new grub menu options or changing UUID's in /etc/fstab are done automatically.

0

I wouldn't worry about cloning the entire system, just your home directory where all your individual settings are stored. That's what I do. Anyways you will have a built in backup system made for Gnome/Ubuntu. It might not be installed but to do so, install 'deja-dup & duplicity' from your package manager or the console.

2
  • If I just backup the home directory, if the system fails? I just install the vanilla version of Ubuntu and drag and drop the home directory? Will the system allow it as it probably uses some files in Home all the time. Oct 25, 2018 at 13:19
  • By default it will back up everything in the Home Directory except 'Downloads'. Of course you can select which directories you want excluded. It won't complain, just overwrite the dotfiles if they're named the same. But one can also select specific items on restore - It's not complicated and intended to be used by a regular user NOT a system admin. So, yeah, I think you've got the idea!
    – SD Allen
    Oct 26, 2018 at 17:29

You must log in to answer this question.

Not the answer you're looking for? Browse other questions tagged .