/*++
/* NAME
/* smtpd 8
/* SUMMARY
/* Postfix SMTP server
/* SYNOPSIS
/* \fBsmtpd\fR [generic Postfix daemon options]
/*
/* \fBsendmail -bs\fR
/* DESCRIPTION
/* The SMTP server accepts network connection requests
/* and performs zero or more SMTP transactions per connection.
/* Each received message is piped through the \fBcleanup\fR(8)
/* daemon, and is placed into the \fBincoming\fR queue as one
/* single queue file. For this mode of operation, the program
/* expects to be run from the \fBmaster\fR(8) process manager.
/*
/* Alternatively, the SMTP server be can run in stand-alone
/* mode; this is traditionally obtained with "\fBsendmail
/* -bs\fR". When the SMTP server runs stand-alone with non
/* $\fBmail_owner\fR privileges, it receives mail even while
/* the mail system is not running, deposits messages directly
/* into the \fBmaildrop\fR queue, and disables the SMTP server's
/* access policies. As of Postfix version 2.3, the SMTP server
/* refuses to receive mail from the network when it runs with
/* non $\fBmail_owner\fR privileges.
/*
/* The SMTP server implements a variety of policies for connection
/* requests, and for parameters given to \fBHELO, ETRN, MAIL FROM, VRFY\fR
/* and \fBRCPT TO\fR commands. They are detailed below and in the
/* \fBmain.cf\fR configuration file.
/* SECURITY
/* .ad
/* .fi
/* The SMTP server is moderately security-sensitive. It talks to SMTP
/* clients and to DNS servers on the network. The SMTP server can be
/* run chrooted at fixed low privilege.
/* STANDARDS
/* RFC 821 (SMTP protocol)
/* RFC 1123 (Host requirements)
/* RFC 1652 (8bit-MIME transport)
/* RFC 1869 (SMTP service extensions)
/* RFC 1870 (Message Size Declaration)
/* RFC 1985 (ETRN command)
/* RFC 2034 (SMTP Enhanced Status Codes)
/* RFC 2554 (AUTH command)
/* RFC 2821 (SMTP protocol)
/* RFC 2920 (SMTP Pipelining)
/* RFC 3207 (STARTTLS command)
/* RFC 3461 (SMTP DSN Extension)
/* RFC 3463 (Enhanced Status Codes)
/* RFC 3848 (ESMTP Transmission Types)
/* RFC 4954 (AUTH command)
/* DIAGNOSTICS
/* Problems and transactions are logged to \fBsyslogd\fR(8).
/*
/* Depending on the setting of the \fBnotify_classes\fR parameter,
/* the postmaster is notified of bounces, protocol problems,
/* policy violations, and of other trouble.
/* CONFIGURATION PARAMETERS
/* .ad
/* .fi
/* Changes to \fBmain.cf\fR are picked up automatically, as \fBsmtpd\fR(8)
/* processes run for only a limited amount of time. Use the command
/* "\fBpostfix reload\fR" to speed up a change.
/*
/* The text below provides only a parameter summary. See
/* \fBpostconf\fR(5) for more details including examples.
/* COMPATIBILITY CONTROLS
/* .ad
/* .fi
/* The following parameters work around implementation errors in other
/* software, and/or allow you to override standards in order to prevent
/* undesirable use.
/* .ad
/* .fi
/* .IP "\fBbroken_sasl_auth_clients (no)\fR"
/* Enable inter-operability with SMTP clients that implement an obsolete
/* version of the AUTH command (RFC 4954).
/* .IP "\fBdisable_vrfy_command (no)\fR"
/* Disable the SMTP VRFY command.
/* .IP "\fBsmtpd_noop_commands (empty)\fR"
/* List of commands that the Postfix SMTP server replies to with "250
/* Ok", without doing any syntax checks and without changing state.
/* .IP "\fBstrict_rfc821_envelopes (no)\fR"
/* Require that addresses received in SMTP MAIL FROM and RCPT TO
/* commands are enclosed with <>, and that those addresses do
/* not contain RFC 822 style comments or phrases.
/* .PP
/* Available in Postfix version 2.1 and later:
/* .IP "\fBresolve_null_domain (no)\fR"
/* Resolve an address that ends in the "@" null domain as if the
/* local hostname were specified, instead of rejecting the address as
/* invalid.
/* .IP "\fBsmtpd_reject_unlisted_sender (no)\fR"
/* Request that the Postfix SMTP server rejects mail from unknown
/* sender addresses, even when no explicit reject_unlisted_sender
/* access restriction is specified.
/* .IP "\fBsmtpd_sasl_exceptions_networks (empty)\fR"
/* What remote SMTP clients the Postfix SMTP server will not offer
/* AUTH support to.
/* .PP
/* Available in Postfix version 2.2 and later:
/* .IP "\fBsmtpd_discard_ehlo_keyword_address_maps (empty)\fR"
/* Lookup tables, indexed by the remote SMTP client address, with
/* case insensitive lists of EHLO keywords (pipelining, starttls, auth,
/* etc.) that the SMTP server will not send in the EHLO response to a
/* remote SMTP client.
/* .IP "\fBsmtpd_discard_ehlo_keywords (empty)\fR"
/* A case insensitive list of EHLO keywords (pipelining, starttls,
/* auth, etc.) that the SMTP server will not send in the EHLO response
/* to a remote SMTP client.
/* .IP "\fBsmtpd_delay_open_until_valid_rcpt (yes)\fR"
/* Postpone the start of an SMTP mail transaction until a valid
/* RCPT TO command is received.
/* .PP
/* Available in Postfix version 2.3 and later:
/* .IP "\fBsmtpd_tls_always_issue_session_ids (yes)\fR"
/* Force the Postfix SMTP server to issue a TLS session id, even
/* when TLS session caching is turned off (smtpd_tls_session_cache_database
/* is empty).
/* .PP
/* Available in Postfix version 2.6 and later:
/* .IP "\fBtcp_windowsize (0)\fR"
/* An optional workaround for routers that break TCP window scaling.
/* .PP
/* Available in Postfix version 2.7 and later:
/* .IP "\fBsmtpd_command_filter (empty)\fR"
/* A mechanism to transform commands from remote SMTP clients.
/* ADDRESS REWRITING CONTROLS
/* .ad
/* .fi
/* See the ADDRESS_REWRITING_README document for a detailed
/* discussion of Postfix address rewriting.
/* .IP "\fBreceive_override_options (empty)\fR"
/* Enable or disable recipient validation, built-in content
/* filtering, or address mapping.
/* .PP
/* Available in Postfix version 2.2 and later:
/* .IP "\fBlocal_header_rewrite_clients (permit_inet_interfaces)\fR"
/* Rewrite message header addresses in mail from these clients and
/* update incomplete addresses with the domain name in $myorigin or
/* $mydomain; either don't rewrite message headers from other clients
/* at all, or rewrite message headers and update incomplete addresses
/* with the domain specified in the remote_header_rewrite_domain
/* parameter.
/* AFTER QUEUE EXTERNAL CONTENT INSPECTION CONTROLS
/* .ad
/* .fi
/* As of version 1.0, Postfix can be configured to send new mail to
/* an external content filter AFTER the mail is queued. This content
/* filter is expected to inject mail back into a (Postfix or other)
/* MTA for further delivery. See the FILTER_README document for details.
/* .IP "\fBcontent_filter (empty)\fR"
/* After the message is queued, send the entire message to the
/* specified \fItransport:destination\fR.
/* BEFORE QUEUE EXTERNAL CONTENT INSPECTION CONTROLS
/* .ad
/* .fi
/* As of version 2.1, the Postfix SMTP server can be configured
/* to send incoming mail to a real-time SMTP-based content filter
/* BEFORE mail is queued. This content filter is expected to inject
/* mail back into Postfix. See the SMTPD_PROXY_README document for
/* details on how to configure and operate this feature.
/* .IP "\fBsmtpd_proxy_filter (empty)\fR"
/* The hostname and TCP port of the mail filtering proxy server.
/* .IP "\fBsmtpd_proxy_ehlo ($myhostname)\fR"
/* How the Postfix SMTP server announces itself to the proxy filter.
/* .IP "\fBsmtpd_proxy_options (empty)\fR"
/* List of options that control how the Postfix SMTP server
/* communicates with a before-queue content filter.
/* .IP "\fBsmtpd_proxy_timeout (100s)\fR"
/* The time limit for connecting to a proxy filter and for sending or
/* receiving information.
/* BEFORE QUEUE MILTER CONTROLS
/* .ad
/* .fi
/* As of version 2.3, Postfix supports the Sendmail version 8
/* Milter (mail filter) protocol. These content filters run
/* outside Postfix. They can inspect the SMTP command stream
/* and the message content, and can request modifications before
/* mail is queued. For details see the MILTER_README document.
/* .IP "\fBsmtpd_milters (empty)\fR"
/* A list of Milter (mail filter) applications for new mail that
/* arrives via
postfix-2.9-20110130.tar.gz
需积分: 0 201 浏览量
更新于2011-07-20
收藏 3.47MB GZ 举报
《Postfix邮件服务器详解——基于postfix-2.9-20110130.tar.gz的构建与配置》
在IT行业中,邮件服务是不可或缺的基础设施之一,尤其对于企业内部通信和对外业务交流至关重要。Postfix是一款开源、免费且高效稳定的邮件传输代理软件,被广泛应用于全球众多组织和公司。本文将深入探讨基于`postfix-2.9-20110130.tar.gz`的Postfix邮件服务器的安装、配置和管理,帮助读者全面了解这一强大的邮件系统。
1. **Postfix简介**
Postfix由Wietse Venema在1998年开发,设计目标是提供高性能、安全性和易管理性。其设计思想是将复杂的邮件系统分解为多个独立的组件,每个组件负责特定的任务,从而提高系统的稳定性和可维护性。2.9版本是在2011年1月30日发布的一个稳定版本,虽然年代较为久远,但其核心功能仍然可靠。
2. **安装过程**
- 解压`postfix-2.9-20110130.tar.gz`到本地目录。
- 使用`./configure`命令进行配置,根据系统环境选择合适的选项。
- 运行`make`编译源码。
- 执行`make install`安装到系统路径。
3. **基本配置**
Postfix的配置文件主要位于`/etc/postfix`目录下,主要包括`main.cf`(主配置文件)和`master.cf`(守护进程配置文件)。配置项繁多,例如:
- `myhostname`: 服务器的完全合格域名(FQDN)。
- `mydomain`: 用于发送邮件时的域名。
- `myorigin`: 发送邮件的默认域。
- `inet_interfaces`: 定义Postfix监听的网络接口。
- `smtpd_recipient_restrictions`: 控制谁可以接收邮件的策略。
4. **启动与管理**
- 启动Postfix服务:`systemctl start postfix`(或`service postfix start`,取决于Linux发行版)。
- 检查Postfix状态:`systemctl status postfix`(或`service postfix status`)。
- 配置文件变动后,需要重启服务使改动生效:`systemctl restart postfix`。
5. **安全与反垃圾邮件**
- TLS加密:启用SMTPS(465端口)和STARTTLS(587端口),确保邮件传输安全。
- SPF、DKIM和DMARC:设置这些记录可防止伪造邮件并增强邮件信誉。
- SpamAssassin:集成垃圾邮件过滤器,提升邮件质量。
6. **高级特性**
- 邮件队列管理:通过`mailq`命令查看邮件队列,`postqueue`和`postsuper`命令用于管理队列。
- 邮件转发:通过`virtual`或`forward`表实现本地用户和远程用户的邮件转发。
- 身份验证:支持SMTP身份验证,增加安全性,防止滥用。
7. **故障排查**
- 日志分析:Postfix的日志文件通常位于`/var/log/maillog`,是排查问题的重要线索。
- `postconf -n`:查看当前生效的配置项,对比`main.cf`检查是否有误。
- `postfix check`:检查配置文件的语法错误。
8. **监控与性能优化**
- 监控工具如Nagios、Zabbix等可用于实时监控Postfix的状态。
- 根据负载调整配置,如限制并发连接数、优化DNS查询缓存等。
总结,Postfix作为一款成熟的邮件服务器软件,其丰富的配置选项和模块化设计使其能适应各种环境和需求。通过深入了解和实践,我们可以充分利用其功能,构建稳定、高效的邮件服务系统。对于初学者,理解并掌握Postfix的配置和管理,将有助于提升运维技能,而对于资深管理员,不断探索和优化Postfix的使用,可以提升邮件系统的整体性能和安全性。
sq19860103
- 粉丝: 0
- 资源: 5
最新资源
- 纸箱检测23-YOLOv9数据集合集.rar
- 1键切换,随机播放本地音乐(适合管理大量本地音乐),无需联网,珍藏版音乐软件
- canoe的log数据文件读取
- 纸检测55-YOLOv5数据集合集.rar
- 实现vue+docxtemplater导出word文档功能时,需要引入的资源文件
- 个人PPT模板,总结或者作为素材使用
- 纸板、面料、纸类、塑料检测68-YOLO(v5至v9)、COCO、CreateML、Darknet、Paligemma、TFRecord、VOC数据集合集.rar
- 【java源代码】基于spring+vue的音乐推荐管理(完整前后端+mysql+说明文档+LW).zip
- 长文本c++Aes加密
- 纸和塑料检测55-YOLO(v7至v9)、Paligemma、VOC数据集合集.rar