[Date Prev][Date Next] [Thread Prev][Thread Next] [Date Index] [Thread Index]

Re: Gzip problems



* Larry (doccpu@yahoo.com) [030620 15:14]:
> 
> --- Mark Ferlatte <ferlatte@cryptio.net> wrote:
> > I forget: was there a reason you didn't want to use
> > tar?  That's usually what I do:
> 
> The media I used wouldn't hold an entire directory,
> and gziping the files let me copy to the media till it
> was full, then again, etc.

You can use tar, as Mark suggested, to create one big, compressed file.
Then you can use split to cut it up into floppy-sized chunks, copy these
to floppies, and use cat to restore it on the other side.

Or, if you want to string it all together:

tar cjv ./mydirectory | split -b $((1440*1024))
Then you have a bunch of files xaa, xab, xac, ... each is 1440KiB, ready
to stick on floppies:
dd if=xaa of=/dev/fd0 bs=1440K count=1
dd if=xab of=/dev/fd0 bs=1440K count=1
:
:
Of course, use a different floppy for each =)

then, on the other machine:
dd if=/dev/fd0 of=xaa bs=1440K count=1
dd if=/dev/fd0 of=xab bs=1440K count=1
:
:
tar xjv < x??

Untested, but it should work =)

It will be more efficient than doing a few files at a time: you'll be
less likely to miss something, and you'll fill each floppy to capacity,
along with (probably) getting better compression.  This will also take
care of any files that are too big to fit on the media, i.e. they're
bigger than 1440KiB even when compressed.

good times,
Vineet
-- 
http://www.doorstop.net/
-- 
"Those who desire to give up freedom in order to gain security will not
have, nor do they deserve, either one."  --President Thomas Jefferson

Attachment: signature.asc
Description: Digital signature


Reply to: