Copy Files in Linux

The way files are copied in Linux depend on your distribution and file system. All versions of Linux could copy files from the command line. There are also a number of file managers both text based and GUI that could be used

Steps

Command Line

Every Linux version comes with a command line. If you don't have a GUI to use, or if you are already in Terminal, you can use these text based commands.

  1. Move to the directory you want to copy your files from. To move a file from the home folder into the documents folder, you first need to use the "cd" command to move into your home folder:
  2. Use the copy command to move your files to the directory you want. Now that you are in the folder you want to copy files from, choose which file you want to copy and run the "cp" command to copy it to the folder you want it copied to. So if the file you want copied to the documents folder is called myFile.txt, the command to use is...
  3. Move to the folder you copied the file to and check if it copied correctly. The best way to do this is by running these commands and finding your file in the list.

Graphical file managers

  1. Many file managers/browser programs usually copy files by using their Edit menu items, or by dragging file icons from one folder to another.
  2. Open your file manager (In Ubuntu, you can open it by going to "Computer" in the "Places" menu on the top of your screen) and browse to the file you want to copy.
  3. Click on the file you want to copy.
  4. Go to the "Edit" menu and select "Copy".
  5. Browse to the folder you want to copy the file to.
  6. Go to the "Edit" menu and select "Paste".

Related Articles