sendmail 설치
# yum install sendmail sendmail-cf
sendmail.mc 파일수정
52,53 line 수정 (앞부분 dnl 제거)
TRUST_AUTH_MECH(`EXTERNAL DIGEST-MD5 CRAM-MD5 LOGIN PLAIN')dnl
define(`confAUTH_MECHANISMS', `EXTERNAL GSSAPI DIGEST-MD5 CRAM-MD5 LOGIN PLAIN')dnl
116 line 수정
127.0.0.1을 0.0.0.0으로 개방
sendmail 재시작
# service sendmail restart
sendmail 테스트
# telnet localhost 25
Trying 127.0.0.1...
Connected to localhost.localdomain (127.0.0.1).
Escape character is '^]'.
220 linux.net ESMTP Sendmail 8.13.8/8.13.8; Tue, 11 Mar 2008 17:36:47 -0400
# yum install dovecot
# vi /etc/dovecot/dovecot.conf 수정
주석 제거
# Protocols we want to be serving.
protocols = imap pop3 lmtp
# A comma separated list of IPs or hosts where to listen in for connections.
# "*" listens in all IPv4 interfaces, "::" listens in all IPv6 interfaces.
# If you want to specify non-default ports or anything more complex,
# edit conf.d/master.conf.
listen = *
#/etc/dovecot/conf.d/10-auth.conf 수정
# Disable LOGIN command and all other plaintext authentications unless
# SSL/TLS is used (LOGINDISABLED capability). Note that if the remote IP
# matches the local IP (ie. you're connecting from the same computer), the
# connection is considered secure and plaintext authentication is allowed.
disable_plaintext_auth = no
dovecot 서비스 재시작
# service dovecot restart
dovecot imap4 서비스 테스트
# telnet localhost 143
Trying 127.0.0.1...
Connected to localhost.localdomain (127.0.0.1).
Escape character is '^]'.
* OK Dovecot ready.
dovecot pop3 서비스 테스트
# telnet localhost 110
Trying 127.0.0.1...
Connected to localhost.localdomain (127.0.0.1).
Escape character is '^]'.
+OK Dovecot ready.
※ 만약 localhost를 제외한 외부에서 sendmail 혹은 dovecot(imap, pop3)에 텔넷 연결이 되지 않을 경우
다음 세 가지 사항을 점검해 볼 필요가 있다.
1. iptables 25번, 110번, 143번 포트가 방화벽에서 허용되고 있는지 유/무
2. netstat -avp LISTENINIG 포트 체크
3. ps -ef | grep sendmail 혹은 ps -ef | grep dovecot
-----------------------------------------------------------------------------------------------------------------------------------------------------------------
/etc/dovecot/conf.d/10-mail.conf
# <doc/wiki/MailLocation.txt>
mail_location = mbox:/var/empty:INBOX=/var/spool/mail/%u:INDEX=MEMORY 추가
'리눅스' 카테고리의 다른 글
Apache : CSR 생성 및 SSL 인증서 적용 (0) | 2015.04.13 |
---|---|
sftp (0) | 2015.04.09 |
톰캣 아파치 연동하기 (0) | 2015.04.08 |
crontab (0) | 2015.04.07 |
etc/host.conf (0) | 2015.04.07 |