1 / 21

Using the Terminal

Using the Terminal. Lab 3 +. "Under Linux there are GUIs (graphical user interfaces). where you can point and click and drag, and hopefully get work done without first reading lots of documentation. The traditional Unix environment is a CLI (command line interface)

Download Presentation

Using the Terminal

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. Using the Terminal Lab 3+

  2. "Under Linux there are GUIs (graphical user interfaces). • where you can point and click and drag, and hopefully get work done without first reading lots of documentation. • The traditional Unix environment is a CLI (command line interface) • where you type commands to tell the computer what to do. That is faster and more powerful, but requires finding out what the commands are."

  3. What is the Terminal • There are many varieties of Linux, but almost all of them use similar commands that can be entered from a command-line interface terminal. • The Terminal = command line interface = shell that gives command to the OS. • A "shell" is a program which interprets commandsso that the operating system can understand them. • the use of the shell can be quicker than a graphical method. • Red Hat uses bash as its default shell.

  4. What is BASH? • BASH = Bourne Again Shell • BASH is a shell written as a free replacement to the standard Bourne Shell which is written by Steve Bourne for UNIX systems. • It has all of the features of the original Bourne shell, plus additions that make it easier to program with and use from the command line. • Since it is Free Software, it has been adopted as the default shell on most Linux systems.

  5. Starting a Terminal • Applications  System Tools  Terminal • Print Screen

  6. Shell Prompt Terms • terminal window • shell prompt • command line • Shell • Print Screen

  7. Terminal Window • The terminal window is the window that contains the shell prompt, command line, and output from the shell.

  8. Shell Prompt • The shell prompt is the marker on the screen that shows where the command line should be placed. The following is an example of a shell prompt: UserName@ComputerName:~$ @ to separate UserName from ComputerName. : colon to separate the computer name from the directory. ~tilda to represent your home directory. $ to terminate the prompt.

  9. Command Line • The command line is where options to a command are placed. The following is an example of a command line: • command -options <filename>

  10. Shell • The shell is the program that interprets commands so that the operating system can understand them.

  11. The prompt --- the command you type --- Enter. • The lines that follow show the output that results from the command. • NOTE:command may have options:command -options

  12. Checking your login session • Login Identity includes: user name, group name, user ID, and group ID. • To find out information about your identity: • Linux keeps track of login session: when you logged in, how long you have been idle, and where you logged in from.

  13.  -m option tells the who command to print information about the current user -u says to add information about idle time and the process ID -H asks that a header be printed

  14. Checking directories and permissions • To find out what your current directory is: • To find out the name of your home directory:

  15. To get back to your home directory: • To change the current directory to the directory that you choose:

  16. To list the contents of the current directory: File & Directory Commands DateThe date of last modification permissions UserThe user that owns the file, or directory SizeThe size in bytes GroupThe group that file belongs to, Directories This field specifies the number of links or directories inside this directory. Directory or FileThe name of the file or directory.

  17. File & Directory Commands • List the contents of your home directory • List the contents of your root directory

  18. Checking system activity • To list running processes and monitoring system usage: • a option ask to show process of all users who are associated with your current terminal • u option asks that user names be shown , as well as other information such as the time process started and CPU usage. • VSZ (virtual set size)  size of image process(in kilobytes). • RSS(resident set size) size of program in memory.

  19. Checking system activity • To see and monitor all the processes running on the system : use spacebar to page through , and q to end the list

  20. Checking system activity • To stop any process by PID i.e. to kill process • To stop all process except your shell

  21. References žRed Hat Linux Bible: Fedora and Enterprise Editionby Christopher Negus  http://labnet321.blog.com/references/chapter-4/

More Related