UNIX Lecture 1
Download

UNIX Lecture 1

Advertisement
Download Presentation
Comments
prema
From:
|  
(155) |   (0) |   (0)
Views: 23 | Added: 09-02-2012
Rate Presentation: 0 0
Description:
January 16, 2007. Spring 2007. 2. What is UNIX. a computer operating system an operating system is the software that provides the interface between the hardware of a computer system and the applications programs running on it. January 16, 2007. Spring 2007. 3. What is UNIX. UNIX provides a range of tools that can be combined and manipulated to perform such a wide variety of jobs that users of the system can very often carry out sophisticated tasks without writing programs in a programming lan32361
UNIX Lecture 1

An Image/Link below is provided (as is) to

Download Policy: Content on the Website is provided to you AS IS for your information and personal use only and may not be sold or licensed nor shared on other sites. SlideServe reserves the right to change this policy at anytime. While downloading, If for some reason you are not able to download a presentation, the publisher may have deleted the file from their server.











- - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - E N D - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - -




1. January 16, 2007 Spring 2007 1 UNIX Lecture 1 Hana Filip

2. January 16, 2007 Spring 2007 2 What is UNIX a computer operating system an operating system is the software that provides the interface between the hardware of a computer system and the applications programs running on it

3. January 16, 2007 Spring 2007 3 What is UNIX UNIX provides a range of tools that can be combined and manipulated to perform such a wide variety of jobs that users of the system can very often carry out sophisticated tasks without writing programs in a programming language Text preparation and printing Document storage and manipulation Programming E-mail

4. January 16, 2007 Spring 2007 4 What is Unix originally developed for multi-user systems now is also run on 'stand-alone' machines

5. January 16, 2007 Spring 2007 5 What is UNIX can be found on a wide variety of computer systems: global computer networks like the World Wide Web PCs often have Linux (a UNIX-type operating system) or a variety of BSD installed (BSD = Berkeley Software Distribution, or Berkeley UNIX, one of the branches of UNIX) OS X Apple Macintoshes all run a form of UNIX a host of free open software systems like FreeBSD, NetBSD or GNU/Linux all are varieties of a UNIX-type operating system GNU pronounced ?guh-noo?, acronym for Gnu?s Not UNIX, a UNIX-like operating system that comes with source code that can be copied, modified, and redistributedGNU pronounced ?guh-noo?, acronym for Gnu?s Not UNIX, a UNIX-like operating system that comes with source code that can be copied, modified, and redistributed

6. January 16, 2007 Spring 2007 6

7. January 16, 2007 Spring 2007 7

8. January 16, 2007 Spring 2007 8

9. January 16, 2007 Spring 2007 9 History of UNIX UNIX was first developed in the early 1970s at Bell Laboratories in the USA (in collaboration with GE and MIT). AT&T (the owners of Bell Laboratories) made UNIX available at nominal cost to academic users, allowing researchers at universities to modify and extend UNIX. UC Berkeley was the first university to get interested in the UNIX system in 1973, a PDP-11 installed in 1974, and the computer science department used it for extensive research thereafter Columbia (1974), Santa Cruz (1979), MIT (1983 - Athena networked workstations)

10. January 16, 2007 Spring 2007 10 Different UNIX Systems System V (distributed by the original developers, AT&T) AIX (IBM) Berkeley BSD (from the University of California, Berkeley) SunOS, now known as Solaris (from the makers of Sun workstations) Xenix (a PC version of UNIX).

11. January 16, 2007 Spring 2007 11 UNIX Features written in the high level level language C easy to install on new computing systems the UNIX operating system consists of the kernel Performs basic operating system functions such as accessing files, allocating memory, etc. the shell Provides the user interface to the kernel C shell (csh) is the original default shell for interactive work C is a general-purpose computer programming language developed in 1972 by Dennis Ritchie at the Bell Telephone Laboratories for use with the UNIX operating systemC is a general-purpose computer programming language developed in 1972 by Dennis Ritchie at the Bell Telephone Laboratories for use with the UNIX operating system

12. January 16, 2007 Spring 2007 12 UNIX Features tcsh is a UNIX shell based on and compatible with the C shell (csh) ?t? in tcsh comes from the T in TENEX, an operating system inspired Ken Greer, the author of tcsh, with its command-completion feature early versions of Mac OS X shipped with tcsh as the default shell, the most recent versions now have bash

13. January 16, 2007 Spring 2007 13 Shell Commands % shell prompt you are in the shell mode, the main command center of the UNIX system alternative shell prompts are $ # >

14. January 16, 2007 Spring 2007 14 Shell Commands % date [RETURN] the command is typed and then the RETURN key is pressed this causes the computer to execute that command date displays current date and time is a two-way command: after executing the command, the computer returns you to the Shell Mode (your originating mode)

15. January 16, 2007 Spring 2007 15 Shell Commands How do you spell ? ? UNIX maintains an on-line spelling dictionary % look egg [RETURN] % look psych [RETURN]

16. January 16, 2007 Spring 2007 16 Shell Commands telnet command allows you to communicate with a remote computer that is using the Telnet protocol % telnet [host] [RETURN] opens a telnet session to the domain [host] % telnet grove.ufl.edu [RETURN]

17. January 16, 2007 Spring 2007 17 Shell Commands login Trying 128.227.8.12... Connected to grove.ufl.edu. Escape character is '^]'. Compaq Tru64 UNIX V5.1A (Rev. 1885) (dogwood) (pts/12) login: hfilip Password: Compaq Tru64 UNIX V5.1A (Rev. 1885); Tue Oct 22 07:01:45 EDT 2002 >

18. January 16, 2007 Spring 2007 18 Shell Commands % who [RETURN] current users on the system % whoami [RETURN] current user of the account % cd .. [RETURN] change directory move one tier up in the directory % ls [RETURN] list the files in the current directory % cd ~ [RETURN] move back to your home directory

19. January 16, 2007 Spring 2007 19 Shell Commands % logout [RETURN] Connection closed by foreign host.

20. January 16, 2007 Spring 2007 20 Your First File OBJECTIVES Create a file for visual editing Append text to the file Escape from Text Append Mode Quit working on a file, save the changes made in the file and return to the Shell Display a list of files in your account Email your file

21. January 16, 2007 Spring 2007 21 Your First File Starting Your First File 1. Logon to your UNIX account % vi[SPACE]first vi indicates that you wish to use the UNIX visual text editor first is the name of the file to be worked on Press the [RETURN] key The screen will clear and a note will appear at the bottom of the screen "first" [New File] Tildes (~) will parade in a column down the left, the cursor will appear at the top left of the screen

22. January 16, 2007 Spring 2007 22 Your First File Appending Text You are now in the Visual Editor Command Mode Press this key a SINGLE time (and do NOT press the RETURN key): a What happened?

23. January 16, 2007 Spring 2007 23 Your First File Appending Text Nothing. In the Visual Editor Command Mode, pressing the a key (once) tells vi that you want to add or append text to the file After pressing the a key (once) the visual editor will add anything you type to the file and at the same time display it on the screen. You are now in the Append Mode.

24. January 16, 2007 Spring 2007 24 Your First File Appending Text Type in the following sentence I anticipate a long and harmonious relationship with UNIX.

25. January 16, 2007 Spring 2007 25 Your First File Leaving the Append Mode Press the ESC key Nothing appears to happen, but you are now out of Append Mode and back in the Visual Editor Command Mode. To be certain press the ESC key again. If a beep sounds, vi is telling you that you are in Command Mode.

26. January 16, 2007 Spring 2007 26 Your First File Leaving the Append Mode From the Command Mode type duty What happened? The terminal should have beeped at you - several times.

27. January 16, 2007 Spring 2007 27 Your First File Leaving the Append Mode From the Command Mode type aduty What happened? The word duty appears on the screen?

28. January 16, 2007 Spring 2007 28 Your First File Leaving the Append Mode SUMMARY The a command permits you to start entering text The ESC key stops the append process and returns you to the Command Mode

29. January 16, 2007 Spring 2007 29 Your First File Returning to the Shell ?I am finished - save this text in a file for another time and bring me back to the Shell.? Type - ESC key - ZZ (Upper Case) hold down the SHIFT key and press the Z key twice

30. January 16, 2007 Spring 2007 30 Your First File Listing Files % ls [RETURN] The filename first should appear % first

31. January 16, 2007 Spring 2007 31 Your First File Mail - Sending a File % mail [LOGIN@SYSTEM] < [FILENAME] [RETURN] leave one space between mail and [LOGIN] Example: % mail hana.filip@gmail.com < first If the person you wish to send an email message is on the same system, you need not include in the address: % mail tigger < tritesayings

32. January 16, 2007 Spring 2007 32 Your First File Mail - Sending a Message % mail [LOGIN@SYSTEM] [RETURN] [TYPE YOUR MESSAGE] CTRL-D

33. January 16, 2007 Spring 2007 33 Your First File Transcript % script [RETURN] Script started, file is typescript % mail hana.filip@gmail.com hello % [CTRL-D] %exit Script done, file is typescript %

34. January 16, 2007 Spring 2007 34 Your First File Copying Files % ls [RETURN] % typescript % cp typescript [NEW.FILENAME] [RETURN] % ls typescript [NEW.FILENAME] cp copy

35. January 16, 2007 Spring 2007 35 Your First File Renaming Files % ls [RETURN] % file1 % mv file1 file2 [RETURN] % ls file2 mv moves file1 into file2

36. January 16, 2007 Spring 2007 36 Your First File Cursor Moving Commands Depending on the terminal type: arrow keys h, j, k, l keys or both

37. January 16, 2007 Spring 2007 37 Your First File Cursor Moving Commands Slash-search command: Command mode (Press [ESCAPE]) /[word] e.g., /duck /a Press [RETURN] Pressing the n key will send the cursor to the next identical word or letter in your file

38. January 16, 2007 Spring 2007 38 Your First File Deleting lines Command mode (Press [ESCAPE]) Position the cursor on any character on a line you want to delete Type dd Pressing the u key will undo the effect of the most recent text changing command u the undo or ?I goofed? command

39. January 16, 2007 Spring 2007 39 Your First File Deleting Lines Command mode (Press [ESCAPE]) Position the cursor on any character on a line you want to delete Type 3dd What happened?

40. January 16, 2007 Spring 2007 40 Your First File Deleting Words dw delete word move the cursor to the first letter of any word deletes the whole word and the cursor ?lands? on the first character of the next word place the cursor in the middle of a word and try the dw command - what happens? 3dw

41. January 16, 2007 Spring 2007 41 Your First File Deleting Specific Characters x Move the cursor to a letter or a space Press x ?Delete one character at a time? under x 6x

42. January 16, 2007 Spring 2007 42 Your First File Replacing a Single Character r replaces the one character located under the cursor with the very next character that you type If the cursor is located at the w in two, typing r followed by o will give you too

43. January 16, 2007 Spring 2007 43 Your First File Breaking Up a Long Line r [RETURN] Move the cursor to the space between two words Type the replace r command and then press the [RETURN] key

44. January 16, 2007 Spring 2007 44 Your First File Substituting for a Single Character s substituting for a single character one-way text changing command - moves you into the Append Mode r is a two-way text-changing command for a replacement of a single character - leaves you in the Command Mode

45. January 16, 2007 Spring 2007 45 Your First File Substituting for a Word cw change word Move the cursor on the first letter in a word Type cw Deletes that word Lets you append as much text as you wish One-way text changing command - moves you into the Append Mode

46. January 16, 2007 Spring 2007 46 Your First File Substituting for Lines cc Substitutes text for a whole line Move the cursor to some place in a given line Type cc Deletes that line Lets you append as much text as you wish One-way text changing command - moves you into the Append Mode

47. January 16, 2007 Spring 2007 47 Your First File Summary Commands that substitute or change characters, words and lines

48. January 16, 2007 Spring 2007 48 Your First File Inserting Text i Select a place to which you want to add some text Type the i(nsert) command The text will be entered to the left of the cursor i moves you into the Append Mode

49. January 16, 2007 Spring 2007 49 Your First File Opening a Line Below o Opens a new line below the cursor line o moves you into the Append Mode

50. January 16, 2007 Spring 2007 50 Your First File Opening a Line Above O (capital) Opens a new line above the cursor line O moves you into the Append Mode

51. January 16, 2007 Spring 2007 51 Your First File Summary of Append Commands O i a o i inserts text to the left O Opens the line above a appends to the right o opens the line below


Other Related Presentations

Copyright © 2014 SlideServe. All rights reserved | Powered By DigitalOfficePro