aliases 中文man頁(yè)面
NAME
aliases - sendmail使用的別名文件
總覽
aliases
描述
此文件描述了 /usr/sbin/sendmai 使用的用戶賬號(hào)別名。它位于 /etc 并格式化成如下形式的一連串的行: name: name_1, name2, name_3, . . .
其中的 name 是含別名的原名,而 name_n 就是那個(gè)原名的一組別名。以空格起首的行是上一行的延續(xù)。以`#'起首的行是注釋。
別名化只發(fā)生在本地賬號(hào)上。不能發(fā)生循環(huán)現(xiàn)象,因?yàn)猷]件不會(huì)對(duì)任何人進(jìn)行于一多次的投遞。在完成別名化后,本地的和合法的收信人會(huì)有一個(gè)``.forward''文件存于他們的宿主目錄,此文件用于把郵件按文件中定義好的用戶列表進(jìn)行轉(zhuǎn)發(fā)。
此別名文件只包含原始數(shù)據(jù);實(shí)際的別名化信息存于用程序 newaliases(1) 建立的 /etc/aliases.db 這個(gè)二進(jìn)制格式的文件中。每次別名文件更改后都要執(zhí)行 newaliases 命令來(lái)使更改有效。
另見
newaliases(1), dbopen(3), dbm(3), sendmail(8)
#p#
NAME
aliases - aliases file for sendmail
SYNOPSIS
aliases
DESCRIPTION
This file describes user ID aliases used by sendmail. The file resides in /etc/mail and is formatted as a series of lines of the form
- name: addr_1, addr_2, addr_3, . . .
The name is the name to alias, and the addr_n are the aliases for that name. addr_n can be another alias, a local username, a local filename, a command, an include file, or an external address.
- Local Username
- username
- The username must be available via getpwnam(3).
- Local Filename
- /path/name
- Messages are appended to the file specified by the full pathname (starting with a slash (/))
- Command
- |command
- A command starts with a pipe symbol (|), it receives messages via standard input.
- Include File
- :include: /path/name
- The aliases in pathname are added to the aliases for name.
- E-Mail Address
- user@domain
- An e-mail address in RFC 822 format.
Lines beginning with white space are continuation lines. Another way to continue lines is by placing a backslash directly before a newline. Lines beginning with # are comments.
Aliasing occurs only on local names. Loops can not occur, since no message will be sent to any person more than once.
If an alias is found for name, sendmail then checks for an alias for owner-name. If it is found and the result of the lookup expands to a single address, the envelope sender address of the message is rewritten to that address. If it is found and the result expands to more than one address, the envelope sender address is changed to owner-name.
After aliasing has been done, local and valid recipients who have a ``.forward'' file in their home directory have messages forwarded to the list of users defined in that file.
This is only the raw data file; the actual aliasing information is placed into a binary format in the file /etc/mail/aliases.db using the program newaliases(1). A newaliases command should be executed each time the aliases file is changed for the change to take effect.
SEE ALSO
newaliases(1), dbm(3), dbopen(3), db_open(3), sendmail(8)