ค้นหาเว็บไซต์

การตั้งค่า Zimbra Collaboration Suite (ZCS) บน RHEL/CentOS 7/8


Zimbra Collaboration Suite (ZCS) เป็นโอเพ่นซอร์ส แพลตฟอร์มการทำงานร่วมกันสำหรับเซิร์ฟเวอร์อีเมล ได้รับการพัฒนาในสองรุ่น รุ่น Open Source ( ฟรี) และ Network Edition (ชำระเงิน) ซึ่งให้บริการต่างๆ เช่น LDAP, SMTP, POP และ IMAP, ไคลเอ็นต์เว็บเมล, ปฏิทิน, งาน, โปรแกรมป้องกันไวรัส, ป้องกันสแปม และคนอื่น ๆ.

บทช่วยสอนนี้จะอธิบายวิธีการติดตั้ง Zimbra Collaboration Suite Open Source Edition บนเซิร์ฟเวอร์ CentOS/RHEL 7

ความต้องการ

  • เซิร์ฟเวอร์ DNS ภายนอกที่มีบันทึกที่ถูกต้องทั้ง A และ MX เพื่อชี้ไปยังที่อยู่ IP ของเซิร์ฟเวอร์เมล Zimbra ของคุณ
  • การติดตั้ง CentOS 8/RHEL 8 หรือ CentOS 7/RHEL 7 ขั้นต่ำใหม่ทั้งหมดโดยไม่ต้องใช้เมล ฐานข้อมูล LDAP, DNS หรือเซิร์ฟเวอร์ Http ใด ๆ
  • ที่อยู่ IP แบบคงที่ที่กำหนดให้กับอินเทอร์เฟซเครือข่าย

ขั้นตอนที่ 1: ติดตั้งแพ็คเกจระบบ

1. ก่อนที่เราจะดำเนินการตามขั้นตอนการติดตั้ง Zimbra Collaboration Suite ก่อนอื่นให้เข้าสู่ระบบคอนโซลเซิร์ฟเวอร์ของคุณด้วยสิทธิ์รูทและติดตั้งแพ็คเกจต่อไปนี้:

yum -y install unzip net-tools sysstat openssh-clients perl-core libaio nmap-ncat libstdc++.so.6

2. จากนั้น ให้ออกคำสั่ง getenforce เพื่อตรวจสอบว่า Selinux เปิดใช้งานอยู่ในเครื่องของคุณหรือไม่ ในกรณีที่ตั้งค่านโยบายเป็น บังคับใช้ ให้ปิดใช้งานโดยออกคำสั่งด้านล่าง:

getenforce
setenforce 0
getenforce

หากต้องการปิดใช้งาน Selinux บน CentOS โดยสมบูรณ์ ให้เปิดไฟล์ /etc/selinux/config ด้วยโปรแกรมแก้ไขข้อความ และตั้งค่าบรรทัด SELINUX เป็น disabled

3. ตรวจสอบให้แน่ใจว่าได้ติดตั้งยูทิลิตี้ระบบ wget บนระบบของคุณด้วยการใช้คำสั่งต่อไปนี้:

yum install wget 

ขั้นตอนที่ 2: กำหนดค่าชื่อโฮสต์ของระบบ

4. เพื่อให้ Zimbra ทำงานได้อย่างถูกต้อง คุณต้องตั้งชื่อโฮสต์ของเครื่องท้องถิ่นและ FQDN ให้ชี้ไปยังที่อยู่ IP ของเซิร์ฟเวอร์ของคุณโดยการเรียกใช้ด้านล่างนี้ คำสั่ง hostnamectl จากบัญชีรูท:

hostnamectl set-hostname mail
echo "192.168.0.14  mail.centos7.lan  mail " >> /etc/hosts
cat /etc/hosts

แทนที่ชื่อโฮสต์ของระบบและค่า FQDN ตามนั้นเพื่อให้ตรงกับการตั้งค่าโดเมนของคุณเอง ทดสอบชื่อโฮสต์และค่า FQDN โดยการออกคำสั่ง ping กับทั้งสองระเบียน

ping -c1 mail.centos7.lan
ping -c1 mail

ขั้นตอนที่ 3: เพิ่มที่อยู่ IP แบบคงที่

5. หากเซิร์ฟเวอร์ของคุณใช้ที่อยู่ IP แบบไดนามิกของ DHCP คุณจะต้องแก้ไขการ์ดอินเทอร์เฟซเครือข่ายและกำหนดค่าให้ใช้ที่อยู่ IP แบบคงที่ รับข้อมูลอินเทอร์เฟซเครือข่ายโดยใช้คำสั่ง ip addr และระบุ NIC ภายนอกเซิร์ฟเวอร์ของคุณ (โดยปกติจะเป็นเช่น enp0s3 หรือ eth0)

ip addr

จากนั้น รันคำสั่ง nmtui-edit กับอินเทอร์เฟซที่คุณต้องการเปลี่ยนการตั้งค่า และกำหนดอินเทอร์เฟซด้วยที่อยู่ IP ด้วยตนเอง ใช้ภาพหน้าจอด้านล่างเป็นแนวทาง

nmtui-edit enp0s3

ขั้นตอนที่ 4: ปิดใช้งานบริการที่ไม่ต้องการ

6. การติดตั้งเริ่มต้นของ CentOS มาพร้อมกับ postfix daemon ที่ติดตั้งและทำงานอยู่แล้ว หากต้องการปิดใช้งานและลบบริการ postfix ให้รันคำสั่งต่อไปนี้:

systemctl stop postfix
systemctl disable postfix
yum remove postfix

หลังจากที่บริการถูกลบออกแล้ว ให้ออกคำสั่ง ss เพื่อตรวจสอบว่า daemons อื่นๆ เข้ากันไม่ได้กับบริการของ Zimbra เช่น LDAP, httpd, dovecot กำลังทำงานอยู่ในระบบของคุณหรือไม่ หากเป็นกรณีนี้ให้ลบออกด้วย

ขั้นตอนที่ 5: ติดตั้ง Zimbra Collaboration Suite Open Source Edition

7. ตอนนี้ได้เวลาติดตั้ง Zimbra Collaboration Suite แล้ว ไปที่หน้าดาวน์โหลด Zimbra Collaboration Suite และรับเวอร์ชันล่าสุดบนระบบของคุณโดยออกคำสั่ง wget ต่อไปนี้:

----------------- For RHEL/CentOS 8 -----------------
wget https://files.zimbra.com/downloads/8.8.15_GA/zcs-8.8.15_GA_3953.RHEL8_64.20200629025823.tgz

----------------- For RHEL/CentOS 7 -----------------
wget https://files.zimbra.com/downloads/8.8.15_GA/zcs-8.8.15_GA_3869.RHEL7_64.20190918004220.tgz

----------------- For RHEL/CentOS 6 -----------------
wget https://files.zimbra.com/downloads/8.8.15_GA/zcs-8.8.15_GA_3869.RHEL6_64.20190918004220.tgz

8. หลังจากการดาวน์โหลดเสร็จสิ้น ให้ใช้คำสั่ง unzip เพื่อแยกไฟล์เก็บถาวร ป้อนไดเร็กทอรีที่แยกออกมาของ Zimbra และแสดงรายการเนื้อหาไดเร็กทอรีเพื่อค้นหาไฟล์ตัวติดตั้ง

tar xfz zcs-8.8.15_GA_3953.RHEL8_64.20200629025823.tgz
cd zcs-8.8.15_GA_3953.RHEL8_64.20200629025823/
ls

9. ตอนนี้ เริ่มกระบวนการติดตั้ง Zimbra โดยเรียกใช้งานไฟล์สคริปต์ตัวติดตั้งชื่อ install.sh

หลังจากตรวจสอบระบบหลายครั้ง โปรแกรมติดตั้งจะแจ้งให้คุณยอมรับใบอนุญาต ยอมรับใบอนุญาต (y) เพื่อดำเนินการขั้นตอนการติดตั้งต่อไป

./install.sh
OR
./install.sh --platform-override   [On different platforms other than RHEL]
ผลลัพธ์ตัวอย่าง
Operations logged to /tmp/install.log.92OcKO6s
Checking for existing installation...
    zimbra-drive...NOT FOUND
    zimbra-imapd...NOT FOUND
    zimbra-patch...NOT FOUND
    zimbra-mta-patch...NOT FOUND
    zimbra-proxy-patch...NOT FOUND
    zimbra-license-tools...NOT FOUND
    zimbra-license-extension...NOT FOUND
    zimbra-network-store...NOT FOUND
    zimbra-network-modules-ng...NOT FOUND
    zimbra-chat...NOT FOUND
    zimbra-talk...NOT FOUND
    zimbra-ldap...NOT FOUND
    zimbra-logger...NOT FOUND
    zimbra-mta...NOT FOUND
    zimbra-dnscache...NOT FOUND
    zimbra-snmp...NOT FOUND
    zimbra-store...NOT FOUND
    zimbra-apache...NOT FOUND
    zimbra-spell...NOT FOUND
    zimbra-convertd...NOT FOUND
    zimbra-memcached...NOT FOUND
    zimbra-proxy...NOT FOUND
    zimbra-archiving...NOT FOUND
    zimbra-core...NOT FOUND


----------------------------------------------------------------------
PLEASE READ THIS AGREEMENT CAREFULLY BEFORE USING THE SOFTWARE.
SYNACOR, INC. ("SYNACOR") WILL ONLY LICENSE THIS SOFTWARE TO YOU IF YOU
FIRST ACCEPT THE TERMS OF THIS AGREEMENT. BY DOWNLOADING OR INSTALLING
THE SOFTWARE, OR USING THE PRODUCT, YOU ARE CONSENTING TO BE BOUND BY
THIS AGREEMENT. IF YOU DO NOT AGREE TO ALL OF THE TERMS OF THIS
AGREEMENT, THEN DO NOT DOWNLOAD, INSTALL OR USE THE PRODUCT.

License Terms for this Zimbra Collaboration Suite Software:
https://www.zimbra.com/license/zimbra-public-eula-2-6.html
----------------------------------------------------------------------



Do you agree with the terms of the software license agreement? [N] y

10. ขั้นต่อไป กระบวนการติดตั้งจะถามคำถามคุณมากมายเพื่อกำหนดค่า Zimbra daemon อย่างถูกต้อง ใช้ข้อความที่ตัดตอนมาจากการติดตั้งด้านล่างเพื่อตั้งค่าบริการ Zimbra เพิ่มเติม

Use Zimbra's package repository [Y] y

Importing Zimbra GPG key

Configuring package repository

Checking for installable packages

Found zimbra-core (local)
Found zimbra-ldap (local)
Found zimbra-logger (local)
Found zimbra-mta (local)
Found zimbra-dnscache (local)
Found zimbra-snmp (local)
Found zimbra-store (local)
Found zimbra-apache (local)
Found zimbra-spell (local)
Found zimbra-memcached (repo)
Found zimbra-proxy (local)
Found zimbra-drive (repo)
Found zimbra-imapd (local)
Found zimbra-patch (repo)
Found zimbra-mta-patch (repo)
Found zimbra-proxy-patch (repo)


Select the packages to install

Install zimbra-ldap [Y] y

11. ถัดไป ระบบจะขอให้คุณติดตั้งแพ็คเกจ Zimbra กด Y เพื่อติดตั้งทั้งหมด

Select the packages to install

Install zimbra-ldap [Y] y Install zimbra-logger [Y] y Install zimbra-mta [Y] y Install zimbra-dnscache [Y] y Install zimbra-snmp [Y] y Install zimbra-store [Y] y Install zimbra-apache [Y] y Install zimbra-spell [Y] y Install zimbra-memcached [Y] y Install zimbra-proxy [Y] y Checking required space for zimbra-core Checking space for zimbra-store Checking required packages for zimbra-store zimbra-store package check complete. Installing: zimbra-core zimbra-ldap zimbra-logger zimbra-mta zimbra-dnscache zimbra-snmp zimbra-store zimbra-apache zimbra-spell zimbra-memcached zimbra-proxy zimbra-drive zimbra-imapd zimbra-patch zimbra-mta-patch zimbra-proxy-patch zimbra-chat

12. สุดท้ายนี้ มันจะเริ่มกระบวนการติดตั้ง Zimbra

The system will be modified.  Continue? [N] y

Beginning Installation - see /tmp/install.log.92OcKO6s for details...

                          zimbra-core-components will be downloaded and installed.
                          zimbra-common-core-jar will be installed.
                         zimbra-common-core-libs will be installed.
                         zimbra-common-mbox-conf will be installed.
                   zimbra-common-mbox-conf-attrs will be installed.
                    zimbra-common-mbox-conf-msgs will be installed.
                  zimbra-common-mbox-conf-rights will be installed.
                           zimbra-common-mbox-db will be installed.
                         zimbra-common-mbox-docs will be installed.
                   zimbra-common-mbox-native-lib will be installed.
                            zimbra-timezone-data will be installed.
                                     zimbra-core will be installed.
                          zimbra-ldap-components will be downloaded and installed.
                                     zimbra-ldap will be installed.
                                   zimbra-logger will be installed.
                           zimbra-mta-components will be downloaded and installed.
                                      zimbra-mta will be installed.
                      zimbra-dnscache-components will be downloaded and installed.
                                 zimbra-dnscache will be installed.
                          zimbra-snmp-components will be downloaded and installed.
                                     zimbra-snmp will be installed.
Last metadata expiration check: 0:00:56 ago on Sat 01 Aug 2020 01:56:00 AM EDT.
                       zimbra-jetty-distribution will be downloaded and installed.
                         zimbra-store-components will be downloaded and installed.
                   zimbra-mbox-admin-console-war will be installed.
                                zimbra-mbox-conf will be installed.
                                 zimbra-mbox-war will be installed.
                             zimbra-mbox-service will be installed.
                          zimbra-mbox-store-libs will be installed.
                       zimbra-mbox-webclient-war will be installed.
                                    zimbra-store will be installed.
                        zimbra-apache-components will be downloaded and installed.
                                   zimbra-apache will be installed.
                         zimbra-spell-components will be downloaded and installed.
                                    zimbra-spell will be installed.
Last metadata expiration check: 0:01:07 ago on Sat 01 Aug 2020 01:56:00 AM EDT.
                                zimbra-memcached will be downloaded and installed.
                         zimbra-proxy-components will be downloaded and installed.
                                    zimbra-proxy will be installed.
Last metadata expiration check: 0:01:18 ago on Sat 01 Aug 2020 01:56:00 AM EDT.
                                    zimbra-drive will be downloaded and installed (later).
                                    zimbra-imapd will be installed.
Last metadata expiration check: 0:01:20 ago on Sat 01 Aug 2020 01:56:00 AM EDT.
                                    zimbra-patch will be downloaded and installed (later).
Last metadata expiration check: 0:01:22 ago on Sat 01 Aug 2020 01:56:00 AM EDT.
                                zimbra-mta-patch will be downloaded and installed (later).
Last metadata expiration check: 0:01:23 ago on Sat 01 Aug 2020 01:56:00 AM EDT.
                              zimbra-proxy-patch will be downloaded and installed (later).
Last metadata expiration check: 0:01:27 ago on Sat 01 Aug 2020 01:56:00 AM EDT.
                                     zimbra-chat will be downloaded and installed (later).

Downloading packages (11):
   zimbra-core-components
   zimbra-ldap-components
   zimbra-mta-components
   zimbra-dnscache-components
   zimbra-snmp-components
   zimbra-jetty-distribution
   zimbra-store-components
   zimbra-apache-components
   zimbra-spell-components
   zimbra-memcached
   zimbra-proxy-components
      ...done

Removing /opt/zimbra
Removing zimbra crontab entry...done.
Cleaning up zimbra init scripts...done.
Cleaning up /etc/security/limits.conf...done.

Finished removing Zimbra Collaboration Server.


Installing repo packages (11):
   zimbra-core-components
   zimbra-ldap-components
   zimbra-mta-components
   zimbra-dnscache-components
   zimbra-snmp-components
   zimbra-jetty-distribution
   zimbra-store-components
   zimbra-apache-components
   zimbra-spell-components
   zimbra-memcached
   zimbra-proxy-components
      ...

13. การกำหนดค่าร้านค้า

1) Status:                                  Enabled
   2) Create Admin User:                       yes
   3) Admin user to create:                    [email 
** 4) Admin Password                           UNSET
   5) Anti-virus quarantine user:              [email 
   6) Enable automated spam training:          yes
   7) Spam training user:                      [email 
   8) Non-spam(Ham) training user:             [email 
   9) SMTP host:                               mail.centos7.lan
  10) Web server HTTP port:                    8080
  11) Web server HTTPS port:                   8443
  12) Web server mode:                         https
  13) IMAP server port:                        7143
  14) IMAP server SSL port:                    7993
  15) POP server port:                         7110
  16) POP server SSL port:                     7995
  17) Use spell check server:                  yes
  18) Spell server URL:                        http://mail.centos7.lan:7780/aspell.php
  19) Enable version update checks:            TRUE
  20) Enable version update notifications:     TRUE
  21) Version update notification email:       [email 
  22) Version update source email:             [email 
  23) Install mailstore (service webapp):      yes
  24) Install UI (zimbra,zimbraAdmin webapps): yes

Select, or 'r' for previous menu [r] 4 # Select 4 to set admin password Password for [email  (min 6 characters): [54mE0RmqN] enter admin password here
Store configuration

   1) Status:                                  Enabled
   2) Create Admin User:                       yes
   3) Admin user to create:                    [email 
   4) Admin Password                           set
   5) Anti-virus quarantine user:              [email 
   6) Enable automated spam training:          yes
   7) Spam training user:                      [email 
   8) Non-spam(Ham) training user:             [email 
   9) SMTP host:                               mail.centos7.lan
  10) Web server HTTP port:                    8080
  11) Web server HTTPS port:                   8443
  12) Web server mode:                         https
  13) IMAP server port:                        7143
  14) IMAP server SSL port:                    7993
  15) POP server port:                         7110
  16) POP server SSL port:                     7995
  17) Use spell check server:                  yes
  18) Spell server URL:                        http://mail.centos7.lan:7780/aspell.php
  19) Enable version update checks:            TRUE
  20) Enable version update notifications:     TRUE
  21) Version update notification email:       [email 
  22) Version update source email:             [email 
  23) Install mailstore (service webapp):      yes
  24) Install UI (zimbra,zimbraAdmin webapps): yes

Select, or 'r' for previous menu [r] r
Main menu

   1) Common Configuration:
   2) zimbra-ldap:                             Enabled
   3) zimbra-logger:                           Enabled
   4) zimbra-mta:                              Enabled
   5) zimbra-dnscache:                         Enabled
   6) zimbra-snmp:                             Enabled
   7) zimbra-store:                            Enabled
   8) zimbra-spell:                            Enabled
   9) zimbra-proxy:                            Enabled
  10) Default Class of Service Configuration:
   s) Save config to file
   x) Expand menu
   q) Quit

*** CONFIGURATION COMPLETE - press 'a' to apply
Select from menu, or press 'a' to apply config (? - help) a  # Apply configuration Save configuration data to a file? [Yes] Enter Save config in file: [/opt/zimbra/config.11047] Saving config in /opt/zimbra/config.11047...done. The system will be modified - continue? [No] yes Operations logged to /tmp/zmsetup01262016-002704.log Setting local config values...done. Initializing core config...Setting up CA...done. Deploying CA to /opt/zimbra/conf/ca ...done. Creating SSL zimbra-store certificate...done. Creating new zimbra-ldap SSL certificate...done. Creating new zimbra-mta SSL certificate...done. Creating new zimbra-proxy SSL certificate...done. Installing mailboxd SSL certificates...done. Installing MTA SSL certificates...done. Installing LDAP SSL certificate...done. Installing Proxy SSL certificate...done. Initializing ldap...done. Setting replication password...done. Setting Postfix password...done. Setting amavis password...done. Setting nginx password...done. Setting BES searcher password...done. Creating server entry for mail.centos7.lan...done. Setting Zimbra IP Mode...done. Saving CA in ldap ...done. Saving SSL Certificate in ldap ...done. Setting spell check URL...done. Setting service ports on mail.centos7.lan...done. Setting zimbraFeatureTasksEnabled=TRUE...done. Setting zimbraFeatureBriefcasesEnabled=TRUE...done. Setting Master DNS IP address(es)...done. Setting DNS cache tcp lookup preference...done. Setting DNS cache udp lookup preference...done. Setting DNS tcp upstream preference...done. Setting TimeZone Preference...done. Initializing mta config...done. Setting services on mail.centos7.lan...done. Adding mail.centos7.lan to zimbraMailHostPool in default COS...done. Creating domain mail.centos7.lan...done. Setting default domain name...done. Creating domain mail.centos7.lan...already exists. Creating admin account [email . Creating root alias...done. Creating postmaster alias...done. Creating user [email . Creating user [email . Creating user [email . Setting spam training and Anti-virus quarantine accounts...done. Initializing store sql database...done. Setting zimbraSmtpHostname for mail.centos7.lan...done. Configuring SNMP...done. Setting up syslog.conf...done. Starting servers...done. Installing common zimlets... com_zimbra_adminversioncheck...done. com_zimbra_attachcontacts...done. com_zimbra_attachmail...done. com_zimbra_bulkprovision...done. com_zimbra_cert_manager...done. com_zimbra_clientuploader...done. com_zimbra_date...done. com_zimbra_email...done. com_zimbra_mailarchive...done. com_zimbra_phone...done. com_zimbra_proxy_config...done. com_zimbra_srchhighlighter...done. com_zimbra_tooltip...done. com_zimbra_url...done. com_zimbra_viewmail...done. com_zimbra_webex...done. com_zimbra_ymemoticons...done. Finished installing common zimlets. Restarting mailboxd...done. Creating galsync account for default domain...done. You have the option of notifying Zimbra of your installation. This helps us to track the uptake of the Zimbra Collaboration Server. The only information that will be transmitted is: The VERSION of zcs installed (8.6.0_GA_1153_RHEL7_64) The ADMIN EMAIL ADDRESS created ([email ) Notify Zimbra of your installation? [Yes] no Notification skipped Setting up zimbra crontab...done. Moving /tmp/zmsetup01262016-002704.log to /opt/zimbra/log Configuration complete - press return to exit # Press Enter

ขั้นตอนที่ 6: การกำหนดค่าเริ่มต้นของ Zimba

14. หลังจากการติดตั้งเสร็จสิ้น ให้เปิดเว็บเบราว์เซอร์และนำทางไปยังชื่อโดเมนหรือที่อยู่ IP ของเครื่องที่ใช้บริการ Zimbra บนพอร์ต 7071 ผ่านโปรโตคอล HTTPS ยอมรับ เกิดข้อผิดพลาดด้านความปลอดภัยของใบรับรอง และเข้าสู่ระบบด้วยข้อมูลประจำตัวที่กำหนดค่าไว้ระหว่างกระบวนการติดตั้ง ชื่อผู้ใช้เริ่มต้นสำหรับแผงเว็บผู้ดูแลระบบของ Zimbra คือ ผู้ดูแลระบบ

https://mail.centos7.lan:7071
or
https://192.168.1.14:7071 

15. เมื่อเข้าสู่ระบบคอนโซลเว็บของผู้ดูแลระบบแล้ว คุณสามารถเริ่มเพิ่มใบรับรอง SSL ของคุณเอง สร้างบัญชีเมล ชื่อแทนเมล และอื่นๆ เพียงจำไว้ว่าพอร์ต 7071 ใช้สำหรับงานด้านการดูแลระบบเท่านั้น

ลูกค้าสามารถเข้าสู่ระบบกล่องเว็บเมลได้อย่างปลอดภัยโดยใช้ชื่อโดเมนหรือที่อยู่ IP ของเซิร์ฟเวอร์ผ่านโปรโตคอล HTTPS

https://mail.centos7.lan 
or
https://192.168.1.14 

ยินดีด้วย! ตอนนี้คุณได้ติดตั้งเมลสแต็คปฏิบัติการเต็มรูปแบบในสถานที่ของคุณแล้ว

ขั้นตอนที่ 6: ลบหรือถอนการติดตั้ง Zimbra

หากคุณต้องการถอนการติดตั้งบริการ Zimbra ควบคู่ไปกับส่วนประกอบต่างๆ ให้เรียกใช้สคริปต์การติดตั้งด้วยตัวเลือก -u

./install.sh -u

หากต้องการลบไฟล์เก็บถาวรการติดตั้ง Zimbra และไดเร็กทอรีให้รันคำสั่งด้านล่าง:

cd
rm -rf zcs-*

สุดท้ายนี้ เพื่อรัน Zimbra Collaboration Suite อย่างเหมาะสม คุณต้องมีเครื่องที่ทรงพลังซึ่งมี RAM ขั้นต่ำ 4GB


สงวนลิขสิทธิ์. © Linux-Console.net • 2019-2024