Page MenuHomeFreeBSD

docs/41089 pax(1) -B option does not mention interaction with -z option
ClosedPublic

Authored by crees on Dec 29 2018, 9:52 PM.
Tags
Referenced Files
Unknown Object (File)
Mon, Mar 11, 4:02 PM
Unknown Object (File)
Mon, Mar 11, 4:02 PM
Unknown Object (File)
Mon, Mar 11, 4:02 PM
Unknown Object (File)
Fri, Mar 8, 2:11 AM
Unknown Object (File)
Jan 4 2024, 1:31 AM
Unknown Object (File)
Jan 4 2024, 1:14 AM
Unknown Object (File)
Jan 4 2024, 1:14 AM
Unknown Object (File)
Jan 4 2024, 12:48 AM
Subscribers

Details

Summary

I've taken the patch supplied in the PR, but added a cross-reference to zip(1) to make files to span floppies etc (if anyone still fancies doing that).

-B option of pax says that it limits the number of bytes
written to a volume, but when the -z option is also used
the number of bytes written is less than that specified,
by the compression ratio. For example, see
How-To-Repeat.

Fix:

Add a sentence or two to the description of the -B option
along the lines of:
"Note that the specified size is for the pax image
itself. If the -z option is also used, the resulting
file may contain fewer bytes, according to the
compressibility of the archive contents."

Alternatively, perhaps the pax author could be persuaded
to run the archive size counter on the _output_ of the
gzip pipe? That would certainly be more useful.
How-To-Repeat: You won't get the same result, because you don't have my
file system contents, but any file tree should do (other
than one full of MP3 files or the like...)
pax -w -t -z -f /backup/full-${today_d}.pax -B667m $dirs
resulted in the warning message
"pax: User specified archive volume byte limit reached."
but a subsequent listing of the /backup directory shows:
-rw-r--r-- 1 root wheel 352215042 Jul 29 03:11 full-020729.pax

Diff Detail

Repository
rS FreeBSD src repository - subversion
Lint
Lint Not Applicable
Unit
Tests Not Applicable

Event Timeline

pax.1
817 ↗(On Diff #52409)

Pet igor

916 ↗(On Diff #52409)

Pet igor

bcr added a subscriber: bcr.

Igor feels certainly petted enough, so I approve. ;-)

This revision is now accepted and ready to land.Dec 29 2018, 10:50 PM
This revision was automatically updated to reflect the committed changes.
crees retitled this revision from docs/31089 pax(1) -B option does not mention interaction with -z option to docs/41089 pax(1) -B option does not mention interaction with -z option.Dec 29 2018, 11:09 PM