220 likes | 391 Views
P ostfix MTA. SPARCS 08 진준호 ( Alex ). 시작하기에 앞서 …. MUA : E-mail 클라이언트 . MTA : 특정 프로토콜을 이용하여 메일을 다른 서버로 전달하는 프로그램 . 전송 프로토콜 : UUCP(Unix-to-Unix protocol), SMTP(Simple Mail Transfer Protocol). Postfix 란 ?. Postfix : 리눅스 용 MTA 중 하나 센드메일 ( Sendmail ) 을 대체하기 위해 개발
E N D
Postfix MTA SPARCS 08 진준호 (Alex )
시작하기에 앞서… • MUA : E-mail 클라이언트. • MTA : 특정 프로토콜을 이용하여 메일을 다른 서버로 전달하는 프로그램. • 전송 프로토콜 : UUCP(Unix-to-Unix protocol), SMTP(Simple Mail Transfer Protocol)
Postfix 란 ? • Postfix : 리눅스 용 MTA 중하나 센드메일(Sendmail)을 대체하기 위해 개발 └ 보다 빠르게 └ 보다 쉽게(용이한 설정 변경 및 관리) └ 보다 안전하게 (높은 수준의 보안) • 이제 직접 써보기 !!
Postfix 설치 • $ sudo apt-get install postfix • $ sudo apt-get install courier-pop$ sudo apt-get install courier-imap
Postfix 설치 • 메일 폴더 설정 • $ sudopostconf –e ‘home_mailbox = Maildir/’ * postconf –e : edit main.cf configuration file. • procmail설정 꺼주기 • $ sudopostconf –e “mailbox_command = ”
Postfix 설치 후 • /etc/postfix(postfix 설정 파일) • master.cf : postfix 처리 과정 제어 • main.cf : 전역 SMTP 설정 파일 (parameter = value) ex: mynetwork = $myhostname ($: 다른 매개변수 값 참조)
Postfix 설치 후 • /usr/sbin/ (모든 postfix 명령) … • post~~ : postfix 명령들
Postfix 설치 후 • /var/spool/postfix (큐 관리자가 파일을 관리하는 디렉토리) • 큐 관리자 : 들어오는 이메일 메시지 받고, 메일 배달을 위해 다른 postfix 구성요소 준비
Postfix 설치 후 • /var/spool/postfix (큐 관리자가 파일을 관리하는 디렉토리) • incoming : 모든 메시지 • active : 배달 or 배달 준비 중인 메시지 • deferred : 즉시 배달할 수 없는 메시지 (재전송 시도) • corrupt : 손상되어 배달할 수 없는 메시지 • man: 정보 (맨 페이지)
Postfix 설정 • $ sudodpkg-reconfigure postfix ☜ 요거 선택 ㅋ
Postfix 설정 설정 끝,ㅋ
Postfix 설정 • 완료 ! => /etc/postfix/main.cf 확인
Postfix 시작 • $ sudo postfix start • $ sudo postfix stop • $ sudo postfix reload (설정 파일 변경 시)
오오오… 메일 보내진건가.. • 메일 갔나 확인 ! • $ cdMaildir/new • $ ls 오 뭔가 있다 왔다!
exim • $ apt-get install exim4 qpopper sasl2-bin • $ cd /etc/exim4 • $ cd update-exim4.conf.conf • dc_other_hostnames=메일도메인 • dc_local_interfaces=접속허용가능호스트 • dc_relay_domains=릴레이 시킬도메인
exim • $ update-exim4.conf -d /etc/exim4 -o /etc/exim4/exim4.conf • '''$ ls /etc/exim4./ ../ conf.d/ exim4.conf exim4.conf.template passwd.client update-exim4.conf.conf''
exim • $ vi /etc/exim4/exim4.conf.template • $ update-exim4.conf -d /etc/exim4 -o /etc/exim4/exim4.conf (exim4.conf file 재생성) • $ vi /etc/group • Debian-exim유저를 sasl그룹에 포함
exim • sasl데몬 가동 • $ vi /etc/default/saslauthd • START="yes”MECHANISMS="pam shadow • exim4, sasl데몬 재시작 • $ /etc/init.d/saslauthd restart • $ /etc/init.d/exim4 restart
Aliases • 사용자나 관리자가 메일을 redirect 할 수 있게 해준다. 메일링 목록을 정의 컴퓨터간에 메일을 포워딩 사용자가 여러 이름을 참조할 수 있게 해줌 • /etc/aliases
Aliases • /etc/aliases 에서 <alias name> : include:/SPARCS/mail/aliases.d/<alias name> • /SPARCS/etc/Aliases/<alias name> 파일에 주소를 하나씩 • newaliases