If you are using a Mac computer or a PC running Linux operating system, you already have all the tools that are needed to transfer NMR data from the spectrometer host computers as long as you have a user account, as mentioned on page 26-27 in the New User Manual.
Below is a step by step tutorial on how to do this using command lines for those who are not familiar with Unix commands. It requires a Mac or Linux computer with internet connection as well as a login account on the spectrometer computers where you wish to take the NMR data from. All commands should be finished with a hit to the ‘Enter’ key.
- Open a terminal under ‘System Tools’ or you may search for ‘Terminal” if it can’t be found. We call it Terminal A
- Using Terminal A to remotely login the spectrometer computer by command:
For other spectrometers, use i500, i400, gem300 etc to replace vxr400. Replace vnmr1 with your login account and then enter your password when the system prompts you to. If it’s the first time you remotely login that specific spectrometer, you also need to confirm the connection with a ‘yes’.
- Now Terminal A should be remotely using the spectrometer computer. Some basic unix commands can be used:
This returns the name of current working directory.
list directory contents
change directory to where your data is located
If many data directories exist, you can narrow down the contents being listed,
ls -d *ubq*
This will list only data directories containing “ubq” in the name.
- The command below saves all data files containing “ubq” in the name into a single archive named ‘ubq.tar’
tar cvf ubq.tar *ubq*
- Command ‘mv’ moves the archive file to the home directory. This is optional just for convenience
mv ubq.tar ~
- Open a second terminal, Terminal B, which will be used to transfer the data.
- Under Terminal B, ‘cd’ to where you want the data be transferred to. To create a new directory:
This will create a new directory called ‘vxr400’ and change current working directory there.
- Below is the command that actually transfers the archive file
scp email@example.com:ubq.tar .
enter password then the transfer will start.
- When it’s done, list the contents to make sure that the file has been transferred.
- This last command restores the individual directories and files from the archive.
tar xvf ubq.tar
That’s it. Don’t forget to issue exit in Terminal A to close the connection to the spectrometer computer.
Below is a summary of the unix commands used above.
pwd – to print name of current/working directory
ls – to list directory contents
cd – to change the current directory
mkdir – make directories
mv – move (rename) files
tar – to save many files together into a single archive, and can restore individual files from the archive.
ssh – a program for logging into a remote machine and for executing commands on a remote machine
scp – secure copy (remote file copy program)
If you want to learn more about each command, type ‘man command’ eg. ‘man scp’, ‘man tar’, ‘man ls’ etc. in a terminal. Transferring data this way gives you more freedom. You may transfer a large amount of data using scp just once.