This shows you the differences between two versions of the page.
Both sides previous revision Previous revision Next revision | Previous revision | ||
sendmail [2011/05/13 00:35] k2patel |
sendmail [2020/08/10 02:35] (current) |
||
---|---|---|---|
Line 10: | Line 10: | ||
when you modify /etc/mail/aliases.\\ | when you modify /etc/mail/aliases.\\ | ||
Possibly you see following message. \\ | Possibly you see following message. \\ | ||
- | //alias database /etc/mail/aliases.db out of date// \\ | + | //**alias database /etc/mail/aliases.db out of date**// \\ |
Simply run following and will fix it. | Simply run following and will fix it. | ||
Line 16: | Line 17: | ||
newaliases | newaliases | ||
</code> | </code> | ||
+ | OR\\ | ||
+ | run 'make' in /etc/mail to update all databases\\ | ||
+ | OR | ||
+ | <code bash> | ||
+ | sendmail -bi | ||
+ | </code> | ||
==== Error Code 126 ==== | ==== Error Code 126 ==== | ||
Line 41: | Line 47: | ||
NOTE : change 192.168.1.22 with your IP. | NOTE : change 192.168.1.22 with your IP. | ||
+ | |||
+ | ==== Clear queue ==== | ||
+ | |||
+ | Check if you want to delete all mail. | ||
+ | <code bash> | ||
+ | mailq | ||
+ | OR | ||
+ | sendmail -bp | ||
+ | </code> | ||
+ | |||
+ | Now if you want to delete everything in queue just delete everything inside mqueue folder.\\ | ||
+ | In CentOS it is located at **/var/spool/mqueue/** | ||
+ | <code bash> | ||
+ | rm -rf /var/spool/mqueue/* | ||
+ | </code> | ||
+ | |||
+ | If there is too many files to remove you better use option like xargs with find. | ||
+ | <code bash> | ||
+ | find /var/spool/mqueue -name * -print0 |xargs -0 -r -n100 rm | ||
+ | </code> |