Olaf Kirch - Linux Network Administrator Guide, Second Edition

Здесь есть возможность читать онлайн «Olaf Kirch - Linux Network Administrator Guide, Second Edition» весь текст электронной книги совершенно бесплатно (целиком полную версию без сокращений). В некоторых случаях можно слушать аудио, скачать через торрент в формате fb2 и присутствует краткое содержание. Год выпуска: 2000, ISBN: 2000, Жанр: ОС и Сети, на английском языке. Описание произведения, (предисловие) а так же отзывы посетителей доступны на портале библиотеки ЛибКат.

Linux Network Administrator Guide, Second Edition: краткое содержание, описание и аннотация

Предлагаем к чтению аннотацию, описание, краткое содержание или предисловие (зависит от того, что написал сам автор книги «Linux Network Administrator Guide, Second Edition»). Если вы не нашли необходимую информацию о книге — напишите в комментариях, мы постараемся отыскать её.

This book was written to provide a single reference for network administration in a Linux environment. Beginners and experienced users alike should find the information they need to cover nearly all important administration activities required to manage a Linux network configuration. The possible range of topics to cover is nearly limitless, so of course it has been impossible to include everything there is to say on all subjects. We've tried to cover the most important and common ones. We've found that beginners to Linux networking, even those with no prior exposure to Unix-like operating systems, have found this book good enough to help them successfully get their Linux network configurations up and running and get them ready to learn more.
There are many books and other sources of information from which you can learn any of the topics covered in this book (with the possible exception of some of the truly Linux-specific features, such as the new Linux firewall interface, which is not well documented elsewhere) in greater depth. We've provided a bibliography for you to use when you are ready to explore more.

Linux Network Administrator Guide, Second Edition — читать онлайн бесплатно полную книгу (весь текст) целиком

Ниже представлен текст книги, разбитый по страницам. Система сохранения места последней прочитанной страницы, позволяет с удобством читать онлайн бесплатно книгу «Linux Network Administrator Guide, Second Edition», без необходимости каждый раз заново искать на чём Вы остановились. Поставьте закладку, и сможете в любой момент перейти на страницу, на которой закончили чтение.

Тёмная тема
Сбросить

Интервал:

Закладка:

Сделать

The following example shows three possible types of entries:

samiam@bovine.net colin

sunny@bovine.net darkhorse@mystery.net

@dairy.org mail@jhm.org

@artist.org $1@red.firefly.com

In this example, we are virtual hosting three domains: bovine.net, dairy.org, and artist.org.

The first entry redirects mail sent to a user in the bovine.netvirtual domain to a local user on the machine. The second entry redirects mail to a user in the same virtual domain to a user in another domain. The third example redirects all mail addressed to any user in the dairly.orgvirtual domain to a single remote mail address. Finally, the last entry redirects any mail to a user in the artist.orgvirtual domain to the same user in another domain; for example, julie@artists.org would be redirected to julie@red.firefly.com .

Testing Your Configuration

The m4 command processes the macro definition files according to its own syntax rules without understanding anything about correct sendmail syntax; so there won't be any error messages if you've gotten anything wrong in your macro definition file. For this reason, it is very important that you thoroughly test your configuration. Fortunately, sendmail provides a relatively easy way of doing this.

sendmail supports an "address test" mode that allows us to test our configuration and identify any errors. In this mode of operation, we invoke sendmail from the command line, and it prompts us for a ruleset specification and a destination mail address. sendmail then processes that destination address using the rules specified, displaying the output of each rewrite rule as it proceeds. To place sendmail into this mode, we invoke it with the -bt argument:

# /usr/sbin/sendmail -bt

ADDRESS TEST MODE (ruleset 3 NOT automatically invoked)

Enter ‹ruleset› ‹address›

The default configuration file used is the /etc/mail/sendmail.cf file; you can specify an alternate configuration file using the -C argument. To test our configuration, we need to select a number of addresses to process that will tell us that each of our mail-handing requirements are met. To illustrate this, we'll work through a test of our more complicated UUCP configuration shown in Example 18.2.

First we'll test that sendmail is able to deliver mail to local users on the system. In these tests we expect all addresses to be rewritten to the localmailer on this machine:

# /usr/sbin/sendmail -bt

ADDRESS TEST MODE (ruleset 3 NOT automatically invoked)

Enter

> 3,0 isaac

rewrite: ruleset 3 input: isaac

rewrite: ruleset 96 input: isaac

rewrite: ruleset 96 returns: isaac

rewrite: ruleset 3 returns: isaac

rewrite: ruleset 0 input: isaac

rewrite: ruleset 199 input: isaac

rewrite: ruleset 199 returns: isaac

rewrite: ruleset 98 input: isaac

rewrite: ruleset 98 returns: isaac

rewrite: ruleset 198 input: isaac

rewrite: ruleset 198 returns: $# local $: isaac

rewrite: ruleset 0 returns: $# local $: isaac

This output shows us how sendmail processes mail addressed to isaacon this system. Each line shows us what information has been supplied to a ruleset or the result obtained from processing by a ruleset. We told sendmail we wished to use rulesets 3 and 0 to process the address. Ruleset 0 is what is normally invoked and we forced ruleset 3 because it is not tested by default. The last line shows us that the result of ruleset 0 does indeed direct mail to isaacto the localmailer.

Next we'll test mail addressed to our SMTP address: isaac@vstout.vbrew.com. We should be able to produce the same end result as our last example:

# /usr/sbin/sendmail -bt

ADDRESS TEST MODE (ruleset 3 NOT automatically invoked)

Enter

> 3,0 isaac@vstout.vbrew.com

rewrite: ruleset 3 input: isaac @ vstout . vbrew . com

rewrite: ruleset 96 input: isaac < @ vstout . vbrew . com >

rewrite: ruleset 96 returns: isaac < @ vstout . vbrew . com . >

rewrite: ruleset 3 returns: isaac < @ vstout . vbrew . com . >

rewrite: ruleset 0 input: isaac < @ vstout . vbrew . com . >

rewrite: ruleset 199 input: isaac < @ vstout . vbrew . com . >

rewrite: ruleset 199 returns: isaac < @ vstout . vbrew . com . >

rewrite: ruleset 98 input: isaac < @ vstout . vbrew . com . >

rewrite: ruleset 98 returns: isaac < @ vstout . vbrew . com . >

rewrite: ruleset 198 input: isaac < @ vstout . vbrew . com . >

rewrite: ruleset 198 returns: $# local $: isaac

rewrite: ruleset 0 returns: $# local $: isaac

Again, this test passed. Next we'll test mail to our UUCP style address: vstout!isaac.

# /usr/sbin/sendmail -bt

ADDRESS TEST MODE (ruleset 3 NOT automatically invoked)

Enter

> 3,0 vstout!isaac

rewrite: ruleset 3 input: vstout ! isaac

rewrite: ruleset 96 input: isaac < @ vstout . UUCP >

rewrite: ruleset 96 returns: isaac < @ vstout . vbrew . com . >

rewrite: ruleset 3 returns: isaac < @ vstout . vbrew . com . >

rewrite: ruleset 0 input: isaac < @ vstout . vbrew . com . >

rewrite: ruleset 199 input: isaac < @ vstout . vbrew . com . >

rewrite: ruleset 199 returns: isaac < @ vstout . vbrew . com . >

rewrite: ruleset 98 input: isaac < @ vstout . vbrew . com . >

rewrite: ruleset 98 returns: isaac < @ vstout . vbrew . com . >

rewrite: ruleset 198 input: isaac < @ vstout . vbrew . com . >

rewrite: ruleset 198 returns: $# local $: isaac

rewrite: ruleset 0 returns: $# local $: isaac

This test has also passed. These tests confirm that any mail received for local users on this machine will be properly delivered irrespective of how the address is formatted. If you've defined any aliases for your machine, such as virtual hosts, you should repeat these tests for each of the alternate names by which this host is known to ensure they also work correctly.

Next we will test that mail addressed to other hosts in the vbrew.comdomain is delivered directly to that host using the SMTP mailer:

# /usr/sbin/sendmail -bt

ADDRESS TEST MODE (ruleset 3 NOT automatically invoked)

Enter

> 3,0 isaac@vale.vbrew.com

rewrite: ruleset 3 input: isaac @ vale . vbrew . com

rewrite: ruleset 96 input: isaac < @ vale . vbrew . com >

rewrite: ruleset 96 returns: isaac < @ vale . vbrew . com . >

rewrite: ruleset 3 returns: isaac < @ vale . vbrew . com . >

rewrite: ruleset 0 input: isaac < @ vale . vbrew . com . >

Читать дальше
Тёмная тема
Сбросить

Интервал:

Закладка:

Сделать

Похожие книги на «Linux Network Administrator Guide, Second Edition»

Представляем Вашему вниманию похожие книги на «Linux Network Administrator Guide, Second Edition» списком для выбора. Мы отобрали схожую по названию и смыслу литературу в надежде предоставить читателям больше вариантов отыскать новые, интересные, ещё непрочитанные произведения.


Отзывы о книге «Linux Network Administrator Guide, Second Edition»

Обсуждение, отзывы о книге «Linux Network Administrator Guide, Second Edition» и просто собственные мнения читателей. Оставьте ваши комментарии, напишите, что Вы думаете о произведении, его смысле или главных героях. Укажите что конкретно понравилось, а что нет, и почему Вы так считаете.

x