{"id":28,"date":"2012-05-03T09:02:00","date_gmt":"2012-05-03T09:02:00","guid":{"rendered":"http:\/\/pheonixsolutions.com\/?p=28"},"modified":"2026-06-12T22:06:50","modified_gmt":"2026-06-12T16:36:50","slug":"postfix-tuning-and-steps-to-tune-the-postfix-in-server","status":"publish","type":"post","link":"https:\/\/pheonixsolutions.com\/blog\/postfix-tuning-and-steps-to-tune-the-postfix-in-server\/","title":{"rendered":"Postfix Tuning and steps to tune the postfix in server"},"content":{"rendered":"\n<h2 class=\"wp-block-heading\">Introduction<\/h2>\n\n\n\n<p class=\"wp-block-paragraph\">Postfix is a widely used mail transfer agent (MTA) that handles email delivery and routing on Linux servers. On busy mail servers, improper configuration can lead to increased system load, excessive disk I\/O, and queue processing delays. This guide outlines several tuning recommendations that can help improve Postfix performance and reduce server load.<\/p>\n\n\n\n<hr class=\"wp-block-separator has-alpha-channel-opacity\"\/>\n\n\n\n<h2 class=\"wp-block-heading\">Prerequisites<\/h2>\n\n\n\n<ul class=\"wp-block-list\">\n<li>Root or SSH access to the server<\/li>\n\n\n\n<li>Basic knowledge of Postfix configuration<\/li>\n\n\n\n<li>Access to syslog and Postfix configuration files<\/li>\n<\/ul>\n\n\n\n<hr class=\"wp-block-separator has-alpha-channel-opacity\"\/>\n\n\n\n<h2 class=\"wp-block-heading\">Implementation<\/h2>\n\n\n\n<h3 class=\"wp-block-heading\">Optimize Syslog Performance<\/h3>\n\n\n\n<p class=\"wp-block-paragraph\">One of the best ways to reduce server load is to write mail logs to a separate syslog server.<\/p>\n\n\n\n<p class=\"wp-block-paragraph\">Add the following entry to your syslog configuration:<\/p>\n\n\n\n<p class=\"wp-block-paragraph\">mail.* @xxx.xxx.xxx.xxx<\/p>\n\n\n\n<p class=\"wp-block-paragraph\">If a separate syslog server is not available, you can reduce disk synchronization overhead by prefixing the log file path with a dash (-):<\/p>\n\n\n\n<p class=\"wp-block-paragraph\">mail.* -\/var\/log\/maillog<\/p>\n\n\n\n<p class=\"wp-block-paragraph\">By default, syslogd synchronizes the log file after every write operation. Disabling this behavior can significantly reduce system load on busy mail servers.<\/p>\n\n\n\n<hr class=\"wp-block-separator has-alpha-channel-opacity\"\/>\n\n\n\n<h3 class=\"wp-block-heading\">Tune Postfix Queue Settings<\/h3>\n\n\n\n<p class=\"wp-block-paragraph\">Edit the Postfix configuration file:<\/p>\n\n\n\n<p class=\"wp-block-paragraph\">\/etc\/postfix\/main.cf<\/p>\n\n\n\n<p class=\"wp-block-paragraph\">Add or modify the following parameters:<\/p>\n\n\n\n<p class=\"wp-block-paragraph\">minimal_backoff_time = 2000s<\/p>\n\n\n\n<p class=\"wp-block-paragraph\">maximal_backoff_time = 8000s<\/p>\n\n\n\n<p class=\"wp-block-paragraph\">maximal_queue_lifetime = 2d<\/p>\n\n\n\n<p class=\"wp-block-paragraph\">message_size_limit = 10240000<\/p>\n\n\n\n<p class=\"wp-block-paragraph\">qmgr_message_active_limit = 20000<\/p>\n\n\n\n<p class=\"wp-block-paragraph\">qmgr_message_recipient_limit = 20000<\/p>\n\n\n\n<p class=\"wp-block-paragraph\">transport_retry_time = 120s<\/p>\n\n\n\n<hr class=\"wp-block-separator has-alpha-channel-opacity\"\/>\n\n\n\n<h3 class=\"wp-block-heading\">Parameter Overview<\/h3>\n\n\n\n<p class=\"wp-block-paragraph\"><strong>minimal_backoff_time<\/strong><\/p>\n\n\n\n<p class=\"wp-block-paragraph\">Specifies the minimum delay before Postfix retries delivery of a deferred message.<\/p>\n\n\n\n<hr class=\"wp-block-separator has-alpha-channel-opacity\"\/>\n\n\n\n<p class=\"wp-block-paragraph\"><strong>maximal_backoff_time<\/strong><\/p>\n\n\n\n<p class=\"wp-block-paragraph\">Specifies the maximum delay between delivery retry attempts.<\/p>\n\n\n\n<hr class=\"wp-block-separator has-alpha-channel-opacity\"\/>\n\n\n\n<p class=\"wp-block-paragraph\"><strong>maximal_queue_lifetime<\/strong><\/p>\n\n\n\n<p class=\"wp-block-paragraph\">Defines how long a message remains in the queue before it is returned as undeliverable.<\/p>\n\n\n\n<hr class=\"wp-block-separator has-alpha-channel-opacity\"\/>\n\n\n\n<p class=\"wp-block-paragraph\"><strong>message_size_limit<\/strong><\/p>\n\n\n\n<p class=\"wp-block-paragraph\">Sets the maximum message size allowed by Postfix.<\/p>\n\n\n\n<hr class=\"wp-block-separator has-alpha-channel-opacity\"\/>\n\n\n\n<p class=\"wp-block-paragraph\"><strong>qmgr_message_active_limit<\/strong><\/p>\n\n\n\n<p class=\"wp-block-paragraph\">Controls the number of messages that can be active in the queue manager simultaneously.<\/p>\n\n\n\n<hr class=\"wp-block-separator has-alpha-channel-opacity\"\/>\n\n\n\n<p class=\"wp-block-paragraph\"><strong>qmgr_message_recipient_limit<\/strong><\/p>\n\n\n\n<p class=\"wp-block-paragraph\">Controls the maximum number of recipients that the queue manager can process.<\/p>\n\n\n\n<hr class=\"wp-block-separator has-alpha-channel-opacity\"\/>\n\n\n\n<p class=\"wp-block-paragraph\"><strong>transport_retry_time<\/strong><\/p>\n\n\n\n<p class=\"wp-block-paragraph\">Defines how often Postfix retries a failed transport.<\/p>\n\n\n\n<hr class=\"wp-block-separator has-alpha-channel-opacity\"\/>\n\n\n\n<h3 class=\"wp-block-heading\">Queue Management Considerations<\/h3>\n\n\n\n<p class=\"wp-block-paragraph\">These settings help reduce the workload caused by repeated delivery attempts, especially when processing bounced or undeliverable messages.<\/p>\n\n\n\n<p class=\"wp-block-paragraph\">The qmgr_message_active_limit and qmgr_message_recipient_limit values have been increased to allow the queue manager to process more messages in memory, which may help reduce disk activity and improve overall performance on busy servers.<\/p>\n\n\n\n<hr class=\"wp-block-separator has-alpha-channel-opacity\"\/>\n\n\n\n<h2 class=\"wp-block-heading\">Conclusion<\/h2>\n\n\n\n<p class=\"wp-block-paragraph\">Proper Postfix tuning can significantly reduce server load and improve mail delivery performance. Optimizing syslog handling and adjusting queue management parameters helps minimize disk I\/O, improve resource utilization, and ensure smoother email processing on high-volume mail servers.<\/p>\n","protected":false},"excerpt":{"rendered":"<p>Introduction Postfix is a widely used mail transfer agent (MTA) that handles email delivery and routing on Linux servers. On [&hellip;]<\/p>\n","protected":false},"author":1,"featured_media":0,"comment_status":"open","ping_status":"open","sticky":false,"template":"","format":"standard","meta":{"site-sidebar-layout":"default","site-content-layout":"","ast-site-content-layout":"default","site-content-style":"default","site-sidebar-style":"default","ast-global-header-display":"","ast-banner-title-visibility":"","ast-main-header-display":"","ast-hfb-above-header-display":"","ast-hfb-below-header-display":"","ast-hfb-mobile-header-display":"","site-post-title":"","ast-breadcrumbs-content":"","ast-featured-img":"","footer-sml-layout":"","ast-disable-related-posts":"","theme-transparent-header-meta":"","adv-header-id-meta":"","stick-header-meta":"","header-above-stick-meta":"","header-main-stick-meta":"","header-below-stick-meta":"","astra-migrate-meta-layouts":"default","ast-page-background-enabled":"default","ast-page-background-meta":{"desktop":{"background-color":"var(--ast-global-color-5)","background-image":"","background-repeat":"repeat","background-position":"center center","background-size":"auto","background-attachment":"scroll","background-type":"","background-media":"","overlay-type":"","overlay-color":"","overlay-opacity":"","overlay-gradient":""},"tablet":{"background-color":"","background-image":"","background-repeat":"repeat","background-position":"center center","background-size":"auto","background-attachment":"scroll","background-type":"","background-media":"","overlay-type":"","overlay-color":"","overlay-opacity":"","overlay-gradient":""},"mobile":{"background-color":"","background-image":"","background-repeat":"repeat","background-position":"center center","background-size":"auto","background-attachment":"scroll","background-type":"","background-media":"","overlay-type":"","overlay-color":"","overlay-opacity":"","overlay-gradient":""}},"ast-content-background-meta":{"desktop":{"background-color":"var(--ast-global-color-4)","background-image":"","background-repeat":"repeat","background-position":"center center","background-size":"auto","background-attachment":"scroll","background-type":"","background-media":"","overlay-type":"","overlay-color":"","overlay-opacity":"","overlay-gradient":""},"tablet":{"background-color":"var(--ast-global-color-4)","background-image":"","background-repeat":"repeat","background-position":"center center","background-size":"auto","background-attachment":"scroll","background-type":"","background-media":"","overlay-type":"","overlay-color":"","overlay-opacity":"","overlay-gradient":""},"mobile":{"background-color":"var(--ast-global-color-4)","background-image":"","background-repeat":"repeat","background-position":"center center","background-size":"auto","background-attachment":"scroll","background-type":"","background-media":"","overlay-type":"","overlay-color":"","overlay-opacity":"","overlay-gradient":""}},"_jetpack_newsletter_access":"","_jetpack_dont_email_post_to_subs":false,"_jetpack_newsletter_tier_id":0,"_jetpack_memberships_contains_paywalled_content":false,"_jetpack_memberships_contains_paid_content":false,"footnotes":"","jetpack_publicize_message":"","jetpack_publicize_feature_enabled":true,"jetpack_social_post_already_shared":false,"jetpack_social_options":{"image_generator_settings":{"template":"highway","default_image_id":0,"font":"","enabled":false},"version":2},"jetpack_post_was_ever_published":false},"categories":[1019],"tags":[171],"class_list":["post-28","post","type-post","status-publish","format-standard","hentry","category-cloud-aws","tag-postfix","psol-cat-cloud-aws"],"jetpack_publicize_connections":[],"jetpack_shortlink":"https:\/\/wp.me\/phn2x7-s","jetpack_sharing_enabled":true,"jetpack_featured_media_url":"","_links":{"self":[{"href":"https:\/\/pheonixsolutions.com\/blog\/wp-json\/wp\/v2\/posts\/28","targetHints":{"allow":["GET"]}}],"collection":[{"href":"https:\/\/pheonixsolutions.com\/blog\/wp-json\/wp\/v2\/posts"}],"about":[{"href":"https:\/\/pheonixsolutions.com\/blog\/wp-json\/wp\/v2\/types\/post"}],"author":[{"embeddable":true,"href":"https:\/\/pheonixsolutions.com\/blog\/wp-json\/wp\/v2\/users\/1"}],"replies":[{"embeddable":true,"href":"https:\/\/pheonixsolutions.com\/blog\/wp-json\/wp\/v2\/comments?post=28"}],"version-history":[{"count":1,"href":"https:\/\/pheonixsolutions.com\/blog\/wp-json\/wp\/v2\/posts\/28\/revisions"}],"predecessor-version":[{"id":10354,"href":"https:\/\/pheonixsolutions.com\/blog\/wp-json\/wp\/v2\/posts\/28\/revisions\/10354"}],"wp:attachment":[{"href":"https:\/\/pheonixsolutions.com\/blog\/wp-json\/wp\/v2\/media?parent=28"}],"wp:term":[{"taxonomy":"category","embeddable":true,"href":"https:\/\/pheonixsolutions.com\/blog\/wp-json\/wp\/v2\/categories?post=28"},{"taxonomy":"post_tag","embeddable":true,"href":"https:\/\/pheonixsolutions.com\/blog\/wp-json\/wp\/v2\/tags?post=28"}],"curies":[{"name":"wp","href":"https:\/\/api.w.org\/{rel}","templated":true}]}}