INSTALLASI POSTFIX DI FREEBSD


tikus

Install post fix ternyata gak begitu rumit. gue hanya 2 hari pusing. gak seperti yg laen hehehehe.

tahap installasi

1. download file postfix

fetch http://www.pttuntex.com/~david/softwareBSD/postfix-2.0.0.2.tar.gz

2. extract file nya dan masuk ke direktorynya

tar fxzv postfix-2.0.10.tar.gz

cd postfix-2.0.10.tar.gz

3. compile

make

4. buat group dan user postfix

pw groupadd postfix

pw groupadd postdrop

pw useradd postfix -g postfix -d /sbin/nologin -s /nonexistent

5. install (akan muncul pertanyaan)

make install

install_root: [/]
tempdir: [/tmp/snapshot-20011008]
config_directory: [/etc/postfix]
daemon_directory: [/usr/libexec/postfix]
command_directory: [/usr/sbin]
queue_directory: [/var/spool/postfix]
sendmail_path: [/usr/lib/sendmail]
newaliases_path: [/usr/bin/newaliases]
mailq_path: [/usr/bin/mailq]
mail_owner: [postfix]
setgid_group: [postdrop]
manpages: [/usr/local/man]
sample_directory: [/etc/postfix]
readme_directory: [no]
6. setelah install sukses, edit file main.cf di /etc/postfix perhatikan baris berikut dan edit seperlunya
edit /etc/postfix/main.cf
berikut configure main.cf ( heran pa harus se detail ini yach hihihhihi dasar nista)
————- /etc/postfix/main.cf ——————–
#soft_bounce = no

# LOCAL PATHNAME INFORMATION
queue_directory = /var/spool/postfix
command_directory = /usr/sbin
daemon_directory = /usr/libexec/postfix

# QUEUE AND PROCESS OWNERSHIP
mail_owner = postfix
#default_privs = nobody

# INTERNET HOST AND DOMAIN NAMES
#myhostname = host.domain.tld
myhostname = lukis.or.id
mydomain = lukis.or.id

# SENDING MAIL
#myorigin = $myhostname
myorigin = $mydomain

# RECEIVING MAIL

#inet_interfaces = all
#inet_interfaces = $myhostname
#inet_interfaces = $myhostname, localhost

#proxy_interfaces =
#proxy_interfaces = 1.2.3.4

#mydestination = $myhostname, localhost.$mydomain
#mydestination = $myhostname, localhost.$mydomain $mydomain
#mydestination = $myhostname, localhost.$mydomain, $mydomain,
# mail.$mydomain, http://www.$mydomain, http://ftp.$mydomain

# REJECTING MAIL FOR UNKNOWN LOCAL USERS
#local_recipient_maps = unix:passwd.byname $alias_maps
#local_recipient_maps = proxy:unix:passwd.byname $alias_maps
#local_recipient_maps =

#unknown_local_recipient_reject_code = 550
unknown_local_recipient_reject_code = 450
# TRUST AND RELAY CONTROL

#mynetworks_style = class
#mynetworks_style = subnet
#mynetworks_style = host

#mynetworks = 168.100.189.0/28, 127.0.0.0/8
#mynetworks = $config_directory/mynetworks
#mynetworks = hash:/etc/postfix/network_table

# INTERNET OR INTRANET

#relayhost = $mydomain
#relayhost = gateway.my.domain
#relayhost = uucphost
#relayhost = [an.ip.add.ress]
# REJECTING UNKNOWN RELAY USERS
#relay_recipient_maps = hash:/etc/postfix/relay_recipients

# INPUT RATE CONTROL
#in_flow_delay = 1s

# ADDRESS REWRITING
# ADDRESS REDIRECTION (VIRTUAL DOMAIN)

# “USER HAS MOVED” BOUNCE MESSAGES
# TRANSPORT MAP
#
# Insert text from sample-transport.cf if you need explicit routing.

# ALIAS DATABASE
# “postfix reload” to eliminate the delay.
#
#alias_maps = dbm:/etc/aliases
#alias_maps = hash:/etc/aliases
#alias_maps = hash:/etc/aliases, nis:mail.aliases
#alias_maps = netinfo:/aliases

# The alias_database parameter specifies the alias database(s) that
# are built with “newaliases” or “sendmail -bi”. This is a separate
# configuration parameter, because alias_maps (see above) may specify
# tables that are not necessarily all under control by Postfix.
#
#alias_database = dbm:/etc/aliases
#alias_database = dbm:/etc/mail/aliases
#alias_database = hash:/etc/aliases
# DEBUGGING CONTROL
#
# The debug_peer_level parameter specifies the increment in verbose
# logging level when an SMTP client or server host name or address
# matches a pattern in the debug_peer_list parameter.
#
debug_peer_level = 2
#
debugger_command =
PATH=/bin:/usr/bin:/usr/local/bin:/usr/X11R6/bin
xxgdb $daemon_directory/$process_name $process_id & sleep 5

#
sendmail_path = /usr/sbin/sendmail
# newaliases_path: The full pathname of the Postfix newaliases command.
# This is the Sendmail-compatible command to build alias databases.
#
newaliases_path = /usr/bin/newaliases

# mailq_path: The full pathname of the Postfix mailq command. This
# is the Sendmail-compatible mail queue listing command.
#
mailq_path = /usr/bin/mailq

# setgid_group: The group for mail submission and queue management
# commands. This must be a group name with a numerical group ID that
# is not shared with other accounts, not even with the Postfix account.
#
setgid_group = postdrop

# manpage_directory: The location of the Postfix on-line manual pages.
#
manpage_directory = /usr/local/man

# sample_directory: The location of the Postfix sample configuration files.
#
sample_directory = /etc/postfix

# readme_directory: The location of the Postfix README files.
#
readme_directory = no

—————— /etc/postfix/main.cf —————————————-
7. Update /etc/syslog.conf to log mail to /var/log/maillog
echo “mail.info /var/log/maillog” >> /etc/syslog.conf
touch /var/log/maillog

8. buat direktory postfix di /usr/local/bin/postfix dan copy file bin dari source ke dir tersebut
cd /home/postfix/postfix-2.0.0.2/bin
mkdir /usr/local/bin/postfix
mkdir /usr/local/postfix
cp * /usr/local/bin/postfix
cp * /usr/local/postfix

9. update file sendmail, mailq dan newaliases
mv /usr/sbin/sendmail /usr/sbin/sendmail.OFF
mv /usr/bin/newaliases /usr/bin/newaliases.OFF
mv /usr/bin/mailq /usr/bin/mailq.OFF
chmod 0 /usr/sbin/sendmail.OFF /usr/bin/newaliases.OFF /usr/bin/mailq.OFF

ln -s /usr/local/postfix/sendmail /usr/sbin/sendmail
ln -s /usr/local/postfix/sendmail /usr/bin/mailq
ln -s /usr/local/postfix/sendmail /usr/bin/newaliases
mv /etc/rc.sendmail /etc/rc.sendmail.bak

10. jalankhan newaliases
/usr/bin/newalias

11. jalankan postfix dan masukkan postfix ke /etc/rc.local supaya otomatis ruuning pada saat reboot
/usr/sbin/postfix start
echo /usr/sbin/postfix start >> /etc/rc.local

12. test telnet localhost 25
$ telnet localhost 25
Trying 127.0.0.1…
Connected to localhost.kopegtel-pontianak.or.id.
Escape character is ‘^]’.
220 chemod.lukis.or.id ESMTP Postfix

Instalasi Qpopper

INSTALL QPOPPER

mkdir /home/qpopper
cd qpopper4.0.5.tar.gz
wget ftp://ftp.qualcomm.com/eudora/servers/unix/popper/qpopper4.0.5.tar.gz
tar fxzv qpopper4.0.5.tar.gz
cd qpopper4.0.5.tar.gz
./configure
make
make install

edit di /etc/inetd.conf
masukin ini
pop3    stream  tcp     nowait  root            /usr/local/sbin/popper popper -s
save

lalu jalanin

popper -s

kill -HUP ‘inetd’

kill -HUP pidinetd

————————-

kill -HUP `cat /var/run/inetd.pid`

netstat -na | grep LISTEN

telnet localhost 110

Tinggalkan Balasan

Isikan data di bawah atau klik salah satu ikon untuk log in:

Logo WordPress.com

You are commenting using your WordPress.com account. Logout / Ubah )

Gambar Twitter

You are commenting using your Twitter account. Logout / Ubah )

Foto Facebook

You are commenting using your Facebook account. Logout / Ubah )

Foto Google+

You are commenting using your Google+ account. Logout / Ubah )

Connecting to %s

%d blogger menyukai ini: