Unix 2 -- Logging On To math or pascal

Math 10 -- D. C. Smolarski, S.J.
Santa Clara University, Department of Mathematics and Computer Science

[Return to Math 10 Homepage]
[Return to Unix 1 Page | Go to Unix 3 Page ]

Contents


Logging on to math

After connecting to math, you will be prompted for your username by the system prompt login:. Enter the 8 character (or fewer) abbreviation of your name (followed by the enter key). Then enter your password after the Password: prompt.

Initially you will be given a password to be used. At the first login, you will be asked to change your password and enter a new one twice and then log in again. The password must be at least 6 characters long and must contains at least two alphabetical letters and at least one number.

Logging Out

To log out, one invokes the command
     exit
or the command (if using math)
     logout
at the system prompt.

If you are using CDE, click on the EXIT icon in the middle of the "Front Panel" to the right of the "Four" icon. If you are using KDE (on pascal), click on the K icon on the left end of the task bar and then click on logout.

Changing your Password

Computer passwords should be changed regularly. Some systems are set so that the password must be changed at regular intervals.

To change your password, type

     passwd
at the system prompt. The program will prompt you for both your old password and the new one (twice!).

Pick a password others will not be able to guess easily. It must be at least 6 characters long with at least two alphabetical letters and one number. Do not use any part of your name or a friend's name and do not use a word that is in a dictionary.

On most systems, letters past the 8th are ignored, so the first 8 characters shold be a good, self-contained password.

It may take a few minutes for a new password to take effect. If you should ever forget your password, contact your instructor for advice.

Resetting the Shell

The nature of a Unix shell is explained at the following link, Which Unix Shell Should I Use?.

In brief, a shell is interface between the operating system and the user. Most Unix commands will work in any standard shell, but some shells have additional features (like file name completion or command recall) that other shells do not have.

The oldest shell is called the Bourne shell, invoked by the command sh. A old superset of the Bourne shell is called the Korn shell, invoked by the command ksh. A newer superset of the Bourne shell is the POSIX shell which is the default shell on math. Both of these shells make the use of "scripts" easy (a script is similar to a "batch" file in DOS, in which several system commands can be included and invoked as a mini-program).

Probably one of the more widely used shells is the C-shell, invoked by the command csh, and this is the shell whose commands frequently appear in texts. A superset of this shell, sometimes called Turbo-C-shell, is invoked by the command tcsh. The tcsh shell allows for command line completion (using the TAB key) and for recall and editing of previous commands (using the uparrow key).

After logging in, you can always change shells during your session. But most users perfer to use one shell rather than another so that they have their preferred shell automatically each time they log in.

You can change your login shell by invoking the following commands:
For tcsh--
on math

     chsh username /opt/tcsh/bin/tcsh
or, on pascal
     chsh -s /bin/tcsh
For csh--
on math
     chsh username /usr/bin/csh
or, on pascal
     chsh -s /bin/csh
(where username is your personal username and the last character string corresponds to the desired shell.)

After invoking this command, your shell will automatically be the one designated until you change your shell again.

Specific information about the shells available on the systems and their locations can be found through the on-line help file by invoking (on math)

     man sh
or (on pascal)
 
     man shells

My recommendation is that you use Turbo-C-shell (tcsh) as your default login shell. To do this, execute the first chsh command given above.

When using the Turbo-C-shell (or C-shell) on math, you will be prompted for the terminal type (TERM=) when logging in. The default indicated should be "vt220." This should be accepted (by pressing "Enter") if using a campus machine other than in O'Connor via ReflectionX. If you use ReflectionX, enter "hpterm." (On the other hand, enter "xterm" if using an X-Windows terminal). When using POSIX or other shells, you may need to use the command

    TERM=vt220
These commands will conform the interface correctly to the physical machine you are using so that graphics and cursor movement will occur correctly.


[Return to Math 10 Homepage]
[Return to Unix 1 Page | Go to Unix 3 Page ]

This page is maintained by Dennis C. Smolarski, S.J. dsmolarski@math.scu.edu
© Copyright 1998-2001 Dennis C. Smolarski, SJ, All rights reserved.
Last changed: 13 September 2001.