Lab #1 CIS121 – Introduction to the Operating System Environment

Getting Started

This lab is to provide students with an introduction to the Solaris Operating System environment. The contents of the lab is very important to every computer science major. You will learn the following:

1. Unix shell commands for manipulating files, directories(folders), devices, etc.

2. How to customize your workspace/desktop in Solaris

3. How to access Spelman e-mail via the webmail applet

4. How to create text files using a Unix text editor

5. How to access your WebCT account and the class webpage

 

There is a lot of information in this lab, and you should treat this as an opportunity to begin learning about this professional software development environment. You will learn about more software tools as the semester progresses.

Learning about Your Workspace

To get started, you will first need to log into your computer. The machines are all connected to a local area network (LAN) at Spelman and the Internet. Each of you has a login id and password. This login id and password can be used on any of the Solaris workstations in rooms 223 and 227 (not the windows PCs). Your workspace moves with your login id, and so the customizations that you make on this machine will be seen on any of the workstations you decide to use.

Logging In

1. Your login id: first 4 letters of your last name followed by the first 3 letters of your first name

EXAMPLE: Betty Boop would have the login id ÒboopbetÓ

 

2. Your password has been temporarily set to be the same.

 

3. Select GNOME desktop environment

 

The first login may take a while to initialize your preferences.

License Registration

Now, you may be asked about the Solaris license. Do the following: (if not, then skip)

 

  1. Select register now
  2. Select never register

Changing Password

Now, you need to change your password. Do the following:

  1. Place mouse over an empty part of the desktop
  2. Click the right mouse button
  3. Select ÒNew TerminalÓ from the menu
  4. Place mouse on the terminal window
  5. Choosing a Password (taken in part from http://www.cs.umd.edu/faq/Passwords.shtml)

 

How Not to Choose a Password

¯    Words in the dictionary.

¯    Words in any dictionary.

¯    Your user name.

¯    Your real name.

¯    Your spouse's name.

¯    Anyone's name (it's easy enough to get a list of 100,000  names and try each one to break into your account).

¯    Any word in any ``cracking dictionary.'' There are lists of words  that crackers use to try to crack passwords: passwords that  a lot of people use. Some of these lists include:

 Abbreviations, Asteroids, Biology,  Cartoons, Character Patterns, Machine names,  famous names, female names, Bible,  male names, Movies, Myths-legends, Number Patterns, Short Phrases, Places,  Science Fiction, Shakespeare, Songs,  Sports, Surnames

 

How to Choose a Good Password

Creating a good password can be difficult, so here are some guidelines to use:

 

¯    Choose a password that is at least six characters long. This should be long enough to discourage a brute-force attack. Currently, the maximum password length on many Unix systems is eight characters, but if you want to add a few more characters to make it easier to remember, go ahead. Just bear in mind that anything after the eighth character will be ignored (so ``abnormalbrain'' is the same as ``abnormal'').

¯    In general, a good password will have a mix of lower- and upper-case characters, numbers, and punctuation marks, and should be at least 6 characters long. Unfortunately, passwords like this are often hard to remember and result in people writing them down. Do not write your passwords down!

¯    The license plate rule: take a phrase and try to squeeze it into eight characters, as if you wanted to put it on a vanity license plate.

¯    Some people like to pick several small words, separated by punctuation marks of some kind.

¯    Put a punctuation mark in the middle of a word, e.g., ``vege%tarian''.

¯    Use some unusual way of contracting a word. You don't have to use an apostrophe.

¤       One of my favorite passwords was ``kEp*-h&y'': ``kEp'' --> ``keep'', ``*-'' --> ``laser'' (like those signs that you see outside of physics labs), and ``h&y'' --> ``handy''; ``Keep your laser handy!''

¯    You can use control characters. Just bear in mind that a lot of them have special meanings. If you use ^D, ^H or ^U, for example, you might not be able to log in again.

¯    Think of an uncommon phrase, and take the first, second or last letter of each word. ``You can't always get what you want'' would yield ``ycagwyw''. Throw in a capital letter and a puntuation mark or a number or two, and you can end up with ``yCag5wyw''.

¯    Deliberately misspelling one or more words can make your password harder to crack.

¯    Use several of the techniques above.

¯    Something that no one but you would ever think of. The best password is one that is totally random to anyone else except you. It is difficult to tell you how to come up with these, but people are able to do it. Use your imagination!

 

  1. Enter the following: (note that machinename% is a placeholder for the prompt in the terminal window, you should type the information following the prompt and press the <return> key)

machinename% passwd

            (you will not see anything when you type)

            Enter your current password, which is your username now.

            Then enter your new password ( you will have to do this twice to verify you type it properly)

Learning the Graphical User Interface

In this section of the lab, you will be following the online tutorial for GNOME  and the terminal window.  GNOME is what is called the window manager; this is the software that provides the different window and desktop features. The tutorial will show you how to customize the interface to your liking.

  1. Locate the Òlife-preserverÓ icon on the desktop (labeled ÒGNOME OverviewÓ), and double-click it with the left-mouse-button.
  2. Click on ÒIntroducing Desktop ComponentsÓ, read this, and then click on ÒNext>>Ó at the bottom or top of the screen.
  3. Read each section and perform the tasks in each section. You can use ÒNext>>Ó to move to the next section and ÒPrevious<<Ó moves you to the previous section.

 

The next tutorial to follow is the terminal window tutorial that will show you how to make customizations there including changing the font color and size as well as making the background transparent.

  1. Open a terminal window as you did before, if you need a refresher:
    1. Place mouse over an empty part of the desktop
    2. Click the right mouse button
    3. Select ÒNew TerminalÓ from the menu
    4. Place mouse on the terminal window
  2. Press the ÒF1Ó key for help or click on ÒHelpÓ in the menu and select ÒContentsÓ.
  3. This tutorial is similar to the previous tutorial in terms of navigating next and previous. Go through this tutorial, and customize your terminal window.

 

Now you have completed the graphical user interface portion of this lab. You may revisit this at anytime to learn more.

 

Course-Related Websites

 

This course utilizes 3 websites. The first site is the general course website that contains the syllabus, Instructor and TA information, homework assignments, lecture materials, etc. The second site is called WebCT and it contains information such as the class bulletin board, class supplements, online quizzes and exams,  and grades! The third and final website is where you are able to read your Spelman College E-mail. You probably already know how to access this, but we want to make sure you know how to do it from these machines.

 

Course Website

Lets start with the general course website:

 

  1. To get started a shell command window (terminal window) – see previous section if you forgot how.
  2. Start the web browser named ÒmozillaÓ

 

machinename% mozilla &

 

NOTE: make sure you use the Ò&Ó to get the prompt back. You will need the prompt.

 

NOTE: Resize mozilla to allow you to get the terminal window and mozilla on the screen at one time.

 

  1. Open the webpage at the following URL:

 

http://www.spelman.edu/~compsci/cis121

 

WebCT Website

Now lets open the webct site. Open the webpage http://webct.spelman.edu

 

Your login id will be the same as your ?? account.  You will need to use the same id for your initial password, and then change your password. After you log in, change your password:

 

  1. The title of your page at the top should be ÒMy WebCT: Your NameÓ
  2. Now click on the ÒPassword SettingsÓ, and change the password

 

After that, you need to join the cis121 course that you belong to. If the course is not in your list.

 

  1. Go back to the ÒMy WebCTÓ link at the top of the page or click on the back button.
  2. At the bottom, there is a link to ÒAdd CourseÓ, click that link
  3. Find the ÒCIS121Ó class  for your professors and add that course.

 

After you have done that, visit the course and snoop around to answer the following questions:

 

  1. How do you find all of  the lecture material?
  2. How do you locate the class assignments?
  3. How do you find your grades?
  4. Send a message to the discussion board, and tell the whole class ÒhelloÓ, and tell us about you.
  5. Everyone join the chatroom, and have a chat. Join the room entitled ÒThe General CIS121 ChatroomÓ.

 

Spelman E-mail Access

Now lets open your Spelman College e-mail via the web http://www.spelman.edu, and click on the link towards the middle of the page that is labeled ÒwebmailÓ. Now select your graduating class year, and enter your E-mail username and password. Note, this is not the same id as your Unix login  and may or may not be the same as your WebCT name.

 

Unix Shell Commands

 

In this section of lab you will be learning how to enter various commands in the terminal window. These commands are called ÒUnix CommandsÓ. You will need to follow the steps which will include going to a website, reading some material, following the steps and answering questions about the steps. These commands are very useful to you while you are at Spelman and they are also used by many companies that use these types of machines (I have even seen them come up in interviews!).

 

1. To get started you will need to open your web browser from a shell command window:

 

machinename% mozilla &

 

NOTE: make sure you use the Ò&Ó to get the prompt back. You will need the prompt.

 

NOTE: Resize mozilla to allow you to get the terminal window and mozilla on the screen at one time.

 

2. Open the webpage at the following URL:

 

http://www.spelman.edu/~compsci/unix

 

3. Read the first 2 sections, Typographical Conventions and Introduction to The UNIX operating system

 

4. Now complete Tutorials 1-4 and answer questions in the deliverables section. You will be reading and typing in the commands shown in RED. Be sure to pay attention to what you are doing. ItÕs a good habit to even try to guess what the result of the command will be before you try it. You will be tested on this, so take notes as you go.

Lab Sessions

This lab is to be done during and outside of  lab class.

Deliverables

Answer the following questions as you do the tutorials:

 

1. In exercise 1a, show the command you used.

 

2. What does the following command do?

% ls ~

 

3. In exercise 2a, show the command you used.

 

4. What is the command to view the last 15 lines of the science.txt file?

 

5. What is the command to view the first 15 lines of the science.txt file?

 

6. How many lines does the science.txt file have? How many words?

 

7. What is the result of the command?

         % ls ?list