From owner-freebsd-questions@freebsd.org Sun Jun 18 20:37:24 2017 Return-Path: Delivered-To: freebsd-questions@mailman.ysv.freebsd.org Received: from mx1.freebsd.org (mx1.freebsd.org [IPv6:2001:1900:2254:206a::19:1]) by mailman.ysv.freebsd.org (Postfix) with ESMTP id CDE4AD8D806 for ; Sun, 18 Jun 2017 20:37:24 +0000 (UTC) (envelope-from dpchrist@holgerdanske.com) Received: from holgerdanske.com (holgerdanske.com [IPv6:2001:470:0:19b::b869:801b]) (using TLSv1.2 with cipher ECDHE-RSA-AES256-GCM-SHA384 (256/256 bits)) (Client CN "holgerdanske.com", Issuer "holgerdanske.com" (not verified)) by mx1.freebsd.org (Postfix) with ESMTPS id BDDF47B219 for ; Sun, 18 Jun 2017 20:37:24 +0000 (UTC) (envelope-from dpchrist@holgerdanske.com) Received: from 99.100.19.101 ([99.100.19.101]) by holgerdanske.com with ESMTPSA (ECDHE-RSA-AES128-GCM-SHA256:TLSv1.2:Kx=ECDH:Au=RSA:Enc=AESGCM(128):Mac=AEAD) (SMTP-AUTH username dpchrist@holgerdanske.com, mechanism PLAIN) for ; Sun, 18 Jun 2017 13:37:23 -0700 From: David Christensen Subject: Re: tar: Failed to open '/dev/sa0' To: freebsd-questions@freebsd.org References: <9369978e-7041-3ef9-2cb4-66555054425b@holgerdanske.com> <9fa11efc8dc815b02b53565e468c7eb6@perso.pw> Message-ID: Date: Sun, 18 Jun 2017 13:37:22 -0700 User-Agent: Mozilla/5.0 (X11; FreeBSD i386; rv:45.0) Gecko/20100101 Thunderbird/45.6.0 MIME-Version: 1.0 In-Reply-To: <9fa11efc8dc815b02b53565e468c7eb6@perso.pw> Content-Type: text/plain; charset=windows-1252; format=flowed Content-Transfer-Encoding: 8bit X-BeenThere: freebsd-questions@freebsd.org X-Mailman-Version: 2.1.23 Precedence: list List-Id: User questions List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , X-List-Received-Date: Sun, 18 Jun 2017 20:37:24 -0000 On 06/18/17 13:21, Solène Rapenne wrote: > Je 2017-06-18 20:59, David Christensen skribis: >> 2017-06-18 11:53:14 dpchrist@freebsd ~ >> $ tar c .thunderbird > dpchrist-thunderbird-20170618.tar >> tar: Failed to open '/dev/sa0' > I think the syntax should be > > tar cf - .thunderbird > output.tar > > or > > tar cf output.tar .thunderbird > > /dev/sd0 is a tape device IIRC, tar assume you want to save to a tape > by default, that's why you have to use the f flag (to a file or to > standard output) Yes -- thank you: 2017-06-18 13:31:20 dpchrist@freebsd ~ $ tar cf - .thunderbird > output.tar 2017-06-18 13:31:37 dpchrist@freebsd ~ $ gtar cf - .thunderbird > output.gtar 2017-06-18 13:31:52 dpchrist@freebsd ~ $ ls -l output.* -rw-r--r-- 1 dpchrist dpchrist 223703040 Jun 18 13:31 output.gtar -rw-r--r-- 1 dpchrist dpchrist 223119360 Jun 18 13:31 output.tar I STFW yesterday, found that solution, and thought I had tried it. But, the tar command is issued over SSH by a Perl script running on another machine with the output piped to that other machine, so I must have confused myself with too many levels of indirection.... David