Upgrade/iRedMail/0.8.2-0.8.3
From iRedMail
(Created page with '__TOC__ ---- This tutorial is still a DRAFT, do NOT apply it. ---- = ChangeLog = * 2012-10-10: [RHEL/CentOS/Scientific 6 only] Fix incorrect path in cron job. * 2012-10-10: [De…') |
|||
| (7 intermediate revisions not shown) | |||
| Line 1: | Line 1: | ||
__TOC__ | __TOC__ | ||
| - | |||
| - | |||
| - | |||
= ChangeLog = | = ChangeLog = | ||
| + | * 2012-10-16: [ldap] Fix incorrect LDAP URI in Cluebringer config file. | ||
| + | * 2012-10-16: [Optional] Send an email to postmaster@ if user's mailbox is larger than or equal to 95% full. | ||
| + | * 2012-10-10: Upgrade iRedAdmin (open source edition). | ||
* 2012-10-10: [RHEL/CentOS/Scientific 6 only] Fix incorrect path in cron job. | * 2012-10-10: [RHEL/CentOS/Scientific 6 only] Fix incorrect path in cron job. | ||
* 2012-10-10: [Debian/Ubuntu only] Fix incorrect SQL table name in /etc/apache2/conf.d/cluebringer.conf | * 2012-10-10: [Debian/Ubuntu only] Fix incorrect SQL table name in /etc/apache2/conf.d/cluebringer.conf | ||
= General (All backends should apply these steps) = | = General (All backends should apply these steps) = | ||
| + | == Upgrade iRedAdmin (open source edition) == | ||
| + | Please follow this tutorial to upgrade iRedAdmin open source edition to the latest stable release: [[IRedMail/FAQ/Upgrade.iRedAdmin.Open.Source.Edition |How to upgrade iRedAdmin (open source edition) to the latest stable release]] | ||
| + | |||
== [RHEL/CentOS/Scientific 6 only] Incorrect path in cron job == | == [RHEL/CentOS/Scientific 6 only] Incorrect path in cron job == | ||
Note: This is applicable to Red Hat Enterprise Linux 6, CentOS 6, Scientific Linux 6. If you're running other distributions or releases, please skip this step. | Note: This is applicable to Red Hat Enterprise Linux 6, CentOS 6, Scientific Linux 6. If you're running other distributions or releases, please skip this step. | ||
| - | iRedMail uses incorrect path ('''/''') in user '''amavis''''s cron job, please change it to '''/var/ | + | iRedMail uses incorrect path ('''/''') in user '''amavis''''s cron job, please change it to '''/var/spool/amavisd/quarantine/''' instead. Steps: |
* Execute command '''crontab''' like below to edit user amavis's cron job: | * Execute command '''crontab''' like below to edit user amavis's cron job: | ||
| Line 26: | Line 29: | ||
</pre>}} | </pre>}} | ||
| - | * Change the path '''/''' to '''/var/ | + | * Change the path '''/''' to '''/var/spool/amavisd/quarantine/''' like below: |
{{cmd|<pre> | {{cmd|<pre> | ||
| - | 1 5 * * * find /var/ | + | 1 5 * * * find /var/spool/amavisd/quarantine/ -ctime +15 | xargs rm -rf {} |
</pre>}} | </pre>}} | ||
* Save your changes and exit editor. | * Save your changes and exit editor. | ||
| + | == [Optional] Send an email to postmaster@ if user's mailbox is larger than or equal to 95% full == | ||
| + | |||
| + | Note: This update is optional but strongly recommended, so that you, mail server administrator, can deal with mailbox quota exceed issue in time. | ||
| + | |||
| + | * Append below text into /usr/local/bin/dovecot-quota-warning.sh: | ||
| + | {{cmd|<pre> | ||
| + | # Send a copy to postmaster@ if mailbox is greater than or equal to 95% full. | ||
| + | if [ ${PERCENT} -ge 95 ]; then | ||
| + | DOMAIN="$(echo ${USER} | awk -F'@' '{print $2}')" | ||
| + | cat << EOF | PH_DOVECOT_DELIVER -d postmaster@${DOMAIN} -o "plugin/quota=dict:User quota::noenforcing:proxy::quota" | ||
| + | From: no-reply@PH_HOSTNAME | ||
| + | Subject: Mailbox Quota Warning: ${PERCENT}% full, ${USER} | ||
| + | |||
| + | Your mailbox is now ${PERCENT}% full, please clean up some mails for | ||
| + | further incoming mails. | ||
| + | EOF | ||
| + | fi | ||
| + | </pre>}} | ||
| + | |||
| + | * Replace 'PH_DOVECOT_DELIVER' above by the real path of Dovecot deliver program, you can find the path in the same file: /usr/local/bin/dovecot-quota-warning.sh. | ||
| + | ** On RHEL/CentOS/Scientific Linux/Gentoo, it's '''/usr/libexec/dovecot/deliver'''. | ||
| + | ** On Debian/Ubuntu/openSUSE, it's '''/usr/lib/dovecot/deliver'''. | ||
| + | ** On FreeBSD/OpenBSD, it's '''/usr/local/libexec/dovecot/deliver'''. | ||
| + | |||
| + | * Replace 'PH_HOSTNAME' above by your server hostname. You can get it with below command: | ||
| + | {{cmd|<pre> | ||
| + | # hostname --fqdn | ||
| + | </pre>}} | ||
= OpenLDAP backend special = | = OpenLDAP backend special = | ||
| + | == Fix incorrect LDAP URI in Cluebringer config file == | ||
| + | |||
| + | Note: This step is applicable if you have Cluebringer installed, which means you're running PostgreSQL backend, or running Debian 7 (wheezy), Ubuntu 11.10 and later releases. | ||
| + | |||
| + | * Open Apache config file of Cluebringer | ||
| + | ** on RHEL/CentOS/Scientific Linux 6, it's '''/etc/httpd/conf.d/cluebringer.conf'''. | ||
| + | ** on Debian 7 (wheezy), or Ubuntu 11.10 or later releases, it's '''/etc/apache2/conf.d/cluebringer.conf'''. | ||
| + | ** on FreeBSD, it's '''/usr/local/etc/apache22/Includes/cluebringer.conf'''. | ||
| + | |||
| + | * Find parameter '''AuthLDAPUrl''' and update it: | ||
| + | ** replace '''o=domainAdmins''' by '''o=domains''' | ||
| + | ** replace '''objectclass=mailAdmin''' by '''objectclass=mailUser''' | ||
| + | |||
| + | * Save changes and restarting Apache web server. | ||
= MySQL backend special = | = MySQL backend special = | ||
| Line 47: | Line 92: | ||
= PostgreSQL backend special = | = PostgreSQL backend special = | ||
| + | No update required. | ||
Current revision as of 14:07, 24 October 2012
Contents |
ChangeLog
- 2012-10-16: [ldap] Fix incorrect LDAP URI in Cluebringer config file.
- 2012-10-16: [Optional] Send an email to postmaster@ if user's mailbox is larger than or equal to 95% full.
- 2012-10-10: Upgrade iRedAdmin (open source edition).
- 2012-10-10: [RHEL/CentOS/Scientific 6 only] Fix incorrect path in cron job.
- 2012-10-10: [Debian/Ubuntu only] Fix incorrect SQL table name in /etc/apache2/conf.d/cluebringer.conf
General (All backends should apply these steps)
Upgrade iRedAdmin (open source edition)
Please follow this tutorial to upgrade iRedAdmin open source edition to the latest stable release: How to upgrade iRedAdmin (open source edition) to the latest stable release
[RHEL/CentOS/Scientific 6 only] Incorrect path in cron job
Note: This is applicable to Red Hat Enterprise Linux 6, CentOS 6, Scientific Linux 6. If you're running other distributions or releases, please skip this step.
iRedMail uses incorrect path (/) in user amavis's cron job, please change it to /var/spool/amavisd/quarantine/ instead. Steps:
- Execute command crontab like below to edit user amavis's cron job:
| Terminal: |
# crontab -e -u amavis |
- Find below line:
| Terminal: |
# Delete virus mails which created 15 days ago.
1 5 * * * find / -ctime +15 | xargs rm -rf {}
|
- Change the path / to /var/spool/amavisd/quarantine/ like below:
| Terminal: |
1 5 * * * find /var/spool/amavisd/quarantine/ -ctime +15 | xargs rm -rf {}
|
- Save your changes and exit editor.
[Optional] Send an email to postmaster@ if user's mailbox is larger than or equal to 95% full
Note: This update is optional but strongly recommended, so that you, mail server administrator, can deal with mailbox quota exceed issue in time.
- Append below text into /usr/local/bin/dovecot-quota-warning.sh:
| Terminal: |
# Send a copy to postmaster@ if mailbox is greater than or equal to 95% full.
if [ ${PERCENT} -ge 95 ]; then
DOMAIN="$(echo ${USER} | awk -F'@' '{print $2}')"
cat << EOF | PH_DOVECOT_DELIVER -d postmaster@${DOMAIN} -o "plugin/quota=dict:User quota::noenforcing:proxy::quota"
From: no-reply@PH_HOSTNAME
Subject: Mailbox Quota Warning: ${PERCENT}% full, ${USER}
Your mailbox is now ${PERCENT}% full, please clean up some mails for
further incoming mails.
EOF
fi
|
- Replace 'PH_DOVECOT_DELIVER' above by the real path of Dovecot deliver program, you can find the path in the same file: /usr/local/bin/dovecot-quota-warning.sh.
- On RHEL/CentOS/Scientific Linux/Gentoo, it's /usr/libexec/dovecot/deliver.
- On Debian/Ubuntu/openSUSE, it's /usr/lib/dovecot/deliver.
- On FreeBSD/OpenBSD, it's /usr/local/libexec/dovecot/deliver.
- Replace 'PH_HOSTNAME' above by your server hostname. You can get it with below command:
| Terminal: |
# hostname --fqdn |
OpenLDAP backend special
Fix incorrect LDAP URI in Cluebringer config file
Note: This step is applicable if you have Cluebringer installed, which means you're running PostgreSQL backend, or running Debian 7 (wheezy), Ubuntu 11.10 and later releases.
- Open Apache config file of Cluebringer
- on RHEL/CentOS/Scientific Linux 6, it's /etc/httpd/conf.d/cluebringer.conf.
- on Debian 7 (wheezy), or Ubuntu 11.10 or later releases, it's /etc/apache2/conf.d/cluebringer.conf.
- on FreeBSD, it's /usr/local/etc/apache22/Includes/cluebringer.conf.
- Find parameter AuthLDAPUrl and update it:
- replace o=domainAdmins by o=domains
- replace objectclass=mailAdmin by objectclass=mailUser
- Save changes and restarting Apache web server.
MySQL backend special
[Debian/Ubuntu only] Fix incorrect SQL table name in /etc/apache2/conf.d/cluebringer.conf
Note: This is applicable to Debian and Ubuntu only.
iRedMail uses incorrect SQL table name admin in /etc/apache2/conf.d/cluebringer.conf, please change it to mailbox like below:
| File: /etc/apache2/conf.d/cluebringer.conf |
AuthMySQL_Password_Table mailbox
|
Restarting Apache service is required.
PostgreSQL backend special
No update required.
