Login to your Instructional Unix Account

For several classes in EECS, you will be doing your assignments by logging on to a shared machine (server) running the Unix operating system. Even though you may be using a personal computer or a workstation that is capable of computation locally, you will mainly be using them as terminals (clients), whose job is to pass keystrokes to the server and display outputs from the server.

To use a shared machine, first you need an account on the machine.

The name of the instructional server may be newport.eecs.uci.edu, ladera.eecs.uci.edu, or malibu.eecs.uci.edu. You can log in to your account with your user name and password. Your account also comes with a certain amount of disk space. You can use this space to store homework assignment files, and you don’t need to bring your own disks or other storage media.

If ladera.eecs.uci.edu is down you can try another machine listed upon login. You can use the same user name and password, and your files will be the same. However, ladera runs the Gnu/Linux operating system, while the others run SunOS.  This means they will run different versions of the commands, which may behave the same or slightly differently; or some commands may be available on one but not on the other.

1. Application for an EECS Account

(*** My knowledge on how to apply for an EECS Account is outdated... please help.  I think the instructor sends batch request to Duncan Phillips or Evans Curtis at OIT? ***)

  • majors
  • non-majors

2. Software and Commands for Remote Login

You can connect to these Unix servers from virtually any computer anywhere that has internet access. What you need is a client program for remote login.

Previously, people used rlogin or telnet to connect to the server, and ftp or rcp to transfer files. However, they are insecure, because your keystrokes or output are in clear text and can be snooped by others. This means your account name and password can be stolen this way. So, for security reasons, do not use either of these programs.

Instead, use ssh as the primary way to connect to the server. ssh stands for secure shell, and it encrypts your network communication, so that your data looks like garbage to snoopers. For file transfers, use sftp (secure file transfer protocol) or scp (secure copy), which are secure. You could also set up an ssh-tunnel so that previously unencrypted communications can be encrypted.

Depending on what computer you use, it may have a different implementation of ssh, but the basic function underneath are all the same. 

  • If you are logging in from a Win32 machine (e.g, NT, XP, Vista, etc), you can use PuTTY.

  • Actually, Win32 users are strongly recommended to install Cygwin, which gives you a unix-like command- line environment. It can be downloaded for free from http://www.cygwin.com/. Once you download the installer (setup.exe), choose the packages for SSH, X Windows, and other tools you find useful. If you install the SSH package in Cygwin, then you can just use it instead of PuTTY to log in to the instructional server.

  • MacOS X and Gnu/Linux already has this built-in (use Terminal or X11 to run a unix shell). MacOS X users can also consider iTerm, which supports enhanced features. PuTTY is also available on Linux.

  • iPhone/iOS users can try iSSH, pTerm, or TouchTerm. 

The command to login to the instructional server is 

    % ssh ladera.eecs.uci.edu -l yourUserName

alternatively, newer versions of ssh can use the newer syntax

    % ssh yourUserName@ladera.eecs.uci.edu

It will ask you for the password. However, you can set up your ssh public/private key pairs so that you don’t have to type in the password when logged in from your account. 

If you are logging in from an X terminal, you can use the command

    % ssh ladera.eecs.uci.edu -X -l yourUserName

alternatively, newer ssh can support the command line syntax

    % ssh -X yourUserName@ladera.eecs.uci.edu   (If -X doesn’t work, try -Y)

(note: % is the prompt, not part of your command) It will prompt you for your password. Note that the -X option allows you to run programs that open X windows on your screen (e.g, Netscape, IDLE, xclock, acroread, mozilla, etc). However, for the purpose of this course, we probably will not make use of any features specific to X-Window.

3. The Unix Shell

By now you should be logged in, and you should be looking at the prompt

ladera% _

Note: in the following writeup, we will show just

%

for the prompt, instead of

ladera%

If you login to another machine, such as malibu, then the prompt would instead look like malibu%

The fact that % is used as the prompt indicates that it is “C shell” (csh or tcsh), which is Berkeley-style shell and is common for Sun OS environments. Another shell with recent rise in popularity is bash, for Bourne-again shell. It is written for the GNU free software project and is now the default for MacOS X, Linux, Cygwin, and more. There are some minor differences between bash and csh, but for the most part, the commands described here are the same.

You should change your password using the passwd command. The password will be changed on all the servers, not just on the server you are logging into.

Try out the following commands at the shell prompt.

ls list files
cd (change working directory)
pwd (print working directory)
mkdir (make directory)
mv (rename/move files)
cp (copy files)
rm (remove files)
rmdir (remove directory)
cat (print the content of a file)
more (print the content of a file, one screen at a time)
echo (print the arguments on the rest of the command line)

 

Most commands take one or more file names as parameters. When referring to files, you may need to qualify the file name with directory references, absolute vs. relative paths:

. (current directory)
.. (one level higher)
~ (home directory)
/ the root (top level) directory

 

Scholarly Lite is a free theme, contributed to the Drupal Community by More than Themes.