IMAP是支持POP3和IMAP兩種協議的,在安裝Linux時,如沒有把它裝好,可以通過以下方法安裝。
把Red Hat Linux7.0的光盤放入執行以下指令:
# mount /dev/dcrom /mnt/cdrom
# cd /mnt/cdrom/RedHat/RPMS
# rpm -i imap-4.7c2-12.i386.rpm
# cd
# umount /mnt/cdrom
# vi /etc/services '把pop2 pop3 imap2前面的#號去掉
# cd /etc/xinetd.d
分別生成imap ipop3 ipop2三個文件,文件內容如下:
service imap
{
socket_type = stream
wait = no
user = root
server = /usr/sbin/imapd
log_on_success += DURATION USERID
log_on_failure += USERID
disable = no
}
service pop2
{
socket_type = stream
wait = no
user = root
server = /usr/sbin/ipop2d
log_on_success += USERID
log_on_failure += USERID
disable = no
}
service pop3
{
socket_type = stream
wait = no
user = root
server = /usr/sbin/ipop3d
log_on_success += USERID
log_on_failure += USERID
disable = no
}
執行如下指令,要求xinetd程序重新讀取設定文件:
# /etc/rc.d/init.d/xinetd reload
# telnet localhost 143
測試一下看看imap進程起了沒有,正確的應該會出現下面的界面
trying 127.0.0.1...
Connected to localhost.
Escape character is '^]'.
* OK localhost IMAP4rev1 v12.264 server ready