December 1999
Beginner
528 pages
11h 10m
English
Format:
cp options file1 file2
Options:
| -i | Prompt for confirmation for overwriting files |
| -p | Preserve the permission modes and modification times |
| -r | Recursively copy a directory |
To copy the file myfile to myfile1.bak
$ cp myfile 1 myfile1.bak
To copy the file get.prd from /usr/local/sybin to /usr/local/bin
$ pwd
usr/local/sybin
$ cp get.prd../bin
To recursively copy all files and directories from /logs (downwards) to /hold/logs
$ cp -r /logs/ /hold/logs
Read now
Unlock full access