Changes

Jump to navigation Jump to search
1,335 bytes added ,  18:48, 18 October 2016
Line 1: Line 1:  
== How to Transfer Files ==
 
== How to Transfer Files ==
    +
=== Both machines are on the UConn network ===
 
A safe way to transfer files to and from the cluster to a personal computer is to use the [http://linux.die.net/man/1/scp scp] (Secure Copy) command.
 
A safe way to transfer files to and from the cluster to a personal computer is to use the [http://linux.die.net/man/1/scp scp] (Secure Copy) command.
   Line 13: Line 14:  
<pre>
 
<pre>
 
scp username@stats.phys.uconn.edu:/path/to/remote/file.txt /path/to/new/local/location/
 
scp username@stats.phys.uconn.edu:/path/to/remote/file.txt /path/to/new/local/location/
 +
</pre>
 +
 +
=== Transferring to/from offsite ===
 +
 +
Sometimes it is necessary to transfer files between your local machine and stats. This can become complicated if the local machine is not on the UConn network. In this case the connection is:
 +
<pre>
 +
local machine -> intermediate UConn machine -> stats.phys.uconn.edu
 +
</pre>
 +
 +
The first step before being able to transfer files is to set up port forwarding in a separate terminal
 +
<pre>
 +
Terminal 1:
 +
ssh -L9999:stats.phys.uconn.edu:22 <username for intermediate machine>@<hostname of intermediate machine>
 +
 +
Ex: ssh -L9999:stats.phys.uconn.edu:22 TestUser@MiddleMachine.uconn.edu
 +
</pre>
 +
 +
Once the port forwarding has been set, files can be transferred between the two endpoints. To transfer a file from a local machine to stats:
 +
<pre>
 +
Terminal 2:
 +
scp -P 9999 /path/to/local/file.txt <stats username>@localhost:/path/to/stats/file.txt
 +
</pre>
 +
 +
To transfer from stats to a local machine:
 +
<pre>
 +
Terminal 2:
 +
scp -P 9999 <stats username>@localhost:/path/to/stats/file.txt /path/to/local/file.txt
 
</pre>
 
</pre>
   Line 21: Line 49:  
*Transferring to the cluster
 
*Transferring to the cluster
 
<pre>
 
<pre>
scp /cygdrive/c/Users/<personalUsername>/My\ Documents/path/to/file.txt username@stats.phys.uconn.edu:/path/to/remote/location
+
scp /cygdrive/c/Users/<personalUsername>/My\ Documents/path/to/file.txt  
 +
username@stats.phys.uconn.edu:/path/to/remote/location
 
</pre>
 
</pre>
    
*Transferring from the cluster
 
*Transferring from the cluster
 
<pre>
 
<pre>
scp username@stats.phys.uconn.edu:/path/to/remote/file.txt /cygdrive/c/User/<personalUsername>/My\ Documents/path/to/local/location
+
scp username@stats.phys.uconn.edu:/path/to/remote/file.txt  
 +
/cygdrive/c/User/<personalUsername>/My\ Documents/path/to/local/location
 
</pre>
 
</pre>
 +
 +
== Graphical Programs ==
 +
Some users prefer to use a program with a graphical user interface (GUI) instead of the commandline. <b>Use these at your own risk</b>. In the past a student tried using such a program and lost all of the files being transferred.
191

edits

Navigation menu