扫描二维码关注官方公众号
返回列表 发布新帖

[玩法/技巧] 威联通TS-209安装mail server(改机)

6321 3
发表于 2008-8-25 15:29:45 | 查看全部 阅读模式

来吧兄弟,一起玩一起讨论!

您需要 登录 才可以下载或查看,没有账号?注册

×
Hi All,

After 2 weeks googling and expermenting I finally managed to get this one up and running on QNAP's TS109/209 (Pro/Standard) series NAS, now here you go:



XMail Mail Server
XMail is an Internet and intranet mail server featuring an ESMTP server, POP3 server, finger server, TLS support for SMTP and POP3 (both server and client side), multiple domains, no need for users to have a real system account, SMTP relay checking, DNS based maps check, custom (IP based and address based) spam protection, SMTP authentication (PLAIN LOGIN CRAM-MD5 POP3-before-SMTP and custom), a POP3 account syncronizer with external POP3 accounts, account aliases, domain aliases, custom mail processing, direct mail files delivery, custom mail filters, mailing lists, remote administration, custom mail exchangers, logging, and multi-platform code. XMail sources compile under GNU/Linux, FreeBSD, OpenBSD, NetBSD, OSX, Solaris and NT/2K/XP.
--------------------------------------------------------------------------------------------------------------------------------------------------------

UPDATED 12/10/2007

XMail, Dovecot, Cyrus IMAP and many more MTA, MUA related softwares can now be installed as easy as typing in a line of text and hit enter thru Optware/IPKG.
Details on how to install Optware/IPKG can be found here.

Once installed type in this to install XMail:

# ipkg install xmail

this to install dovecot:

# ipkg install Dovecot

and this to install Cyrus IMAPD

# ipkg install cyrus-imapd


Once installed and configurated you can then download their web
interface.

For XMail you can download here.

For Roundcube you can download here.


--------------------------------------------------------------------------------------------------------------------------------------------------------

[size=134%]Step by Step Installation Guide

Step 1. Download the file package

Download the all-in-one package HERE onto the /share/Public directory on your NAS:

Step 2. Install XMail chroot environment

Telnet/SSH to your NAS. Upon command prompt type:

For TS-109 & TS-209 with single disk:
# mkdir /share/HDA_DATA/Xmail

# chmod 700 /share/HDA_DATA/Xmail


For TS-209 running RAID1:
# mkdir /share/MD0_DATA/Xmail

# chmod 700 /share/MD0_DATA/Xmail


then untar


# cd /share/Public

# tar -zxvf xmail-1.24_phpxmail-1.5_ARM-chroot-tsx09.tar.gz

# cd xmail-1.24_phpxmail-1.5_ARM-chroot-tsx09


For TS-109 & TS-209 with single disk:
# tar -C /share/HDA_DATA/Xmail -zxvf arm_chroot.tar.gz

For TS-209 running RAID 1:
# tar -C /share/MD0_DATA/Xmail -zxvf arm_chroot.tar.gz

Step 3. Port Forwarding

Forward these ports:

6017 (xmail remote control access)
25 (smtp)
110 (pop3)

from your router to your NAS. Besides, obtain a DDNS account and setup in the Network Config/DDNS section of your TS-109/209 if you don't have a static WAN IP and a registered domain name. I was able to use my DDNS address (xxx.dyndns.org) as my POP3 and SMTP mailserver hostname as well as my mailserver's domain name (eg. test@xxx.dyndns.org).

Step 4. create an CTRL admin account for XMail

To creat an account/password we will need to Telnet/SSH to the NAS again :

chroot

For TS-109 & TS-209 with single disk:
# chroot /share/HDA_DATA/Xmail

For TS-209 running RAID 1:
# chroot /share/MD0_DATA/Xmail

use the built-in application to generate encrypted password, if say your password is "password".

# XMCrypt password

It should output this:

# 15041616120a1701

This is the encrypted value for the "password". Although one already created as an example in the file package I will demonstrate how to do it as below:

# vi /var/MailRoot/ctrlaccounts.tab

press "i" for insert mode then type in:

admin

press 'tab' once and type:

15041616120a1701 (the password)

Then press "Esc" then ":wq" then "Enter" to save and escape out vi mode.

To start Xmail type:

# /etc/init.d/xmail start

# exit


To check we issue "ps" to see whether or not the daemon is up and running (you should see an entry like this /bin/XMail).

# ps -ax


Step 5. Install PHPXmail

Untar phpxmail from where we untarred the whole package at Step 2.

# cd /share/Public/xmail-1.24_phpxmail-1.5_ARM-chroot-tsx09

# tar -C /share/Qweb zxvf phpxmail1.5.tar.gz


Now open up your browser and type in "http://your-nas-ip/phpxmail/
you should then see this screen below if you have successfully started your XMail server demon.



Now click on "Add new server" then type in the server infomation as below:

Server hostname: qnap.kicks-**.net (Your NAS' Domain Name, or simply your DDNS name if you don't have a FQDN (Fully quarlified domain name).)
Server port: 6017 (Just leave it as default)
CTRL account: admin (The one we created at Step 4)
CTRL password: password (The one we created at Step 4 too)

Then click on "Submit" you will be brought to the log-in page and just log in with the details you just set. Once in you can start to create your mail users or configure other settings as needed.


Un-installation / Remove

To uninstall Xmail:
Simply delete the entire chroot environment. (you might wanna back up your mails before you do this.)

For TS-109 & TS-209 with single disk:
# rm -rf /share/HDA_DATA/Xmail

For TS-209 running RAID 1:
# rm -rf /share/MD0_DATA/Xmail

To uninstall PHPXmail:
Same here just delete the entire script folder.

# rm -rf /share/Qweb/phpxmail

Optional Tips and Tricks

1. To get Xmail to start automatially on every reboot.

# mount /dev/mtdblock5 -t ext2 /tmp/config

# cd /tmp/config

# vi autorun.sh


(add the following startup command to the file - autorun.sh)

# chroot /share/HDA_DATA/Xmail/etc/init.d/xmail start

Save and close.

# chmod 755 autorun.sh

# cd /

# umount /dev/mtdblock5



2. To save your bills and have full rights on mailserver administration.

Simply pick up your phone and cancel your mail hosting after successful installation.

(Nah, this one i am just kidding)


Configuration and references

So does it really work? Well I've successfully sent/received mails using it so the answer is 'yes'. As for details regarding the server config and how to use Xmail, I guess I'll leave that to you with the information and resources below. Good luck!

XMail configuration
http://www.xmailserver.org/Readme.html#configuration

XMail admin configuration
http://www.xmailserver.org/Readme.html# ... n_protocol

PHPXMail support forum
http://nextcode.org/forums/


Changelogs - 2007.11.12
*re-compress the chroot archive (arm_chroot.tar.gz) without the folder arm_root so your get straight to the root of chroot directory once decompressed.
*change the MailRoot location from /share/Xmail/MailRoot to the original location /var/MailRoot also edited the daemon file /etc/init.d/xmail to reflect the new path.
*moved the main executable binaries under /var/MailRoot/bin to /bin for ease of global access.
*remove the need for renaming sendmail to sendmail.foo
*add the "Un-installation / Remove" section.
*add the "Optional Tips and Tricks" section

Say

Andy

_________________
Signature[size=80%]
=====================================================
TS-209-Pro [RAID1][Optware][MLDonkey][Ubuntu (Hardy Heron) vmware image]
TS-409-Pro [RAID5][Squeeze Center 7.01][Twonky Media Server][Native Compiler]
Buffalo WHR-HP-G54 [DD-WRT][D-Link DGS-1005D][GigaLAN]
=====================================================
[
Online Support Form][forum.qnap@qnap.com][Firmware Mailing List]


Last edited by QNAPAndy on Mon Dec 10, 2007 4:11 pm, edited 16 times in total.

评论3

momoVIP互助团队 发表于 2008-8-25 15:33:40 | 查看全部
有没有人懂英文啊翻译下噶
回复 点赞

使用道具 举报

xajhxajh 发表于 2008-8-26 09:51:14 | 查看全部
完全看不明白
回复 点赞

使用道具 举报

52awen 发表于 2009-1-22 12:53:07 | 查看全部
完全不懂,看过了。
回复 点赞

使用道具 举报

回复

您需要登录后才可以回帖 登录 | 注册

本版积分规则

淘宝小店

邀请码

VIP会员

微信客服

公众号

微信群

投诉/建议联系

support@gebi1.cn

未经授权禁止转载,复制和建立镜像,
如有违反,追究法律责任
  • 关注公众号
  • 添加微信客服
Copyright © 2001-2024 隔壁网 版权所有 All Rights Reserved. 粤ICP备14056481号-1
关灯 在本版发帖
扫一扫添加微信客服
返回顶部
快速回复 返回顶部 返回列表