Courier: Difference between revisions
Jump to navigation
Jump to search
(→Ubuntu) |
(→Ubuntu) |
||
Line 22: | Line 22: | ||
To install Courier IMAP: |
To install Courier IMAP: |
||
* Install the required packages: |
* Install the required packages: |
||
<source lang="bash">sudo apt-get install courier-imap courier-doc courier-imap-ssl</source> |
|||
* Create '''/etc/courier/userdb.dat''' |
* Create '''/etc/courier/userdb.dat''' |
||
<source lang="bash"> |
|||
sudo su |
sudo su |
||
pw2userdb >/etc/courier/userdb |
pw2userdb >/etc/courier/userdb |
||
chmod 600 /etc/courier/userdb |
chmod 600 /etc/courier/userdb |
||
makeuserdb |
makeuserdb |
||
</source> |
|||
* Make sure all users have directory {{file|~/Maildir}}: |
|||
<source lang="bash"> |
|||
maildirmake /etc/skel/Maildir # Create Maildir directory for all new users |
maildirmake /etc/skel/Maildir # Create Maildir directory for all new users |
||
</source> |
</source> |
||
To use the password from '''<tt>/etc/courier/userdb</tt>''' (and not from '''PAM''') (as root): |
To use the password from '''<tt>/etc/courier/userdb</tt>''' (and not from '''PAM''') (as root): |
||
* Edit the file <tt>/etc/courier/authdaemonrc</tt>, and change it as follows: |
* Edit the file <tt>/etc/courier/authdaemonrc</tt>, and change it as follows: |
||
<source lang="text">authmodulelist="authuserdb"</source> |
|||
* Restart the daemon: |
* Restart the daemon: |
||
<source lang="bash">/etc/init.d/courier-authdaemon restart</source> |
|||
* Change the password for user '''$USER''' and commit the changes |
* Change the password for user '''$USER''' and commit the changes |
||
<source lang="bash"> |
|||
userdbpw -md5 | sudo userdb $USER set systempw |
userdbpw -md5 | sudo userdb $USER set systempw |
||
sudo makeuserdb |
sudo makeuserdb |
||
</source> |
</source> |
||
* Test the new password with |
* Test the new password with |
||
<source lang="bash"> |
|||
nc imapserver 143 |
nc imapserver 143 |
||
01 LOGIN username password |
01 LOGIN username password |
||
02 LOGOUT |
02 LOGOUT |
||
</source> |
</source> |
||
=== OpenSUSE === |
=== OpenSUSE === |
Revision as of 04:58, 15 June 2015
Courier IMAP is a fast, scalable, enterprise IMAP server that uses Maildirs.
References
- Courier IMAP homepage
- On openSUSE:
- Package doc at /usr/share/doc/packages/courier-authlib and /usr/share/doc/packages/courier-imap.
- On Ubuntu:
- Manpages & package documentation:
- maildirmake(1)
- couriertcpd(1)
- imapd(8)
- userdb(8)
- makeuserdb(8)
- /usr/share/doc/courier-doc (on Ubuntu, with package courier-doc installed)
Install
Ubuntu
To install Courier IMAP:
- Install the required packages:
sudo apt-get install courier-imap courier-doc courier-imap-ssl
- Create /etc/courier/userdb.dat
sudo su
pw2userdb >/etc/courier/userdb
chmod 600 /etc/courier/userdb
makeuserdb
- Make sure all users have directory ~/Maildir:
maildirmake /etc/skel/Maildir # Create Maildir directory for all new users
To use the password from /etc/courier/userdb (and not from PAM) (as root):
- Edit the file /etc/courier/authdaemonrc, and change it as follows:
authmodulelist="authuserdb"
- Restart the daemon:
/etc/init.d/courier-authdaemon restart
- Change the password for user $USER and commit the changes
userdbpw -md5 | sudo userdb $USER set systempw
sudo makeuserdb
- Test the new password with
nc imapserver 143
01 LOGIN username password
02 LOGOUT
OpenSUSE
- Uninstall the default IMAP server (UW IMAP) packages, or they'll create a conflict
- Install Courier IMAP package (packages courier-authlib and courier-imap).
Cygwin
See the page dedicated to Courier Cygwin.