Transferring Files

From Redbrick Wiki
Jump to navigation Jump to search

Scp is a file transfer protocol which is just like ftp only it offers a more secure service. There are two ways of using scp, WinSCP which is a graphical user interface for Windows or the command line version. WinSCP is the easiest to explain so we'll do that one first.

Getting WinSCP

To download WinSCP, just click here!

Using WinSCP

When you first run WinSCP, this is the screen you will be faced with something like this:

Winscp.jpg

Fill in the host name as:

login.redbrick.dcu.ie

Then all you have to fill in is your username and password. The first time you do this it will ask you if you want to add the host to your cache - you just chose either yes or no. Selecting cancel will abort the connection.

Transferring Files

Once you have logged in you will see a list of files on your computer on the left and a list of files on the server you have connected to on the right. To move files across, just click and drag the file from its source to where you want to move it to just like windows explorer. Then all you have to do is click "copy".

Command Line scp

If you are using command line scp, there is different syntax if you want to move a file from your computer to another computer and if you want to get a file from another computer and put it on your own computer.

From Your Computer to Another Computer

When you want to move a file from your current computer to another computer you need to follow the following syntax: scp fileOnComputer1 username@computer2:

For example:

scp exampleFile keloe@login.redbrick.dcu.ie:~/

When it tries to authenticate you will be asked if you wish to continue, just say yes. You will then be asked for your password on computer2. In this case you would be asked for the password for your login to redbrick. The file will then be transfered from your computer to the redbrick server. I have ~/ after ":" which means that the file will go into my home directory. You could give a destination for where you want the file to go.

From Another Computer to Your Own

If you want to get a file from computer 2 and put it on your own computer the syntax is slightly different. You will have to use this syntax:

scp username@machine2:filename destination

For example:

scp keloe@enigma.redbrick.dcu.ie:myFile .

Again when it gets to the authentification stage you will be asked if you wish to continue. Just type yes. You will then be asked for the password to enigma. The full stop "." just means the file will copied into your current directory. You could substitute with another destination if you wanted.

Well that's it. All ya need to know about scp. If you've any questions don't hesitate in asking any member of the Helpdesk team. :-)

Links

WinSCP.net - the WinSCP website.