public inbox for gentoo-user@lists.gentoo.org
 help / color / mirror / Atom feed
From: Alex Schuster <wonko@wonkology.org>
To: gentoo-user@lists.gentoo.org
Subject: Re: [gentoo-user] When copying an os to new disk
Date: Fri, 26 Feb 2010 17:00:22 +0100	[thread overview]
Message-ID: <201002261700.23925.wonko@wonkology.org> (raw)
In-Reply-To: <854dca5c1002260746k48e40be4pcc4d4b6ece79add2@mail.gmail.com>

Kyle Bader writes:

> > I opted to reinstall from source that machine, which wasn't exactly a
> > bad choice anyway.  But as always, rtfm is good advice!  Thanks (not
> > sarcastic, except to mock myself).
> 
> Another option other than rsync or dd is to use tar:

Yeah, that's what I usually do.n The fastest method probably is star, 
but the syntax is a little different.

> tar cf - $old_dir | ( cd $new_dir: tar xf - )
> tar cf - $old_dir | ssh $other_host "( cd $new_dir: tar xf - )"
                                                    ^
The ':' separating commands should be a ';'. Using the -C option would be 
a little easier, but your method also would work for star. This piping 
through ssh is quite cool, isn't it.

If $old_dir is the root partition, I would bin-mount it first to somewhere 
else, so other directories mounted to it (especially/dev, /proc and /sys) 
are not copied:
mount -o bind / /mnt
old_dir=/mnt

	Wonko



  reply	other threads:[~2010-02-26 16:00 UTC|newest]

Thread overview: 12+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2010-02-19 20:34 [gentoo-user] When copying an os to new disk Harry Putnam
2010-02-19 20:58 ` Daniel Troeder
2010-02-19 21:25 ` Volker Armin Hemmann
2010-02-20  9:50   ` Xi Shen
2010-02-22  7:49 ` daid kahl
2010-02-25 17:59   ` daid kahl
2010-02-26  1:06     ` Stroller
2010-02-26 11:59       ` daid kahl
2010-02-26 15:46         ` Kyle Bader
2010-02-26 16:00           ` Alex Schuster [this message]
2010-02-26 18:13             ` Kyle Bader
2010-02-26 23:25             ` Neil Bothwick

Reply instructions:

You may reply publicly to this message via plain-text email
using any one of the following methods:

* Save the following mbox file, import it into your mail client,
  and reply-to-all from there: mbox

  Avoid top-posting and favor interleaved quoting:
  https://en.wikipedia.org/wiki/Posting_style#Interleaved_style

* Reply using the --to, --cc, and --in-reply-to
  switches of git-send-email(1):

  git send-email \
    --in-reply-to=201002261700.23925.wonko@wonkology.org \
    --to=wonko@wonkology.org \
    --cc=gentoo-user@lists.gentoo.org \
    /path/to/YOUR_REPLY

  https://kernel.org/pub/software/scm/git/docs/git-send-email.html

* If your mail client supports setting the In-Reply-To header
  via mailto: links, try the mailto: link
Be sure your reply has a Subject: header at the top and a blank line before the message body.
This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox