Skip site navigation (1)Skip section navigation (2)
Date:      Thu, 8 Jul 2010 12:04:58 -0500
From:      David Kelly <dkelly@hiwaay.net>
To:        Roland Smith <rsmith@xs4all.nl>
Cc:        Jozsi Avadkan <jozsi.avadkan@gmail.com>, FreeBSD Mailing list <freebsd-questions@freebsd.org>
Subject:   Re: slow down dd - how?
Message-ID:  <20100708170458.GA34226@Grumpy.DynDNS.org>
In-Reply-To: <20100708164437.GA21881@slackbox.erewhon.net>
References:  <1278604252.12047.13.camel@localhost> <20100708164437.GA21881@slackbox.erewhon.net>

next in thread | previous in thread | raw e-mail | index | archive | help
On Thu, Jul 08, 2010 at 06:44:38PM +0200, Roland Smith wrote:
> On Thu, Jul 08, 2010 at 05:50:52PM +0200, Jozsi Avadkan wrote:
> > How can I slow down dd?
> 
> Play with the block size parameter (bs). Smaller block sizes means more
> reads. The default is 512 bytes, which is very small.
>  
> > I don't want to slow down the pc, when generating a big file [~40
> > GByte].

I don't think Jozsi wants to burn more CPU cycles, just slow the
process. Perhaps to attract less attention? Or interfere less with other
processes.

Nice(1) is a good start but rtprio(1) is probably where he should look.

Also consider that writing a program of your own to serve as a slow pipe
shouldn't be very hard. Think it would be a good exercise as an
introduction to Unix programming. Simply copy stdin to stdout with a
usleep(3) between. Pipe dd through your slowpipe program.

Someone else has probably written a slow pipe. I haven't looked.

-- 
David Kelly N4HHE, dkelly@HiWAAY.net
========================================================================
Whom computers would destroy, they must first drive mad.



Want to link to this message? Use this URL: <https://mail-archive.FreeBSD.org/cgi/mid.cgi?20100708170458.GA34226>