Section 2: Logging in and Logging out
To ensure security and organization on a system with many users, Unix
machines employ a system of user accounts. Unix account have been created for all
students enrolled in CSC classes. This section familiarizes you with logging in
and out your own Unix account.
This semester we will be working on two Unix machines: a Linux machine
called felix and a Sun machine called
tanner. You can connect to any of these machines
remotely using the secure shell SSH, which you can download on
your laptop from
-
http://csc.villanova.edu/login (Windows and Linux --
follow the Protected Downloads link)
Within campus, you have the option to connect to these machines using
telnet. It may happen that you cannot access felix or
tanner directly, but rather through an intermediary machine
called csgate (keep in mind that telnet is enabled to
work only within campus, due to lack of
security).
Logging in
Logging in to a Unix system requires two pieces of
information: a username, and a
password.
To log into tanner, follow the following sequence of steps.
On any Windows machine within the domain villanova.edu, click on
Start, then select Programs, Accessories and then
Command Prompt. You are given a command prompt that looks like this:
- C:>
Type in
- telnet csgate.csc.vill.edu
and hit the return key. You will be given a login prompt
- login:
Type your
username
at the login prompt, and press
the return key. The system will then ask you for your password.
- Password:
When you type your password, the screen will not display what you type.
A terminal window running the
Unix shell will open on your screen. At the shell prompt, type in the command
- telnet tanner.csc.vill.edu
You will be asked again for your username and your password. Type them in as before.
A new shell running on tanner will prompt you for input. Any command that you
type in at the shell prompt will now run on tanner and the result will be displayed in
your terminal window.
A secure shell will ask you for the same three pieces of information:
the target machine (say, felix.csc.villanova.edu), your username
and your password. Once connected to the remote machine, you will
interact with the Unix shell by typing in commands and inspecting the
answers.
Logging out
When you're ready to quit, type the command
- exit
Before you leave your terminal, make sure that the
computer indicates that you have successfully logged out. If you
have left any unresolved processes, the Unix system will require you to resolve
them before it will let you log out. Some shells will recognize other commands
to log you out, like "logout".
Your username
Your username is the first letter of your first name
followed by the last name (no more than 8 characters for a username, all in
lower case). Your username must be unique on the system where your account exists
since it is the means by which you are identified on the system.
To ensure uniqueness, the algorithm for generating a username is
- First Character of First Name + Last Name (first 7 chars)
- First Char of First Name + Initial + Last Name (first 6 chars)
(if no initial, the second char of first name)
- First and Last Char of First Name + Last Name (first 6 chars)
- First Char of First Name + 1 + Last Name (first 6 chars)
- First Char of First Name + 2 + Last Name (first 6 chars)
- First Char of First Name + 3 + Last Name (first 6 chars)
- First Char of First Name + 4 + Last Name (first 6 chars)
- First Char of First Name + 5 + Last Name (first 6 chars)
- First Char of First Name + 6 + Last Name (first 6 chars)
- First Char of First Name + 7 + Last Name (first 6 chars)
- First Char of First Name + 8 + Last Name (first 6 chars)
- First Char of First Name + 9 + Last Name (first 6 chars)
Your password
When your account has been created, a password has been assigned.
If this is a new account, your password has been set to the letters 'FA'
followed by the villanova student id number (e.g., FA12345678).
The first thing you should do is change your password, using the
passwd utility. Make sure you are logged onto a machine other
than felix (tanner, for instance) when you change your password.
To change your password, type the command
- passwd
after you have logged in. The system will ask for
your old password, to prevent someone else from sneaking up, and changing your
password. Then it will ask for your new password. You will be asked to confirm
your new password, to make sure that you didn't mistype. It is very important
that you choose a good password, so that someone else cannot guess it.