Fix lỗi thường gặp trên Zimbra Email Server

Fix lỗi​​ thường gặp trên Zimbra​​ Email Server

1./ Unknown command sent to server. ZxChatRequest

Nếu bị​​ lỗi này sẽ​​ không hiển thị​​ được cửa sổ​​ chat

msg: unknown document: ZxChatRequest code: service.UNKNOWN_DOCUMENT​​ detail: soap:Sender trace: qtp1225197672-113:1589945617767:bea8a852a2c8c41b

 

https://forums.zimbra.org/viewtopic.php?t=67565

Xử​​ lý:

mv /opt/zimbra/lib/ext/openchat/zal.jar /tmp
cp -rp /opt/zimbra/lib/ext/zimbradrive/zal.jar /opt/zimbra/lib/ext/openchat/zal.jar
su - zimbra
zmmailboxdctl restart

Sau khi xử​​ 

2./ Xử​​ lý lỗi không truy cập được webadmin Zimbra trên chrome

because the website uses HSTS. Network errors and attacks are usually temporary, so this page will probably work later. zimbra chrome

https://www.thesslstore.com/blog/clear-hsts-settings-chrome-firefox/

Truy cập link

chrome://net-internals/#hsts

This is Chrome’s UI for managing your browser’s local HSTS settings.

First, to confirm the domain’s HSTS settings are recorded by Chrome, type the hostname into the Query Domain section at the bottom of the​​ page. Click Query.If the Query box returns Found with settings information below, the domain’s HSTS settings are saved in your browser.

HSTS Settings Chrome

Note that this is a very sensitive search. Only enter the hostname, such as www.example.com or example.com without a​​ protocol or path.

Type the same hostname into the Delete domain section and click

Your browser will no longer force an HTTPS connection for that site! You can test if its working properly by refreshing or navigating to the page.

Note that depending on the​​ HSTS settings provided by the site, you may need to specify the proper subdomain. For example, the HSTS settings for staging.yoursite.com may be separate from yoursite.com so you may need to repeat the steps as appropriate.

Phương án khác có thể tạo ssl free với let’s encrypt cho Email server Zimbra

3./​​ Xử lý lỗi​​ Can't connect to TCP port 10024 on ::1 [Cannot assign requested address]\n ​​ at line 64 in file /opt/zimbra/common/lib/perl5/Net/Server/Proto/TCP.pm

https://rizkiana.id/cant-connect-to-tcp-port-10024-on-1-cannot-assign-requested-address-zimbra/

# vim /opt/zimbra/conf/amavisd.conf.in

 

 ​​ ​​ ​​​​ Add following this line between line inet_socket

 

$inet_socket_bind = '127.0.0.1';

$inet_socket_bind = '127.0.0.1';

 

 ​​ ​​ ​​​​ Save and restart service amavis zimbra

 

# su - zimbra

$ zmamavisdctl restart

Thần thánh vô cùng vì sau khi fix xong lỗi này các​​ service như:​​ antivirus, amavis, antispam​​ đã hoạt động lại

 

4./​​ Xử lý​​ Lỗi

zimbra@mail:/root$ zmprov gcf zimbraMTARestriction zimbraMtaRestriction: reject_invalid_helo_hostname

Không thể​​ connect đến outlook lost connection after ehlo from unknown outlook zimbra

 

zimbra@mail:/root$ ​​ postconf -n | grep helo

smtp_helo_name = $myhostname

smtpd_helo_required = yes

smtpd_recipient_restrictions = check_policy_service inet:localhost:10031, reject_non_fqdn_recipient, permit_sasl_authenticated, permit_mynetworks, reject_unlisted_recipient, reject_invalid_helo_hostname, reject_non_fqdn_sender, permit

 

zimbra@mail:/root$ zmlocalconfig -e smtpd_helo_required=no​​ 

zimbra@mail:/root$

zimbra@mail:/root$ postconf -e smtpd_helo_required=no ​​ 

zimbra@mail:/root$ postconf -n | grep helo

smtp_helo_name = $myhostname

smtpd_helo_required = no

smtpd_recipient_restrictions = check_policy_service inet:localhost:10031, reject_non_fqdn_recipient, permit_sasl_authenticated, permit_mynetworks, reject_unlisted_recipient, reject_invalid_helo_hostname, reject_non_fqdn_sender, permit

 

 

zimbra@mail:/root$ postconf -n | grep helo

smtp_helo_name = $myhostname

smtpd_helo_required = yes

smtpd_recipient_restrictions = check_policy_service inet:localhost:10031, reject_non_fqdn_recipient, permit_sasl_authenticated, permit_mynetworks, reject_unlisted_recipient, reject_invalid_helo_hostname, reject_non_fqdn_sender, permit

 

zimbra@mail:/root$ zmlocalconfig -e smtpd_helo_required=yes

zimbra@mail:/root$

zimbra@mail:/root$ postconf -e smtpd_helo_required=yes

 

5./ Xử​​ lý lỗi zimbra NOQUEUE: reject: Sender address rejected: Server configuration problem;

​​ https://wiki.zimbra.com/wiki/Rejecting_false_%22mail_from%22_addresses

Zimbra Collaboration 8.5 and above

For​​ Zimbra Collaboration 8.5​​ and above, please use the next commands to​​ increase the security and reject the logins for users that doesn't exist in the LDAP:​​ 

zmprov mcf zimbraMtaSmtpdRejectUnlistedRecipient yes

zmprov mcf zimbraMtaSmtpdRejectUnlistedSender yes

zmmtactl restart

zmconfigdctl restart

 

Lỗi​​ zimbra gpg: keyserver receive failed: No keyserver available

https://unix.stackexchange.com/questions/361642/keyserver-receive-failed-on-every-keyserver-available

chạy lệnh

sudo pkill dirmngr; dirmngr --debug-all --daemon --standard-resolver

6./ Fix lỗi không reset được password user email zimbra

Khi truy cập vào webmail chọn reset password thì cửa sổ reset password Zimbra hiện ra nhưng không truy cập được. Lỗi là do chưa mở port 8443 trên Firewall Zimbra.

Các port cần mở trên zimbra

25,80,110,143,443,465,587,993,995,3443,5222,5223,7071,9071,​​ 8443

Port 7780 open cho PolicyD không nên public port này. Chỉ nên mở cho 1 vài IP được phép truy cập.

7./ Fix lỗi DB cbpolicyd.sqlitedb trống

Khi gặp lỗi này khi truy cập trang quản trị cbpolicyd sẽ không có thông tin gì,​​ không tạo mới được các entry.

Kiểm tra dung lượng của dbpolicyd.sqlitedb trống, không có dung lượng.

ll /opt/zimbra/data/cbpolicyd/db

Hướng sử lý:

Cài đặt sqlitedb

apt-get​​ -y​​ install sqlite ​​ 

chạy với user zimbra

zmcbpolicydctl stop
cd /opt/zimbra/data/cbpolicyd/db
mv * /tmp
/opt/zimbra/libexec/zmcbpolicydinit
zmcbpolicydctl start

Để kiểm tra các bảng trong dbpolicyd.sqlitedb

zimbra@mail ~# cd /opt/zimbra/data/cbpolicyd/db

zimbra@mail ~/data/cbpolicyd/db# sqlite3 cbpolicyd.sqlitedb

SQLite version 3.22.0 2018-01-22 18:45:57

Enter ".help" for usage hints.

sqlite> select * from sqlite_sequence;

policies|5

policy_members|5

policy_groups|2

policy_group_members|6

amavis_rules|1

quotas|2

quotas_limits|3

checkhelo_blacklist|4

Tham khảo:

https://forums.zimbra.org/viewtopic.php?t=64121

https://wiki.zimbra.com/wiki/Cluebringer_Policy_Daemon

8./ Fix lỗi zmclamdctl​​ is not running

Nếu gặp lỗi​​ khi chạy lệnh

/opt/zimbra/common/bin/freshclam --config-file=/opt/zimbra/conf/freshclam.conf

Lỗi

WARNING: Clamd was NOT notified: Can't connect to clamd through /opt/zimbra/data/clamav/clamav.sock: No such file or directory

Xử lý bằng cách​​ 

chown zimbra:zimbra​​ /opt/zimbra/data/clamav/

khi check logs

tail -100f /opt/zimbra/log/clamd.log

sẽ thấy

clamd zimbra ERROR: daemonize() failed: Cannot allocate memory

Xử lý bằng cách tạo thêm swap cho Zimbra

dd if=/dev/zero of=/swapfile1 bs=1024 count=5120000

chown root:root /swapfile1

chmod 0600 /swapfile1

mkswap /swapfile1

swapon /swapfile1

tự động mount swap sau khi reboot

echo “/swapfile1 none swap sw 0 0” >> ​​ /etc/fstab

 

free -m

swapon -s

 

zimbra@mail ~# zmclamdctl start

Starting clamd...done.

 

Tham khảo:

https://forums.zimbra.org/viewtopic.php?t=66713

https://www.cyberciti.biz/faq/linux-add-a-swap-file-howto/

SaKuRai

Xin chào, Mình là Sakurai. Blog này là nơi để note lại và chia sẻ những kiến thức, kinh nghiệm mà mình và anh em trong Team. Cảm ơn các bạn đã quan tâm theo dõi!

You may also like...

Leave a Reply