Skip to content

Data transfer to/from Pelle using rsync

There are multiple ways to transfer files to or from Pelle. Here it is described how to do file transfer to/from Pelle using rsync.

Procedure

Prefer a video?

Watch the YouTube video Data transfer to/from Pelle using rsync.

1. Start a terminal on your local computer

Start a terminal on your local computer

2. Transfer files to Pelle

You can transfer files to Pelle by:

2a. Transfer individual files to Pelle

On local computer, do:

rsync [my_local_file] [username]@pelle.uppmax.uu.se:[target_folder]

where

  • [my_local_file] is the path to your local file
  • [target_folder] is the path of the folder you want to copy your file to
  • [username] is your UPPMAX username

for example:

rsync my_local_file.txt sven@pelle.uppmax.uu.se:/home/sven/

If asked, give your UPPMAX password. You can get rid of this prompt if you are using an SSH key pair.

2b. Transfer all files in a folder to Pelle

On local computer, do:

rsync --recursive my_folder [username]@pelle.uppmax.uu.se:[target_folder]

where

  • [target_folder] is the target folder
  • [username] is your UPPMAX username

for example:

rsync --recursive my_folder sven@pelle.uppmax.uu.se:/home/sven/

If asked, give your UPPMAX password. You can get rid of this prompt if you are using an SSH key pair.

Note that in rsync, a slash (/) matters:

Command Effect
rsync --recursive my_folder sven@pelle.uppmax.uu.se:/home/sven Will put the files in my_folder in the Pelle home folder
rsync --recursive my_folder sven@pelle.uppmax.uu.se:/home/sven/ Will put the folder my_folder in the Pelle home folder

3. Transfer files from Pelle to you local computer

You can transfer files from Pelle to your local computer by:

3a. Transfer individual files from Pelle to your local computer

On your local computer, do:

rsync [username]@pelle.uppmax.uu.se:[path_to_file] .

where

  • [path_to_file] is the path to the file you want to download
  • [username] is your UPPMAX username
  • . means 'in the current folder of my local computer' or 'here'

for example:

rsync sven@pelle.uppmax.uu.se:/home/sven/my_file.txt .

If asked, give your UPPMAX password. You can get rid of this prompt if you are using an SSH key pair.

3b. Transfer all folders from Pelle to you local computer

On your local computer, do:

rsync --recursive [username]@pelle.uppmax.uu.se:/[source_folder] .

where

  • [source_folder] is the path to the folder you want to download
  • [username] is your UPPMAX username
  • . means 'in the current folder of my local computer' or 'here'

for example:

rsync --recursive sven@pelle.uppmax.uu.se:/home/sven/my_folder .

If asked, give your UPPMAX password. You can get rid of this prompt if you are using an SSH key pair.