1 / 22

Introduction to Unix (CA263) Getting Started

Introduction to Unix (CA263) Getting Started. Objectives. After reading this chapter, you should be able to: Understand the computing environment in which you will practice Practice your first Unix session by logging on and off your computer network

tarmon
Download Presentation

Introduction to Unix (CA263) Getting Started

An Image/Link below is provided (as is) to download presentation Download Policy: Content on the Website is provided to you AS IS for your information and personal use and may not be sold / licensed / shared on other websites without getting consent from its author. Content is provided to you AS IS for your information and personal use only. Download presentation by click this link. While downloading, if for some reason you are not able to download a presentation, the publisher may have deleted the file from their server. During download, if you can't get a presentation, the file might be deleted by the publisher.

E N D

Presentation Transcript


  1. Introduction to Unix (CA263)Getting Started

  2. Objectives • After reading this chapter, you should be able to: • Understand the computing environment in which you will practice • Practice your first Unix session by logging on and off your computer network • Experiment with a few Unix commands to develop a “feel” for Unix • Acknowledge responsibilities and concern of computer use

  3. The Unix Language • ASCII, American Standard Code for Information Interchange • Originally, ASCII used only 7 bits (0 and 1) providing 128 characters • Extended ASCII uses 8 bits to store 256 characters. For example English letter “H” has a decimal code 72. In term of bits, H is 01001000

  4. Case Sensitivity • Unix is case sensitive. So beware of Shift and CapLock.

  5. Control Characters • Many command employ control characters. • The beep, sound that computer make, is signifies as ^G. Activate ^G by holding down control and press G. • A useful control character is ^L, which usually clear your window. • To correct error use Backspace, or ^H • Pressing ^C usually cancels command, its “kill” control sequence. If not respond then use ^Z as a last ditch to suspend your command. Suspended processes linger and thus consume system memory. • Sometime ^D (exit) can help, it might log you out.

  6. Syntax and Semantics • Writing command correctly and in a specific spelling and order (syntax). If you made error in writing statement you will get syntax error. • The choice of usage and meaning (semantics)

  7. Logging In • The username, also referred as login name, user account, or user ID is typically chosen for you and is usually abstracted from your real name. • Your password is special combination of characters, number, and symbols that you create to protect your account.

  8. Command Window • Command Prompt, is used to enter UNIX command. You are running a shell, which is a program that will interpret your instructions for Unix. • Unix usually comes with three shell, Bourneand Korn shell uses the dollar sign ($), while C shell uses the (%) sign. Your system might be customized with entirely different prompt. • Cursor, used to type commands

  9. Command Window • Command Line, place where you type command using cursor and terminate command by pressing Enter key • Editing the command, Before press Enter you can edit the command line. Use Backspace or Delete to correct error. Typically ^A and ^E which put you at the beginning and end of the command line.

  10. Command Options • Unix command has the following form: • command options arguments • For example print command lp (laser printer) has one option d (for destination), which has it’s own argument, the printer name hp2040 and command argument Data.txt. • $>lp –d hp2040 data.txt

  11. Command Options • Unix command has the following form: • command options arguments • who is a command has a command option am I, which modify the behavior of who, restricting its report to only your identity. • $>who am i

  12. Finding Help • There’s a special Unix command called man, which means manual. To find help on a particular command, entermancommand • $> man lp

  13. Finding your shell • The shell is a UNIX program that helps you to communicate with Unix’s core program. The shell run on the top of UNIX’s core. • To determine your current shell, enter echo $SHELL. The dollar sign ($) tells Unix to look of the value of SHELL, which is an environment variable. • $> echo $SHELL

  14. Logout • With C–shells the command log out will end your session. • In GUI environment you must choose a menu option such as exit, log out, or KillTWM.

  15. Error Message • If you make mistake, Unix will usually respond with an error message: • $> sl • sl: command not found

  16. Protecting Your Account • Change your password • $> passwd • Passwd: Changing password for user ahmed • Old password: • New password: • Re-enter new password: • $>

  17. Fun With Unix • What’s Today • $> date • Sat Mar 26 13:43:21 EST 2008

  18. Unix Command • Cal, On what day were you born • $> cal 10 1923 • Banner, Print big version in ASCII • $> banner TARIQ • Finger, to see who is sharing my last name • $> finger aziz • Lynx, a text based web browser • $> lynx (Type G for go)

  19. Unix Command • History will show your previous commands • $>History • Repeat 10th Command you used before • $>!10 • Customizing some of the command name alias customname command • $>alias dir ls • $>dir • UnixBook Mail Courses • $>ls • UnixBook Mail Courses

  20. Compound Commands • In Unix, the semicolon (;) can connect two command lines. • $> who am i; who

  21. Piping in Unix • Pipe one command’s output into another • $> who | wc –l • $> ls | wc -l

  22. Command Summary • alias customize a command • banner output an big sized message • cal show calendar • date show current date • echo output the value of a variable • finger output information about a user • history show commands recently entered • lp print hard copy • ls list file • lynx invoke text-based Web browser • man find help on a Unix command • more view contents of text file • passwd reset Unix password • sc invoke spreadsheet calculator • time show current time • wc count words in a file • who shows users currently logged on

More Related