How can you copy files or directories?

Answer Posted / hr@tgksolutions.com

To duplicate files or directories, UNIX offers the cp command. For copying files, the syntax is cp source_file destination_directory/. If duplicating a directory, the -r option (meaning recursive) must be added, as in cp -r source_directory destination_directory/. This ensures all sub-files and sub-directories are replicated too. The cp command is fundamental when backing up data or creating duplicate research resources.

Is This Answer Correct ?    0 Yes 0 No



Post New Answer       View All Answers


Please Help Members By Posting Answers For Below Questions

How do I search for text in vi?

766


why metadb requires a seperate slice to create Solaris volume manager

2778


Which command should you use to find the remaining disk space in unix server?

971


Is there a way to erase all files in the current directory, including all its sub-directories, using only one command?

1012


What is used to type command?

750


What is ‘ps’ command for?

840


What is unix command?

872


What difference between cmp and diff commands?

949


How many unix commands are there?

815


What do know about tee command and its usage?

845


What do chmod command do?

807


What is command substitution?

880


What is grep and how do you use it?

783


hw will u use awk in replacing cahrs and files

2932


How does the system know where one command ends and another begins?

1860