// File Transfer from User to the Discover cluster

Users must transfer files between local workstations and Discover using the Bastion Service Direct Mode.

For Command-Line Users

First, make sure you have already completed the configuration step in your .ssh/config for proxied connections (Direct Mode). Then you can transfer files, such as data sets or application files, directly to Discover or Dirac from your terminal. For file transfer to Dirac, replace every instance of "discover" below with "dirac".

In standard bastion configurations, you can run the following: $ scp /my/file.txt userid@discover.nccs.nasa.gov:/target/directory

You will be asked to provide both your PASSCODE and your NCCS Password for all scp commands.

If rsync is available on your client, it might be a better alternative to scp because say if there is a network issue, you can still finish a given transfer (and it should work with the standard bastion configuration for ssh). For example: $ rsync -av --progress --partial /my/file.txt userid@discover.nccs.nasa.gov:"/target/directory"

If the file transfer fails and --partial is set, the target file will be named as the actual file name (i.e. FileYouAreSending.txt), even though the file isn't complete. You can later complete the transfer by running rsync again with either --append or --append-verify: $ rsync -av --progress --append /my/file.txt userid@discover.nccs.nasa.gov:"/target/directory"

For more assistance with either of these commands run "man scp" or "man rsync" to see their manual pages.

MobaXterm

MobaXterm is recommended for Windows users because its built in scp/rsync/sftp is similar to Linux/MacOS configurations.

Download MobaXterm

1) If you have not yet enabled local terminal in Moba: Go to settings -> Misc , and select "Terminal" for the "Open the following tab at startup" field. Click OK. If Moba requires a plug-in download, it will prompt you for it. Once downloaded, restart your Moba. Now you should see a terminal upon launch within the application window.

2) Complete the configuration step in your /home/mobaxterm/.ssh/config for proxied connections (Direct Mode).

3) The new plug in will allow you to use scp, rsync, and other file copy utilities. You may verify you can use the utility by running: "man scp" or "man rsync". This will open the manual pages for the commands, which provides further documentation for the command entered.

4) Test file transfer by running either: $ scp /my/file.txt userid@discover.nccs.nasa.gov:/target/directory
$ rsync -av --progress /my/file.txt userid@discover.nccs.nasa.gov:"/target/directory"

It will ask for your credentials (RSA Token and NCCS Password) and display the transfer status. Now ssh to Discover in Moba and verify that the file was transferred successfully.

For WinSCP users

This video instructional describes how to perform a secure file transfer between the Discover systems and a local windows workstation. The user will be given instruction on how to download and install the PuTTy terminal emulator software as well as the WinSCP secure GUI file transfer utility necessary to accomplish file transfers.



If you have a NASA provided laptop and would like to configure WinSCP to use your PIV card, you may follow the instructions on this PowerPoint slide. Note that if you are NOT a discover-nastran user you should use "discover.nccs.nasa.gov" as the hostname in WinSCP. If you do not have a NASA provided laptop and will be using an RSA Token to authenticate, you may follow these steps:

  1. Download the following configuration files to automatically fill in the required settings for connecting to Discover and Discover-Nastran. On the WinSCP "Login" window click the "Tools" button in the bottom left, then click "Import/Restore."
    Note: These INI files assume that Putty is installed in the default location for Windows 10 64-bit. Users are highly encouraged to use the newest versions of Putty 64-bit and WinSCP.

    The settings from the INI files do not include usernames so enter your NCCS userid in the username field on the Login window. You must also click the "Advanced" button to open the Advanced Site Settings window. Click "proxy" on the tree to the left. Enter your userid in the username field here as well. Now click "ok" then "save" and you may login to your WinSCP Session.

    Note: Do NOT enter an RSA Tokencode or NCCS password in the password field on the Login window. This may result in the connection being closed so leave the field empty. You will be prompted for PASSCODE/Password interactively.

  2. You may also configure WinSCP manually as shown below, or you may check your imported settings.

  3. Session Settings in Login Window
    WINSCP session tab screen shot for demonstration
    Hostname discover.nccs.nasa.gov  or discover-nastran.nccs.nasa.gov 
    Username your NCCS userid
    Password LEAVE BLANK
    Advanced Click to edit Proxy Tab

    Proxy Tab in Advanced Site Settings
    WINSCP proxy tab screen shot for demonstration
    Proxy Tab local
    Local Proxy Command "C:\\Program Files\\PuTTY\\plink.exe" -pw %pass -l %user %proxyhost direct %host
    (This assumes that plink.exe is found under C:\\Program Files\\PuTTY. Also note that "-l" in the command above is a "dash lowercase L". )
    Username NCCS userid
    Password LEAVE BLANK
    Proxy Hostname login.nccs.nasa.gov
    Do DNS name lookup at proxy end Yes
  4. Once you have configured your settings you may click the Login button to Launch WinSCP. Accept the host key fingerprint if it prompts for it, which you may verify the identity of here. Enter the PASSCODE (WinSCP sometimes calls this the "proxy password") which is your RSA Tokencode. Finally, enter your NCCS Password at the regular password prompt and you should now have an open session.

    Note: A WinSCP feature request that asks for WinSCP to prompt for the proxy password if it is left blank is currently being tracked as bug #468; however, the original bug was filed in 2009 so it's unclear how much traction it has at the moment.

    Also, once you have configured WinSCP, do NOT launch PuTTY using the button embedded within WinSCP. Doing so will cause WinSCP to connect back to login.nccs.nasa.gov using a previously used PASSCODE which results in a locked token. Launching the standalone PuTTY should always work fine.