Contents
Changelog:
- 30 August 2018: Correct
labunix##
toportal
(to reflect change in how department Linux accounts work) - 31 August 2018: Link to “modules” explanation.
- 2 September 2018: Add temporary note aboue portalXX workaround.
Note: If you have trouble using
portal.cs.virginia.edu
in the instructions below due to an error about a “host key” changing, for now you may try temporarily usingportalXX.cs.virginia.edu
instead, whereXX
is 01, 02, 03, or 04. Alternately, you may edit theknown_hosts
file to remove a line which includes a “key” for a machine other than the “portal” machine you ended up connecting to. (The problem is that there are four portal machines, each of which has different host keys. SSH complains because it thinks you may be connecting to a malicious machine since it’s not the same machine it remembers connecting to previously.)This will hopefully become unnecessary in the near future.
The most reliable single approach to using a POSIX system similar to the department machines is to use the department machines. This can be done can be done remotely using a secure shell and a secure copy or by using remote desktop via the NoMachine software. (We believe remote desktop option is probably most convenient.)
Tools exist for using these on just about all operating systems.
Lab accounts will be created by the second week of class; see your email for your initial password. If you have changed it and can’t remember what it is now, or otherwise don’t have an account, email the department system admins at
cshelpdesk@virginia.edu
.
About software on the department machines
The department machines use a “module” system to load software, like C compilers. See this guide for using that to load more recent versions of compilers, etc. when using them.
Remote Desktop on Windows, Mac, or Linux
You can use remote desktop to the UVa computer science department Linux environment using the NoMachine client. See this document for instructions.
This will give you a persistent environment to work on the department machines, even if you disconnect.
SSH on Windows
-
Download PuTTY (get the
putty.exe
file) -
Run the
putty.exe
-
In the “Host name” field type
portal.cs.virginia.edu
. -
When prompted, give your lab account username and password (you won’t see the password as you type)
At the end of this you will have a terminal running on a lab machine. You won’t be able to open windows (try nano
, emacs
or vim
if you need an editor) but you can use cd
, gcc
, ./a.out
, ./driver.pl
, and so on.
Windows is pretty nerfed when it comes to open-source tools. You can try the pscp.exe
or psftp.exe
from the PuTTY site, but results vary. See [Files to-and-from lab machines] for how to use pscp
.
SSH in Chrome
I have had reports that this chrome extension works well for ssh, though I have not used it myself.
SSH on Mac, Linux, FreeBSD, OpenBSD, Haiku, etc.
ssh
, scp
, sftp
, rsync
, and the like are installed by default.
Working on lab machines remotely
-
Open a terminal
-
Type
ssh mst3k@portal.cs.virginia.edu
(wheremst3k
is your user ID) -
Type your lab account password (you won’t see it as you type)
At the end of this you will have a terminal running on a lab machine.
You won’t be able to open windows (try nano
, emacs
or vim
if you need an editor) but you can use cd
, gcc
, ./a.out
, ./driver.pl
, and so on.
Files to-and-from lab machines
-
Open a terminal
-
cd
to the directory you want to share -
To send a single file (where
mst3k
is your computing ID):scp localFile.c mst3k@portal.cs.virginia.edu:~/remote/path/
To retrieve a single file:
scp mst3k@portal.cs.virginia.edu:~/remote/path/filename.c ./
Note those are tildes
~
not hyphens-
; the tilde stands for “my home directory on that machine”.
For more complicated file moves, try sftp
or rsync
. Learn more with man sftp
or man rsync
.
Cross-platform File Transfer with FileZilla
If you have trouble with scp
, you might try FileZilla.
- Download and install the FileZilla Client
- Run FileZilla
- The top left icon is the “site manager”; click it
- If you already set up a site, you can reuse it; otherwise create a New Site
- Host
portal.cs.virginia.edu
- Protocol “SFTP”
- Logon Type “Ask for password”
- User
mst3k
— your computing id - Connect ()
- Host
- In the FileZilla window you have your local directory in the left pane and the labunix directory in the right pane. Navigate to the files you want to move, then drag and drop.
Hint on changing passwords
Remember, once you log in to a linux machine, in person or remotely, you can change your password by typing (where mst3k
is your user ID)
kpasswd mst3k
Due to a current issue with the password management server, password changes may not take effect for several hours after running
kpasswd
. This will be changed at some point, but probably not until after you’ve all set your passwords for the semester.