Tải bản đầy đủ (.ppt) (45 trang)

Administration Utilities

Bạn đang xem bản rút gọn của tài liệu. Xem và tải ngay bản đầy đủ của tài liệu tại đây (312.14 KB, 45 trang )

The Saigon CTT
Administration Utilities
The Saigon CTT



Objectives
Objectives

Describe, use man pages and other information

Demonstrate how to communicate with users

Identify system defaults

Demonstrate how to find files
The Saigon CTT



man Pages and the
man Pages and the
man
man


Command
Command

You can get information about most commands
using man. This online help system contains the


following information about each command:

Command name

Synopsis and description

List and definition of all options

Environment and parameters

Related commands are listed at the end of the man
page. The number in parentheses after a
command is the section of the manual pages
The Saigon CTT



Example
Example
$ man passwd
PASSWD(1) User utilities PASSWD(1)
NAME

SYNOPSIS

DESCRIPTION

OPERANDS

EXAMPLE

….
SEE ALSO
finger(1), login(1), nispasswd(1), crypt(3C), passwd(5)
The Saigon CTT



Table
Table


2.1
2.1
:
:
man
man


page
page


sections
sections


and
and



their
their


descriptions
descriptions




The Saigon CTT



man Pages and the
man Pages and the
man
man


Command
Command

To view a particular section of the man
pages, include the section number with the
man command and the term you are looking
for:
man <section numbers> <term>
The Saigon CTT




Scrolling in Man Pages
Scrolling in Man Pages

Spacebar Move forward one screen

Return Move forward one line

b Move back one screen

f Move forward one screen

q Quit the man command

/string Find forward

n Find the next occurrence of string

h Help more
The Saigon CTT



Searching Man Pages by Keyword
Searching Man Pages by Keyword

If you are not sure of the command name, use
the man command with -k option

man -k keyword

Example :
$ man -k insert
insque (3) – insert/remove an item from queue
remque [insque] (3) - insert/remove an item from queue
wrjpgcom (1) – insert text coments into JPG file
The Saigon CTT



Which command use to remove user ?
Which command use to remove user ?
$ man -k delete

groupdel (8) - Delete a group

rmdir (2) - delete a directory

userdel (8) – Delete a user
account and related files
The Saigon CTT



Which command use to modify user ?
Which command use to modify user ?

$ man -k modify
ar (1)- creat, modify and

extract from archive
...
setpnp (8)- modify Plug and Play
BIOS device resources
usermod (8)- Modify user account
...
The Saigon CTT



Which command use to create user ?
Which command use to create user ?
$ man -k create | grep user
newuser (8) – update and create new
user in batch
smnpusm (1) – creates and mantains
SMNPv3 users on a remote entity
useradd (8) – Create a new user or
update default new user
information
The Saigon CTT



Manual Entries
Manual Entries



Manual pages are mostly stored under /usr/man/


man can be searched in multiple directories by
setting the MANPATH variable.
MANPATH=/usr/man:/usr/X11R6/man:/usr/share/man
If the MANPATH is not set then man will
assume /usr/man
The Saigon CTT



Manual Entries
Manual Entries



Manual pages are formatted when needed,
and are displayed using a pager program:

more is generally used by default

Set the PAGER variable to override the default

less is probably now much more suitable,
as you can page backwards, search for
strings and patterns, and more
$ export PAGER=less
The Saigon CTT




Related Commands
Related Commands



On most Linux systems, you can use the
command whatis to print the short
description of a command ("synopsis"):
$ whatis man
man (1) - format and display the on-line manual pages
man (7) - macros to format man pages
The Saigon CTT



Related Commands
Related Commands



If you don't know the actual name of a command,
you can search for keywords in the synopsis with
the commands ”man –k” or its alias apropos
$ apropos manuals
man (1) an interface to the on-line reference manuals
mdoc.samples (7) tutorial sampler for writing manuals with –mdoc

You may run makewhatis to rebuild whatis
database before using these commands
The Saigon CTT




info
info


Command
Command

Not all man pages are being maintained and
are therefore out of date, so info yields
more current information

Some topics treated in info are not
discussed in man at all, info also uses
hypertext links, so it is a more powerful utility
The Saigon CTT



Documentation in
Documentation in
/usr/doc
/usr/doc



Documentation that doesn’t fall under man
pages and info is usually put into /usr/doc.

This directory can hold a wealth of
information :HOWTOs, user guides, FAQs,
READMEs, …
The Saigon CTT



Online Documentation
Online Documentation



Linux Documentation Project:

/>

Tài liệu bạn tìm kiếm đã sẵn sàng tải về

Tải bản đầy đủ ngay
×