From owner-freebsd-questions@FreeBSD.ORG Fri Jul 8 03:20:55 2005 Return-Path: X-Original-To: freebsd-questions@freebsd.org 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 AF33116A41C for ; Fri, 8 Jul 2005 03:20:55 +0000 (GMT) (envelope-from drew@mykitchentable.net) Received: from relay03.roc.ny.frontiernet.net (relay03.roc.ny.frontiernet.net [66.133.182.166]) by mx1.FreeBSD.org (Postfix) with ESMTP id 4ED5743D48 for ; Fri, 8 Jul 2005 03:20:54 +0000 (GMT) (envelope-from drew@mykitchentable.net) Received: from filter03.roc.ny.frontiernet.net (filter03.roc.ny.frontiernet.net [66.133.183.70]) by relay03.roc.ny.frontiernet.net (Postfix) with ESMTP id 2CD77358D59 for ; Fri, 8 Jul 2005 03:20:54 +0000 (UTC) Received: from relay03.roc.ny.frontiernet.net ([66.133.182.166]) by filter03.roc.ny.frontiernet.net (filter03.roc.ny.frontiernet.net [66.133.183.70]) (amavisd-new, port 10024) with LMTP id 00688-03-7 for ; Fri, 8 Jul 2005 03:20:54 +0000 (UTC) Received: from blacklamb.mykitchentable.net (67-137-46-191.dsl2.elk.ca.frontiernet.net [67.137.46.191]) by relay03.roc.ny.frontiernet.net (Postfix) with ESMTP id BD496358716 for ; Fri, 8 Jul 2005 03:20:52 +0000 (UTC) Received: from [192.168.1.3] (bigdaddy.mykitchentable.net [192.168.1.3]) (using TLSv1 with cipher DHE-RSA-AES256-SHA (256/256 bits)) (No client certificate requested) by blacklamb.mykitchentable.net (Postfix) with ESMTP id C96903BF3D1 for ; Thu, 7 Jul 2005 20:20:51 -0700 (PDT) Message-ID: <42CDF112.5070209@mykitchentable.net> Date: Thu, 07 Jul 2005 20:20:50 -0700 From: Drew Tomlinson User-Agent: Mozilla Thunderbird 1.0 (Windows/20041206) X-Accept-Language: en-us, en MIME-Version: 1.0 To: FreeBSD Questions Content-Type: text/plain; charset=ISO-8859-1; format=flowed Content-Transfer-Encoding: 7bit X-Virus-Scanned: by amavisd-new-20040701 (2.0) at filter03.roc.ny.frontiernet.net Subject: tar Syntax Help 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: Fri, 08 Jul 2005 03:20:55 -0000 I'm trying to copy an entire file system while using an exclude file to avoid copying things such as /dev, /proc, etc. I've read the man page and found the -X or --exclude-from tar option. I've create a file called /exclude.list. It contains lines such as: /exclude.list /dev /proc But I can't figure out how to form the correct command line. I basically want to do this: tar -cvf - --exclude-from /exclude.list -C / . | tar xpf - -C . I've search the web and found examples that look similar to the above but this does not work for me. tar attempts to copy /dev and I get all the associated errors. I've tried other placements of either "-X", "X", and "--exclude from" on the command line various things happen from it just being ignored to tar thinking I want to create and archive named "-X", etc., to tar trying to add a file named "-X", etc. to the current archive. I'm at a loss. I'm using 4.11 and trying to make a good backup before upgrading to 5.4. Can anyone tell me the secret incantation to make this work? Thanks, Drew -- Visit The Alchemist's Warehouse Magic Tricks, DVDs, Videos, Books, & More! http://www.alchemistswarehouse.com