Deutsch   English   Français   Italiano  
<vhtjh0$1s5d5$11@dont-email.me>

View for Bookmarking (what is this?)
Look up another Usenet article

Path: ...!eternal-september.org!feeder2.eternal-september.org!news.eternal-september.org!.POSTED!not-for-mail
From: Lawrence D'Oliveiro <ldo@nz.invalid>
Newsgroups: comp.os.linux.misc
Subject: Re: Are We Back to the "Wars" Now ?
Date: Sat, 23 Nov 2024 22:04:17 -0000 (UTC)
Organization: A noiseless patient Spider
Lines: 24
Message-ID: <vhtjh0$1s5d5$11@dont-email.me>
References: <Sp-cnSz8UupYQaf6nZ2dnZfqnPednZ2d@earthlink.com>
	<vhf5ts$16rpr$1@dont-email.me> <vhfjtj$19ijm$1@dont-email.me>
	<vhja6j$23f5e$4@dont-email.me> <vhmm4c$hnbj$1@dont-email.me>
	<vhmn2t$hv8i$3@dont-email.me> <vhnikj$me7m$1@dont-email.me>
	<vhoaau$qjkl$1@dont-email.me>
	<lIqcnTlkpf_Jtd36nZ2dnZfqn_udnZ2d@earthlink.com>
	<vhp9hs$12qaa$2@dont-email.me>
	<v4adnSK1nItcwNz6nZ2dnZfqnPWdnZ2d@earthlink.com>
	<vhrolu$1jata$1@dont-email.me>
	<Oo6dnZb3z-NT6Nz6nZ2dnZfqnPednZ2d@earthlink.com>
	<vhs0vs$1k6ft$2@dont-email.me> <sh291lxvc7.ln2@Telcontar.valinor>
MIME-Version: 1.0
Content-Type: text/plain; charset=UTF-8
Content-Transfer-Encoding: 8bit
Injection-Date: Sat, 23 Nov 2024 23:04:17 +0100 (CET)
Injection-Info: dont-email.me; posting-host="2fd1218dfbbc8c3afa5bbf19b4966652";
	logging-data="1971621"; mail-complaints-to="abuse@eternal-september.org";	posting-account="U2FsdGVkX1/bovS9T6bjkvM5NVLLocdM"
User-Agent: Pan/0.161 (Chasiv Yar; )
Cancel-Lock: sha1:7qrjyFYpASt2Syi0ER4KJsg1LuI=
Bytes: 2330

On Sat, 23 Nov 2024 14:39:40 +0100, Carlos E.R. wrote:

> I use named pipes on my backup script.
> 
> I dd a hard disk partition, compress it, and at the same time calculate
> a checksum.
> 
>      mkfifo mdpipe
>      dd if=/dev/$1  status=progress  bs=16M | tee mdpipe | pigz -3 > $3.gz &
>      md5sum -b mdpipe | tee -a md5checksum_expanded
>      wait
>      rm mdpipe
>      echo "$3" >> md5checksum_expanded
> 
> This way there is only one disk read operation. I can see the thing
> running at max hard disk speed.

Clever. Just one thing, I would probably use a dynamic name for the
pipe and put it in $TMPDIR (e.g. generated with tempfile) so that 1)
multiple instances could run at once, and 2) it doesn’t depend on
writing into the current directory, whatever that might be.

(It’s likely neither of those issues is relevant to your particular
use case ...)