// <ahref="./index.html">Document Index</a></div><h1id="upgrade-iredmail-from-080-to-081">Upgrade iRedMail from 0.8.0 to 0.8.1</h1>
<li><ahref="#update-etciredmail-release-with-iredmail-version-number">Update /etc/iredmail-release with iRedMail version number</a></li>
<li><ahref="#upgrade-roundcube-webmail-to-the-latest-stable-release">Upgrade Roundcube webmail to the latest stable release</a></li>
<li><ahref="#upgrade-iredapd-postfix-policy-server-to-the-latest-stable-release">Upgrade iRedAPD (Postfix policy server) to the latest stable release</a></li>
<li><ahref="#upgrade-iredadmin-open-source-edition-to-the-latest-stable-release">Upgrade iRedAdmin (open source edition) to the latest stable release</a></li>
<li><ahref="#deliver-emails-to-mail-list-members-without-enabledservicesmtp">Deliver emails to mail list members without enabledService=smtp</a></li>
<li><ahref="#add-new-attributevalue-required-by-imap-share-folder-in-dovecot-enabledservicelib-storage">Add new attribute/value required by IMAP share folder in Dovecot: enabledService=lib-storage</a></li>
<li><ahref="#add-missing-sql-table-anyone_shares-in-mysql-database-iredadmin">Add missing SQL table anyone_shares in MySQL database iredadmin</a></li>
<li><ahref="#make-per-user-bcc-settings-have-higher-priority-than-per-domain-settings">Make per-user BCC settings have higher priority than per-domain settings</a></li>
<li><ahref="#fix-incorrect-maildir-path-with-virtual-transport">Fix incorrect maildir path with 'virtual' transport</a></li>
<li><ahref="#make-per-user-bcc-settings-have-higher-priority-than-per-domain-settings_1">Make per-user BCC settings have higher priority than per-domain settings</a></li>
<li><ahref="#add-new-column-required-by-imap-share-folder-in-dovecot-2-enablelib-storage1">Add new column required by IMAP share folder in Dovecot-2: enablelib-storage=1</a></li>
<li><ahref="#add-missing-sql-table-anyone_shares-in-mysql-database-vmail">Add missing SQL table anyone_shares in MySQL database vmail</a></li>
<li><ahref="#add-new-column-language-in-table-vmailmailbox">Add new column language in table vmail.mailbox</a></li>
<li><ahref="#fix-incorrect-maildir-path-with-virtual-transport_1">Fix incorrect maildir path with 'virtual' transport</a></li>
<li><ahref="#make-per-user-bcc-settings-have-higher-priority-than-per-domain-settings_2">Make per-user BCC settings have higher priority than per-domain settings</a></li>
<li><ahref="#add-new-column-required-by-imap-share-folder-in-dovecot-2-enablelib-storage1_1">Add new column required by IMAP share folder in Dovecot-2: enablelib-storage=1</a></li>
<li><ahref="#add-missing-sql-table-anyone_shares-in-postgresql-database-vmail">Add missing SQL table anyone_shares in PostgreSQL database vmail</a></li>
<li><ahref="#add-new-column-language-in-table-vmailmailbox_1">Add new column language in table vmail.mailbox</a></li>
<h3id="deliver-emails-to-mail-list-members-without-enabledservicesmtp">Deliver emails to mail list members without <code>enabledService=smtp</code></h3>
<p>With default Postfix settings in iRedMail-0.7.4 and earlier versions, if a mail
user is not allowed to use SMTP service to send out email (without
<code>enabledService=smtp</code>), user cannot receive emails which delivered to the mail
lists which the user belongs to. Below steps fix this issue.</p>
<ul>
<li>
<p>Edit Postfix config file, <code>main.cf</code>, update <code>virtual_alias_maps</code> to replace
<code>sender_login_maps.cf</code> by <code>virtual_group_members_maps.cf</code>:</p>
<ul>
<li>On Linux and OpenBSD, it's <code>/etc/postfix/main.cf</code>.</li>
<li>On FreeBSD, it's <code>/usr/local/etc/postfix/main.cf</code>. And you should use
<code>/usr/local/etc/postfix/ldap/virtual_group_members_maps.cf</code> in Postfix
<h3id="add-new-attributevalue-required-by-imap-share-folder-in-dovecot-enabledservicelib-storage">Add new attribute/value required by IMAP share folder in Dovecot: <code>enabledService=lib-storage</code></h3>
<p>Note: This step is required in Dovecot-2.x, but you must apply it no matter
which Dovecot version you're running, so that it won't be an issue while you
upgrading from Dovecot-1.x to 2.x.</p>
<p>Dovecot-2.x requires <code>enabledService=lib-storage</code> for IMAP folder sharing.
Below steps are used to add it for all mail users.</p>
<ul>
<li>Download python script used to adding missing values.</li>
<h3id="add-missing-sql-table-anyone_shares-in-mysql-database-iredadmin">Add missing SQL table <code>anyone_shares</code> in MySQL database <code>iredadmin</code></h3>
<p>If you want to share IMAP folder to anyone, you have to create new SQL table
<code>anyone_shares</code> in MySQL database <code>iredadmin</code>. Steps:</p>
<pre><code># mysql -uroot -p
sql> USE iredadmin;
sql> CREATE TABLE IF NOT EXISTS anyone_shares (
from_user VARCHAR(255) NOT NULL,
dummy CHAR(1) DEFAULT '1',
PRIMARY KEY (from_user)
);
</code></pre>
<h3id="make-per-user-bcc-settings-have-higher-priority-than-per-domain-settings">Make per-user BCC settings have higher priority than per-domain settings</h3>
<p>To make sure per-user BCC settings have higher priority than per-domain
settings, please edit Postfix main config file <code>main.cf</code>, reverse the lookup
maps in both <code>sender_bcc_maps</code> and <code>recipient_bcc_maps</code>.</p>
<pre><code>* On Linux and OpenBSD, it's `/etc/postfix/main.cf`.
* On FreeBSD, it's `/usr/local/etc/postfix/main.cf`.
<pre><code># Part of file: mysql/virtual_mailbox_maps.cf
# OLD SETTING
#query = SELECT CONCAT(mailbox.storagenode, '/', mailbox.maildir) FROM ...
# NEW SETTING
query = SELECT CONCAT(mailbox.storagenode, '/', mailbox.maildir, '/Maildir/') FROM ...
</code></pre>
<ul>
<li>Restart Postfix service to make it use new setting.</li>
</ul>
<h3id="make-per-user-bcc-settings-have-higher-priority-than-per-domain-settings_1">Make per-user BCC settings have higher priority than per-domain settings</h3>
<p>To make sure per-user BCC settings have higher priority than per-domain
settings, please edit Postfix main config file <code>main.cf</code>, reverse the lookup
maps in both <code>sender_bcc_maps</code> and <code>recipient_bcc_maps</code>.</p>
<pre><code>* On Linux and OpenBSD, it's `/etc/postfix/main.cf`.
* On FreeBSD, it's `/usr/local/etc/postfix/main.cf`.
<h3id="add-new-column-required-by-imap-share-folder-in-dovecot-2-enablelib-storage1">Add new column required by IMAP share folder in Dovecot-2: <code>enablelib-storage=1</code></h3>
<p>Dovecot-2.x requires <code>mailbox.enablelib-storage=1</code> for IMAP folder sharing.
Below steps are used to add it for all mail users.</p>
<ul>
<li>Login to MySQL server as root user, execute SQL commands to add required
sql> ALTER TABLE mailbox ADD COLUMN `enablelib-storage` TINYINT(1) NOT NULL DEFAULT 1;
sql> CREATE INDEX idx_mailbox_lib_storage ON mailbox (`enablelib-storage`);
-- Add missing index
sql> CREATE INDEX idx_mailbox_enabledoveadm ON mailbox (enabledoveadm);
</code></pre>
<ul>
<li>Update <code>/etc/dovecot/dovecot-mysql.conf</code>, add <code>`` (not single quote) around</code>enable%Ls%Lc`.</li>
</ul>
<pre><code># Part of file: dovecot-mysql.conf
# OLD SETTING
# AND mailbox.enable%Ls%Lc=1 \
# NEW SETTING
AND mailbox.`enable%Ls%Lc`=1 \
</code></pre>
<h3id="add-missing-sql-table-anyone_shares-in-mysql-database-vmail">Add missing SQL table <code>anyone_shares</code> in MySQL database <code>vmail</code></h3>
<p>If you want to share IMAP folder to anyone, you have to create new SQL table
<code>anyone_shares</code> in MySQL database <code>vmail</code>. Steps:</p>
<pre><code># mysql -uroot -p
sql> USE vmail;
sql> CREATE TABLE IF NOT EXISTS anyone_shares (
from_user VARCHAR(255) NOT NULL,
dummy CHAR(1) DEFAULT '1',
PRIMARY KEY (from_user)
);
</code></pre>
<h3id="add-new-column-language-in-table-vmailmailbox">Add new column <code>language</code> in table <code>vmail.mailbox</code></h3>
<p>Column <code>mailbox.language</code> is used to store short code of user preferred
language used by iRedAdmin.</p>
<ul>
<li>Please login to MySQL server as root user, execute SQL commands to add
<pre><code># Part of file: mysql/virtual_mailbox_maps.cf
# OLD SETTING
#query = SELECT (mailbox.storagenode || '/' || mailbox.maildir) FROM ...
# NEW SETTING
query = SELECT CONCAT(mailbox.storagenode, '/', mailbox.maildir, '/Maildir/') FROM ...
</code></pre>
<ul>
<li>Restart Postfix service to make it use new setting.</li>
</ul>
<h3id="make-per-user-bcc-settings-have-higher-priority-than-per-domain-settings_2">Make per-user BCC settings have higher priority than per-domain settings</h3>
<p>To make sure per-user BCC settings have higher priority than per-domain
settings, please edit Postfix main config file <code>main.cf</code>, reverse the lookup
maps in both <code>sender_bcc_maps</code> and <code>recipient_bcc_maps</code>.</p>
<pre><code>* On Linux and OpenBSD, it's `/etc/postfix/main.cf`.
* On FreeBSD, it's `/usr/local/etc/postfix/main.cf`.
<h3id="add-new-column-required-by-imap-share-folder-in-dovecot-2-enablelib-storage1_1">Add new column required by IMAP share folder in Dovecot-2: <code>enablelib-storage=1</code></h3>
<p>Dovecot-2.x requires <code>mailbox.enablelib-storage=1</code> for IMAP folder sharing.
Below steps are used to add it for all mail users.</p>
<ul>
<li>
<p>Please switch to PostgreSQL daemon user, and execute SQL commands to add
<pstyle="text-align: center; color: grey;">All documents are available in <ahref="https://bitbucket.org/zhb/iredmail-docs/src">BitBucket repository</a>, and published under <ahref="http://creativecommons.org/licenses/by-nd/3.0/us/"target="_blank">Creative Commons</a> license. You can <ahref="https://bitbucket.org/zhb/iredmail-docs/get/tip.tar.bz2">download the latest version</a> for offline reading. If you found something wrong, please do <ahref="http://www.iredmail.org/contact.html">contact us</a> to fix it.</p>