From owner-freebsd-questions@FreeBSD.ORG Sun Apr 18 15:39:58 2010 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 B65D4106564A for ; Sun, 18 Apr 2010 15:39:58 +0000 (UTC) (envelope-from wblock@wonkity.com) Received: from wonkity.com (wonkity.com [67.158.26.137]) by mx1.freebsd.org (Postfix) with ESMTP id 58C968FC17 for ; Sun, 18 Apr 2010 15:39:57 +0000 (UTC) Received: from wonkity.com (localhost [127.0.0.1]) by wonkity.com (8.14.3/8.14.3) with ESMTP id o3IFdvea057714; Sun, 18 Apr 2010 09:39:57 -0600 (MDT) (envelope-from wblock@wonkity.com) Received: from localhost (wblock@localhost) by wonkity.com (8.14.3/8.14.3/Submit) with ESMTP id o3IFdvxg057711; Sun, 18 Apr 2010 09:39:57 -0600 (MDT) (envelope-from wblock@wonkity.com) Date: Sun, 18 Apr 2010 09:39:57 -0600 (MDT) From: Warren Block To: "J.D. Bronson" In-Reply-To: <4BCB07C0.8010305@sbcglobal.net> Message-ID: References: <4BCB07C0.8010305@sbcglobal.net> User-Agent: Alpine 2.00 (BSF 1167 2008-08-23) MIME-Version: 1.0 Content-Type: TEXT/PLAIN; charset=US-ASCII; format=flowed X-Greylist: Sender IP whitelisted, not delayed by milter-greylist-4.2.3 (wonkity.com [127.0.0.1]); Sun, 18 Apr 2010 09:39:57 -0600 (MDT) Cc: freebsd-questions@freebsd.org Subject: Re: Backing up freebsd to 1 file? 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: Sun, 18 Apr 2010 15:39:58 -0000 On Sun, 18 Apr 2010, J.D. Bronson wrote: > I have a freebsd 8.0 install and was wondering if it is possible to tar up > the entire install...for backup purposes. > > # cd / > # tar -cvf backup.tar {list of directories} > > then I can ftp the tar file out to another machine. > > This works in theory, but if I need to do a restore tar complains > on 'tar -xpf backup.tar'. As others have mentioned, tar is not well suited for this. > Under OpenBSD, this works as expected. It has given me an easy way > to backup/move/restore or anything I want to do w/o complaining. > > I am running Freebsd on a machine that has no other drives/tapes or anything > so my options for backup are limited. > > All I am trying to do is get a complete image (or snapshot) of my entire > install on this machine and then if I needed to reload or reinstall, I could > do a bare bones freebsd install, copy over the tar'd up file and extract it > from within / and then reboot an I would be go to go. If you don't have any other drives, where will the backup file be stored so it survives a system failure or reinstall? > Thoughts on this would be appreciated... dump/restore is the standard safe way; you can send it over ssh to back up to a file on another machine. Sometimes people use dd, which can be effective if you use some tricks like filling unused space with zero so compression is effective. There's another option. I've mentioned clonezilla.org here before as a way to back up Windows systems; it's fast and only copies used sectors. Newer beta versions of clonezilla now support UFS directly, so they can back up FreeBSD disks. This is nice because it also backs up the MBR, and splits the backup files into 2G increments. It may also be faster than dump/restore. Note that I only noticed the UFS mode lately and have only tried it once so far, so no real experience on how safe it is yet. -Warren Block * Rapid City, South Dakota USA