# 1 Course Description

CS 252 is an introduction to Unix with emphasis on the skills necessary to be a productive programmer in Unix, Linux, and related environments.

The focus of this course is on learning enough Unix for students to function productively in CS courses at the 300 level and beyond. Because working directly from a workstation console in a CS Dept lab is no longer the dominant mode of interacting with our Unix systems, this course will emphasize connecting via the Internet from a remote PC to our Unix systems. Both text-based (ssh/shell) and window-based (X) connections will be covered.

## 1.1 Topics Covered

1. Getting started
• Why Unix? Logging in.
1. The Basics: Working in Text Mode

• Working at the command line, the Unix File System, absolute and relative paths, basic file manipulation commands, wildcards and quoting,
• editing files (nano, emacs, & vim)
• file permissions
• file transfer (sftp, scp)
• regular expressions (grep, sed)
• redirection and pipelines
2. Program Development

• compiling and executing programs (g++, gcc, java)
• project management (make)
• compiling in editors
3. Working in Graphics Mode (X)

• X and X2Go
• editing in X
• IDEs for program development (emacs, vim, Code::Blocks, Eclipse)
• Debugging (gdb and IDEs, nemiver)
4. Scripting

• Environment variables, customizing the Unix environment, writing shell scripts

A more detailed outline is available on the course website.

# 2 Basic Information

## 2.1 Instructor

 Steven J. Zeil E&CS 3208 (757) 683-4928 Fax: (757) 683-4900 zeil@cs.odu.edu

When sending e-mail to the instructor, please put include the course number (“CS252”) as part of your Subject line. Messages with that in the subject are flagged by my email program for faster attention and are less likely to be lost amid my daily dose of spam messages.

## 2.2 Location

This course is hosted on ODU’s Blackboard server.

## 2.3 Texts

The readings for this course available on-line.

• The lecture notes, denoted in the course outline by the symbol , are required readings.

• All information necessary to do the assignments and complete the course is in the lecture notes.

• Various textbook chapters, identified in the course outline by the symbol are also listed.

These are optional readings.

• If you are struggling with some of the ideas presented in the lecture notes, you may find that the texts provide alternative viewpoints or explanations.

• These texts are available on-line via the ODU Library through the Virtual Library of Virginia (VLVA).

Everything you need to complete the assignments and successfully pass the exam is in the Lecture Notes.

The Lecture Notes include Try This exercises to give you practice with the commands and concepts covered in the course.

• The Internet is a wonderful resource, but copying something that you don’t really understand from a webpage just because it seems vaguely relevant is likely to lead to trouble.
• Nearly a quarter of my mail traffic in this course last semester was dealing with problems arising because someone insisted that something they copied from the Internet must be correct, despite it not actually working, or helping people to recover from damage done to their files and directories by a command they copied from the Internet without understanding what it did.

If a command or option is not covered in the Lecture Notes, and you have not practiced with it in a Try This exercises, you don’t need it to complete the assignments. Unless you really, really understand what you are doing, don’t use it!

## 2.4 Course Prerequisites

• CS 150 (Introduction to Programming), or an equivalent, or current registration in CS 333

Students are also expected to be familiar with the use of standard Internet-based tools including email and web browsers.

## 2.5 Hardware and Software Requirements

Because this course is hosted on the Internet, you will need to make sure that you have access to the appropriate computing equipment and software to participate in the course activities.

### 2.5.1 Computing Devices

You will not need your own access to a Unix or Linux machine. The CS Dept provides such machines, and learning how to use them from both on and off-campus locations is a major theme of the course.

You will need hands-on access to a PC of some kind. These do not need to be particularly powerful machines, as you will be using them as entry points for remote connections to the CS Dept. machines on which you will be doing your “real” work.

Your PC for this course may run:

You will need to install some software on your PC. All such software is available in free, open-source distributions and will be introduced as it becomes relevant during the course.

• You should not plan on using a PC at your place of work, or in a library, or other locations where you do not have permission to install software.

• In some cases, you may be able to install the software to a USB flashdrive and then use that on machines where you otherwise do not have permissions to install software. Be aware, however, that some sites that lock down their machines to prevent new software installation may also lock them down to prevent execution of programs from USB drives.

### 2.5.2 Software

Software requirements are fairly relaxed. You will need a reasonably up-to-date version of the Edge, Firefox, or Chrome web browser. Other browsers or older versions of these may also be acceptable, but cannot be guaranteed so, because the course materials are not tested with other and older browsers.

• Neither Internet Explorer (Windows) nor Safari (Apple) are recommended. They might work. They might not.

As noted above, you may be installing other software to support this course.

### 2.5.3 Internet Access

You will need a good quality internet connection. Again, be wary of planning to use PCs at work, libraries, etc., with this course. Many of these places will run firewalls that heavily restrict access to network services.

If you are working form home, your home internet probably allows the access you need by default. If you need to check with the systems staff at some location, tell them that you need to make outgoing connections to

1. web servers using the http and https protocol. If you can view web pages like this one, you are probably OK.

2. secure shell servers using the ssh protocol (port 22). Although rare, some companies and public libraries (including at least one city library in the local Hampton Roads area) do block this.

# 3 Course Policies

## 3.1 Meeting Times

This is a self-paced Internet-delivered course. There are no regularly scheduled class meetings.

## 3.2 Computer Accounts

All students taking this course will need a login account on the CS Dept.’s Unix network. (This is distinct from any Midas or other account you may have from the general University computer center – the ODU ITS).

You may have a CS account already if you were registered for a CS class last semester. If not, you will need to create a new account. Instructions on how to do so are in the course materials for the first module of the course.

## 3.3 Communications

When sending email related to this course, please remember to include “CS252” as part of the email subject line. This will flag your email for my attention and may also help avoid its getting lost amid my daily spam.

As noted earlier, I will hold regular office hours. Off-campus students can contact the instructor by telephone or by network conferencing during these times.

## 3.4 Academic Honesty

Everything turned in for grading in this course must be your own work.

• If you have questions about the readings or the general subject matter, you may ask me, your classmates, other students, tutors, or anyone else you think might be helpful.

• If you have questions about assignments (or any other graded activity), you may ask me, the course TA (if I have one – I usually do not have one for this course), or official tutors provided by the CS Dept. or ODU.

You may not discuss possible solutions to assignments or other graded activities with your classmates, other students, TAs for other courses (including TAs for CS 150, 250, or 333), tutors who you may have hired on your own, forums and help sites on the web, etc. Students who copy the bulk of an assignment from other students or from online sites will, at the very least, receive a zero on that assignment.

The instructor reserves the right to question a student orally or in writing and to use his evaluation of the student’s understanding of the assignment and of the submitted solution as evidence of cheating.

Violations will be reported to the office of Office of Student Conduct and Academic Integrity for consideration for punitive action.

Students who contribute to violations by sharing their code/designs with others are subject to the same penalties as those who misrepresent such work as their own.

This is a Pass/Fail course. No letter grades are assigned. The only possible grades are P, F, and WF. (This course does not affect your grade point average — only letter-graded courses can do that.)

### 3.5.1 Requirements

To obtain a pass (P) grade, students must accumulate 18 points out of a possible 24.

Points are awarded as follows:

• One point for each assignment completed, up to a total of 14.

• All assignments are automatically graded. Students can check their assignment status at any time by using the Grades button on the various course directory pages.
• One point for each 10% correct on the final exam.

• The final exam is a multiple-choice exam and will be available on line during exam week on dates listed in the course outline.

For example, a student who completes all 14 points need score only 40% on the final exam. A student who completes 12 assignments must score a 60% on the final exam.

Students who fail to achieve the required 18 points will be given an F, except for students who have never completed a single assignment, who will be given a WF.

It is worth noting that the course is designed with the assumption that students will make a serious attempt to complete all assignments, even though this is not strictly required. The assignments give you practice with and help to reinforce the lessons tested by the exam.

Historically, there is a strong correlation between the number of assignments completed and the chances of scoring high enough on the exam to pass the course:

# assignments completed % of students passing the course
< 8 mathematically impossible to pass
8 0%
9 0%
10 10%
11 33%
12 60%
13 85%
14 95%

### 3.5.2 Due Dates

Assignments are due by the end of the day announced in the outline/schedule. Typically this is the final day of classes for the Fall and Spring semesters and the day prior to the opening of the final exam for the Summer semester.

The final exam will be available on-line. Refer to the outline/schedule for the dates. Detailed instructions will be posted in the Exams area on Blackboard.

### 3.5.3 Extensions, Exceptions, and Incomplete (I) Grades

Exceptions to the due dates or grading policy will only be granted under the conditions defined by the ODU policy on Incomplete (I) grades: “exceptional circumstances beyond the student’s control”. Except in such circumstances, students who fail to complete the course in the time allowed will not be permitted to resume the course without re-registering, and would then be expected to complete all assignments from the beginning of the course.

Reasons that are most likely to justify an exception include extended illness, military deployments, or job transfer/relocation, but you should be prepared to document these if requested.

The following are usually not valid reasons for an extension:

• “I forgot that I was signed up for this course.” or “I didn’t know what the Grading policy was.”

This was not beyond your control.

• “I have a part-time (full-time) job.”

This is not exceptional. Most of your classmates work, many of them full-time.

• “I have a heavy course-load this semester.”

Neither exceptional nor outside your control.

• “I’ve worked so hard on this course.”

I’m sure that your fellow students would not appreciate the implication that you believe they have been slacking off.

Fundamentally, though, this argument misses the whole point of grades in a course. They are not a reward for putting in time and effort. They are given, instead, to certify that you have demonstrated a certain level of knowledge and, in the case of a course like this that is a prerequisite to many other courses, to make sure that you are sufficiently prepared to succeed in those later courses.

• “I got stuck on assignment X and was never able to catch up.”

Actually, this might qualify, but only if you made good use of email and/or my office hours to resolve your problems with that assignment in a timely fashion. Your chances of getting an exception in this case will also depend upon just how many assignments you have remaining to complete. You are far more likely to get a short period of time to complete one assignment than to get any extra time at all to complete 7 assignments.

• "I had trouble completing some assignments and haven’t sent you an email or attended your office hours because I’m not the kind of person who likes to ask for help.

Then you shouldn’t be the kind of person who asks for exceptions either. A significant part of a college-level education is learning to exploit the information resources available to you. Deliberately refusing to do so is not a behavior that I’m inclined to reward.

Requests for an “I” grade or extended time to complete the course should be made before the actual end of the semester, whenever possible. Requests made after grades have been submitted will need to include an explanation of why the request was delayed.

### 3.5.4 Fourth-Week Grade Report

University regulations require that all instructors of 100 or 200-level courses provide students with an interim grade report by the end of the 4th week of the semester. Obviously, such a report is of questionable utility in a self-paced course like this one.

Students may obtain this report from Leo Online (the same system used to retrieve end-of-semester grades). Students who, by the end of the 4th week of the semester, have completed at least 4 assignments are considered to be “on a pace” to successfully finish the course by the end of the semester.

# 4 Getting Started

A typical work session for this course starts by entering the course via the course BlackBoard site (linked at the bottom of this page) to check for announcements. Then click on “Outline” to reach the course Outline page.

On the Outline page, you will see the list of topics, with on-line lecture notes, textbook readings, and assignments. You can then begin working through the course material, or pick up from wherever you last left off.

For example, a CS 250 instructor may want to give an assignment on October 15 in which the g++ compiler will be used, and so may inform CS 250 students that they must have completed the CS 252 assignment on “compiling using g++” by October 7.