From owner-freebsd-questions@FreeBSD.ORG Sat Nov 3 18:05:29 2007 Return-Path: Delivered-To: freebsd-questions@freebsd.org Received: from mx1.freebsd.org (mx1.freebsd.org [IPv6:2001:4f8:fff6::34]) by hub.freebsd.org (Postfix) with ESMTP id 404ED16A418 for ; Sat, 3 Nov 2007 18:05:29 +0000 (UTC) (envelope-from uwe@laverenz.de) Received: from cg-p07-fb.rzone.de (cg-p07-fb.rzone.de [81.169.146.215]) by mx1.freebsd.org (Postfix) with ESMTP id 9958213C491 for ; Sat, 3 Nov 2007 18:05:28 +0000 (UTC) (envelope-from uwe@laverenz.de) Received: from mo-p07-ob.rzone.de (mrclete-mo-p07-ob.mail [192.168.63.176]) by gibbsson-fb-06.store (RZmta 14.0) with ESMTP id P02870jA3F251M for ; Sat, 3 Nov 2007 18:35:00 +0100 (MET) (envelope-from: ) Received: from athena.laverenz.de (p5480E7EA.dip.t-dialin.net [84.128.231.234]) by post.webmailer.de (mrclete mo3) (RZmta 14.0) with ESMTP id g01b81jA3G84jK for ; Sat, 3 Nov 2007 18:33:33 +0100 (MET) (envelope-from: ) Received: from localhost (localhost.localdomain [127.0.0.1]) by athena.laverenz.de (Postfix) with ESMTP id 7469EE0AA24C for ; Sat, 3 Nov 2007 18:33:33 +0100 (CET) Received: from athena.laverenz.de ([127.0.0.1]) by localhost (athena [127.0.0.1]) (amavisd-new, port 10024) with LMTP id 12782-02 for ; Sat, 3 Nov 2007 18:32:11 +0100 (CET) Received: by athena.laverenz.de (Postfix, from userid 2000) id BD48FE0AA246; Sat, 3 Nov 2007 18:32:10 +0100 (CET) Date: Sat, 3 Nov 2007 18:32:10 +0100 From: Uwe Laverenz To: freebsd-questions@freebsd.org Message-ID: <20071103173210.GA12558@laverenz.de> Mail-Followup-To: freebsd-questions@freebsd.org References: <003e01c81cf2$27ff3840$77fda8c0$@com> Mime-Version: 1.0 Content-Type: text/plain; charset=us-ascii Content-Disposition: inline In-Reply-To: <003e01c81cf2$27ff3840$77fda8c0$@com> Organization: private site Sender: uwe@laverenz.de User-Agent: Mutt/1.5.9i X-Virus-Scanned: by amavisd-new-20030616-p10 (Debian) at laverenz.de X-RZG-AUTH: l30WrtbrzmfyRJtZ7/TtK2qIdZIgjE9K4Q55TXGhenj8TX5ShWTsXpHkgawlIgdqbQ== X-RZG-CLASS-ID: mo07 Subject: Re: Duplicate existing FreeBSD Server in VM X-BeenThere: freebsd-questions@freebsd.org X-Mailman-Version: 2.1.5 Precedence: list List-Id: User questions List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , X-List-Received-Date: Sat, 03 Nov 2007 18:05:29 -0000 On Fri, Nov 02, 2007 at 12:46:09PM +1100, Terry Sposato wrote: > I have just installed a machine and have it setup running a web based CRM > solution. I want to have an exact duplicate of this machine running as a VM > for redundancy reasons. The best and easiest way I know of is using /usr/ports/net/rsync for this task. I often used it to move BSD or Linux systems to new hardware or transfer them into a VM. I usually make sure that the kernel supports all important hardware on the target machine and that /etc/fstab is correct. After that I start to transfer filesystem after filesystem with e.g.: # rsync -avxH --delete --exclude /etc/fstab / root@target:/ You might want to exclude other files (e.g. /etc/rc.conf) from being overwritten, I guess. The nice thing with rsync is that only diffs are transferred, so it would be easy and fast to keep your VM in sync with the source machine. Uwe P.S.: Yesterday I moved a FreeBSD 4.5 system from a Proliant 3000 (~7 years old) to a VMware Server VM using rsync. All I had to take care of was the use of a GENERIC kernel, a new /etc/fstab and a changed ifconfig line in /etc/rc.conf.