piping output of dd through bzip2

Steve Holmes steve at holmesgrown.com
Mon Jan 14 21:15:54 EST 2002


I just did and got it to work here.

dd if=/dev/hda1 bs=1024 count=1024 |bzip >windows.img

I noticed that dd of a 3.5 gig partition was gonna take a very long time.
The output of my little test confirmed equal in and out counts but there
was no output messages from bzip2; I suppose that's normal behavior for
that program.  The bzip2 man page mentions a -c option for standard input
and output but not sure when that is actually needed.  Perhaps so if a
filename is specified but you want the output to go to stdout.  I did my
tests without the option.

On Mon, 14 Jan 2002, Jason wrote:

> did you try it with output the redirection symbol(">" [greater than sign])?
> On Monday January 14, 2002 06:07 pm, you wrote:
> > Well, bzip2 doesn't seem to work because it gave me that error.
> > Greg
> >
> > On Mon, Jan 14, 2002 at 05:58:43PM -0700, Jason wrote:
> > > ok, ok, gzip, bzip, bzip2, <insert your standard input to standard output
> > > compressor here>, whatever, they'll all work
> > >
> > > On Monday January 14, 2002 05:46 pm, you wrote:
> > > > Why should I use bzip if bzip2 gives better compression?
> > > > Greg
> > > >
> > > > On Mon, Jan 14, 2002 at 03:57:06PM -0700, Jason wrote:
> > > > > try it with 'bzip > windows.img'
> > > > >
> > > > > On Monday January 14, 2002 03:42 pm, you wrote:
> > > > > > Ok, I've just tried the following using the format indicated.
> > > > > >
> > > > > > "dd if=/dev/hda1 |bzip2 -9 windows.img"
> > > > > >
> > > > > > The result was:
> > > > > >
> > > > > > bzip2: Can't open input file windows.img: No such file or
> > > > > > directory. 9+0 records in
> > > > > > 8+0 records out
> > > > > >
> > > > > >
> > > > > > Greg
> > > > >
> > > > > _______________________________________________
> > > > > Speakup mailing list
> > > > > Speakup at braille.uwo.ca
> > > > > http://speech.braille.uwo.ca/mailman/listinfo/speakup
> > > >
> > > > _______________________________________________
> > > > Speakup mailing list
> > > > Speakup at braille.uwo.ca
> > > > http://speech.braille.uwo.ca/mailman/listinfo/speakup
> > >
> > > _______________________________________________
> > > Speakup mailing list
> > > Speakup at braille.uwo.ca
> > > http://speech.braille.uwo.ca/mailman/listinfo/speakup
> >
> > _______________________________________________
> > Speakup mailing list
> > Speakup at braille.uwo.ca
> > http://speech.braille.uwo.ca/mailman/listinfo/speakup
>
> _______________________________________________
> Speakup mailing list
> Speakup at braille.uwo.ca
> http://speech.braille.uwo.ca/mailman/listinfo/speakup
>





More information about the Speakup mailing list