dumb backup question
andy baxter
andy at earthsong.free-online.co.uk
Fri Jan 11 13:19:11 UTC 2008
Tim M wrote:
> Hi, I have used Sbackup to the small file server I am learning on. I
> have tried to restore a couple of times using sbackup and never have
> really gotten it to work. Would it be simpler to just backup /home
> rather than mess with backing up the other /var, /usr/local and /etc?
> The only way I have been completely successful in restoring is by
> backing up my home directory. I know it most likely takes much more
> time to do completely reload Ubuntu and download updates. I might try
> to backup and restore this laptop later today . . . just to see if I
> can get it to work.
> Tim
I think that if you try to use a backup program to restore your system
files, you are likely to get into trouble. E.g. you need a basic system
in place to run the backup program in the first place. So I would
recommend that you let the ubuntu installer take care of rebuilding your
system if you ever need to, and use the backup program just for your own
files. A couple of things which may be useful to make it quicker to
rebuild your system:
- you can make a log of all installed packages using 'sudo dpkg
--get-selections > packages.log'. When you reinstall, you can run 'sudo
dpkg --set-selections < packages.log' and 'sudo apt-get dselect-upgrade'
(I think) to reinstall everything that was logged as installed before.
- all the .debs you have downloaded are kept in /var/cache/apt/archives,
so you could back these up to make reinstalling a bit quicker.
The way I do things is to have a single partition, mounted as /local,
which contains all the files I have created or downloaded myself, and
then link this into the main filesystem using symbolic links. e.g.
/local/usr => /usr/local
/local/home => /home
/local/website is an image of my personal website.
etc.
This means that all the data I need to back up is in one place, and I
can back it up easily by just copying everything under /local to my
backup device (a partition on a usb hard drive). It also means that if I
want to completely reinstall the system, I can do so without risking
destroying the files under /local, which are on a separate partition.
If you want to back up /etc, this may not work so well though.
andy.
More information about the ubuntu-users
mailing list