cp(1) | cp(1) |
With the
Warning: While copying a directory tree that has device special ®les, use the
Speci®es the handling of any extent attributes of the ®le[s] to be copied. extarg takes one of the following values.
warn Issues a warning message if extent attributes cannot be copied, but copies the ®le anyway.
ignore Does not copy the extent attributes.
force Fails to copy the ®le if the extent attribute can not be copied.
Extent attributes can not be copied if the ®les are being copied to a ®le system which does not support extent attributes or if that ®le system has a different block size than the original. If
Access Control Lists (ACLs)
If new_®le is a new ®le, or if a new ®le is created in dest_directory, it inherits the access control list of the original ®le1, ®le2, etc., altered to re¯ect any difference in ownership between the two ®les (see acl(5) and aclv(5)). In JFS ®le systems, new ®les created by cp do not inherit their parent directory's default ACL entries (if any), but instead retain the ACLs of the ®les being copied. When copying ®les from a JFS ®le system to an HFS ®le system or vice versa, optional ACL entries are lost.
EXTERNAL INFLUENCES
Environment Variables
LC_CTYPE determines the interpretation of text as single and/or
LANG and LC_CTYPE determine the local language equivalent of y (for yes/no queries).
LANG determines the language in which messages are displayed.
If LC_CTYPE is not speci®ed in the environment or is set to the empty string, the value of LANG is used as a default for each unspeci®ed or empty variable. If LANG is not speci®ed or is set to the empty string, a default of "C" (see lang(5)) is used instead of LANG. If any internationalization variable contains an invalid setting, cp behaves as if all internationalization variables are set to "C". See environ(5).
International Code Set Support
Single- and
EXAMPLES
The following command moves the directory sourcedir and its contents to a new location (targetdir) in the ®le system. Since cp creates the new directory, the destination directory targetdir should not already exist.
cp
The
This example is equivalent to:
mv sourcedir targetdir
To copy all ®les and directory subtrees in the current directory to an existing targetdir, use:
cp
− 2 − | Section 1−115 |
c