IMPORTANT NOTE: Your data will be available to the
observing program PI on the
Keck
Observatory Archive (KOA) a day or two after the observing
run. Therefore, there is no need for you to download your data on
your observing night, unless you wish to.
If you wish to download your data on your observing night, you can
use either SCP, SFTP, or FTP. The prefered methods for transfering
data are SCP and SFTP, because they are more secure.
Which computer to use depends on the instrument. Some
recommendations are:
- Instrument-specific Linux computers:
- nirc2.keck.hawaii.edu for NIRC2
- deimos.keck.hawaii.edu for DEIMOS
- mosfire.keck.hawaii.edu for MOSFIRE
- Generic Solaris machines:
- sshserver1.keck.hawaii.edu
- sshserver2.keck.hawaii.edu
- sshserver4.keck.hawaii.edu
If you try to SCP or SFTP to one of our Solaris machines from a modern
computer, the trasfer may fail due to incompatibilities in
the SSH key exchange method. A workaround to this issue is to add the following
aliases to your ~/.aliases, ~/.cshrc
or ~/.bashrc, depending on the type of shell on your
local computer (note the bash syntax in this example):
alias kscp="scp -o KexAlgorithms=+diffie-hellman-group1-sha1 -o HostKeyAlgorithms=+ssh-dss -c 3des-cbc"
alias ksftp="sftp -o KexAlgorithms=+diffie-hellman-group1-sha1 -o HostKeyAlgorithms=+ssh-dss -c 3des-cbc"
Then you can use the instructions for the
SCP Procedure at Keck
via Laptop or
scp procedure from outside Keck
by replacing
scp with
kscp. You can use the
instructions for
Using SFTP to transfer to a laptop with no
SFTP server by replacing
sftp with
ksftp.
Procedures
WARNING: If you use thi method, the transfer can be
terminated any time after sunrise, if the VNC server or the
terminal where you initiated the transfer needs to be shut
down.
Please follow these steps to transfer data from a Keck machine
to an outside machine using scp:
-
Launch a terminal using the VNC background menu. Which
terminal to launch will depend on the instrument. This can an
instrument host terminal, e.g. polo (DEIMOS)
or nirspecserver (NIRSPEC), or local terminal
on the VNC server, e.g. deimos
(DEIMOS), nirspec (NIRSPEC)
or mosfire (MOSFIRE).
- Change to your data directory. Use the cd
command to move to your data directory. cdata is a
usual alias on most instrument to change to your data
directory. Note that data disks can be accessed using the
syntax /s/sdataXXX or /s/sdataXXXX,
depending on the instrument.
-
Execute the scp command to transfer the
data, as follows
scp *.fits youruser@yourcomputer:YourLocalDataDir/
-
You can close the terminal once the transfer is completed.
Observers can copy data directly to their laptops while at
Keck. In this case, it is best to initiate the transfer from the
laptop in order to avoid having to figure out the address of the
laptop. If you have the scp program installed on
your laptop, please follow these steps to pull data onto your
laptop from a Keck machine:
-
Open a window on your laptop and navigate to the
directory where you would like to store your data.
-
Execute the scp command to transfer the entire
contents of your data directory to the current directory on your
laptop, as in:
scp -r account@host:/path/ .
where account is the name of your observing
account, e.g. deimos7, host is the name of
the instrument host or VNC server,
e.g. deimos or polo,
and path is the pathname to your data. For
example, to copy data from the
directory /s/sdata1004/deimos8/2020dec15 as user
deimos8, enter:
scp -r deimos8@deimos.keck.hawaii.edu:/s/sdata1004/deimos8/2020dec15 .
Observers can copy data to or from Keck from external machines
(whether laptops or workstations) using scp. Please
follow these steps to copy data from Keck computers to your
external machine:
- Obtain access through the Keck firewall. Please contact
your WMKO Staff Astronomer for instructions. If you are
running the Keck remote observing software, access though
the Keck firewall is granted automatically on any of your
local computer terminals.
-
Open a window on your computer navigate to the directory
where you would like to store your data.
-
Execute the scp command to transfer the entire
contents of your data directory to the current directory on your
laptop, as in:
scp -r account@host:/path/ .
where account is the name of your observing
account, e.g. deimos7, host is the name of
the instrument host or VNC server,
e.g. deimos or polo,
and path is the pathname to your data. For
example, to copy data from the
directory /s/sdata1004/deimos8/2020dec15 as user
deimos8, enter:
scp -r deimos8@deimos.keck.hawaii.edu:/s/sdata1004/deimos8/2020dec15 .
WARNING: If you use thi method, the transfer can be
terminated any time after sunrise, if the VNC server or the
terminal where you initiated the transfer needs to be shut
down.
Please follow these steps to transfer data using SFTP:
-
Launch a terminal using the VNC background menu. Which
terminal to launch will depend on the instrument. This can an
instrument host terminal, e.g. polo (DEIMOS)
or nirspecserver (NIRSPEC), or local terminal
on the VNC server, e.g. deimos
(DEIMOS), nirspec (NIRSPEC)
or mosfire (MOSFIRE).
- Change to your data directory. Use the cd
command to move to your data directory. cdata is a
usual alias on most instrument to change to your data
directory. Note that data disks can be accessed using the
syntax /s/sdataXXX or /s/sdataXXXX,
depending on the instrument.
-
Execute the sftp command to access your computer as
follows:
sftp youruser@yourcomputer
-
Type
put *.fits
to transfer all of the FITS
images in the directory.
-
When the transfer has completed, you may use the command
lcd directory
to move to another directory
on the Keck machine, and use put again to copy the
data.
-
When done transferring all files, type quit to
end your FTP session.
-
You can close the terminal once the transfer is completed.
IMPORTANT NOTE: Most modern Linux computers at Keck do not
have FTP, e.g. deimos
or nirc2. However, there are still some old Sun
stations that have FTP, e.g. sshserver2. If you wish
to use FTP from one of the old Sun stations:
-
Open a secure shell to one of the SSH servers from any of the
terminals in your VNC session, for instance:
ssh nspec7@sshserver2
Input the password corresponding to your designated instrument
numbered account.
-
Change to your data directory. Use the cd
command to move to your data directory. cdata is a
usual alias on most instrument to change to your data
directory. Note that data disks can be accessed using the
syntax /s/sdataXXX or /s/sdataXXXX,
depending on the instrument.
-
Run the ftp command to start an FTP session.
-
Use the command
open my_home_site
to
open an FTP connection to your home site. Provide the proper
account name and password to log in.
-
Use the cd to move to the directory where you
would like your data stored.
-
Issue the command binary to set binary
transfer mode.
-
Issue the command prompt to turn off
verification of each file transfer.
-
Type
put *.fits
to transfer all of the FITS
images in the directory.
-
When the transfer has completed, you may use the command
lcd directory
to move to another directory
on the Keck machine, and use put again to copy the
data.
-
When done transferring all files, type quit to
end your FTP session, and then close the terminal.
Please follow these steps to transfer data using SFTP from your
computer to one of the Keck host computers:
-
Change to the datat directory where your would like to
download the data to on your local computer
-
Launch sftp on your local computer as follows:
sftp username@keckhostname.keck.hawaii.edu
where keckhostname will depend on the
instrument. Some examples of valid hosts are
polo (DEIMOS), nirspecserver
(NIRSPEC), deimos
(DEIMOS), nirspec
(NIRSPEC), nirc2 (NIRC2)
or sshserver1.
- Change to your data directory. Use the cd
command to move to your data directory. Note that data disks
can be accessed using the syntax /s/sdataXXX
or /s/sdataXXXX, depending on the instrument.
-
Type
get *.fits
to transfer all of the FITS
images onto your local directory.
-
When the transfer has completed, you may use the command
cd directory
to move to another directory on the
Keck machine, and use get again to copy the data.
-
When done transferring all files, type quit to
end your FTP session.