{"id":4612,"date":"2013-05-19T12:25:49","date_gmt":"2013-05-19T04:25:49","guid":{"rendered":"https:\/\/webhostinggeeks.com\/howto\/?p=4612"},"modified":"2023-04-28T09:48:21","modified_gmt":"2023-04-28T09:48:21","slug":"how-to-setup-postfix-on-centos-6-4","status":"publish","type":"post","link":"https:\/\/webhostinggeeks.com\/howto\/how-to-setup-postfix-on-centos-6-4\/","title":{"rendered":"How to Setup Postfix on CentOS 6.4"},"content":{"rendered":"<p><img decoding=\"async\" data-src=\"https:\/\/webhostinggeeks.com\/howto\/wp-content\/uploads\/2013\/02\/Posfix-Mail.jpg\" alt=\"Posfix Mail\" width=\"120\" height=\"120\" class=\"alignleft size-full wp-image-4299 lazyload\" data-srcset=\"https:\/\/webhostinggeeks.com\/howto\/wp-content\/uploads\/2013\/02\/Posfix-Mail.jpg 120w, https:\/\/webhostinggeeks.com\/howto\/wp-content\/uploads\/2013\/02\/Posfix-Mail-100x100.jpg 100w\" data-sizes=\"(max-width: 120px) 100vw, 120px\" src=\"data:image\/svg+xml;base64,PHN2ZyB3aWR0aD0iMSIgaGVpZ2h0PSIxIiB4bWxucz0iaHR0cDovL3d3dy53My5vcmcvMjAwMC9zdmciPjwvc3ZnPg==\" style=\"--smush-placeholder-width: 120px; --smush-placeholder-aspect-ratio: 120\/120;\" \/>Postfix is a open-source mail transfer agent (MTA) that routes and delivers electronic mail. Postfix is an alternative for Sendmail service which provide the same function. This post will describe on how you can install and setup postfix on CentOS 6.4. After you installed postfix, you can use postfix command to controls the operation of the Postfix mail system such as start or stop the master daemon, do a health check, and other maintenance.<\/p>\n<p>1. To install Postfix, use the following yum command :<\/p>\n<pre>\n[root@centos64 ~]# yum install postfix -y\n<\/pre>\n<p>2. To verify if Postfix is already installed, use the following rpm command :<\/p>\n<pre>\n[root@centos64 ~]# rpm -q postfix\n<\/pre>\n<p>Example :<\/p>\n<pre>\n[root@centos64 ~]# rpm -q postfix\npostfix-2.6.6-2.2.el6_1.x86_64\n<\/pre>\n<p>3. How to check Postfix version :<\/p>\n<pre>\n[root@centos64 ~]# postconf -d | grep mail_version\n<\/pre>\n<p>Example :<\/p>\n<pre>\n[root@centos64 ~]# postconf -d | grep mail_version\nmail_version = 2.6.6\nmilter_macro_v = $mail_name $mail_version\n<\/pre>\n<p>4. Configure Basic postfix main.cf file :<\/p>\n<pre>\n[root@centos64 ~]# vi \/etc\/postfix\/main.cf\n<\/pre>\n<p>Uncomment and modify the following two line :<\/p>\n<pre>\nmyhostname = centos6.4.ehowstuff.local\nmydomain = ehowstuff.local\n<\/pre>\n<p>myhostname: is the host name of the system (i.e, the system is called mail or mail.example.com).<br \/>\nmydomain: is the domain name for the email server (it can be a real or fake domain name).<\/p>\n<p>5. Start the postfix service :<\/p>\n<pre>\n[root@centos64 ~]# service postfix start\nStarting postfix:                                          [  OK  ]\n<\/pre>\n<p>6. Restart the postfix service :<\/p>\n<pre>\n[root@centos64 ~]# service postfix restart\nShutting down postfix:                                     [  OK  ]\nStarting postfix:                                          [  OK  ]\n<\/pre>\n<p>7. How to show postfix pid number on running for postfix services ?<\/p>\n<pre>\n[root@centos64 ~]# ps -ef | grep postfix\nroot      3081     1  0 05:57 ?        00:00:00 \/usr\/libexec\/postfix\/master\npostfix   3083  3081  0 05:57 ?        00:00:00 pickup -l -t fifo -u\npostfix   3084  3081  0 05:57 ?        00:00:00 qmgr -l -t fifo -u\nroot      3292  1963  0 06:40 pts\/0    00:00:00 grep postfix\n<\/pre>\n","protected":false},"excerpt":{"rendered":"<p>Postfix is a open-source mail transfer agent (MTA) that routes and delivers electronic mail. Postfix is an alternative for Sendmail service which provide the same function. This post will describe&#8230;<\/p>\n","protected":false},"author":6,"featured_media":4299,"comment_status":"open","ping_status":"closed","sticky":false,"template":"","format":"standard","meta":{"wds_primary_category":0,"footnotes":""},"categories":[2055,1028],"tags":[1255,1355,1479,1536,1664,1786],"class_list":["post-4612","post","type-post","status-publish","format-standard","has-post-thumbnail","hentry","category-centos","category-postfix","tag-centos-6-4","tag-email-server","tag-imap","tag-linux","tag-postfix","tag-smtp"],"_links":{"self":[{"href":"https:\/\/webhostinggeeks.com\/howto\/wp-json\/wp\/v2\/posts\/4612","targetHints":{"allow":["GET"]}}],"collection":[{"href":"https:\/\/webhostinggeeks.com\/howto\/wp-json\/wp\/v2\/posts"}],"about":[{"href":"https:\/\/webhostinggeeks.com\/howto\/wp-json\/wp\/v2\/types\/post"}],"author":[{"embeddable":true,"href":"https:\/\/webhostinggeeks.com\/howto\/wp-json\/wp\/v2\/users\/6"}],"replies":[{"embeddable":true,"href":"https:\/\/webhostinggeeks.com\/howto\/wp-json\/wp\/v2\/comments?post=4612"}],"version-history":[{"count":0,"href":"https:\/\/webhostinggeeks.com\/howto\/wp-json\/wp\/v2\/posts\/4612\/revisions"}],"wp:featuredmedia":[{"embeddable":true,"href":"https:\/\/webhostinggeeks.com\/howto\/wp-json\/wp\/v2\/media\/4299"}],"wp:attachment":[{"href":"https:\/\/webhostinggeeks.com\/howto\/wp-json\/wp\/v2\/media?parent=4612"}],"wp:term":[{"taxonomy":"category","embeddable":true,"href":"https:\/\/webhostinggeeks.com\/howto\/wp-json\/wp\/v2\/categories?post=4612"},{"taxonomy":"post_tag","embeddable":true,"href":"https:\/\/webhostinggeeks.com\/howto\/wp-json\/wp\/v2\/tags?post=4612"}],"curies":[{"name":"wp","href":"https:\/\/api.w.org\/{rel}","templated":true}]}}