How to login to Linux at DCU
There are many different ways to use Linux at DCU.
- Go physically into CA labs.
- Reboot a PC.
- Choose Linux.
- The School of Computing ("CA") has its own Linux and Windows sysadmins.
- For Linux admin problems (e.g. password issues) see docs:
And can email sysadmins at:
support@computing.dcu.ie
Access from home and from Windows.
- ssh
- This is a hugely important protocol, in use globally to give you a command-line on a remote Linux/Unix system.
More below.
- sftp
- This is a hugely important protocol, in use globally to give you a read-write file system on a remote Linux/Unix system.
More below.
- Web browser access
- A more recent invention is Web browser access to do ssh (command line only)
or maybe get an entire GUI
through the Web browser.
This is set up for DCU, but may not be set up for other Linux systems you will meet elsewhere.
student.computing.dcu.ie Linux account
All the remote access routes lead to your student.computing.dcu.ie Linux account.
I have my own such account, which is
mhumphrysdculab
My account has the following properties:
Your account will be similar
(change user name and group name).
Apparently all students are now under:
/users/student
2FA
A single password is very handy, but sadly is not very secure.
Globally, hackers run bots trying to guess passwords of ssh logins on large numbers of servers.
Your password may be hard to guess,
but if there are lots of users,
some
will have simple passwords and the bots will get in.
DCU uses a
2FA
security system for many things.
The idea is you need something else, that a hacker will not have.
For example, it is linked to your phone.
- DCU used to require 2FA for student.computing.dcu.ie.
No longer, it seems.
- DCU 2FA help for other things.
ssh keys
A simple form of "something a foreign hacker will not have"
is to use
ssh keys.
This is a key kept as a file on your computer, that must match another key on the server.
The key is
huge (like around 1600 characters)
so unlike a password cannot be guessed by the hacker's bot.
If you use ssh keys, you
do not need 2FA or password.
ssh is the normal way globally of getting command-line access to a Linux/Unix system.
(Web interfaces like termcast are not so common.)
Windows ssh client: PuTTY
- PuTTY (free)
- PuTTY download
- PuTTY FAQ
- Some settings you might change:
- Connection - Data - username
- Right-click bar - Change settings - Colors - Use system colors
- Change settings - Appearance - Change font
- Stop sessions timing out when idle: Connection - "Seconds between keepalives" - set value to say 30
- Window - Behaviour - Warn before close - off
- Copy-and-paste
is strange on PuTTY:
- Copy - Select text
- Paste - Right-click (or Shift-Insert)
- Right-click Paste is rather dangerous, so you can change this:
- Window - Selection - Right brings up menu
Notes for later
If you set up ssh keys,
then you can use ssh and sftp without
password or 2FA.
- Login to Linux
- Setup a .ssh directory if it does not exist
mkdir ~/.ssh
- Generate keypair using
ssh-keygen
cd ~/.ssh
ssh-keygen
Hit enter to accept default filename.
Hit enter to skip passphrase.
-
Result is private and public key files:
- Append public key to authorized_keys:
cat id_rsa.pub >> authorized_keys
- Hide authorized_keys:
chmod go-rwx ~/.ssh
chmod go-rwx ~/.ssh/authorized_keys
This is important. Clients may generate cryptic errors if authorized_keys is not hidden.
- Copy private key to your PC.
There could be various ways of doing this.
- To use private key with PuTTY:
- Now you have a private key on your PC,
you tell your ssh and sftp clients to use this private key instead of a password.
You need to tell it username.
-
You will find it logs you in with no password and no 2FA.
One way of transferring files to/from your Linux account:
- Insert USB key.
- It appears under: /media/disk
- media icon on desktop - Unmount
sftp or similar is the normal way of getting remote read-write file system access to Linux/Unix systems.
Notes for later
How to turn an sftp site into a drive
If (as is common) you have a Windows client and a Linux server,
you can use sftp to turn the Linux server into a
drive on Windows,
like the X: drive.
sftp likes a silent shell