Download your favorite Linux distribution at LQ ISO.
Go Back > Forums > Linux Forums > Linux - Desktop
User Name
Linux - Desktop This forum is for the discussion of all Linux Software used in a desktop context.


  Search this Thread
Old 10-04-2010, 04:45 PM   #1
Registered: Jun 2010
Distribution: Ubuntu, CentOS
Posts: 33

Rep: Reputation: 0
Back up questions...

If I was to use a backup my Home directory, would that allow me to restore my system to its current state?

If so would this be dependent on the distro? In other words, if my Home directory was a backup in CentOS, could that same Home directory be used in Ubuntu? Would it cause any conflicts?

The Home directory is pretty large and appears to contain a lot of files that rarely change. Is backing up the whole directory recommended or just picking and choosing frequently changing files?

Thanks in advance,
Old 10-04-2010, 05:09 PM   #2
Registered: Jul 2010
Distribution: Gentoo, Debian, Mint, Xubuntu
Posts: 150

Rep: Reputation: 35
In order to backup and restore the entire system, you would need to backup almost the entire root filesystem.

All your user's data (like "My Documents" in Windows) should be stored in their home directory. Therefore, if all you wish to protect are your files, and not necessarily the system's configuration files, then backing up your home directory should be fine (if you manage your files correctly).

However, as I mentioned, backing up the home directory will not allow you to restore the entire system.

Your user files can be moved between distributions with no issues, but configuration files may pose a problem. I would recommend not moving hidden files and directories (ones starting with a ".") between distributions, unless you know what you're doing.

There are many ways backups can be done. One that historically was a common technique (due to the usage of tape drives) is to occasionally do a full backup, then incrementally back up just the files that have changed. Another is to do multiple full backups, although that would take a large amount of storage space.

There are two more modern ways that I like. One is to keep the full backup up to date, and then have incremental backups going in reverse (for older versions). The other is to have what appear to be multiple full backups, but are actually hard links of the same files. This is what rsnapshot, the only backup program I have used, does.

In short:

Backing up the home directory will get all your user files but not allow you to restore the entire system.

Moving a home directory to another distribution is not recommended.

There are many ways to do backups, the best of which only store files that have changed more than once.

I hope this helps.
1 members found this post helpful.
Old 10-05-2010, 12:26 AM   #3
LQ Guru
Registered: Jan 2006
Location: Virginia, USA
Distribution: Slackware, Debian, Mageia, and whatever VMs I happen to be playing with
Posts: 12,872
Blog Entries: 18

Rep: Reputation: 3340Reputation: 3340Reputation: 3340Reputation: 3340Reputation: 3340Reputation: 3340Reputation: 3340Reputation: 3340Reputation: 3340Reputation: 3340Reputation: 3340
Originally Posted by kern68 View Post
If I was to use a backup my Home directory, would that allow me to restore my system to its current state?
The answer is a resounding "It depends."

If, for example, you are looking to recreate an installation after a system crash, you need to back up much more than your home directory, as crosstalk said. Frankly, that's not worth the effort for the home user--it's easier to reinstall from scratch and then recreate the installation as outlined below.

If you are looking to move files to another computer and replicate the functionality of your home directory or to rebuild the current computer, the answer is sort of.

You can back up the non-hidden files in your home directory to external media, move them to another computer, and recreate them there with no problem. This, however, will not recreate your user configuration, which is normally in hidden directories.

When I back up my home directory, I back up my non-hidden files and select hidden directories for applications for which those hidden directories contain data which I have configured to my own preferences.

These include opera (~/.opera), Pan (~/.pan2), Fluxbox (~/.fluxbox).

Most of the other ~/ dot hidden directories I do not back up, because they do not contain configuration information that I care about. In other words, the default configuration for those items is fine with me.

Once I have the new box ready (or the old box rebuilt), I install the app in question unless it is already there because it was included in the distro (Pan is a good example--many distros include it).

I import the non-hidden contents of my backed up home directory. Bing bang boom all my documents and pictures and spreadsheets and binaries are there.

Now for the hidden files.

I'll use Opera for an example, since it's not normally included in a Linux distribution.

1. Install Opera.

2. Run Opera once as user (this creates ~/.opera).

3. Rename the default hidden directory in a file manager or from the command line (mv .opera .opera.orig).

4. Copy the backed up .opera folder into place.

5. Run Opera as user to make sure it worked. (If I'm successful, my mail is back, my links are back, my newsgroups are back, my rss feeds are back, my skins are back, everything is back.)

This method has not failed me yet with Opera, Pan, or Fluxbox. With Opera and Pan, this has restored mail stores, newsgroup lists and subscriptions, and all that neat stuff. With Fluxbox, it has restored menus, backgrounds, and other config files (if the menus point to programs that don't exist in the new installation, the menus will still display, but the links to the missing programs will not work--they will just lie there non-responsively).

Nothing like a good "it depends," is there?

Good luck.

Last edited by frankbell; 10-05-2010 at 12:29 AM. Reason: grammar
1 members found this post helpful.
Old 10-26-2010, 02:01 AM   #4
LQ Newbie
Registered: Jan 2009
Distribution: Kubuntu, Bohdi, Mint Lisa
Posts: 21

Rep: Reputation: 1
This is great information to know as a FYI.
Thank you


Thread Tools Search this Thread
Search this Thread:

Advanced Search

Posting Rules
You may not post new threads
You may not post replies
You may not post attachments
You may not edit your posts

BB code is On
Smilies are On
[IMG] code is Off
HTML code is Off

Similar Threads
Thread Thread Starter Forum Replies Last Post
Questions about bring back life to an old laptop 449 Linux - Newbie 7 11-02-2008 02:23 AM
Mythbuntu front-end and back-end questions... Liambiscuit Linux - Software 4 09-28-2008 06:11 PM
...back again with questions Mr-Imbroglio Slackware 1 04-24-2006 11:31 AM
Back to Slack! Questions on dualbooting with GRUB instead of LILO Matt.Ramos Slackware - Installation 1 04-17-2006 09:23 PM
Back up Questions CloudBuilder SUSE / openSUSE 2 07-28-2005 05:33 PM > Forums > Linux Forums > Linux - Desktop

All times are GMT -5. The time now is 12:13 AM.

Main Menu
Write for LQ is looking for people interested in writing Editorials, Articles, Reviews, and more. If you'd like to contribute content, let us know.
Main Menu
RSS1  Latest Threads
RSS1  LQ News
Twitter: @linuxquestions
Facebook: linuxquestions Google+: linuxquestions
Open Source Consulting | Domain Registration