From owner-freebsd-questions Mon Oct 7 6:30: 2 2002 Delivered-To: freebsd-questions@freebsd.org Received: from mx1.FreeBSD.org (mx1.freebsd.org [216.136.204.125]) by hub.freebsd.org (Postfix) with ESMTP id 30A8837B401 for ; Mon, 7 Oct 2002 06:29:59 -0700 (PDT) Received: from smtprelay6.dc2.adelphia.net (smtprelay6.dc2.adelphia.net [64.8.50.38]) by mx1.FreeBSD.org (Postfix) with ESMTP id B5EE643E88 for ; Mon, 7 Oct 2002 06:29:57 -0700 (PDT) (envelope-from barbish@a1poweruser.com) Received: from barbish ([68.65.175.62]) by smtprelay6.dc2.adelphia.net (Netscape Messaging Server 4.15 smtprelay6 Dec 7 2001 09:58:59) with SMTP id H3M5HW03.GA6 for ; Mon, 7 Oct 2002 09:29:56 -0400 Reply-To: From: "JoeB" To: "FBSDQ" Subject: RE: Ghost to image bkup FBSD(SOLUTION) Date: Mon, 7 Oct 2002 09:29:55 -0400 Message-ID: MIME-Version: 1.0 Content-Type: text/plain; charset="us-ascii" Content-Transfer-Encoding: 7bit X-Priority: 3 (Normal) X-MSMail-Priority: Normal X-Mailer: Microsoft Outlook IMO, Build 9.0.2416 (9.0.2911.0) X-MimeOLE: Produced By Microsoft MimeOLE V6.00.2600.0000 In-Reply-To: Importance: Normal Sender: owner-freebsd-questions@FreeBSD.ORG Precedence: bulk List-ID: List-Archive: (Web Archive) List-Help: (List Instructions) List-Subscribe: List-Unsubscribe: X-Loop: FreeBSD.ORG For the archives The question of using the Norton Ghost program to make an single flat image file of an hard drives partition containing FBSD has been asked many times on this list. UP until now the answer has all ways been that the benefits of using Ghost on a MS/win partition can not be achieved when used on a FBSD slice because the ghost created image file contains all the unused space as well as the used space. Jacob S. Barrett had the idea of zeroing out the unused space before running ghost so ghost will compress all the zero filled space resulting in an image file size and elapse run time comparable to what you would achieve on a MS/win partition. This is a great work around. Before running the Ghost program from native booted ms/dos you have to run this command on FBSD before shutting FBSD down. dd if=/dev/zero of=filler bs=1m ; rm filler Below is the original thread > -----Original Message----- > From: owner-freebsd-questions@FreeBSD.ORG > [mailto:owner-freebsd-questions@FreeBSD.ORG]On Behalf Of Dan Nelson > Sent: Friday, October 04, 2002 10:33 AM > To: Jacob S. Barrett > Cc: freebsd-questions@FreeBSD.ORG > Subject: Re: Block Zeroing Tool > > In the last episode (Oct 04), Jacob S. Barrett said: > >>Is there a tool for FreeBSD that zeros the unallocated blocks on a >>filesystem? >> >>The company I work for has an image on demand system for our lab >>machines. This system relies on ghost which only supports file by >>file imaging on certain file systems. I want to take disk images of >>certain FreeBSD installations. Ghost will only take sector by sector >>images of FreeBSD partitions. Since it is doing this it stores all >>the "junk" unused blocks as well. This makes for a very large image >>even with high compression. If I can zero out the unused blocks >>before taking the image with high compression the image size should >>be much smaller. >> >>So, is there utility to zero out those blocks? Does this make sense? >>Is there a better way to take images of FreeBSD machines? > > > dd if=/dev/zero of=filler bs=1m ; rm filler > > > > I also have tried to use ghost to make image backups of FBSD, > but the image is the same size as the FBSD slice. > Have you tested the solution posted above to zero out the unused > disk space in the FBSD slice so ghost will only image bkup real data? > Did it work like you hoped? > Yes I have tested it, and it works great. Be sure to turn compression on to high to get the best results. Here is what I saw after zeroing the unallocated blocks using the dd command. FreeBSD partition size: 11G Allocated space: 6G Ghost image size: 3.4G Before zeroing out the images on this box were between 8-9G. Needless to say our IT guy is much happier that my box isn't chewing up 9G per image on the system anymore. And I am happy that imaging this machine only takes an hour now rather than 4. -Jake -- Jacob S. Barrett jbarrett@amduat.net www.amduat.net To Unsubscribe: send mail to majordomo@FreeBSD.org with "unsubscribe freebsd-questions" in the body of the message