a2p
accept
access
acct
addftinfo
addr2line
adjtime
afmtodit
after
aio_cancel
aio_error
aio_read
aio_return
aio_suspend
aio_waitcomplete
aio_write
alias
aliases
alloc
anvil
append
apply
apropos
ar
array
as
asa
asn1parse
at
atq
atrm
attemptckalloc
attemptckrealloc
authlib
authtest
autopoint
awk
b64decode
b64encode
basename
batch
bc
bdes
bell
bg
bgerror
biff
big5
binary
bind
bindkey
bindtags
bindtextdomain
bio
bitmap
blowfish
bn
bootparams
bootptab
bounce
brandelf
break
breaksw
brk
bsdiff
bsdtar
bsnmpd
bspatch
bthost
btsockstat
buffer
builtin
builtins
bunzip2
button
byacc
bzcat
bzegrep
bzfgrep
bzgrep
bzip2
c2ph
c89
c99
ca
cal
calendar
canvas
cap_mkdb
case
cat
catch
catman
cc
cd
cdcontrol
chdir
checkbutton
checknr
chflags
chfn
chgrp
chio
chkey
chmod
chown
chpass
chroot
chsh
ci
ciphers
ckalloc
ckdist
ckfree
ckrealloc
cksum
cleanup
clear
clipboard
clock
clock_getres
clock_gettime
clock_settime
close
cmp
co
col
colcrt
colldef
colors
colrm
column
comm
command
compile_et
complete
compress
concat
config
connect
console
continue
core
courierlogger
couriertcpd
cp
cpan
cpio
cpp
creat
crl
crontab
crunchgen
crunchide
crypt
crypto
csh
csplit
ctags
ctm
ctm_dequeue
ctm_rmail
ctm_smail
cu
cursor
cursors
cut
cvs
date
dbiprof
dbiproxy
dc
dcgettext
dcngettext
dd
dde
default
defer
deliverquota
des
destroy
devfs
df
dgettext
dgst
dh
dhparam
dialog
diff
diff3
dig
dir
dirent
dirname
dirs
discard
disktab
dngettext
do
domainname
done
dprofpp
dsa
dsaparam
dtmfdecode
du
dup
dup2
eaccess
ec
ecdsa
echo
echotc
ecparam
ed
edit
editrc
ee
egrep
elf
elfdump
elif
else
enc
enc2xs
encoding
end
endif
endsw
engine
enigma
entry
env
envsubst
eof
eqn
err
errno
error
errstr
esac
ethers
euc
eui64
eval
event
evp
ex
exec
execve
exit
expand
export
exports
expr
extattr
extattr_delete_fd
extattr_delete_file
extattr_get_fd
extattr_get_file
extattr_set_fd
extattr_set_file
f77
false
famm
famx
fblocked
fbtab
fc
fchdir
fchflags
fchmod
fchown
fcntl
fconfigure
fcopy
fdescfs
fdformat
fdread
fdwrite
fetch
fg
fgrep
fhopen
fhstat
fhstatfs
fi
file
file2c
fileevent
filename
filetest
find
find2perl
finger
flex
flock
flush
fmt
focus
fold
font
fontedit
for
foreach
fork
format
forward
fpathconf
frame
from
fs
fstab
fstat
fstatfs
fsync
ftp
ftpchroot
ftpusers
ftruncate
futimes
g711conv
gb2312
gb18030
gbk
gcc
gcore
gcov
gdb
gencat
gendsa
genrsa
gensnmptree
getconf
getdents
getdirentries
getdtablesize
getegid
geteuid
getfacl
getfh
getfsstat
getgid
getgroups
getitimer
getlogin
getopt
getopts
getpeername
getpgid
getpgrp
getpid
getppid
getpriority
getresgid
getresuid
getrlimit
getrusage
gets
getsid
getsockname
getsockopt
gettext
gettextize
gettimeofday
gettytab
getuid
glob
global
gmake
goto
gperf
gprof
grab
grep
grid
grn
grodvi
groff
groff_font
groff_out
groff_tmac
grog
grolbp
grolj4
grops
grotty
group
groups
gunzip
gzcat
gzexe
gzip
h2ph
h2xs
hash
hashstat
hd
head
help2man
hesinfo
hexdump
history
host
hostname
hosts
hosts_access
hosts_options
hpftodit
http
hup
i386_get_ioperm
i386_get_ldt
i386_set_ioperm
i386_set_ldt
i386_vm86
iconv
id
ident
idprio
if
ifnames253
ifnames259
image
imapd
incr
indent
indxbib
info
infokey
inode
install
instmodsh
interp
intro
introduction
ioctl
ipcrm
ipcs
ipf
ipftest
ipnat
ippool
ipresend
issetugid
jail
jail_attach
jobid
jobs
join
jot
kbdcontrol
kbdmap
kcon
kdestroy
kdump
kenv
kevent
keycap
keylogin
keylogout
keymap
keysyms
kgdb
kill
killall
killpg
kinit
kldfind
kldfirstmod
kldload
kldnext
kldstat
kldsym
kldunload
klist
kpasswd
kqueue
kse
kse_create
kse_exit
kse_release
kse_switchin
kse_thr_interrupt
kse_wakeup
ktrace
label
labelframe
lam
lappend
last
lastcomm
lastlog
lchflags
lchmod
lchown
ld
ldap
ldapadd
ldapcompare
ldapdelete
ldapmodify
ldapmodrdn
ldappasswd
ldapsearch
ldapwhoami
ldd
leave
less
lesskey
lex
lgetfh
lhash
libnetcfg
library
limit
limits
lindex
link
linprocfs
linsert
lint
lio_listio
list
listbox
listen
lj4_font
lkbib
llength
lmtp
ln
load
loadfont
local
locale
locate
lock
lockf
log
logger
login
logins
logname
logout
look
lookbib
lorder
lower
lp
lpq
lpr
lprm
lptest
lrange
lreplace
ls
lsearch
lseek
lset
lsort
lstat
lsvfs
lutimes
lynx
m4
madvise
magic
mail
maildiracl
maildirkw
maildirmake
mailq
mailx
make
makeinfo
makewhatis
man
manpath
master
mc
mcedit
mcview
md2
md4
md5
mdc2
memory
menu
menubar
menubutton
merge
mesg
message
mincore
minherit
minigzip
mkdep
mkdir
mkfifo
mkimapdcert
mklocale
mknod
mkpop3dcert
mkstr
mktemp
mlock
mlockall
mmap
mmroff
modfind
modfnext
modnext
modstat
moduli
more
motd
mount
mprotect
mptable
msdos
msdosfs
msgattrib
msgcat
msgcmp
msgcomm
msgconv
msgen
msgexec
msgfilter
msgfmt
msggrep
msginit
msgmerge
msgs
msgunfmt
msguniq
mskanji
msql2mysql
msync
mt
munlock
munlockall
munmap
mv
myisamchk
myisamlog
myisampack
mysql
mysqlaccess
mysqladmin
mysqlbinlog
mysqlcheck
mysqld
mysqldump
mysqld_multi
mysqld_safe
mysqlhotcopy
mysqlimport
mysqlshow
mysql_config
mysql_fix_privilege_tables
mysql_zap
namespace
nanosleep
nawk
nc
ncal
ncplist
ncplogin
ncplogout
neqn
netconfig
netgroup
netid
netstat
networks
newaliases
newgrp
nex
nfsstat
nfssvc
ngettext
nice
nl
nm
nmount
nohup
nologin
notify
nroff
nseq
nslookup
ntp_adjtime
ntp_gettime
nvi
nview
objcopy
objdump
objformat
ocsp
od
onintr
open
openssl
opieaccess
opieinfo
opiekey
opiekeys
opiepasswd
option
options
oqmgr
pack
package
packagens
pagesize
palette
pam_auth
panedwindow
parray
passwd
paste
patch
pathchk
pathconf
pawd
pax
pbm
pcre
pcreapi
pcrebuild
pcrecallout
pcrecompat
pcrecpp
pcregrep
pcrematching
pcrepartial
pcrepattern
pcreperform
pcreposix
pcreprecompile
pcresample
pcretest
perl
perl56delta
perl58delta
perl561delta
perl570delta
perl571delta
perl572delta
perl573delta
perl581delta
perl582delta
perl583delta
perl584delta
perl585delta
perl586delta
perl587delta
perl588delta
perl5004delta
perl5005delta
perlaix
perlamiga
perlapi
perlapio
perlapollo
perlartistic
perlbeos
perlbook
perlboot
perlbot
perlbs2000
perlbug
perlcall
perlcc
perlce
perlcheat
perlclib
perlcn
perlcompile
perlcygwin
perldata
perldbmfilter
perldebguts
perldebtut
perldebug
perldelta
perldgux
perldiag
perldoc
perldos
perldsc
perlebcdic
perlembed
perlepoc
perlfaq
perlfaq1
perlfaq2
perlfaq3
perlfaq4
perlfaq5
perlfaq6
perlfaq7
perlfaq8
perlfaq9
perlfilter
perlfork
perlform
perlfreebsd
perlfunc
perlglossary
perlgpl
perlguts
perlhack
perlhist
perlhpux
perlhurd
perlintern
perlintro
perliol
perlipc
perlirix
perlivp
perljp
perlko
perllexwarn
perllinux
perllocale
perllol
perlmachten
perlmacos
perlmacosx
perlmint
perlmod
perlmodinstall
perlmodlib
perlmodstyle
perlmpeix
perlnetware
perlnewmod
perlnumber
perlobj
perlop
perlopenbsd
perlopentut
perlos2
perlos390
perlos400
perlothrtut
perlpacktut
perlplan9
perlpod
perlpodspec
perlport
perlqnx
perlre
perlref
perlreftut
perlrequick
perlreref
perlretut
perlrun
perlsec
perlsolaris
perlstyle
perlsub
perlsyn
perlthrtut
perltie
perltoc
perltodo
perltooc
perltoot
perltrap
perltru64
perltw
perlunicode
perluniintro
perlutil
perluts
perlvar
perlvmesa
perlvms
perlvos
perlwin32
perlxs
perlxstut
perror
pfbtops
pftp
pgrep
phones
photo
pic
pickup
piconv
pid
pipe
pkcs7
pkcs8
pkcs12
pkg_add
pkg_check
pkg_create
pkg_delete
pkg_info
pkg_sign
pkg_version
pkill
pl2pm
place
pod2html
pod2latex
pod2man
pod2text
pod2usage
podchecker
podselect
poll
popd
popup
posix_madvise
postalias
postcat
postconf
postdrop
postfix
postkick
postlock
postlog
postmap
postqueue
postsuper
pr
pread
preadv
printcap
printenv
printf
proc
procfs
profil
protocols
prove
proxymap
ps
psed
psroff
pstruct
ptrace
publickey
pushd
puts
pwd
pwrite
pwritev
qmgr
qmqpd
quota
quotactl
radiobutton
raise
rand
ranlib
rcp
rcs
rcsclean
rcsdiff
rcsfile
rcsfreeze
rcsintro
rcsmerge
read
readelf
readlink
readonly
readv
realpath
reboot
recv
recvfrom
recvmsg
red
ree
refer
regexp
registry
regsub
rehash
remote
rename
repeat
replace
req
reset
resolver
resource
return
rev
revoke
rfcomm_sppd
rfork
rhosts
ripemd
ripemd160
rlog
rlogin
rm
rmd160
rmdir
rpc
rpcgen
rs
rsa
rsautl
rsh
rtld
rtprio
rup
ruptime
rusers
rwall
rwho
s2p
safe
sasl
sasldblistusers2
saslpasswd2
sbrk
scache
scale
scan
sched
sched_getparam
sched_getscheduler
sched_get_priority_max
sched_get_priority_min
sched_rr_get_interval
sched_setparam
sched_setscheduler
sched_yield
scon
scp
script
scrollbar
sdiff
sed
seek
select
selection
semctl
semget
semop
send
sendbug
sendfile
sendmail
sendmsg
sendto
services
sess_id
set
setegid
setenv
seteuid
setfacl
setgid
setgroups
setitimer
setlogin
setpgid
setpgrp
setpriority
setregid
setresgid
setresuid
setreuid
setrlimit
setsid
setsockopt
settc
settimeofday
setty
setuid
setvar
sftp
sh
sha
sha1
sha256
shar
shells
shift
shmat
shmctl
shmdt
shmget
showq
shutdown
sigaction
sigaltstack
sigblock
sigmask
sigpause
sigpending
sigprocmask
sigreturn
sigsetmask
sigstack
sigsuspend
sigvec
sigwait
size
slapadd
slapcat
slapd
slapdn
slapindex
slappasswd
slaptest
sleep
slogin
slurpd
smbutil
smime
smtp
smtpd
socket
socketpair
sockstat
soelim
sort
source
spawn
speed
spinbox
spkac
splain
split
squid
squid_ldap_auth
squid_ldap_group
squid_unix_group
sscop
ssh
sshd_config
ssh_config
stab
startslip
stat
statfs
stop
string
strings
strip
stty
su
subst
sum
suspend
swapoff
swapon
switch
symlink
sync
sysarch
syscall
sysconftool
sysconftoolcheck
systat
s_client
s_server
s_time
tabs
tail
talk
tar
tbl
tclsh
tcltest
tclvars
tcopy
tcpdump
tcpslice
tcsh
tee
tell
telltc
telnet
term
termcap
terminfo
test
texindex
texinfo
text
textdomain
tfmtodit
tftp
then
threads
time
tip
tk
tkerror
tkvars
tkwait
tlsmgr
tmac
top
toplevel
touch
tput
tr
trace
trafshow
trap
troff
true
truncate
truss
tset
tsort
tty
ttys
type
tzfile
ui
ul
ulimit
umask
unalias
uname
uncomplete
uncompress
undelete
unexpand
unhash
unifdef
unifdefall
uniq
units
unknown
unlimit
unlink
unmount
unset
unsetenv
until
unvis
update
uplevel
uptime
upvar
usbhidaction
usbhidctl
users
utf8
utimes
utmp
utrace
uudecode
uuencode
uuidgen
vacation
variable
verify
version
vfork
vgrind
vgrindefs
vi
vidcontrol
vidfont
view
virtual
vis
vt220keys
vwait
w
wait
wait3
wait4
waitpid
wall
wc
wget
what
whatis
where
whereis
which
while
who
whoami
whois
window
winfo
wish
wm
write
writev
wtmp
x509
xargs
xgettext
xmlwf
xstr
xsubpp
yacc
yes
ypcat
ypchfn
ypchpass
ypchsh
ypmatch
yppasswd
ypwhich
yyfix
zcat
zcmp
zdiff
zegrep
zfgrep
zforce
zgrep
zmore
znew
_exit
__syscall
 
FreeBSD/Linux/UNIX General Commands Manual
Hypertext Man Pages
pax
 
PAX(1)			FreeBSD General Commands Manual 		PAX(1)

NAME
     pax -- read and write file archives and copy directory hierarchies

SYNOPSIS
     pax [-cdnvz] [-f archive] [-s replstr] ... [-U user] ... [-G group] ...
	 [-T [from_date] [,to_date]] ... [pattern ...]
     pax -r [-cdiknuvzDYZ] [-f archive] [-o options] ... [-p string] ...
	 [-s replstr] ... [-E limit] [-U user] ... [-G group] ... [-T
	 [from_date] [,to_date]] ... [pattern ...]
     pax -w [-dituvzHLPX] [-b blocksize] [[-a] [-f archive]] [-x format]
	 [-s replstr] ... [-o options] ... [-U user] ... [-G group] ...
	 [-B bytes] [-T [from_date] [,to_date] [/[c][m]]] ... [file ...]
     pax -r -w [-diklntuvDHLPXYZ] [-p string] ... [-s replstr] ... [-U user]
	 ... [-G group] ... [-T [from_date] [,to_date] [/[c][m]]] ...
	 [file ...] directory

DESCRIPTION
     The pax utility will read, write, and list the members of an archive
     file, and will copy directory hierarchies.  These operations are indepen-
     dent of the specific archive format, and support a wide variety of dif-
     ferent archive formats.  A list of supported archive formats can be found
     under the description of the -x option.

     The presence of the -r and the -w options specifies which of the follow-
     ing functional modes pax will operate under: list, read, write, and copy.

       List.  Write to standard output a table of contents of the mem-
	     bers of the archive file read from standard input, whose path-
	     names match the specified patterns.  The table of contents con-
	     tains one filename per line and is written using single line
	     buffering.

     -r      Read.  Extract the members of the archive file read from the
	     standard input, with pathnames matching the specified patterns.
	     The archive format and blocking is automatically determined on
	     input.  When an extracted file is a directory, the entire file
	     hierarchy rooted at that directory is extracted.  All extracted
	     files are created relative to the current file hierarchy.	The
	     setting of ownership, access and modification times, and file
	     mode of the extracted files are discussed in more detail under
	     the -p option.

     -w      Write.  Write an archive containing the file operands to standard
	     output using the specified archive format.  When no file operands
	     are specified, a list of files to copy with one per line is read
	     from standard input.  When a file operand is also a directory,
	     the entire file hierarchy rooted at that directory will be
	     included.

     -r -w   Copy.  Copy the file operands to the destination directory.  When
	     no file operands are specified, a list of files to copy with one
	     per line is read from the standard input.	When a file operand is
	     also a directory the entire file hierarchy rooted at that direc-
	     tory will be included.  The effect of the copy is as if the
	     copied files were written to an archive file and then subse-
	     quently extracted, except that there may be hard links between
	     the original and the copied files (see the -l option below).

	     Warning: The destination directory must not be one of the file
	     operands or a member of a file hierarchy rooted at one of the
	     file operands.  The result of a copy under these conditions is
	     unpredictable.

     While processing a damaged archive during a read or list operation, pax
     will attempt to recover from media defects and will search through the
     archive to locate and process the largest number of archive members pos-
     sible (see the -E option for more details on error handling).

OPERANDS
     The directory operand specifies a destination directory pathname.	If the
     directory operand does not exist, or it is not writable by the user, or
     it is not of type directory, pax will exit with a non-zero exit status.

     The pattern operand is used to select one or more pathnames of archive
     members.  Archive members are selected using the pattern matching nota-
     tion described by fnmatch(3).  When the pattern operand is not supplied,
     all members of the archive will be selected.  When a pattern matches a
     directory, the entire file hierarchy rooted at that directory will be
     selected.	When a pattern operand does not select at least one archive
     member, pax will write these pattern operands in a diagnostic message to
     standard error and then exit with a non-zero exit status.

     The file operand specifies the pathname of a file to be copied or
     archived.	When a file operand does not select at least one archive mem-
     ber, pax will write these file operand pathnames in a diagnostic message
     to standard error and then exit with a non-zero exit status.

OPTIONS
     The following options are supported:

     -r    Read an archive file from standard input and extract the specified
	   files.  If any intermediate directories are needed in order to
	   extract an archive member, these directories will be created as if
	   mkdir(2) was called with the bitwise inclusive OR of S_IRWXU,
	   S_IRWXG, and S_IRWXO as the mode argument.  When the selected ar-
	   chive format supports the specification of linked files and these
	   files cannot be linked while the archive is being extracted, pax
	   will write a diagnostic message to standard error and exit with a
	   non-zero exit status at the completion of operation.

     -w    Write files to the standard output in the specified archive format.
	   When no file operands are specified, standard input is read for a
	   list of pathnames with one per line without any leading or trailing
	   .

     -a    Append files to the end of an archive that was previously written.
	   If an archive format is not specified with a -x option, the format
	   currently being used in the archive will be selected.  Any attempt
	   to append to an archive in a format different from the format
	   already used in the archive will cause pax to exit immediately with
	   a non-zero exit status.  The blocking size used in the archive vol-
	   ume where writing starts will continue to be used for the remainder
	   of that archive volume.

	   Warning: Many storage devices are not able to support the opera-
	   tions necessary to perform an append operation.  Any attempt to
	   append to an archive stored on such a device may damage the archive
	   or have other unpredictable results.  Tape drives in particular are
	   more likely to not support an append operation.  An archive stored
	   in a regular file system file or on a disk device will usually sup-
	   port an append operation.

     -b blocksize
	   When writing an archive, block the output at a positive decimal
	   integer number of bytes per write to the archive file.  The
	   blocksize must be a multiple of 512 bytes with a maximum of 64512
	   bytes.  Archives larger than 32256 bytes violate the POSIX standard
	   and will not be portable to all systems.  A blocksize can end with
	   k or b to specify multiplication by 1024 (1K) or 512, respectively.
	   A pair of blocksizes can be separated by x to indicate a product.
	   A specific archive device may impose additional restrictions on the
	   size of blocking it will support.  When blocking is not specified,
	   the default blocksize is dependent on the specific archive format
	   being used (see the -x option).

     -c    Match all file or archive members except those specified by the
	   pattern and file operands.

     -d    Cause files of type directory being copied or archived, or archive
	   members of type directory being extracted, to match only the direc-
	   tory file or archive member and not the file hierarchy rooted at
	   the directory.

     -f archive
	   Specify archive as the pathname of the input or output archive,
	   overriding the default standard input (for list and read) or
	   standard output (for write).  A single archive may span multiple
	   files and different archive devices.  When required, pax will
	   prompt for the pathname of the file or device of the next volume in
	   the archive.

     -i    Interactively rename files or archive members.  For each archive
	   member matching a pattern operand or each file matching a file op-
	   erand, pax will prompt to /dev/tty giving the name of the file, its
	   file mode and its modification time.  The pax utility will then
	   read a line from /dev/tty.  If this line is blank, the file or ar-
	   chive member is skipped.  If this line consists of a single period,
	   the file or archive member is processed with no modification to its
	   name.  Otherwise, its name is replaced with the contents of the
	   line.  The pax utility will immediately exit with a non-zero exit
	   status if  is encountered when reading a response or if
	   /dev/tty cannot be opened for reading and writing.

     -k    Do not overwrite existing files.

     -l    Link files.	(The letter ell).  In the copy mode (-r -w), hard
	   links are made between the source and destination file hierarchies
	   whenever possible.

     -n    Select the first archive member that matches each pattern operand.
	   No more than one archive member is matched for each pattern.  When
	   members of type directory are matched, the file hierarchy rooted at
	   that directory is also matched (unless -d is also specified).

     -o options
	   Information to modify the algorithm for extracting or writing ar-
	   chive files which is specific to the archive format specified by
	   -x.	In general, options take the form: name=value

     -p string
	   Specify one or more file characteristic options (privileges).  The
	   string option-argument is a string specifying file characteristics
	   to be retained or discarded on extraction.  The string consists of
	   the specification characters a, e, m, o, and p.  Multiple charac-
	   teristics can be concatenated within the same string and multiple
	   -p options can be specified.  The meaning of the specification
	   characters are as follows:

	   a   Do not preserve file access times.  By default, file access
	       times are preserved whenever possible.

	   e   `Preserve everything', the user ID, group ID, file mode bits,
	       file access time, and file modification time.  This is intended
	       to be used by root, someone with all the appropriate privi-
	       leges, in order to preserve all aspects of the files as they
	       are recorded in the archive.  The e flag is the sum of the o
	       and p flags.

	   m   Do not preserve file modification times.  By default, file mod-
	       ification times are preserved whenever possible.

	   o   Preserve the user ID and group ID.

	   p   `Preserve' the file mode bits.  This intended to be used by a
	       user with regular privileges who wants to preserve all aspects
	       of the file other than the ownership.  The file times are pre-
	       served by default, but two other flags are offered to disable
	       this and use the time of extraction instead.

	   In the preceding list, `preserve' indicates that an attribute
	   stored in the archive is given to the extracted file, subject to
	   the permissions of the invoking process.  Otherwise the attribute
	   of the extracted file is determined as part of the normal file cre-
	   ation action.  If neither the e nor the o specification character
	   is specified, or the user ID and group ID are not preserved for any
	   reason, pax will not set the S_ISUID (setuid) and S_ISGID (setgid)
	   bits of the file mode.  If the preservation of any of these items
	   fails for any reason, pax will write a diagnostic message to
	   standard error.  Failure to preserve these items will affect the
	   final exit status, but will not cause the extracted file to be
	   deleted.  If the file characteristic letters in any of the string
	   option-arguments are duplicated or conflict with each other, the
	   one(s) given last will take precedence.  For example, if
		 -p eme
	   is specified, file modification times are still preserved.

     -s replstr
	   Modify the file or archive member names specified by the pattern or
	   file operands according to the substitution expression replstr,
	   using the syntax of the ed(1) utility regular expressions.  The
	   format of these regular expressions are:
		 /old/new/[gp]
	   As in ed(1), old is a basic regular expression and new can contain
	   an ampersand (&), \n (where n is a digit) back-references, or
	   subexpression matching.  The old string may also contain 
	   characters.	Any non-null character can be used as a delimiter (/
	   is shown here).  Multiple -s expressions can be specified.  The
	   expressions are applied in the order they are specified on the com-
	   mand line, terminating with the first successful substitution.  The
	   optional trailing g continues to apply the substitution expression
	   to the pathname substring which starts with the first character
	   following the end of the last successful substitution.  The first
	   unsuccessful substitution stops the operation of the g option.  The
	   optional trailing p will cause the final result of a successful
	   substitution to be written to standard error in the following for-
	   mat:
		  >> 
	   File or archive member names that substitute to the empty string
	   are not selected and will be skipped.

     -t    Reset the access times of any file or directory read or accessed by
	   pax to be the same as they were before being read or accessed by
	   pax.

     -u    Ignore files that are older (having a less recent file modification
	   time) than a pre-existing file or archive member with the same
	   name.  During read, an archive member with the same name as a file
	   in the file system will be extracted if the archive member is newer
	   than the file.  During write, a file system member with the same
	   name as an archive member will be written to the archive if it is
	   newer than the archive member.  During copy, the file in the desti-
	   nation hierarchy is replaced by the file in the source hierarchy or
	   by a link to the file in the source hierarchy if the file in the
	   source hierarchy is newer.

     -v    During a list operation, produce a verbose table of contents using
	   the format of the ls(1) utility with the -l option.	For pathnames
	   representing a hard link to a previous member of the archive, the
	   output has the format:
		  == 
	   For pathnames representing a symbolic link, the output has the for-
	   mat:
		  => 
	   Where  is the output format specified by the ls(1)
	   utility when used with the -l option.  Otherwise for all the other
	   operational modes (read, write, and copy), pathnames are written
	   and flushed to standard error without a trailing  as soon
	   as processing begins on that file or archive member.  The trailing
	   , is not buffered, and is written only after the file has
	   been read or written.

     -x format
	   Specify the output archive format, with the default format being
	   ustar.  The pax utility currently supports the following formats:

	   cpio     The extended cpio interchange format specified in the IEEE
		    Std 1003.2 (``POSIX.2'') standard.	The default blocksize
		    for this format is 5120 bytes.  Inode and device informa-
		    tion about a file (used for detecting file hard links by
		    this format) which may be truncated by this format is
		    detected by pax and is repaired.

	   bcpio    The old binary cpio format.  The default blocksize for
		    this format is 5120 bytes.	This format is not very porta-
		    ble and should not be used when other formats are avail-
		    able.  Inode and device information about a file (used for
		    detecting file hard links by this format) which may be
		    truncated by this format is detected by pax and is
		    repaired.

	   sv4cpio  The System V release 4 cpio.  The default blocksize for
		    this format is 5120 bytes.	Inode and device information
		    about a file (used for detecting file hard links by this
		    format) which may be truncated by this format is detected
		    by pax and is repaired.

	   sv4crc   The System V release 4 cpio with file crc checksums.  The
		    default blocksize for this format is 5120 bytes.  Inode
		    and device information about a file (used for detecting
		    file hard links by this format) which may be truncated by
		    this format is detected by pax and is repaired.

	   tar	    The old BSD tar format as found in 4.3BSD.	The default
		    blocksize for this format is 10240 bytes.  Pathnames
		    stored by this format must be 100 characters or less in
		    length.  Only regular files, hard links, soft links, and
		    directories will be archived (other file system types are
		    not supported).  For backwards compatibility with even
		    older tar formats, a -o option can be used when writing an
		    archive to omit the storage of directories.  This option
		    takes the form:
			  -o write_opt=nodir

	   ustar    The extended tar interchange format specified in the IEEE
		    Std 1003.2 (``POSIX.2'') standard.	The default blocksize
		    for this format is 10240 bytes.  Pathnames stored by this
		    format must be 250 characters or less in length.

	   The pax utility will detect and report any file that it is unable
	   to store or extract as the result of any specific archive format
	   restrictions.  The individual archive formats may impose additional
	   restrictions on use.  Typical archive format restrictions include
	   (but are not limited to): file pathname length, file size, link
	   pathname length and the type of the file.

     -z    Use gzip(1) to compress (decompress) the archive while writing
	   (reading).  Incompatible with -a.

     -B bytes
	   Limit the number of bytes written to a single archive volume to
	   bytes.  The bytes limit can end with m, k, or b to specify multi-
	   plication by 1048576 (1M), 1024 (1K) or 512, respectively.  A pair
	   of bytes limits can be separated by x to indicate a product.

	   Warning: Only use this option when writing an archive to a device
	   which supports an end of file read condition based on last (or
	   largest) write offset (such as a regular file or a tape drive).
	   The use of this option with a floppy or hard disk is not recom-
	   mended.

     -D    This option is the same as the -u option, except that the file
	   inode change time is checked instead of the file modification time.
	   The file inode change time can be used to select files whose inode
	   information (e.g. uid, gid, etc.) is newer than a copy of the file
	   in the destination directory.

     -E limit
	   Limit the number of consecutive read faults while trying to read a
	   flawed archives to limit.  With a positive limit, pax will attempt
	   to recover from an archive read error and will continue processing
	   starting with the next file stored in the archive.  A limit of 0
	   will cause pax to stop operation after the first read error is
	   detected on an archive volume.  A limit of NONE will cause pax to
	   attempt to recover from read errors forever.  The default limit is
	   a small positive number of retries.

	   Warning: Using this option with NONE should be used with extreme
	   caution as pax may get stuck in an infinite loop on a very badly
	   flawed archive.

     -G group
	   Select a file based on its group name, or when starting with a #, a
	   numeric gid.  A '\' can be used to escape the #.  Multiple -G
	   options may be supplied and checking stops with the first match.

     -H    Follow only command line symbolic links while performing a physical
	   file system traversal.

     -L    Follow all symbolic links to perform a logical file system traver-
	   sal.

     -P    Do not follow symbolic links, perform a physical file system tra-
	   versal.  This is the default mode.

     -T [from_date][,to_date][/[c][m]]
	   Allow files to be selected based on a file modification or inode
	   change time falling within a specified time range of from_date to
	   to_date (the dates are inclusive).  If only a from_date is sup-
	   plied, all files with a modification or inode change time equal to
	   or younger are selected.  If only a to_date is supplied, all files
	   with a modification or inode change time equal to or older will be
	   selected.  When the from_date is equal to the to_date, only files
	   with a modification or inode change time of exactly that time will
	   be selected.

	   When pax is in the write or copy mode, the optional trailing field
	   [c][m] can be used to determine which file time (inode change, file
	   modification or both) are used in the comparison.  If neither is
	   specified, the default is to use file modification time only.  The
	   m specifies the comparison of file modification time (the time when
	   the file was last written).	The c specifies the comparison of
	   inode change time (the time when the file inode was last changed;
	   e.g. a change of owner, group, mode, etc).  When c and m are both
	   specified, then the modification and inode change times are both
	   compared.  The inode change time comparison is useful in selecting
	   files whose attributes were recently changed or selecting files
	   which were recently created and had their modification time reset
	   to an older time (as what happens when a file is extracted from an
	   archive and the modification time is preserved).  Time comparisons
	   using both file times is useful when pax is used to create a time
	   based incremental archive (only files that were changed during a
	   specified time range will be archived).

	   A time range is made up of six different fields and each field must
	   contain two digits.	The format is:
		 [yy[mm[dd[hh]]]]mm[.ss]
	   Where yy is the last two digits of the year, the first mm is the
	   month (from 01 to 12), dd is the day of the month (from 01 to 31),
	   hh is the hour of the day (from 00 to 23), the second mm is the
	   minute (from 00 to 59), and ss is the seconds (from 00 to 59).  The
	   minute field mm is required, while the other fields are optional
	   and must be added in the following order:
		 hh, dd, mm, yy.
	   The ss field may be added independently of the other fields.  Time
	   ranges are relative to the current time, so
		 -T 1234/cm
	   would select all files with a modification or inode change time of
	   12:34 PM today or later.  Multiple -T time range can be supplied
	   and checking stops with the first match.

     -U user
	   Select a file based on its user name, or when starting with a #, a
	   numeric uid.  A '\' can be used to escape the #.  Multiple -U
	   options may be supplied and checking stops with the first match.

     -X    When traversing the file hierarchy specified by a pathname, do not
	   descend into directories that have a different device ID.  See the
	   st_dev field as described in stat(2) for more information about
	   device ID's.

     -Y    This option is the same as the -D option, except that the inode
	   change time is checked using the pathname created after all the
	   file name modifications have completed.

     -Z    This option is the same as the -u option, except that the modifica-
	   tion time is checked using the pathname created after all the file
	   name modifications have completed.

     The options that operate on the names of files or archive members (-c,
     -i, -n, -s, -u, -v, -D, -G, -T, -U, -Y, and -Z) interact as follows.

     When extracting files during a read operation, archive members are
     `selected', based only on the user specified pattern operands as modified
     by the -c, -n, -u, -D, -G, -T, -U options.  Then any -s and -i options
     will modify in that order, the names of these selected files.  Then the
     -Y and -Z options will be applied based on the final pathname.  Finally
     the -v option will write the names resulting from these modifications.

     When archiving files during a write operation, or copying files during a
     copy operation, archive members are `selected', based only on the user
     specified pathnames as modified by the -n, -u, -D, -G, -T, and -U options
     (the -D option only applies during a copy operation).  Then any -s and -i
     options will modify in that order, the names of these selected files.
     Then during a copy operation the -Y and the -Z options will be applied
     based on the final pathname.  Finally the -v option will write the names
     resulting from these modifications.

     When one or both of the -u or -D options are specified along with the -n
     option, a file is not considered selected unless it is newer than the
     file to which it is compared.

EXIT STATUS
     The pax utility will exit with one of the following values:

     0	 All files were processed successfully.

     1	 An error occurred.

EXAMPLES
     The command:
	   pax -w -f /dev/sa0 .
     copies the contents of the current directory to the device /dev/sa0.

     The command:
	   pax -v -f filename
     gives the verbose table of contents for an archive stored in filename.

     The following commands:
	   mkdir /tmp/to
	   cd /tmp/from
	   pax -rw . /tmp/to
     will copy the entire /tmp/from directory hierarchy to /tmp/to.

     The command:
	   pax -r -s ',^//*usr//*,,' -f a.pax
     reads the archive a.pax, with all files rooted in ``/usr'' into the ar-
     chive extracted relative to the current directory.

     The command:
	   pax -rw -i . dest_dir
     can be used to interactively select the files to copy from the current
     directory to dest_dir.

     The command:
	   pax -r -pe -U root -G bin -f a.pax
     will extract all files from the archive a.pax which are owned by root
     with group bin and will preserve all file permissions.

     The command:
	   pax -r -w -v -Y -Z home /backup
     will update (and list) only those files in the destination directory
     /backup which are older (less recent inode change or file modification
     times) than files with the same name found in the source file tree home.

DIAGNOSTICS
     Whenever pax cannot create a file or a link when reading an archive or
     cannot find a file when writing an archive, or cannot preserve the user
     ID, group ID, or file mode when the -p option is specified, a diagnostic
     message is written to standard error and a non-zero exit status will be
     returned, but processing will continue.  In the case where pax cannot
     create a link to a file, pax will not create a second copy of the file.

     If the extraction of a file from an archive is prematurely terminated by
     a signal or error, pax may have only partially extracted a file the user
     wanted.  Additionally, the file modes of extracted files and directories
     may have incorrect file bits, and the modification and access times may
     be wrong.

     If the creation of an archive is prematurely terminated by a signal or
     error, pax may have only partially created the archive which may violate
     the specific archive format specification.

     If while doing a copy, pax detects a file is about to overwrite itself,
     the file is not copied, a diagnostic message is written to standard error
     and when pax completes it will exit with a non-zero exit status.

SEE ALSO
     cpio(1), tar(1)

STANDARDS
     The pax utility is a superset of the IEEE Std 1003.2 (``POSIX.2'') stan-
     dard.  The options -z, -B, -D, -E, -G, -H, -L, -P, -T, -U, -Y, -Z, the
     archive formats bcpio, sv4cpio, sv4crc, tar, and the flawed archive han-
     dling during list and read operations are extensions to the POSIX stan-
     dard.

HISTORY
     The pax utility appeared in 4.4BSD.

AUTHORS
     Keith Muller at the University of California, San Diego

BUGS
     The pax utility does not recognize multibyte characters.

FreeBSD 6.1			 July 3, 2004			   FreeBSD 6.1
=193671
+27
(15)