<html>
<head>
<meta content="text/html; charset=ISO-8859-1"
http-equiv="Content-Type">
</head>
<body text="#000000" bgcolor="#FFFFFF">
<div class="moz-cite-prefix">On 4/18/2014 5:02 AM, Paul Cartwright
wrote:<br>
</div>
<blockquote cite="mid:5350F834.3040601@gmail.com" type="cite">
<pre wrap="">ok, well my error count went to 31 sectors on /dev/sda the other day..
I've been rcping /home over to a partition on sdb, so this morning,
before I opened email, I edited /etc/fstab, commented out /home, moved
my partition on /dev/sdb to /home and.... rebooted. SO, I didn't get
that error I have been getting where it always drops me to that enter
password or Control-D to continue, it just flat booted:)
so now I have an /dev/sda with .. nothing mounted . /dev/sda3 is my
windows 7 partition, sda2 I think is the Dell recovery partition, I
forget what sda1 is..
Yesterday I did a clonezilla disk copy of /sda to a spare partition on
sdb. It errored on my /dev/sda5 /home but copied the other partitions.
I also have a nice new 2TB drive sitting here in a box. If I just
replace the old 1TB drive with the new 2TB drive and do a clonezilla
restore, will I be able to boot to grub menu? does it copy the MBR?
suggestions/comments?? am I missing something??
</pre>
</blockquote>
<font face="DejaVu Sans">(sent to both you and ALE)<br>
<br>
I love Clonezilla. It should do all you need. You might have to
use Gparted or something to expand the new drive after Clonezilla
is finished since it will think it's only the size of the original
disk (or it used to it seems).<br>
<br>
I use sfdisk (/sbin/sfdisk) to back up the mbr:<br>
<br>
/sbin/sfdisk -d /dev/sda > /<backup
directory>/mbr-backup-`date +%Y-%m-%d`.bak<br>
<br>
and fsarchiver to back up everything else on my running system:<br>
<br>
fsarchiver -A -a -v -j2 -o savefs /<backup
directory>/system-backup-`date +%Y-%m-%d`.fsa /dev/sda1<br>
<br>
My switches tell fsarchiver to:<br>
-A do a live backup of a mounted system<br>
-a don't worry if the partition is mounted without
acl/xattr options<br>
-v be verbose (sometimes don't use this)<br>
-j# use multi-core cpu (i use 2 cores)<br>
-o overwrite the archive if it exists instead of
failing<br>
<br>
I use the date command to keep track of when the backup has run.<br>
<br>
I really like how fsarchiver "doesn't care" about the size of the
disk you are putting it back onto when I do a recovery. As long
as it fits, you're good (in my experience).<br>
</font><br>
I run the following on Ubuntu/Debian systems with the sudo command
or as root (yes I like to live on the edge).<br>
<br>
***<begin my simple bash backup script>***<br>
<br>
#!/bin/bash<br>
<br>
clear<br>
<br>
echo "cleaning apt cache\n"<br>
<br>
apt-get clean<br>
<br>
echo<br>
<br>
echo "sfdisk is backing up the mbr\n"<br>
<br>
/sbin/sfdisk -d /dev/sda >
/backup-directory-here/mbr-backup-`date +%Y-%m-%d`.bak<br>
<br>
echo<br>
<br>
echo "fsarchiver is backing up system\n"<br>
<br>
fsarchiver -A -a -v -j2 -o savefs
/backup-directory-here/cool-system-name-backup-`date +%Y-%m-%d`.fsa
/dev/sda1<br>
<br>
echo<br>
<br>
echo "rsync is now making a copy of the fsarchive image\n"<br>
<br>
rsync -avh --progress /backup-directory/ /other-backup-directory/<br>
<br>
echo<br>
<br>
echo "alright. we're done here.\n"<br>
<br>
echo "$wipe"<br>
<br>
***<end my simple bash backup script>***<br>
<br>
I run that as a cron job and have it keep only the last several
(it's backing up my media server so i'm only looking at 3-4 Gig
backups).<br>
<br>
directory/partition names were changed to gloss over my childlike
admin skillz.<br>
<br>
Have a good one.<br>
<br>
Preston<br>
<pre class="moz-signature" cols="72">--
Be who you are and say what you feel, because those who mind don’t matter and those who matter don’t mind.
-Dr. Seuss
</pre>
</body>
</html>