创客百科

姿势共享,有节操无门槛参与的创客百科,创客动力之源 \ (^_^) /

用户工具

站点工具


note:spoony:给postfix清空邮件发送队列

给POSTFIX清空邮件发送队列

最近发现邮件日志大小一下子增长的很快,经过检查发现邮件服务器被发送了很多垃圾邮件,使用postqueue -p查看发现10多万封垃圾邮件.

因此不得不把所有的邮件队列全部清除,首先找到发垃圾邮件的帐号,予以停用。

然后执行如下命令顺序删除队列中的垃圾邮件。

1)首先停止postfix

service postfix stop

2)清除所有发送队列

postsuper -d ALL

3)启动postfix

service postfix start

这样就将待发送的垃圾邮件都删除了。

What clients to relay mail from

By default, Postfix will forward mail from clients in authorized network blocks to any destination. Authorized networks are defined with the mynetworks configuration parameter. The current default is to authorize the local machine only. Prior to Postfix 3.0, the default was to authorize all clients in the IP subnetworks that the local machine is attached to.

Postfix can also be configured to relay mail from “mobile” clients that send mail from outside an authorized network block. This is explained in the SASL_README and TLS_README documents.

IMPORTANT: If your machine is connected to a wide area network then your default mynetworks setting may be too friendly.

Examples (specify only one of the following):

/etc/postfix/main.cf:

  mynetworks_style = subnet  (default: authorize subnetworks)
  mynetworks_style = host    (safe: authorize local machine only)
  mynetworks = 127.0.0.0/8   (safe: authorize local machine only)
  mynetworks = 127.0.0.0/8 168.100.189.2/32 (authorize local machine) 

http://www.postfix.org/BASIC_CONFIGURATION_README.html http://openwares.net/linux/postfix_fundmental_setup.html

本页面的其他翻译:
note/spoony/给postfix清空邮件发送队列.txt · 最后更改: 2016/12/27 23:41 由 Spoony