From owner-freebsd-questions@FreeBSD.ORG Thu Nov 6 19:53:37 2003 Return-Path: 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 630DD16A4CE for ; Thu, 6 Nov 2003 19:53:37 -0800 (PST) Received: from rwcrmhc13.comcast.net (rwcrmhc13.comcast.net [204.127.198.39]) by mx1.FreeBSD.org (Postfix) with ESMTP id 258EE43FDF for ; Thu, 6 Nov 2003 19:53:36 -0800 (PST) (envelope-from slave-mike@rv1.dynip.com) Received: from duron.rv1.dynip.com (c-66-177-119-177.se.client2.attbi.com[66.177.119.177]) by comcast.net (rwcrmhc13) with ESMTP id <2003110703533401500s0cj0e>; Fri, 7 Nov 2003 03:53:35 +0000 Received: from rv1.dynip.com (localhost [127.0.0.1]) by duron.rv1.dynip.com (8.12.10/8.12.10) with ESMTP id hA73rXnW062565; Thu, 6 Nov 2003 22:53:33 -0500 (EST) (envelope-from slave-mike@rv1.dynip.com) Message-ID: <3FAB173D.1090803@rv1.dynip.com> Date: Thu, 06 Nov 2003 22:53:33 -0500 From: slave-mike User-Agent: Mozilla/5.0 (X11; U; Linux i686; en-US; rv:1.4) Gecko/20030624 Netscape/7.1 X-Accept-Language: en-us, en MIME-Version: 1.0 To: Martin McCormick References: <200311062200.hA6M0uLH074820@dc.cis.okstate.edu> In-Reply-To: <200311062200.hA6M0uLH074820@dc.cis.okstate.edu> Content-Type: text/plain; charset=us-ascii; format=flowed Content-Transfer-Encoding: 7bit cc: freebsd-questions@freebsd.org Subject: Re: Extracting individual Files via tar X-BeenThere: freebsd-questions@freebsd.org X-Mailman-Version: 2.1.1 Precedence: list List-Id: User questions List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , X-List-Received-Date: Fri, 07 Nov 2003 03:53:37 -0000 you must use the f flag when manipulation files. no f flag equals attempt to access tape drive. Martin McCormick wrote: > The command > > tar ztf /usr/local/src/ports.tar.gz > > produces a table of contents just like the man page says it should. > The man page also says that individual files can be recovered or > listed but I haven't gotten that to work at all. if I try: > > $ tar zt ports/print/pstotext/ /usr/local/src/ports.tar.gz > > tar (child): /dev/sa0: Cannot open: Permission denied > tar (child): Error is not recoverable: exiting now > > gzip: stdin: unexpected end of file > tar: Child returned status 2 > tar: ports/print/pstotext: Not found in archive > tar: /usr/local/src/ports.tar.gz: Not found in archive > tar: Error exit delayed from previous errors > > In the successful test, tar obviously knew which specification > was the archive and was able to uncompress it with the z flag. The > file specification I am attempting to recover from the archive throws > tar completely off. I looked in the handbook and all the examples I > found were the more usual procedure of unpacking whole file systems > as in > > tar zxf somedir/archive.tar.gz > > I'm not having trouble with that use of tar. > > Thank you. > > Martin McCormick WB5AGZ Stillwater, OK > OSU Information Technology Division Network Operations Group > _______________________________________________ > freebsd-questions@freebsd.org mailing list > http://lists.freebsd.org/mailman/listinfo/freebsd-questions > To unsubscribe, send any mail to "freebsd-questions-unsubscribe@freebsd.org"