Review: unattended.iredmail.installation.md.

This commit is contained in:
Zhang Huangbin 2014-09-17 13:28:29 +08:00
parent 867dc8d61f
commit 2e610c7e47
9 changed files with 277 additions and 96 deletions

1
.hgignore Normal file
View File

@ -0,0 +1 @@
.DS_Store

View File

@ -1,23 +1,28 @@
<http://www.iredmail.org/wiki/index.php?title=IRedMail/FAQ/Unattended.iRedMail.Installation>
# How to perform silent/unattended iRedMail installation
#How to perform silent/unattended iRedMail installation
* iRedMail will store configrations in file iRedMail-x.y.z/config during installation, and ask you whether to use it for installation directly or re-create one.
* iRedMail will read several global variables for automate installation.
iRedMail will store configrations in file iRedMail-x.y.z/config during
installation, and ask you whether to use it for installation directly
or create a new one.
You can create a sample config file by executing iRedMail installer:
<pre>
# bash iRedMail.sh
</pre>
After config wizard dialogs, you will find file "config" under iRedMail root directory. For example, __/root/iRedMail-0.8.7/config__. it will ask whether to start installation or not, you can cancel it if you want.
You can copy this config file to deploy as many servers as you want, change the hard-coded passwords in it if you want.
```bash
# bash iRedMail.sh
```
After config wizard dialogs, you will find file `config` under iRedMail root
directory. For example, `/root/iRedMail-0.8.7/config`. it will ask whether to
start installation or not, you can cancel it if you want.
You can copy this config file to deploy as many servers as you want, change
the hard-coded passwords in it if you want.
How to deploy a new server with sample config file:
* Copy sample config file to new server, e.g. /root/iRedMail-0.8.7/config.
* Copy sample config file to new server, e.g. `/root/iRedMail-0.8.7/config`.
* Execute iRedMail installer with shell variables:
<pre>
```bash
# AUTO_USE_EXISTING_CONFIG_FILE=y \
AUTO_INSTALL_WITHOUT_CONFIRM=y \
AUTO_CLEANUP_REMOVE_SENDMAIL=y \
@ -27,41 +32,60 @@ How to deploy a new server with sample config file:
AUTO_CLEANUP_REPLACE_MYSQL_CONFIG=y \
AUTO_CLEANUP_RESTART_POSTFIX=n \
bash iRedMail.sh
</pre>
```
## Sample Deployment
--------
Here's how i preform iRedMail tests every day with VMware Fusion on Mac OS X,
all are completed automatically with a shell command.
* Install a clean, basic/minimal OS (Debian/CentOS/OpenBSD/FreeBSD, etc), set
proper hostname, configure network, then shut down this server and create a
VMware snapshot named `Latest`. The snapshot name will be used in my shell
script, it needs a snapshot name to reverse VM to the clean OS.
Here's how i preform iRedMail tests every day with VMware Fusion on Mac OS X, all are completed with a shell script and VMware command line tool "vmrun" and "scp", "ssh". Hope it helps.
* Revert VM to the latest snapshot (a clean, basic, minimal OS) with VMware
command line tool `vmrun`.
* Install a clean, basic/minimal OS (Debian/CentOS/openSUSE/OpenBSD/etc), set proper hostname, configure network, then shut down this server and create a VMware snapshot named "Latest". The snapshot name will be used in my shell script, it needs a snapshot name to reverse VM to the clean OS.
* Revert VM to the latest snapshot (a clean, basic, minimal OS) with "vmrun".
* Start this VM with "vmrun", sleep 30 (or 60) seconds waiting for OS start up.
* Detect network connection to this VM, if it's up, upload required files with "scp":
* Start this VM with `vmrun`, sleep 30 (or 60) seconds waiting for OS start up.
* Detect network connection to this VM, if it's up, upload required files with `scp`:
* the latest development edition of iRedMail
* source tarballs required by iRedMail (Roundcube, iRedAdmin, iRedAPD, etc)
* downloaded RHEL/CentOS/Debian/Ubuntu/OpenBSD binary packages, FreeBSD distfiles etc. The most important one is a prepared iRedMail config file: iRedMail-x.y.z/config.
* Create/Update iRedMail installation status file: iRedMail-x.y.z/.status to skip downloading source tarballs, etc.
* downloaded RHEL/CentOS/Debian/Ubuntu/OpenBSD binary packages, FreeBSD
distfiles etc. The most important one is a prepared iRedMail config file: iRedMail-x.y.z/config.
* Create/Update iRedMail installation status file: iRedMail-x.y.z/.status
to skip downloading source tarballs, etc.
* Perform installation via ssh like this:
<pre>
```shell
ssh root@[SERVER] "cd /root/iRedMail/ && IREDMAIL_DEBUG='NO' AUTO_USE_EXISTING_CONFIG_FILE=y AUTO_INSTALL_WITHOUT_CONFIRM=y AUTO_CLEANUP_REMOVE_SENDMAIL=y AUTO_CLEANUP_REMOVE_MOD_PYTHON=y AUTO_CLEANUP_REPLACE_FIREWALL_RULES=y AUTO_CLEANUP_RESTART_IPTABLES=y AUTO_CLEANUP_REPLACE_MYSQL_CONFIG=y AUTO_CLEANUP_RESTART_POSTFIX=n bash iRedMail.sh"
</pre>
```
* Perform after-installation tasks: upload downloaded ClamAV database, ..., reboot server.
It should be finished in 2-3 minutes (uploading binary packages takes most time), then i got a working iRedMail server. I do this many times each day.
It should complete in 2-3 minutes (uploading binary packages takes most time),
then i got a working iRedMail server. I do this many times every day.
I have 5 prepared iRedMail config files for different backends: OpenLDAP, MySQL, MariaDB, PostgreSQL, ldapd (OpenBSD only). i run my script with an option to install iRedMail with specified backend like below, the script will upload proper config file to server:
<pre>
I have 5 prepared iRedMail config files for different backends: OpenLDAP,
MySQL, MariaDB, PostgreSQL, ldapd (OpenBSD only). i run my script with an
option to install iRedMail with specified backend like below, the script will
upload proper config file to server:
```shell
# bash auto.centos7.sh ldap
# bash auto.centos7.sh mysql
# bash auto.centos7.sh pgsql
# bash auto.ubuntu14.sh mariadb
# bash auto.openbsd55.sh ldapd
</pre>
```
Below is file of __auto.centos7.sh__ mentioned above, it prepares VMware virtual machine, then execute another script __c7.sh__ to perform the real installation.
<pre>
Below is file of `auto.centos7.sh` mentioned above, it prepares VMware virtual
machine, then execute another script `c7.sh` to perform the real installation.
```shell
#!/usr/bin/env bash
# File: auto.centos7.sh
@ -95,9 +119,9 @@ done
echo "* Start testing iRedMail."
sh ${VM_HOSTNAME}.sh ${backend}
</pre>
```
<pre>
```shell
#!/usr/bin/env bash
# File: c7.sh
[ X"$#" != X'1' ] && echo 'No backend?' && exit 255
@ -127,4 +151,4 @@ ssh root@${HOST} "/usr/bin/systemctl stop firewalld"
#scp -r clamav/* root@${HOST}:/var/lib/clamav/
#ssh root@${HOST} "chown clamupdate:clamupdate /var/lib/clamav/*"
ssh root@${HOST} "echo 'reboot'; reboot"
</pre>
```

View File

@ -10,7 +10,7 @@
# - better way to strip prefix in dir/file name: [number]-
# Directory used to store converted html files.
PWD="$(PWD)"
PWD="."
SOURCE_DIR="${PWD}/src"
OUTPUT_DIR="${PWD}/html"
INDEX_MD="${OUTPUT_DIR}/index.md"
@ -51,14 +51,15 @@ for chapter_dir in ${all_chapter_dirs}; do
# Output directory.
# Remove prefix '[number]-' in chapter directory name.
_output_chapter_dir="${OUTPUT_DIR}/$(strip_name_prefix ${chapter_dir})"
chapter_dir_in_article="$(strip_name_prefix ${chapter_dir})"
_output_chapter_dir="${OUTPUT_DIR}/${chapter_dir_in_article}"
_title_md="${chapter_dir}/_title.md"
_summary_md="${chapter_dir}/_summary.md"
if [ -f ${_title_md} ]; then
# generate index info of chapter
echo "# [$(cat ${_title_md})](${_output_chapter_dir}/_summary.html)" >> ${INDEX_MD}
echo "# [$(cat ${_title_md})](${chapter_dir_in_article}/_summary.html)" >> ${INDEX_MD}
fi
mkdir -p ${_output_chapter_dir} &>/dev/null
@ -80,16 +81,16 @@ for chapter_dir in ${all_chapter_dirs}; do
# Get title.
_article_title="$(head -1 ${article_file} | awk -F'#' '{print $2}')"
#echo "article title: ${_article_title}"
echo "* [${_article_title}](${_output_chapter_dir}/${article_html_file})" >> ${INDEX_MD}
echo "* [${_article_title}](${chapter_dir_in_article}/${article_html_file})" >> ${INDEX_MD}
${CMD_CONVERT} ${article_file} ${_output_chapter_dir}
done
done
cd ${OUTPUT_DIR}
#cd ${OUTPUT_DIR}
# Generate index.html
python ../tools/markdown2html.py ${INDEX_MD} ${OUTPUT_DIR} css='../css/markdown.css'
${CMD_CONVERT} ${INDEX_MD} ${OUTPUT_DIR} css='../css/markdown.css'
# Cleanup
#rm -f ${INDEX_MD}

View File

@ -2,37 +2,23 @@ body{
margin: 0 auto;
font-family: Georgia, Palatino, serif;
line-height: 1;
max-width: 80%;
max-width: 70%;
padding: 30px;
}
h1, h2, h3, h4 {
h1, h2, h3, h4, h5 {
font-weight: 400;
}
h1, h2, h3, h4, h5, p {
margin-top: 24px;
margin-bottom: 24px;
}
p {
margin-bottom: 4px;
padding: 0;
}
h1 {
/*font-size: 48px;*/
font-size: 36px;
}
h2 {
/*font-size: 36px;*/
/* The bottom margin is small. It's designed to be used with gray meta text
* below a post title. */
/*margin: 24px 0 6px;*/
font-size: 24px;
margin: 10px 0 6px 20px;
}
h3 {
font-size: 24px;
}
h4 {
font-size: 21px;
}
h5 {
font-size: 18px;
}
h1 { font-size: 36px; }
h2 { font-size: 24px; }
h3 { font-size: 24px; }
h4 { font-size: 21px; }
h5 { font-size: 18px; }
a {
color: #0099ff;
margin: 0;
@ -104,18 +90,15 @@ hr {
/* Code below this line is copyright Twitter Inc. */
button,
input,
select,
textarea {
button, input, select, textarea {
font-size: 100%;
margin: 0;
vertical-align: baseline;
*vertical-align: middle;
vertical-align: middle;
}
button, input {
line-height: normal;
*overflow: visible;
overflow: visible;
}
button::-moz-focus-inner, input::-moz-focus-inner {
border: 0;
@ -261,17 +244,15 @@ button::-moz-focus-inner {
}
pre, code {
font-size: 16px;
background: #f5f5f5;
border: 1px solid #ccc;
border-radius: 3px;
overflow-x: auto;
padding: 5px 10px 5px 10px;
word-wrap: normal
background: #f5f5f5;
border: 1px solid #ccc;
border-radius: 3px;
overflow-x: auto;
padding: 5px 10px 5px 10px;
word-wrap: normal
}
code {padding: 1px 5px 1px 5px;}
pre>code {
font-size: 16px;
margin: 0;
border: 0;
padding: 1px 3px;

View File

@ -0,0 +1,158 @@
<html>
<head>
<meta http-equiv="Content-Type" content="text/html; charset=utf-8" />
<title></title>
<link href="../../css/markdown.css" rel="stylesheet"></head>
</head>
<body>
<h3></h3>
<h1 id="how-to-perform-silentunattended-iredmail-installation">How to perform silent/unattended iRedMail installation</h1>
<p>iRedMail will store configrations in file iRedMail-x.y.z/config during
installation, and ask you whether to use it for installation directly
or create a new one.</p>
<p>You can create a sample config file by executing iRedMail installer:</p>
<pre><code class="bash"># bash iRedMail.sh
</code></pre>
<p>After config wizard dialogs, you will find file <code>config</code> under iRedMail root
directory. For example, <code>/root/iRedMail-0.8.7/config</code>. it will ask whether to
start installation or not, you can cancel it if you want.</p>
<p>You can copy this config file to deploy as many servers as you want, change
the hard-coded passwords in it if you want.</p>
<p>How to deploy a new server with sample config file:</p>
<ul>
<li>Copy sample config file to new server, e.g. <code>/root/iRedMail-0.8.7/config</code>.</li>
<li>Execute iRedMail installer with shell variables:</li>
</ul>
<pre><code class="bash"># AUTO_USE_EXISTING_CONFIG_FILE=y \
AUTO_INSTALL_WITHOUT_CONFIRM=y \
AUTO_CLEANUP_REMOVE_SENDMAIL=y \
AUTO_CLEANUP_REMOVE_MOD_PYTHON=y \
AUTO_CLEANUP_REPLACE_FIREWALL_RULES=y \
AUTO_CLEANUP_RESTART_IPTABLES=y \
AUTO_CLEANUP_REPLACE_MYSQL_CONFIG=y \
AUTO_CLEANUP_RESTART_POSTFIX=n \
bash iRedMail.sh
</code></pre>
<h2 id="sample-deployment">Sample Deployment</h2>
<p>Here's how i preform iRedMail tests every day with VMware Fusion on Mac OS X,
all are completed automatically with a shell command.</p>
<ul>
<li>
<p>Install a clean, basic/minimal OS (Debian/CentOS/OpenBSD/FreeBSD, etc), set
proper hostname, configure network, then shut down this server and create a
VMware snapshot named <code>Latest</code>. The snapshot name will be used in my shell
script, it needs a snapshot name to reverse VM to the clean OS.</p>
</li>
<li>
<p>Revert VM to the latest snapshot (a clean, basic, minimal OS) with VMware
command line tool <code>vmrun</code>.</p>
</li>
<li>
<p>Start this VM with <code>vmrun</code>, sleep 30 (or 60) seconds waiting for OS start up.</p>
</li>
<li>
<p>Detect network connection to this VM, if it's up, upload required files with <code>scp</code>:</p>
</li>
<li>the latest development edition of iRedMail</li>
<li>source tarballs required by iRedMail (Roundcube, iRedAdmin, iRedAPD, etc)</li>
<li>
<p>downloaded RHEL/CentOS/Debian/Ubuntu/OpenBSD binary packages, FreeBSD
distfiles etc. The most important one is a prepared iRedMail config file: iRedMail-x.y.z/config.</p>
</li>
<li>
<p>Create/Update iRedMail installation status file: iRedMail-x.y.z/.status
to skip downloading source tarballs, etc.</p>
</li>
<li>
<p>Perform installation via ssh like this:</p>
</li>
</ul>
<pre><code class="shell">ssh root@[SERVER] &quot;cd /root/iRedMail/ &amp;&amp; IREDMAIL_DEBUG='NO' AUTO_USE_EXISTING_CONFIG_FILE=y AUTO_INSTALL_WITHOUT_CONFIRM=y AUTO_CLEANUP_REMOVE_SENDMAIL=y AUTO_CLEANUP_REMOVE_MOD_PYTHON=y AUTO_CLEANUP_REPLACE_FIREWALL_RULES=y AUTO_CLEANUP_RESTART_IPTABLES=y AUTO_CLEANUP_REPLACE_MYSQL_CONFIG=y AUTO_CLEANUP_RESTART_POSTFIX=n bash iRedMail.sh&quot;
</code></pre>
<ul>
<li>Perform after-installation tasks: upload downloaded ClamAV database, ..., reboot server.</li>
</ul>
<p>It should complete in 2-3 minutes (uploading binary packages takes most time),
then i got a working iRedMail server. I do this many times every day.</p>
<p>I have 5 prepared iRedMail config files for different backends: OpenLDAP,
MySQL, MariaDB, PostgreSQL, ldapd (OpenBSD only). i run my script with an
option to install iRedMail with specified backend like below, the script will
upload proper config file to server:</p>
<pre><code class="shell"># bash auto.centos7.sh ldap
# bash auto.centos7.sh mysql
# bash auto.centos7.sh pgsql
# bash auto.ubuntu14.sh mariadb
# bash auto.openbsd55.sh ldapd
</code></pre>
<p>Below is file of <code>auto.centos7.sh</code> mentioned above, it prepares VMware virtual
machine, then execute another script <code>c7.sh</code> to perform the real installation.</p>
<pre><code class="shell">#!/usr/bin/env bash
# File: auto.centos7.sh
[ X&quot;$#&quot; != X'1' ] &amp;&amp; echo 'No backend? ldap, mysql, pgsql' &amp;&amp; exit 255
export backend=&quot;${1}&quot;
export VMRUN='vmrun -T fusion'
export VM_USER_ROOT='root'
export VM_HOSTNAME='c7'
export VM=&quot;/Users/zhb/vm.packages/vm/CentOS-7-x86_64.vmwarevm/CentOS-7-x86_64.vmx&quot;
echo &quot;* Revert to the latest snapshot.&quot;
${VMRUN} revertToSnapshot ${VM} Latest
echo &quot;* Start VM.&quot;
${VMRUN} start ${VM}
echo &quot;* Sleep 30 seconds to wait VM start up.&quot;
sleep 30
echo &quot;* Detect network status with ssh.&quot;
while :; do
ssh ${VM_USER_ROOT}@${VM_HOSTNAME} &quot;exit&quot;
if [ X&quot;$?&quot; == X'0' ]; then
break
else
sleep 5
fi
done
echo &quot;* Start testing iRedMail.&quot;
sh ${VM_HOSTNAME}.sh ${backend}
</code></pre>
<pre><code class="shell">#!/usr/bin/env bash
# File: c7.sh
[ X&quot;$#&quot; != X'1' ] &amp;&amp; echo 'No backend?' &amp;&amp; exit 255
backend=&quot;${1}&quot;
# hostname of your VMware virtual machine set in Mac OS X /etc/hosts.
HOST=&quot;c7&quot;
echo 'copying iRedMail ...'
scp -r ~/projects/iredmail/iRedMail root@${HOST}:~ &gt;/dev/null
echo 'copying pkgs/misc ...'
scp -r misc root@${HOST}:~/iRedMail/pkgs/ &gt;/dev/null
scp -r config.${backend} root@${HOST}:~/iRedMail/config &gt;/dev/null
echo 'copying archives ...'
scp -r rhel/7/yum root@${HOST}:/var/cache/ &gt;/dev/null
echo 'updating .status ...'
ssh root@${HOST} &quot;echo export status_check_new_iredmail='DONE' &gt; /root/iRedMail/.status&quot;
ssh root@${HOST} &quot;echo export status_fetch_pkgs='DONE' &gt;&gt; /root/iRedMail/.status&quot;
ssh root@${HOST} &quot;echo export status_fetch_misc='DONE' &gt;&gt; /root/iRedMail/.status&quot;
ssh root@${HOST} &quot;echo export status_cleanup_update_clamav_signatures='DONE' &gt;&gt; /root/iRedMail/.status&quot;
ssh root@${HOST} &quot;cd /root/iRedMail/ &amp;&amp; yum clean metadata &amp;&amp; AUTO_USE_EXISTING_CONFIG_FILE=y AUTO_INSTALL_WITHOUT_CONFIRM=y AUTO_CLEANUP_REMOVE_SENDMAIL=y AUTO_CLEANUP_REMOVE_MOD_PYTHON=y AUTO_CLEANUP_REPLACE_FIREWALL_RULES=y AUTO_CLEANUP_RESTART_IPTABLES=y AUTO_CLEANUP_REPLACE_MYSQL_CONFIG=y AUTO_CLEANUP_RESTART_POSTFIX=n bash iRedMail.sh&quot;
ssh root@${HOST} &quot;/usr/bin/systemctl stop firewalld&quot;
#ssh root@${HOST} &quot;mkdir /root/pro &amp;&amp; cp /var/www/iredadmin/settings.py /root/pro/&quot;
#scp -r clamav/* root@${HOST}:/var/lib/clamav/
#ssh root@${HOST} &quot;chown clamupdate:clamupdate /var/lib/clamav/*&quot;
ssh root@${HOST} &quot;echo 'reboot'; reboot&quot;
</code></pre></body></html>

View File

@ -7,16 +7,18 @@
<body>
<h3></h3>
<h1 id="frequently-asked-questions-and-howto-documents"><a href="/Users/zhb/projects/docs/html/faq-howto/_summary.html">Frequently Asked Questions and Howto documents</a></h1>
<h1 id="frequently-asked-questions-and-howto-documents"><a href="faq-howto/_summary.html">Frequently Asked Questions and Howto documents</a></h1>
<ul>
<li><a href="/Users/zhb/projects/docs/html/faq-howto/amavisd.no.x-spam.headers.html"> Amavisd + SpamAssassin not working, no mail header (X-Spam-*) inserted.</a></li>
<li><a href="/Users/zhb/projects/docs/html/faq-howto/completely.disable.amavisd.clamav.spamassassin.html"> How to completely disable amavisd/ClamAV/SpamAssassin</a></li>
<li><a href="/Users/zhb/projects/docs/html/faq-howto/disable.spam.virus.scanning.for.outgoing.mails.html"> How to disable spam virus scanning for outgoing mails</a></li>
<li><a href="/Users/zhb/projects/docs/html/faq-howto/howto.configure.thunderbird.for.iredmail.html"> Configure Thunderbird as mail client (IMAP, SMTP and global ldap address book)</a></li>
<li><a href="/Users/zhb/projects/docs/html/faq-howto/howto.enable.smtps.service.html"> How to enable SMTPS service (SMTP over SSL, port 465)</a></li>
<li><a href="/Users/zhb/projects/docs/html/faq-howto/pipe.incoming.email.for.certain.user.to.external.script.html"> How to pipe incoming email for certain user to external script </a></li>
<li><a href="faq-howto/amavisd.no.x-spam.headers.html"> Amavisd + SpamAssassin not working, no mail header (X-Spam-*) inserted.</a></li>
<li><a href="faq-howto/completely.disable.amavisd.clamav.spamassassin.html"> How to completely disable amavisd/ClamAV/SpamAssassin</a></li>
<li><a href="faq-howto/disable.spam.virus.scanning.for.outgoing.mails.html"> How to disable spam virus scanning for outgoing mails</a></li>
<li><a href="faq-howto/howto.configure.thunderbird.for.iredmail.html"> Configure Thunderbird as mail client (IMAP, SMTP and global ldap address book)</a></li>
<li><a href="faq-howto/howto.enable.smtps.service.html"> How to enable SMTPS service (SMTP over SSL, port 465)</a></li>
<li><a href="faq-howto/pipe.incoming.email.for.certain.user.to.external.script.html"> How to pipe incoming email for certain user to external script </a></li>
<li><a href="faq-howto/unattended.iredmail.installation.html"> How to perform silent/unattended iRedMail installation</a></li>
</ul>
<h1 id="backup-and-restore"><a href="/Users/zhb/projects/docs/html/backup-restore/_summary.html">Backup and Restore</a></h1>
<h1 id="backup-and-restore"><a href="backup-restore/_summary.html">Backup and Restore</a></h1>
<ul>
<li><a href="/Users/zhb/projects/docs/html/backup-restore/migrate.to.new.iredmail.server.html">How to migrate old iRedMail server to the latest stable release</a></li>
<li><a href="backup-restore/migrate.to.new.iredmail.server.html">How to migrate old iRedMail server to the latest stable release</a></li>
<li><a href="troubleshooting/turn.on.debug.mode.in.dovecot.html"> How to turn on debug mode in Dovecot</a></li>
</ul></body></html>

View File

@ -1,10 +0,0 @@
# [Frequently Asked Questions and Howto documents](/Users/zhb/projects/docs/html/faq-howto/_summary.html)
* [ Amavisd + SpamAssassin not working, no mail header (X-Spam-*) inserted.](/Users/zhb/projects/docs/html/faq-howto/amavisd.no.x-spam.headers.html)
* [ How to completely disable amavisd/ClamAV/SpamAssassin](/Users/zhb/projects/docs/html/faq-howto/completely.disable.amavisd.clamav.spamassassin.html)
* [ How to disable spam virus scanning for outgoing mails](/Users/zhb/projects/docs/html/faq-howto/disable.spam.virus.scanning.for.outgoing.mails.html)
* [ Configure Thunderbird as mail client (IMAP, SMTP and global ldap address book)](/Users/zhb/projects/docs/html/faq-howto/howto.configure.thunderbird.for.iredmail.html)
* [ How to enable SMTPS service (SMTP over SSL, port 465)](/Users/zhb/projects/docs/html/faq-howto/howto.enable.smtps.service.html)
* [ How to pipe incoming email for certain user to external script ](/Users/zhb/projects/docs/html/faq-howto/pipe.incoming.email.for.certain.user.to.external.script.html)
# [Backup and Restore](/Users/zhb/projects/docs/html/backup-restore/_summary.html)
* [How to migrate old iRedMail server to the latest stable release](/Users/zhb/projects/docs/html/backup-restore/migrate.to.new.iredmail.server.html)

View File

@ -0,0 +1,24 @@
<html>
<head>
<meta http-equiv="Content-Type" content="text/html; charset=utf-8" />
<title></title>
<link href="../../css/markdown.css" rel="stylesheet"></head>
</head>
<body>
<h3></h3>
<h1 id="how-to-turn-on-debug-mode-in-dovecot">How to turn on debug mode in Dovecot</h1>
<p>To turn on debug mode in Dovecot, please update Dovecot config file
<code>/etc/dovecot/dovecot.conf</code> (Linux/OpenBSD) or
<code>/usr/local/etc/dovecot/dovecot.conf</code> (FreeBSD), set <code>mail_debug</code> to <code>yes</code>:</p>
<pre><code>mail_debug = yes
</code></pre>
<p>Restart Dovecot service.</p>
<p>If you need authentication and password related debug message, turn on related
settings and restart dovecot service.</p>
<pre><code>auth_verbose = yes
auth_debug = yes
auth_debug_passwords = yes
auth_verbose_passwords = yes
</code></pre></body></html>