Добавил:
Upload Опубликованный материал нарушает ваши авторские права? Сообщите нам.
Вуз: Предмет: Файл:
UNIX_podibni_OS / Unix подобные ОС Лаб. работа 1.doc
Скачиваний:
28
Добавлен:
17.03.2016
Размер:
110.59 Кб
Скачать

3. Получение справки и помощи в Unix.

Практически каждый UNIX имеет то, что называется "Руководство" - man ( ``manual pages''). Эта команда man содержит документацию на различные команды системы, ресурсы, конфигурационные файлы.

Для ее использования необходимо набрать man<имя команды>, в результате чего на экран будет выведена информация по использованию данной команды. Для примера посмотрим как можно использовать (с какими параметрами) саму командуman:

[ik11-04@target ~$]man man

MAN(1) Unix General Commands Manual MAN(1)

NAME

man - format and display the on-line manual pages

SYNOPSIS

man [-adfhkotw] [-m machine] [-p string] [-M path] [-P pager] [-S list]

[section] name ...

DESCRIPTION

Man formats and displays the on-line manual pages. This version knows

about the MANPATH and PAGER environment variables, so you can have your

own set(s) of personal man pages and choose whatever program you like to

display the formatted pages. If section is specified, man only looks in

that section of the manual. You may also specify the order to search the

sections for entries and which preprocessors to run on the source files

Via command line options or environment variables. If enabled by the

system administrator, formatted man pages will also be compressed with

the `/usr/bin/gzip -c' command to save space.

The options are as follows:

-M path Specify an alternate manpath. By default, man uses

manpath(1) (which is built into the man binary) to determine

the path to search. This option overrides the MANPATH envi-

ronment variable.

-P pager Specify which pager to use. By default, man uses more -s.

This option overrides the PAGER environment variable.

-S list List is a colon separated list of manual sections to search.

This option overrides the MANSECT environment variable.

-a By default, man will exit after displaying the first manual

page it finds. Using this option forces man to display all

the manual pages that match name, not just the first.

-d Don't actually display the man pages, but do print gobs of

debugging information.

.........................................

[ik11-04@target ~$]

Если вы хотите найти информацию о других опциях команды ls, введите man ls и вам на экран будут выведены страницы Руководства.

[ik11-04@target ~$]man ls

LS(1) Unix General Commands Manual LS(1)

NAME

ls - list directory contents

SYNOPSIS

ls [-ABCFGHLPRTWabcdfghiklmnopqrstuwx1] [file ...]

DESCRIPTION

For each operand that names a file of a type other than directory, ls

displays its name as well as any requested, associated information. For

each operand that names a file of type directory, ls displays the names

of files contained within that directory, as well as any requested, asso-

ciated information.