Describes how I customize my accounts in computer clusters, with some specific tips for Harvard Odyssey and NCAR Cheyenne.
Files in local are for your local computer, or any other cluster.
Files in share are for all machines (local, odyssey and cheyenne).
- .ssh/config (Single sign on, for Mac or other Linux-like systems)
- Publickey (No password sign on)
- .ssh/config (No password sign on with host-based authentication)
NoMachine for Odyssey(Decommissioned)- My Odyssey login practice
- File transfer - ZModem
- File transfer - other
- .inputrc (history-search-backward)
- .vim .vimrc
SSH ControlMaster allows you to sign on once and reuse it. You must go from same source node to same destination node.
- On source node, download corresponding .ssh/config, and change pchan to your username on destination node. In the example below, I have defined a nickname
ody
. I have appended ControlPath with -%l so that different source nodes on same file system will not interfere.
Host ody
User pchan
HostName login.rc.fas.harvard.edu
ControlMaster auto
ControlPath ~/.ssh/%r@%h:%p-%l
-
On source node, run
ssh -CY -o ServerAliveInterval=30 -fN ody
to create a token (password required). This step prints nothing to screen and you are still on source node, but a token named like~/.ssh/[email protected]:22-localhost.localdomain
is created. -
When token exists and is open, use nickname
ody
to replaceusername@address
(examples below). Stop and redo step 2 if you are asked for password.
ssh -Y ody
rsync ody:~/some_file ~/ # file transfer
sftp ody
ssh-keygen
ssh-copy-id [email protected]
Cheyenne only, across various cheyenne login nodes.
Host cheyenne?
HostName %h.ib0
- Can disconnect and reconnect without losing your session.
- Faster graphic forwarding than X11.
- Avoid loading modules in bashrc.
- Follow instructions on RC page.
- I suggest saving password, and GNOME desktop in the connection file.
- CtrlAlt0, click
Display
, turn onResize remote screen
. - From top-left corner, click
Applications
>System Tools
>Terminal
to open a new terminal.
- Some keyboard shortcuts may not work. I use right click to copy and paste.
- Download openauth on local computer (NOT phone).
- Put openauth in startup. Windows user: follow steps below. Mac user: invent your way and tell me.
- In
File Explorer
, simply typestartup
in path line. This will bring you toC:\Users\some_user\AppData\Roaming\Microsoft\Windows\Start Menu\Programs\Startup
. - From downloaded zip file of openauth, copy
*-openauth.bat
into startup folder. - Edit
*-openauth.bat
with absolute path ofJAuth.jar
, e.g.start javaw -jar C:\Users\some_user\Desktop\JAuth.jar
.
- In
- Connect RC VPN at
vpn.rc.fas.harvard.edu
with username likepchan@odyssey
. - Login to rcnx01 (remember password for NoMachine and XShell, or ssh-copy-id).
- Every time after monthly maintenance,
ssh -CY -o ServerAliveInterval=30 -fN rclogin14
. - Every time after monthly maintenance,
ssh -CY -o ServerAliveInterval=30 -fN che
. ssh -Y rclogin14
I like lrzsz (ZModem) for small file transfer (no need to switch to another terminal/program!).
Mac user: follow this link to set up.
Windows user: use XShell - Home/School Free Version available, or other clients that support ZModem.
After that, download sz and rz and put under ~/bin/
(this is usually in your path by default).
Now, you can run sz some_file
to download and rz
to upload.
- Odyssey Home directory and Lab storage can be mounted on your local computer. (link)
- Dropbox synchronizing. Try get Harvard-funded Dropbox.
- GitHub - free student pack available.
- Large file transfer with Globus (link: Cheyenne, Odyssey).
- More options on RC page.
Bottons (e.g. PageUp or ↑) can be bound to action history-search-backward
, so no need to memorize and type historical commands. In bash, this can be done by inputrc (defaults in /etc/inputrc).
- (Usu. Windows) If there is PageUp on your keyboard and it can go to remote server, you can download .inputrc.less and move to
~/.inputrc
. - If not (usu. Mac), you can download .inputrc.more and move to
~/.inputrc
. This will bind ↑ tohistory-search-backward
, instead ofprevious-history
. - For the first time, sign out and sign in, or
bind -f ~/.inputrc
to load the new inputrc. - Now when you type
cd
PageUp, orss
PageUp, you will be able to use PageUp and PageDn to search historical commands. Use ↑ and ↓ instead if you used .inputrc.more. Use Ctrlc to stop searching. - You might also want to do
export HISTSIZE=9999
andexport HISTCONTROL=ignoredups
in your .bashrc to store more histories.