Solved

How to backup a Kubuntu System partition?

Posted on 2010-09-20
9
821 Views
Last Modified: 2013-12-16
Hi

How to backup a Kubuntu System partition?
I saw Partimage is a solution. But one of my friends told you could also copy all files from the system partioton to another. Will this work to restore the system, is this true?

What is the best practice?

Thanks!
0
Comment
Question by:*** Hopeleonie ***
  • 3
  • 2
  • 2
  • +2
9 Comments
 
LVL 6

Assisted Solution

by:Ferrosti
Ferrosti earned 50 total points
ID: 33718392
I usually don't backup my system like this. Ubuntu is set up very fast, so I usually go for my data as well as my home directory.
Since I play around with my system a lot it is more reliable to set it up and put back my home directory. That's all.

In your case the bootsector won't be backed up, so you'd either have to install it new or really go the partimage way.
0
 
LVL 2

Accepted Solution

by:
mobilescholar earned 250 total points
ID: 33718493
Partimage is very useful. If you are new to linux, you could try Clonezilla (http://clonezilla.org/) which has a user-friendly front-end to utilities like partimage.

What backup scheme are you going to use (daily, weekly, monthly) and to what medium (an internal/external disk, burn to DVD, tape drive? Is this a business server or a home desktop?

For my home server, I just backup my /home/ directory weekly and just keep an install disk handy (and a list of the system modifications I make).

0
 
LVL 19

Author Comment

by:*** Hopeleonie ***
ID: 33718552
First thanks you both!

@mobilescholar
Home desktop. This is just for testing and fun. :-)
0
Master Your Team's Linux and Cloud Stack!

The average business loses $13.5M per year to ineffective training (per 1,000 employees). Keep ahead of the competition and combine in-person quality with online cost and flexibility by training with Linux Academy.

 
LVL 16

Assisted Solution

by:gelonida
gelonida earned 150 total points
ID: 33718896
I only make partial backups
- /etc
- /home
- /root


I use rsync for this task.




0
 
LVL 6

Assisted Solution

by:Jelcin
Jelcin earned 50 total points
ID: 33719641
If you want a complete image of a hdd you can use "dd if=/dev/sda(x) of=/home/user/image.img".
You can than mount this image with mount -o loop, offset=x /home/user/image.img /mnt/image.
Or write it to another hdd by changing if target with of target.
This is good if you want a full backup of your hdd including mbr and partition table or a backup of a single partition.
0
 
LVL 16

Expert Comment

by:gelonida
ID: 33719686
Jelcin,

I agree with the dd command
however if I didn't overlook something, then no offset should be specified for the mount command
0
 
LVL 16

Assisted Solution

by:gelonida
gelonida earned 150 total points
ID: 33719813
hopeleonie,

making an image of your system partition is a rather safe way of backing up the system.

However please note, that backing up the system partition means, that the system partition should be mounted read-only (or not at all)


if your system partition isn't too big and and you don't want to backup your system partition too often, then
dd is a nice option.

if you do not intend to perform a loopback mount of your backup, then you could compress it.

Example
dd if=/dev/sda(x) | gzip > /home/user/image.img.gz

this might be useful in case you wanted to store multiple generations of your file system

If you wanted to mount the image file later on, then you had to uncompress it
(However you would need enough disk space on your backup medium to store the compressed AND uncompressed version.

You could also look at fsarchiver, though I never tried it personally
http://www.fsarchiver.org/Main_Page


http://www.fsarchiver.org/Main_Page

0
 
LVL 6

Expert Comment

by:Jelcin
ID: 33719995
Gelonida,

you can use offset if you do a full backup of the complete hdd with several partitions. With offset you can than specify where the single partitions within full hdd backup you want to mount start.
0
 
LVL 19

Author Comment

by:*** Hopeleonie ***
ID: 33728288
Made a mistake want to give 100 points to gelonida ID 33719813. Total 500 Points.

Sorry Moderator!
Leonie
0

Featured Post

Master Your Team's Linux and Cloud Stack!

The average business loses $13.5M per year to ineffective training (per 1,000 employees). Keep ahead of the competition and combine in-person quality with online cost and flexibility by training with Linux Academy.

Question has a verified solution.

If you are experiencing a similar issue, please ask a related question

Suggested Solutions

Title # Comments Views Activity
Penetration Testing home based work 3 91
centos linux 65 159
How to enable sync between two yum repo? 1 41
centos commands 6 69
In my business, I use the LTS (Long Term Support) versions of Linux. My workstations do real work, and so I rarely have the patience to deal with silly problems caused by an upgraded kernel that had experimental software on it to begin with from a r…
You ever wonder how to backup Linux system files just like Windows System Restore?  Well you can use Timeshift in Linux to perform those similar action.  This tutorial will show you how to backup your system files and keep regular intervals. Note…
Learn several ways to interact with files and get file information from the bash shell. ls lists the contents of a directory: Using the -a flag displays hidden files: Using the -l flag formats the output in a long list: The file command gives us mor…
This demo shows you how to set up the containerized NetScaler CPX with NetScaler Management and Analytics System in a non-routable Mesos/Marathon environment for use with Micro-Services applications.

820 members asked questions and received personalized solutions in the past 7 days.

Join the community of 500,000 technology professionals and ask your questions.

Join & Ask a Question