Transferring files over SFTP: Difference between revisions
| mNo edit summary | No edit summary | ||
| Line 4: | Line 4: | ||
| On the server, your files are located in <code>/home/group/username/</code>. For a normal user with username <code>username/</code> this will be <code>/home/user/username/</code>, for an organisation with username <code>organisation/</code> this will be <code>/home/org/organisation/</code> etc. | On the server, your files are located in <code>/home/group/username/</code>. For a normal user with username <code>username/</code> this will be <code>/home/user/username/</code>, for an organisation with username <code>organisation/</code> this will be <code>/home/org/organisation/</code> etc. | ||
| =Non-graphical methods= | ==Non-graphical methods== | ||
| The most common way to transfer files is with a terminal by using the <code>scp</code> command. | The most common way to transfer files is with a terminal by using the <code>scp</code> command. | ||
| ==Copying file to host:== | ===Copying file to host:=== | ||
|   scp SourceFile user@host:directory/TargetFile |   scp SourceFile user@host:directory/TargetFile | ||
| If you want to copy an '''empty''' folder, you have to add -r, for example: | If you want to copy an '''empty''' folder, you have to add -r, for example: | ||
|   scp -r SourceFolder user@host:directory/TargetFolder |   scp -r SourceFolder user@host:directory/TargetFolder | ||
| ==Copying file from host:== | ===Copying file from host:=== | ||
|   scp user@host:directory/SourceFile TargetFile |   scp user@host:directory/SourceFile TargetFile | ||
| If you want to copy an '''empty''' folder, you have to add -r, for example: | If you want to copy an '''empty''' folder, you have to add -r, for example: | ||
| Line 24: | Line 24: | ||
|   man scp |   man scp | ||
| =Graphical methods= | ==Graphical methods== | ||
| The graphical methods are explained in [[Accessing your files]]. | The graphical methods are explained in [[Accessing your files]]. | ||
Revision as of 20:03, 26 April 2021
ULYSSIS doesn't support ftp, because it is insecure. However, we support sftp (ftp over ssh). This works similar as ssh.
On the server, your files are located in /home/group/username/. For a normal user with username username/ this will be /home/user/username/, for an organisation with username organisation/ this will be /home/org/organisation/ etc.
Non-graphical methods
The most common way to transfer files is with a terminal by using the scp command.
Copying file to host:
scp SourceFile user@host:directory/TargetFile
If you want to copy an empty folder, you have to add -r, for example:
scp -r SourceFolder user@host:directory/TargetFolder
Copying file from host:
scp user@host:directory/SourceFile TargetFile
If you want to copy an empty folder, you have to add -r, for example:
scp -r user@host:directory/SourceFolder TargetFolder
You don't need to use the full path to your file. You may you the relative path, starting from your home directory. For example:
scp index.html user@ssh1.ulyssis.org:www/index.html
You can find more info on the scp commands by using:
man scp
Graphical methods
The graphical methods are explained in Accessing your files.
