NETWORK USER'S GUIDE

This guide is for new users of the Ryerson Electrical and Computer Engineering department's computer network. Please browse through the table of contents for a overview of this guide. It answers common questions, collected over several years, that many new users of the department's networking facilities have.

Availability

This guide is available online at: http://www.ee.ryerson.ca/guides/user/

Typographic conventions

Interactive Unix commands are typed into a terminal window (e.g. xterm). Examples that depict user input to a terminal window are typeset as follows:

mkdir ele532

This indicates that you have to type mkdir ele532 and then press the Return (or Enter) key.

The output of a program is typeset as follows:

Rank   Owner/ID    Class  Job   Files     Size    Time 
 1    bob@thor       A    424  lab1.ps    33244   07:40
 2    jsmith@thor    A    425  report.ps  18265   07:42

CONTENTS

NETWORK AND LAB RULES

All the workstations in the department (in the labs, in the administrative and faculty offices) are networked together with home directories and applications served from a central file server. All workstations have access to the Internet through a gateway.

The network consists primarily of x86 workstations running Linux (Fedora Core 10) with Windows/XP emulated in VMWare, some labs have Sun SPARC workstations running Solaris 10.

All users should be aware of the following rules governing the use of the network, the labs and the workstations:

ALL USERS WHO HAVE AN ACCOUNT ON THE DEPARTMENT'S COMPUTER NETWORK IMPLICITLY AGREE TO ABIDE BY THESE RULES AND BY THE STUDENT CONDUCT CODE ESTABLISHED BY RYERSON ACADEMIC COMPUTING SERVICES AS SPECIFIED IN THE RYERSON CALENDAR UNDER THE SECTION TITLED COMPUTER SERVICES/FACILITIES.

REPORTING PROBLEMS

If you encounter a problem with any lab equipment, a specific workstation or printer, please note the name of the workstation/printer, the room number it is situated in and report it to a staff member. Contact information for technical staff responsible for a particular lab is posted on the inside of every lab door.

LOGGING IN AND OUT

Logging in to your account

You will need a login ID and a password before logging onto the network; the login-screen resembles the image below:

Login screen of the workstations on the Electrical Engineering Network.

Your login ID

Your login ID name on the Electrical and Computer Engineering network is the same as your short MATRIX login ID (8 characters). Please see the next section.

How do I find my short MATRIX login ID

  1. Login to my.ryerson.ca.
  2. In the window titled Manage My Online Resources, click on the "Manage my Online Resources: Self-serve password change and resources request" link.
  3. Click on the Owner Information link.
  4. The Short ID is at the bottom of the page.

In the Manage My Online Resources window, click on "Manage my Online Resources".

Click on "Owner Information" link.

Your MATRIX short ID is at the bottom of the page.

Your initial password

Your initial password will be the first 8 digits of your student number. The first thing you should do after logging in, is to change your password (refer to section 2.2.1), to prevent other students from abusing your account.

IMPORTANT NOTE: WHEN TYPING IN YOUR STUDENT NUMBER, DO NOT USE THE NUMERIC KEYPAD; INSTEAD, USE THE NUMBERS ALONG THE TOP OF THE KEYBOARD.

Logging in

To login to your account:

  1. If the screen of the workstation is blank, move the mouse.
  2. Type your login ID, press Return.
  3. Type in your password (it will not appear when you type it in), press Return.

If you are unable to login, ask network operations staff in ENG439 for assistance.

Your password

Before changing your default password, you should choose a secure password (refer to section 2.2.1, below). It is important to have a secure password to ensure the integrity of both your account and the network.

A password is considered secure if it is difficult for someone else to guess it (this includes those who use "cracker" programs that attempt to guess passwords).

NEVER DIVULGE YOUR PASSWORD TO ANYONE, INCLUDING YOUR FRIENDS, FAMILY MEMBERS, OR PETS. IF YOU RECEIVE AN EMAIL REQUESTING YOUR STUDENT NUMBER, PASSWORD, DATE OF BIRTH, ETC. DO NOT RESPOND TO IT, JUST DELETE IT.

The account owner will be held responsible for any actions performed from their account.

Choosing a secure password

Following these few rules will ensure a secure password:

With all these restrictions, you're probably wondering what's left; here are a few suggestions:

Changing your password

Once you have thought of a secure password, here are the steps for changing it:

  1. Login (refer to section 2.1 for details).
  2. Select Applications -> Terminal from the menu to open a Terminal; all the commands, below, are typed into this terminal window).
  3. Move the mouse until the pointer is inside the window (the pointer will change to an arrow).
  4. Type: yppasswd

You will be asked to enter your current password (which will be the first 8 digits of your student number), then you will be asked to enter your new password twice.

Logging Out

Select System -> Logout... from the menu to logout.

ACCOUNTING

About your EE account

First-year students are not given accounts on the Department network.

Beginning with your second year, your account will exist until you either graduate from, or drop out of, the program. Your account remains active during the summer months and during your optional internship work term.

Your EE account is only valid for computers in the Center for Computing and Engineering (ENG building); your Matrix account is on a different network.

After graduation you can keep your account by requesting an Alumni Account or you can have all your email forwarded to another email address of your choice, by subscribing to the Alumni Email Service. Forms for both of these services are available in ENG478 and on the departmental website.

Your home directory

After logging in, you can access all your personal files using either the file-browser (double-click on the "Home-folder" icon on the desktop) or using a Terminal window. When you open either a Terminal window or the file-browser, you will start in your home directory.

Double-click on the Home-folder icon to open the file browser.

Account charges

At the beginning of each school term (September and January), every undergraduate student receives $5.00 to cover any printing, disk storage costs you may incur during that term.

Updated Feb. 2013: Your disk storage quota (the maximum amount of storage you are allowed) is set to 500MB . The first 450MB of storage in your home-directory is free of charge— you will not incur any charges if you maintain your home directory disk storage under 450Mb. Table 4.1 lists a summary of the accounting charges.

Service Charges
Laser printer (single-sided) 6 cents/page
Laser printer (double-sided) 10 cents/page (5 cents/face)
Home directory 1 cent/day for every Mb over 450 Mb

Table: Accounting charges for undergraduate students.

Your account is active during the summer and during your internship workterm and any charges especially for unread email incurred during this period will have to be accounted for. If you plan on not using your account for long periods, refer to section 5.4.3 for instructions on making your account dormant.

Account balance

Any costs incurred on the previous day, for disk-space, mail-space, printing and modem use, may be viewed along with your current balance; select Applications ->Your Account ->Account Charges.

If you are remotely logged-in, type:

account

  Charges for: Feb 19 2013
         User: jsmith (student)
   Accounting: 450MB free, 1c/Mb/day disk
        Quota: 500 Mbytes
  Modem usage: $0.0000    (0.0 minutes)
   Disk space: $0.0000    (1368 Kbytes)
     Printing: $0.1000    (2 pages)
        INBOX: $0.0000    (0 bytes)

        Total: $0.1000
      Balance: $4.4126

Negative account balance

A negative account balance indicates you are overdrawn on your account. You will receive email for 7 working days reminding you that your account is negative. You will be automatically locked out (unable to login) from your account if you maintain a negative balance for more than 7 days and the charges will accumulate while you are locked out (you will be locked out sooner if you are overdrawn by a large amount).

You can add money to your account by depositing it with the secretary at the department office in ENG478 . Typically, your account will be credited within 24 hrs. Once your balance is positive, you will automatically be unlocked within 24 hours.

IMPORTANT NOTE: 1. YOU WILL BE UNABLE TO PRINT IF YOUR ACCOUNT BALANCE IS NEGATIVE.

IMPORTANT NOTE: 2. IF YOU NEED YOUR ACCOUNT TO BE UNLOCKED IMMEDIATELY, YOU WILL BE CHARGED $1.00. This amount will be deducted from your account balance.

HOW DO I AVOID GETTING CHARGED?

How do I conserve my home directory diskspace?

You can conserve diskspace by compressing your files. The program to compress files is gzip; use gunzip to uncompress them.

For example, to compress lab1.ps, type:

gzip lab1.ps

Compressed files are given the extension: .gz.

For example, to uncompress lab1.ps.gz, type:

gunzip lab1.ps.gz

You can also compress the entire contents of a directory by giving the -r option; e.g. gzip -r labs/.

Emacs and xemacs will compress and uncompress files on-the-fly, so if you use either of these editors you don't have to uncompress the files before loading them into the editor.

Delete core files

A core file is a complete snapshot of the memory at the time a program crashes. This file is used for debugging the reason for the crash. core files can be safely deleted.

What is taking up all my diskspace ?

There are two ways to check the file-usage in your home folder. You can view a text list of the 10 biggest files in your home or alternatively you can get a graphical representation of all the files in your home folder.

To get a list of the 10 biggest files in your Home folder, select: Applications ->Account ->Find Largest Files.

You can also view the list if you are remotely logged-in or using a Terminal; use the dw command to display a list of the 10 biggest files. dw begins searching from the folder you are currently in. To search the entire contents of your Home folder, cd to your home directory and then run dw. For example,

/home/student2/jsmith> dw

- 1 jsmith   student    45660784 May 25 13:28 ./ELE404_Lab1_report.pdf
- 1 jsmith   student    40335888 Apr 28 16:24 ./movies/Mov_3071.AVI
- 1 jsmith   student    29538065 Feb  9 00:10 ./Fourier_poster.psd
- 1 jsmith   student    15910040 Apr 28 16:03 ./movies/Mov_3076.AVI
- 1 jsmith   student    15548416 Apr  1 20:17 ./mp3/a_place.mp3
- 1 jsmith   student    15119081 Apr 29 16:49 ./public_html/mpeg-binaries.zip
- 1 jsmith   student    15099836 Apr 28 16:00 ./movies/Mov_3074.AVI
- 1 jsmith   student    14852470 Apr 28 15:21 ./movies/Mov_3075.AVI
- 1 jsmith   student    12227964 May  4 15:22 ./maps/world.psd
- 1 jsmith   student    11921408 Mar 30 12:17 ./spheric_lounge.ps

To get a graphical view of your file usage, select: Applications ->System ->Disk Usage Analyzer. Then in the window that appears, click the Scan Home button and wait while your directory is scanned.

The Disk Space Analyser can display a graphical representation of your home folder showing disk usage. You can change the representation from tree-view to rings-view using the menu on the right.

How much diskspace am I using?

To find the total amount of storage in your home directory: Right-click the Home icon on your desktop and select Properties.

Alternatively, you can select Applications ->Your Account ->What is my diskspace?. The pop-up window will display your disk usage and quota in bytes.

Print multiple pages of a PDF or PostScript document onto a single sheet

You can save printing costs by reducing and printing multiple pages of any PDF file onto a single sheet of paper (``N-up'' printing); please refer to the Printing section.

Reduce Firefox Cache

Firefox stores viewed files (html and images) in a cache directory called ~/.mozilla/loginame/xxx.slt/Cache so when you re-visit a site, it will read the local copies of the files rather then retrieving them again. It is recommended that the Disk Cache be set to 0 Mb.

Set the Firefox cache size to 0 via: Edit ->Preferences ->Advanced ->Network.

INTERACTING WITH THE TERMINAL

Most everyday tasks can be carried via menus and by double-clicking, dragging-and-dropping files and icons. However, there are certain tasks that can only be performed via the Terminal; e.g. submitting you labs. So it is to your advantage to familiarize yourself with a few operations of the Terminal.

Working with the shell

The shell is a program that interprets commands that you issue to the operating system. Your default shell is zsh, the Z shell. Any commands executed in a Terminal, are issued by interacting with the Z shell.

The table below summarizes common Unix commands you will find useful.

Unix CommandAction
ls list directory contents
cd dir change directory to dir
mkdir dir/ create a new directory called dir
rmdir dir/ remove directory called dir
rm file delete file (there is no undelete!)
cp source dest copy a file from source to dest
mv old new rename (move) old to new
lpr -Pprinter file print file on printer
lpq -Pprinter list jobs in the printer queue
lprm -Pprinter jobId remove job jobId from the printer
less file display the contents file
ps list processes currently running
kill pid kill process with id pid
man command displays manual page for command
chmod perm file give file permissions (see sec. 3.5.1)
file file identify the type of file

The shell prompt

The shell prompt displays the hostname ("sparrow") of the workstation you are currently logged in to and the current working directory ("/home/student2/jsmith"). When jsmith logs in to sparrow her prompt will look like:

sparrow: /home/student2/jsmith>

Listing files

The command to list files (and directories) is ls.

For example, the simplest form of listing shows just the names of files and directories. Names that appear marked with an asterix ' *' are executable programs; names that appear with a slash ' /' are directories.

The ls command has numerous options that modify the listing. All these options are detailed in the on-line manual page. Refer to section 3.7 for help on using the on-line help system.

Filename completion

Filename completion is a feature of most modern shells that saves you from typing long filenames. The Tab key is used to complete a filename (or directory name) after typing the first few characters.

Subdirectories

It is recommended that you organize your labs and assignments by placing them in sub-directories (or "folders") named after each course you are taking.

For example, to create a sub-directory for ELE428, type:

mkdir ele428

To make ele428 your current working directory, type:

cd ele428

The prompt will change to:

sparrow: /home/student2/jsmith/ele428>

It is not necessary to know the exact name of your home-directory. The command cd (with no options) will place you in your home directory.

Running commands in the background

Whenever you type a command and press Return, the command executes and the shell-prompt is ready for the next command. However, if the command takes a long time to execute, or like mozilla (web-browser), opens a new window, the Terminal becomes unusable since the prompt will re-appear only after the command completes or is interrupted (via Control-C). Running a program "in the background" returns the prompt immediately while the program continues to run.

To run mozilla in the background, simply append an ampersand & to the command:

mozilla &

HINT: Invoke commands that create their own application window with an ampersand; e.g. gv &, emacs &, etc.

How do I delete a file?

The command for deleting files is rm (short for "remove").

For example, to delete lab1.ps, type:

rm lab1.ps

Several files may be deleted simultaneously:

rm lab1.ps lab1.c lab2.*

Directories containing files may be deleted recursively by typing:

rm -rf ele792/

Printing

To save paper, all printers print on both sides of the paper, by default.
The printer partially ejects the paper before printing on the obverse side.
Do not grab the paper emerging from the printer until it is fully in the tray
or the printer will jam.

All public printers (see Table 3.2, below, for names and locations) in the department are networked. You can print a file from any workstation on the network to any printer on the network. Refer to Table 4.1 for a summary of printer related accounting charges.

IMPORTANT NOTE: 1. YOU WILL BE UNABLE TO PRINT IF YOUR ACCOUNT BALANCE IS NEGATIVE.

IMPORTANT NOTE: 2. ONLY POSTSCRIPT OR TEXT FILES CAN BE PRINTED. THE PRINTER WILL REJECT ALL OTHER TYPES OF FILES; IMAGES MUST FIRST BE CONVERTED TO POSTSCRIPT BEFORE PRINTING.

IMPORTANT NOTE: 3. XEROX N24 PRINTERS PARTIALLY EJECT THE PAPER BEFORE PRINTING ON THE OBVERSE SIDE. DO NOT GRAB THE PAPER EMERGING FROM THE PRINTER UNTIL IT IS FULLY IN THE TRAY OR THE PRINTER WILL JAM.

What are the printers called?

Table 3.2 lists the printer names, room locations and capabilities. All printers print double-sided, by default; to print single-sided add the suffix "s" to the name.

Printer Name Default Single-Sided Name Room
prism double-sided laser prisms ENG408
prune double-sided laser prunes ENG409
piano double-sided laser pianos ENG412
pizza double-sided laser pizzas ENG307

Table: Printer names and locations.

How do I print a file?

IMPORTANT NOTE: BEFORE PRINTING A FILE ALWAYS USE THE lpq COMMAND TO CHECK WHETHER THE PRINTER YOU ARE GOING TO PRINT TO, IS READY AND ABLE TO PRINT.

lpq: Check the queue

The command to check the status of the printer and the status of the job queue is lpq. If the printer is busy, the jobs still in the queue, waiting to be printed, will be displayed.

For example, to check the printer status for piano, type:

lpq -Ppiano

If the printer is ready, and if there are no jobs in the queue, the response will be similar to:

Printer: piano@panzer 'Xerox 24N ENG412' (dest raw@piano)
 Queue: no printable jobs in queue
 Status: server finished at 14:10:23

Otherwise, lpq will respond with the location (rank) of the job in the queue, the owner, the job-id, the file name and the file size:

Rank   Owner/ID    Class  Job   Files     Size    Time 
 1    bob@vader      A    424  lab1.ps    33244   07:40
 2    jsmith@thor    A    425  report.ps  18265   07:42

lpr: Print the file

Once you have determined that the printer is working, you can proceed to print the file using the command lpr.

For example, to print the file lab1.ps to the laser printer called purple (the -P option is used to specify the name of the printer), type:

lpr -Ppurple lab1.ps

To print multiple files to the laser-printer prism, you would type:

lpr -Pprism lab1.c.ps lab1.h.ps

For example, to print single-sided on prune (which, by default, prints double-sided), you would add an "s" to the printer name and type:

lpr -Pprunes lab1.ps

HINT: To avoid specifying the printer everytime you print, add the following line to your ~ /.myzshrc replacing prism with the default printer of your choice:

export PRINTER=prism

(Refer to section 4.2.4 explains how to save money when printing files.)

How do I print an .eps file?

Encapsulated PostScript files (.eps) are meant to be embeded into documents. Although they can be viewed (using gv) they cannot be printed by default.

Before printing an .eps file, the PostScript command, showpage must be added to the end of the file. You can do this in two ways:

  1. Load the .eps file into an editor and add a line with the word showpage at the end (the very last line) of the file and save the file.

  2. Alternatively, make a copy of the .eps file and append a showpage command to it. In a Terminal, type:

    cp file.eps file.ps
    echo showpage >>file.ps

I can't print my file, it's too big

To print very large PostScript files (greater than 8 megabytes), use the -s option:

lpr -s -Ppiano very-large-file.ps

How do I cancel a print job?

If you print something and then decide you don't want it, you can cancel the job as long as the job is still in the queue. Once the job begins to print, you can only cancel the unprinted portion of your job. The command to cancel a print job is lprm; you can only cancel your own print jobs.

First use lpq to determine the job-number you wish to remove:

lpq -Pprism

Rank   Owner/ID    Class  Job   Files     Size    Time 
 1    bob@vader      A    424  lab1.ps    33244   07:40
 2    jsmith@thor    A    425  report.ps  18265   07:42

Assuming you are jsmith, to remove job 425, type:

lprm -Pprism 425

IMPORTANT NOTE: After a job is canceled, any pages of the document remaining in the printer's memory will print.

How do I view/print PDF files?

Double-click the PDF file in the file-browser to view it. To print the file select: File ->Print...; select the printer from the Printer tab; select the page-range from the Job tab; click on Print.

IMPORTANT NOTE: 1. When printing large PDF files (e.g. data sheets), split the print job into multiple parts by printing a few pages at a time.

How do I print multiple pages of a PDF or Postscript document onto a single sheet?

Multiple pages of any Postscript file can be reduced and printed on a single sheet of paper (N-up printing) using the psnup command. Note that before you N-up a PDF document, you must first convert it to Postscript using the following steps...

Convert a PDF file to PostScript prior to N-up

PDF files can be converted to PS by selecting Generic PostScript as the printer and Location: File.

  1. Double-click the PDF file
  2. Select File ->Print...
  3. From the Printer tab, select Generic PostScript
  4. From the Location pull-down menu, select File
  5. Change the filename, if necessary, and click Print
  6. Use psnup to print multiple pages of the document on a single sheet.

Print the PostScript document via psnup

For example, to print 2 pages per sheet (4 pages double sided) of the Postscript file, report.ps, to printer piano, type:

psnup -n 2 report.ps | lpr -Ppiano

Those with exceptional eyesight may wish to try 4 pages per page (8 pages, double sided):

psnup -n 4 report.ps | lpr -Ppiano

How do I print multiple pages of a text document onto a single sheet?

Multiple pages of any plain text, ASCII file can be reduced and printed on a single sheet of paper using the enscript command. For example, to print 2 pages per sheet of paper (4 pages double sided) of mail.txt to printer prune, type:

enscript --printer=prune --nup=2 mail.txt

UNIX FILE PERMISSIONS

By default, other students or faculty on the system cannot read your files. You must explicitly allow them access by modifying the access permissions on the files or directories.

All the files and sub-directories in your home-directory are owned by you. They can be protected from or made accessible to other users by changing the access permissions. You may only change the permissions on files you own.

To look at the file permissions (and other information) use the ls -l command; open a Terminal and type:

ls -l

For each file in your directory, you will see a line similar to Figure 3.1:

File ownership and permissions displayed in a long-listing using the ls -l command.

The first item, -rwxr-xr-x is a rwx triplet for each of owner, group and other for the file. It represents the Read, Write and Execute permissions for the owner of the file, you (rwx), users belonging to the same group as you (r-x), and other users (r-x).

The next item, 1, represent the number of links to the file; jsmith, is the username of owner; student, the name of the group which owns it; 365, is its size in bytes; Feb 22 15:31, the time and date the file was last changed, and finally, lab1.c, is its name.

How do I change permissions?

The chmod command is used to modify permissions on files and directories. Table 3.3 summarizes the available options.

OptionDescription
+ grant permission
- remove permission
u user (your permissions)
g group (users in your group)
o other (everyone else)
a specifies all (u, g and o)
r read permissions
w write permissions
x execute permissions

Summary of chmod options

For example, to prevent other people from reading lab1.c ( -rwx --- --- ), type:

chmod g-r,o-r lab1.c

For example, (this is only an example) to allow all users to access your lab1.c (-rwx r-- r-- ), type:

chmod g+r,o+r lab1.c

a better alternative, is to type:

chmod a+r lab1.c

For example, to write-protect lab1.c.backup from accidental deletion (disable write permissions for all), type:

chmod a-w lab1.c.backup

REMOVABLE MEDIA

How do I access the floppy drive?

1. Double-click the Computer icon on your desktop. Then double-click the Floppy Drive icon in the window that appears. Then...

2. Double-click the Floppy icon and drag and drop the files into the floppy window. BEFORE REMOVING THE FLOPPY,
YOU MUST UNMOUNT THE DEVICE: Right-click "floppy" ->Unmount.

mtools

Alternatively, using a Terminal, the mtools suite of programs allows workstations, equipped with floppy drives, to read and write MSDOS format floppies. For example, to get a directory listing of the floppy disk, type:

mdir a:

To copy a file called lab1.c from the current directory (on the system) to the floppy disk, type:

mcopy lab1.c a:

To copy a file called lab1.c from the floppy disk to the directory you are in, type:

mcopy a:lab1.c .

CommandResult
mcd directory change to directory
mcopy source destination copy a file from source to destination
mdel a:filename delete filename
mdir a: get a directory listing
ejecteject the diskette (Suns w/o eject button)

Table: Summary of commands for accessing the floppy drive (a:).

How do I copy files to/from a USB key?

Double-click the USB key on the desktop to access the files. BEFORE REMOVING THE KEY,
YOU MUST UNMOUNT THE DEVICE: Right-click USB Drive ->Unmount.

Most PC workstations have USB ports either on the front-bottom or in the back. When inserted, the key will appear on the Desktop; double-click the icon to view the files.

The drive is mounted as a filesystem in /media/disk/. You may use a Terminal and all the normal Unix commands, (ls, cp, rm, mkdir, mv) to copy files to/from the key, rename and delete files on the key.

IMPORTANT NOTE: before removing the key from the computer, you must "Unmount" the USB-drive: Right-click on the USB icon -> Unmount. If you do not unmount the drive, your data will not be saved on the drive.

How do I access the CD/RW drive?

Some labs have workstations that are equipped with CD/RW drives. A data CD inserted into the drive appears on the desktop; double-click on the icon and the files will appear in a file browser.

To write data to a CD/R or CD/RW:

  1. Insert the blank CD into the drive and wait until the icon named "Blank CD" appears on the desktop.
  2. Select Places ->CD/DVD Creator from the Desktop Menu.
  3. Drag the files and/or folders you wish to write to the CD into the CD/DVD creator window.
  4. Click Write to Disc.
  5. Click OK on the dialog that appears.
  6. Wait until the Writing files to CD dialog completes.
  7. Click Eject, then Close.

Drag the files and folders into the CD/DVD creator window, click Write to Disc, and wait for the Writing files to CD dialog.

MISCELLANEOUS QUESTIONS

How do I undelete a file?

If the file you deleted is still in the Trash, you can still recover it. Once your trash is emptied, or if you used the rm command, files cannot be recovered.

However, since your home-directory is backed up nightly, an earlier version of a deleted file can be restored, if it was created on the previous day.

To recover a file, you need to email: admin@ee.ryerson.ca

  1. the name and complete path of the file(s) to be recovered,
  2. the exact day and time you deleted it,
  3. and the time the file was originally created.

For example,

Please restore ele428/lab6/main.c and ele428/lab6/parser.c deleted on April 16th at 1:20PM and created 2 days ago.

Working with .tar files

A Unix TAR (TApe aRchive) file is similar to a Windows ZIP file. A TAR file with a .gz extension has been compressed with gzip (.tgz is a synonym for tar.gz).

To view contents of the tar file lab1.tar, type:

tar tvf lab1.tar

To view contents of a compressed tar file lab1.tar.gz, type:

tar ztvf lab1.tar.gz

To extract the contents of lab1.tar.gz, type:

tar zxvf lab1.tar.gz

To create a compressed tar file called ele792.tgz with the contents of a directory called ele792, type:

tar zcvf ele792.tgz ele792

How do I find out more about a command?

Online help is available for every Unix command in the form of manual-pages. Each manual page explains how the command can be used and the numerous options available. Use the man command from a Terminal window.

For example, to read the man-page for the ls command, type:

man ls

The output will look like this:

LS(1V)                   USER COMMANDS                     LS(1V)

NAME
     ls - list the contents of a directory

SYNOPSIS
     ls [ -aAcCdfFgilLqrRstu1 ] filename ...

SYSTEM V SYNOPSIS
     /usr/5bin/ls [ -abcCdfFgilLmnopqrRstux ] filename ...

AVAILABILITY
     The System V version of this command is available  with  the
     System  V software installation option.  Refer to Installing
     SunOS  4.1  for  information  on  how  to  install  optional
     software.

Use the space-bar to page through the document; 'q' to quit.

Manual apropos

If you don't know the command name but know what the command does, you can use the -k (keyword) option to man to find the appropriate man-page. For example, to find information related to audio applications, type:

man -k audio

The output (on a Linux system) will resemble the following:

workbone (1)     - A program for playing audio CDROMS
audiocompose (1) - Compose an audio fragment 
audiosend (1)    - Send an audio email message
showaudio (1)    - Play an audio email message

Each command that matches the keyword is listed on a separate line showing the command name (showaudio), which section of the man-page it appears in (1), followed by a brief description of the command.

Additional documentation

Various guides, on a variety of topics, are installed in /usr/common/docs/guides/.

How do I copy and paste text with the mouse

Alphanumeric text can be copied from one application to another, using only the mouse. This technique is useful for copying and pasting between Terminal windows.

To copy text:

  1. Press and hold mouse button-1 (left).
  2. Drag the mouse to hilight the text.

To paste the selected text:

  1. Move the mouse to the application window you wish to paste the selected text into.
  2. Press the mouse button-2 (middle).

Is there a wordprocessor on the system?

OpenOffice is a freely available office suite, very similar to MS Office, published by Sun Microsystems, that includes a word-processor, a spreadsheet, a presentation program (like PowerPoint) and a drawing tool. It can import and export most common document formats like MSWord, PowerPoint, Excel, WordPerfect, etc.

The word processor is available from the menu: Applications->Office->Word Processor

IMPORTANT NOTE: The first time you run any of the applications in the suite, a setup dialog will appear. During the setup, accept the defaults settings. After setup finishes, select the application from the menu again.

Can I Run Windows/XP?

Most PC workstations can run Windows/XP as a client operation system via VMWare. To run Windows/XP, select: Applications->Windows XP. Note that all changes you make to Windows/XP will be lost when you exit VMWare.

My workstation Is not responding, what do I do?

DO NOT RE-BOOT THE WORKSTATION!

One possible reason for your workstation "freezing" is that a program (usually mozilla or Altera) has crashed or is a runaway (using 100% of the CPU).

In such cases, you can login from another workstation and either kill the mis-behaving program or log yourself off.

In the following example, assume the hung workstation is called darthvader and the user is jsmith; here are the steps to remotely login and list the running processes and then kill a process:

  1. Login to another workstation and open a Terminal (if there are no workstations free, ask someone next to you if you can use one of their Terminals).
  2. Remotely login to the hung workstation; type: telnet darthvader (if the workstation refuses your telnet connection, contact one of the network operations staff in ENG439 )
  3. Get a list of the running processes; type: ps -ef

    You will see a listing similar (albeit longer) to this:

      root 102   6750  0   May 12  ?        0:03 nscd
    jsmith 15161 9645  0 17:13:32  ?     1143:49 altera
      root 274   6750  0   May 12  ?        0:00 update
    jsmith 1039  3550  1   May 12  pts/1    0:00 ps -ef
    jsmith 32287 26271 0 11:41:36  ?        0:02 xterm
    jsmith 1196  26271 0 11:41:38  ?        0:00 gnome-session
    

    ps displays a list processes with the owner in the 1st column and the process-id (PID) in the 2nd column; the last column has the process name.

  4. Scroll through the listing and find the process you want to kill (e.g. altera) and type: kill -9 15161 (PID from the second column). To log yourself off, kill the process named gnome-session with PID 1196.

If the above steps do not work, then see the network operations staff in room ENG439.

How do I setup my home-page?

To create a default homepage, which you can later edit, and have the file and directory permissions correctly set, open a Terminal and type:

homepage

This program will create a public_html directory and a file called index.html, which is your home-page.

For example, the URL for jsmith's home-page will be:

http://www.ee.ryerson.ca/~jsmith/

IMPORTANT NOTE: ALL the files in ~/public_html (including images), that are refered to in your home-page, must have their global read-permissions set (chmod a+r filename.html) and directories (including your home-directory) must have global execute permission set (chmod a+x dirname). Refer to section 3.5.1 for an explanation of Unix file permissions/ownership.

How do I display an image in the background?

Use the menu System ->Preferences ->Desktop Background to select the image you wish to use. You can also drag and drop your personal images into the dialog and use them.

IMPORTANT NOTE: When choosing the resolution of your image, consider the that resolution of the monitors in the labs vary; they include 1152x900, 1024x768 and 1280x1024.

REMOTE ACCESS

How do I login from home via dial-up?

You can access your EE department account via commercial dial-up modems or via your ISP.

Terminal emulators

For access via modems, terminal emulators like procomm or telix under DOS, or HyperTerminal under Windows9x, or minicom (Telix clone) under Linux can be used. These communications programs only allow text-based (non-graphical) access and file upload/download services.

After logging in, you may need to set the terminal type and number of rows of your terminal, as follows:

export TERM=vt100
stty rows 24

How do I login from home via high-speed?

SSH Terminal client.

To connect to the department and access your EE account via high-speed Internet connection (Rogers, Bell Sympatico, etc.) you have to use a Secure-Shell application. The EE Department provides Windows, Mac and Unix clients and installation guides available for download from:

http://www.ee.ryerson.ca/secure/

Follow the instructions in the installation guide (PDF). After installing the software login to the host:

pascal.ee.ryerson.ca

Use the Windows/XP Secure Shell Client to login to the department from your home computer and transfer files.
Click Quick Connect and fill-in pascal.ee.ryerson.ca as Host Name, your EE login in User Name and press Connect.

After you have logged-in to pascal, you can then remotely login to any other host on the departmental network. See section below.

How do run programs or scripts on pascal?

After logging in to pascal, you must ssh to one of the workstations in the labs if you need to run or compile programs. In the Secure Shell Terminal window, type: ssh followed by the name of the (workstation you want to remotely login to. The workstation names are written on the computers and are displayed on the login screen). You will be prompted for your password again.

How do I transfer files via high-speed?

Secure file-transfer client.

After installing the Secure-Shell software on your home PC (refer to section 5.2), double-click on the "Secure File Transfer" icon on you desktop and login to pascal.ee.ryerson.ca. Use the application to upload/download your files to/from your local PC your EE account.

How do I mount my EE network account drive on my home computer?

INSTRUCTIONS FOR WINDOWS

First, download and install Bitvise Tunnelier FTP Bridge

Then, download and install Netdrive

On the Login tab, set the remote hostname to pascal.ee.ryerson.ca, your login and password go in the appropriate fields.

On the Services tab, Enable "Ftp to Sftp Bridge".

Make sure your Options tab is set as above.

Now click the Login button. You should see the following window:

Click "Accept and Save". This signature will be used to encrypt the communications between your workstation and the remote server.

You may be presented with the following window if either you've miss typed your pasword or you've told the tunneler not to save your encrypted password in profile on the first login tab.

Once you've successfully logged into the remote site you will see the following icon in your Windows XP panel.

So at this point your FTP to SFTP session has been setup.

Now we configure the Netdrive software.

The first panel sets the site name, IP address which we've setup already and the drive letter you want to setup to appear as your local connection. You don't have to enter your login and password as we've already created the ftp - sftp link with your credentials.

Click connect and you're done!!

If you go to "My Computer" you will now find another local drive.

While your connection is made to the remote site you will see the following icon in the bottom right corner.

INSTRUCTIONS FOR MAC OS X

Download FUSE4X and SSHFS from Github.

Install FUSE4X.

Unpack SHHFS and install the sshfs binary from ~/Downloads/usr/local/bin/sshfs into /usr/local/bin or into ~/bin (ensuring you have your environment PATH variable set accordingly).

To mount the remote directory, use the following command: sshfs hostname:/remote_directory local_directory

Where hostname would be pascal.ee.ryerson.ca, remote_directory would be your home directory (e.g. /home/student2/jsmith) and local_directory would be the location where you wish the remote drive to appear (e.g. /Users/John/Remote_EE).

EMAIL

Refer to Table 4.1 for a complete summary of charges related to email storage.

How do I read my email?

You can read your email securely from anywhere in the world from:

https://webmail.ee.ryerson.ca

Login using your E.E. Department login ID and password.

How do I forward my EE email to another account?

To have email from your EE account automatically forwarded to another account, using any text editor, create a text file in your home directory, called .forward which contains the email address you wish your email to be forwarded to (if you have more than one email address, enter each one on a separate line).

For example, if jsmith, wanted all her email from her EE account to be forwarded to her Yahoo account, she would create a file called .forward, containing the line:

janesmith@yahoo.com

All the email sent to jsmith@ee.ryerson.ca would be subsequently forwarded to jsmith@yahoo.com.

For example, If jsmith wants to forward her mail to a HotMail account, and also keep a local (EE account) copy she would create a .forward file with both email addresses, as follows:


jsmith67@hotmail.com

jsmith

IMPORTANT NOTE: To stop email from being forwarded, delete the .forward file.

Use Webmail to configure your .forward

Alternatively, you may use Webmail to create a .forward file to forward your EE email to another account. Here are the steps:

STEP 1. Login to Webmail using your EE department login and password.

STEP 2.

Click on "Options" along the top of the browser.

STEP 3.

Click on "Vacation Message".

STEP 4.

Scroll down until you see "Forwarding E-Mail Addresses".
Check "Forward incoming message to another email address?"
Add your remote email address(es) in the text box.
Click "Change Settings".

A .forward file will have been created in your home directory and any email you receive from this moment on will be forwarded to the email address(es) you entered.

How do I prevent email to my account during the summer break/IIP Internship?

If you are not planning on using your departmental account during the summer months or during the industrial internship program (IIP) and you do not want email accumulating in your mailbox, use the command:

stopmail

to make you account dormant. All email sent to your account during this time will be discarded. To begin receiving email again, run the command:

startmail

How do I filter out junk mail ?

procmail can be used to filter all incoming mail. You have to setup rules (based on the From:, To: or Subject: headers) to tell it what mail to keep and what mail to discard. To use it:

  1. Create a .forward file in your home directory, with the following line:

    "|IFS=' '&&exec /usr/local/bin/procmail -f-||exit 75 #USERNAME"
    

    replacing USERNAME with your login ID.

  2. Create a .procmailrc file in your home directory, with the filter rules. For example, to ignore all email from the account annoying@hotmail.com, the rule would be:

    :0
    * ^From:.*annoying@hotmail.com
    


    Refer to the manual page for procmailex and procmailrc (see section 3.7 for help on using the online help system). For examples of rules that you can then adapt for your own use .

How do I block spam email ?

It is impossible to block ALL spam (unwanted/unsolicited email messages) to a public email address-- it is only possible to block MOST (a large percentage) of the spam. Each account holder on the EE network has the option of enabling or disabling spam filtering for their account. To find out whether the spam filtering feature is enabled for your account, type the following at any xterm prompt:

SpamAssassin status

If the spam filter is enabled it will report:

   Spam Assassin is enabled.

Otherwise it will respond:

   Spam Assassin is disabled.

To enable the spam filtering feature for your account, type the following at any Terminal prompt:

SpamAssassin start

To disable the spam filtering feature for your account, type the following at any xterm prompt:

SpamAssassin stop

The spam filter that is installed on the departmental network will validate incoming mail against a number of rules which will determine whether or not the incoming email is spam or not. If the filter believes that the incoming email is spam it will move the mail into your ~/mail/caughtspam folder. This file will contain all incoming email that the filter thinks is spam. This email is collected so you can look through any emails that have been identified as spam and decide whether it is truly spam or whether it's a false positive.

Even though the spam filter attempts to block all spam, some spam will inevitably get through. All the spam emails that were missed should be stored in in a folder called ~/mail/missedspam. The system regularly will adjust your personl rules and adapt itself to block new incoming spam.

Do I have to watch my caughtspam file?

Yes, as long as you've enabled the spam filter the caught spam file will grow in size. Go through this file and delete all spam email messages or it will impact your home-directory storage space.

I've just started spam assassin, why is there spam in my mail folder?

The spam filter only works on incoming email. Thus any email that you already received will not be checked against the spam rules.

I've enabled the spam filter but why am I still getting spam?

First there is no perfect spam filter; the process of blocking spam is quite complicated. Second the system will take 2-3 days to learn and adapt to the type of spam that you receive-- please be patient.

Is there anything I can do to help the system learn from missed spam?

Yes you can store any spam that you get into a file called missedspam; simply create the folder called ~/mail/missedspam. Every night the system will attempt to re-adapt its rules based on your missed spam.

APPENDIX

Colophon

This HTML guide was typeset using Emacs 21.4.1 running HTML mode.

Contributors

This guide exists because of contributions made by the following: Cenk Bilgen, Mark Black, Jonathan Chan, Ken Clowes, David A. Curry (choosing secure passwords), John Dear, Luis Fernandes, Daniel Giannitelli, David Magda, Jason Naughton, Rajmund Siwik and Mehmet Zeytinoglu.

If you have any comments about improving future editions of this guide, email them to: <elf@ee.ryerson.ca>.

First Edition

The guide was typeset on a 200MHz Pentium Pro under Linux 2.0.30. The booklet format was generated using psutils tools.

The following CDs were playing during the production: Essential Brazil, various artists; Philips, R.E.M.: Automatic for the People, Green, New Adventures in Hi-Fi; Warner Bros., Masterpieces of Portuguese Polyphony, Lôbo and Magalhães; Hyperion, Graceland, Paul Simon; Warner Bros.

Second & Third Edition

The second edition was produced while listening to various MP3 audio files on a SPARCstation 5/110 running SunOS4.1.4.

Fourth Edition

The fourth edition was remotely edited from a SPARCstation 5/110, on a 6 x 450MHz UltraSPARC Enterprise 3500 with 4Gb of RAM running Solaris 2.6. The booklet format was generated using psnup and dvibook; a Makefile was used to manage dependencies.

The following CDs were playing during the production: Ennio Morricone, The Good, The Bad, The Ugly; EMD/Capitol, Fistful of Dollars; BMG/Razor & Tie, R.E.M., Automatic for the People; Warner Bros., King's Singers English Renaissance, Tallis and Byrd; BMG/RCA Victor, Concerti Grossi, G.F. Handel, Trevor Pinnock and the English Consort; DG/Arkiv.

Fifth Edition

See above for technical details. The following CDs were playing during the production: Natalie Merchant Ophelia; Elektra CD62196, Herb Alpert & The Tijuana Brass, !!Going Places!!; A&M SP4112, Monty Python, The Final Ripoff; EMD/Virgin.

Sixth Edition

Notable CD: Jean Richafort Requiem in memoriam Josquin Desprez, Huelgas Ensemble - Paul van Nevel, Harmonia Mundi.

Seventh Edition

The seventh edition was edited on a 900MHz SunBlade 2000 running Solaris 8 and typeset using the teTeX 2.0.2 distribution. The booklet format was generated using dvibook and the PDF version was generated using dvipdfm. Notable CD: Soundtrack to Amélie by Yann Tiersen. Eclectic music from BBC Radio 3 (http://www.bbc.co.uk/radio3/) on Late Junction and classical music on Through The Night with Susan Sharpe.

Eight Edition

The eight edition (whose release was delayed by a few weeks due to the move to the CCE) was edited on a 2.4GHz P4, running Windows/XP Professional, via an ssh session to a 900MHz SunBlade 2000 running Solaris 8 with GNU Emacs21. It was typeset using the teTeX 2.0.2 distribution. The booklet format was generated using dvibook and the PDF version was generated using dvipdfm. Notable CD: Changing Places, by the Tord Gustavsen Trio, ECM release. The Early Music Show presented variously by Andrew Manze, Lucy Skeeping and Catherine Bott via the BBC Radio 3 audio-stream.

Ninth Edition

The ninth edition was generated, with minor changes, from the eigth edition. Notable CD: French Café, a compilation of French popular music by various musicians (Edith Piaf is noticeably absent).

Tenth Edition

In 2006, the PC workstations were migrated to Fedora Core 5 running the Gnome Desktop thus requiring a complete re-write of this User Guide.

copyright ©1997 - 2012 Luis Fernandes / Wed 08 Feb 2012 06:43:14 PM EST