Module 06 Getting Help.

Slides:



Advertisements
Similar presentations
CS 497C – Introduction to UNIX Lecture 5: Understanding the UNIX Command Chin-Chih Chang
Advertisements

RH030 Linux Computing Essentials
Chapter 4 Getting Help. Using CDE Help Help Manager – primary help tool SunSolve Online – Web-based online help from Sun Solaris Support – Web-based Sun.
Lesson 22 – Introduction to Linux Systems Administration.
Linux+ Guide to Linux Certification, Second Edition
1 Some basic Unix commands u Understand the concept of loggin into and out of a Unix shell u Interact with the system in a basic way through keyboard and.
1 SEEM3460 Tutorial Unix Introduction. 2 Introduction What is Unix? An operation system (OS), similar to Windows, MacOS X Why learn Unix? Greatest Software.
7/17/2009 rwjBROOKDALE COMMUNITY COLLEGE1 Unix Comp-145 C HAPTER 2.
Linux Installation and Administration Lesson 2 Tutor: George Papamarkos.
Introduction to Linux Operating System Tutorial 1
Brief introduction to UNIX A. Emerson CINECA, High Performance Systems.
Introduction to Shell Script Programming
UNIX Unbounded 5th Edition Amir Afzal Chapter 3 Getting Started
CIT 470: Advanced Network and System AdministrationSlide #1 CIT 470: Advanced Network and System Administration Documentation.
Agenda User Profile File (.profile) –Keyword Shell Variables Linux (Unix) filters –Purpose –Commands: grep, sort, awk cut, tr, wc, spell.
Agenda Chapter 1: Linux (Unix) Features Commands (Chapters 2 & 3) Command Structure / Command line editing man, passwd, cal, date, whereis, which Working.
Isecur1ty training center Presented by : Eng. Mohammad Khreesha.
UNIX and Shell Programming (06CS36) Unit 1 Continued… Shrinivas R. Mangalwede Department of Computer Science and Engineering K.L.S. Gogte Institute of.
UNIX Commands. Why UNIX Commands Are Noninteractive Command may take input from the output of another command (filters). May be scheduled to run at specific.
Agenda Link of the week Use of Virtual Machine Review week one lab assignment This week’s expected outcomes Review next lab assignments Break Out Problems.
Agenda Getting Started: Using Unix Unix Structure / Features Elements of the Unix Philosophy Unix Command Structure Command Line Editing Online Unix Command.
Lesson 2-Touring Essential Programs. Overview Development of UNIX and Linux. Commands to execute utilities. Communicating instructions to the shell. Navigating.
BIF713 Basic Unix/Linux Commands Getting Help with Commands.
Agenda Basic Unix Commands (Chapters 2 & 3) Miscellaneous Commands: whereis, which, whoami, finger, passwd, cal, date Working with Files: cat, more, less.
Agenda Basic Unix Commands (Chapters 2 & 3) Miscellaneous Commands: which, passwd, date, ps / kill Working with Files: file, touch, cat, more, less, grep,
2004/051 >> Supply Chain Solutions That Deliver Users.
Computer Literacy BASICS: A Comprehensive Guide to IC 3, 5 th Edition Lesson 3 Windows File Management 1 Morrison / Wells / Ruffolo.
Linux+ Guide to Linux Certification, Second Edition Chapter 4 Exploring Linux Filesystems.
The Kernel At a high level, the kernel in an operating system serves as the bridge between applications and the actual data processing of the hardware.
BIF713 Introduction to Linux. Agenda Getting Started: Using Linux Unix and Linux - Structure / Features Elements of the Linux Philosophy Linux Command.
Linux Tutorial Lesson Two *Getting Help in Linux *Data movement and manipulation *Relative and Absolute path *Processes Note: see chapter 1,2,3 from Linux.
Tutorial support.ebsco.com. Welcome to Explora, EBSCO’s engaging interface for schools and public libraries. Designed to meet the unique needs of its.
Manitoba UNIX Users Group May 12 th, 2009 RTFM: ls(1) Adam Thompson.
MATLAB The name of MATLAB stands for matrix laboratory. Starting a MATLAB Session -On Microsoft® Windows® platforms, start the MATLAB program by double-clicking.
Development Environment
SUSE Linux Enterprise Desktop Administration
Installing and Learning Software
Linux Commands Help HANDS ON TRAINING Author: Muhammad Laique
Computing Fundamentals
Tutorial support.ebsco.com.
Some Linux Commands.
The Command Prompt Commands are the way to “do things” in Unix
New Perspectives on Microsoft Windows 10
Agenda Basic Unix Commands (Chapters 2 & 3) Miscellaneous Commands:
Guide To UNIX Using Linux Third Edition
Chapter 7 Installing Program &Backup Tool
Vi Editor.
Unix Operating System (Week Two)
Introduction to Computers
Tutorial support.ebsco.com.
CIT 470: Advanced Network and System Administration
Central Document Library Quick Reference User Guide View User Guide
System Navigation and Test Launch
Duke University Health System
Windows Internet Explorer 7-Illustrated Essentials
Case Study Creating a Database
MODULE 7 Microsoft Access 2010
Database Applications – Microsoft Access
Word offers a number of features to help you streamline the formatting of documents. In this chapter, you will learn how to use predesigned building blocks.
Introduction to Advanced UNIX
New Perspectives on Windows XP
Manual Water Ski Directory
Command line.
SUSE Linux Enterprise Desktop Administration
Module 5 Getting Help.
UNIX and Shell Programming (06CS36)
Module 4 Command Line Skills
UNIX and Shell Programming (06CS36)
CSCI The UNIX System Editing files
Presentation transcript:

Module 06 Getting Help

Exam Objective Objective Description 2.2 Using the Command Line to Get Help Objective Description Running help commands and navigation of the various help systems

Introduction

Introduction Knowing how to find help while working in Linux is an essential skill for any user. Referring to help provides a quick reminder of how a command works. This is a good information resource when learning new commands.

Man Pages

Man Pages UNIX is the operating system that Linux was modeled after. The developers of UNIX created help documents called man pages (short for manual page). Man pages provide a basic description of the purpose of the command, as well as details regarding available options.

Viewing Man Pages To view a man page for a command, use the man command: For example, the following displays the man page for the ls command: Navigate the document using the arrow keys: To exit viewing a man page, use the Q key. man command sysadmin@localhost:~$ man ls

Viewing Man Pages LS(1) User Commands LS(1) NAME ls - list directory contents SYNOPSIS ls [OPTION]... [FILE]... DESCRIPTION List information about the FILEs (the current directory by default). Sort entries alphabetically if none of -cftuvSUX nor --sort is speci- fied. Mandatory arguments to long options are mandatory for short options too. -a, --all do not ignore entries starting with . The man command uses a pager to display documents. Usually, this pager is the less command, but on some distributions, it may be the more command. Both are very similar in how they perform.

Man Page Sections Man pages are broken into sections. Each section is designed to provide specific information about a command. The following describes some of the more common sections found in man pages: NAME: Provides the name of the command and a very brief description. SYNOPSIS: Provides examples of how the command is executed. NAME ls - list directory contents SYNOPSIS ls [OPTION]... [FILE]...

Man Page Sections DESCRIPTION: Provides a more detailed description of the command. OPTIONS: Lists the options for the command as well as a description of how they are used DESCRIPTION List information about the FILEs (the current directory by default). Sort entries alphabetically if none of -cftuvSUX nor --sort is speci- fied. -a, --all do not ignore entries starting with . -A, --almost-all do not list implied . and .. --author with -l, print the author of each file

Man Page Sections FILES: Provides a more detailed description of the command. AUTHOR: Provides the name of the person who created the man page and (sometimes) how to contact the person. -a, --all do not ignore entries starting with . -A, --almost-all do not list implied . and .. --author with -l, print the author of each file

Man Page Sections REPORTING BUGS: Provides details on how to report problems with the command. COPYRIGHT: Lists the options for the command as well as a description of how they are used REPORTING BUGS GNU coreutils online help: <http://www.gnu.org/software/coreutils/> Report ls translation bugs to <http://translationproject.org/team/> COPYRIGHT Copyright (C) 2017 Free Software Foundation, Inc. License GPLv3+: GNU GPL version 3 or later <http://gnu.org/licenses/gpl.html>. This is free software: you are free to change and redistribute it. There is NO WARRANTY, to the extent permitted by law.

Man Page Sections SEE ALSO: Provides you with an idea of where you can find additional information. This often includes other commands that are related to this command. SEE ALSO Full documentation at: <http://www.gnu.org/software/coreutils/ls> or available locally via: info '(coreutils) ls invocation'

Searching Man Pages To search a man page for a term, press the / and type the term followed by the Enter key. If the term is not found, or upon reaching the end of the matches, the program will report Pattern not found (press Return). If a match is found, to move to the next match of the term, press n. To return to a previous match of the term, press N. /all Sort entries alphabetically if none of -cftuvSUX nor --sort is speci- fied. Mandatory arguments to long options are mandatory for short options too. -a, --all do not ignore entries starting with .

Man Page Categorized by Sections There are thousands of man pages on a typical Linux distribution. To organize all of these man pages, they are categorized by sections. By default there are nine default sections of man pages: General Commands System Calls Library Calls Special Files File Formats and Conventions Games Miscellaneous System Administration Commands Kernel Routines

Man Page Categorized by Sections The man command searches each of these sections in order until it finds the first match. For example, the cal command belongs to the first section of man pages: Sometimes there are man pages with the same name in different sections: It may necessary to specify the section of the correct man page. To specify a different section, provide the number of the section as the first argument of the man command. CAL(1) BSD General Commands Manual CAL(1) sysadmin@localhost:~$ man -f passwd passwd (5) - the password file passwd (1) - change user password passwd (1ssl) - compute password hashes sysadmin@localhost:~$ man 5 passwd PASSWD(5) File Formats and Conversions PASSWD(5)

Finding Commands and Documentation

Finding Commands and Documentation To search for the location of a command or the man pages for a command, use the whereis command. This command searches for commands, source files and man pages in specific locations where these files are typically stored: Man pages are easily distinguished from commands as they are typically compressed with a program called gzip, resulting in a filename that ends in .gz. sysadmin@localhost:~$ whereis ls ls: /bin/ls /usr/share/man/man1p/ls.1.gz /usr/share/man/man1/ls.1.gz

Find Any File or Directory To find any file or directory, use the locate command. This command searches a database of all files and directories that were on the system when the database was created. However, any files created that day will not be searchable with the locate command because the database is updated nightly. It is possible to update the locate database manually by running the updatedb command as root. The output can be quite large so it may be helpful to use the following options: The -c option to the locate command will list how many files match: The -b option only includes listings that have the search term in the basename of the filename. To limit the output even further, place a \ character in front of the search term: sysadmin@localhost:~$ locate -c passwd 97 sysadmin@localhost:~$ locate -b "\passwd"

Info Documentation

Viewing Info Documentation Man pages are excellent sources of information, but they do tend to have a few disadvantages: Each man page is a separate document, not related to any other man page. Man pages may can be difficult to read. The info command also provides documentation on operating system commands and features. Info documentation as a logical organizational structure, making reading documentation easier. Information is broken down into categories that work much like a table of contents in a book. Consider man pages to be more of a reference resource and info documents to be more of a learning guide.

Info Documentation To display the info documentation for a command, use the info command: You can navigate the document using the arrow keys. This documentation is broken up into nodes. In the example below the line highlighted in white shows it’s currently in the ls invocation node: sysadmin@localhost:~$ info ls Next: dir invocation, Up: Directory listing 10.1 `ls': List directory contents ================================== The `ls' program lists information about files (of any type, including directories). Options and file arguments can be intermixed arbitrarily, as usual. Output Omitted... and control characters are output as-is. --zz-Info: (coreutils.info.gz)ls invocation, 58 lines --Top------------- Welcome to Info version 5.2. Type h for help, m for menu item.

Navigating Info Documentation A listing of movement commands is available by hitting the Shift+H key while reading the info documentation. To quit the info documentation, use the Q key. Basic Info command keys l Close this help window. q Quit Info altogether. h Invoke the Info tutorial. Up Move up one line. Down Move down one line. PgUp Scroll backward one screenful. PgDn Scroll forward one screenful. Home Go to the beginning of this node. End Go to the end of this node. Output Omitted...

Additional Help

Using the Help Option Many commands will provide basic information, very similar to the SYNOPSIS found in man pages, by simply using the --help option to the command. sysadmin@localhost:~$ ps --help ********* simple selection ********* ********* selection by list ********* -A all processes -C by command name -N negate selection -G by real group ID (supports names) -a all w/ tty except session leaders -U by real user ID (supports names) -d all except session leaders -g by session OR by effective group name -e all processes -p by process ID T all processes on this terminal -s processes in the sessions given a all w/ tty, including other users -t by tty g OBSOLETE -- DO NOT USE -u by effective user ID (supports names) r only running processes U processes for specified users x processes w/o controlling ttys t by tty *********** output format ********** *********** long options *********** Output Omitted...

Additional System Documentation On most systems, there is a directory where additional documentation is found, such as documentation files stored by third-party software vendors. These documentation files are often called readme files since the files typically have names such as README or readme.txt. Typical locations for these files include /usr/share/doc and /usr/doc.