<!DOCTYPE HTML PUBLIC "-//W3C//DTD HTML 3.2 Final//EN"> <HTML> <HEAD> <META NAME="GENERATOR" CONTENT="SGML-Tools 1.0.9"> <TITLE> Cyrus IMAP HOWTO: Cyrus IMAP Implementation</TITLE> <LINK HREF="Cyrus-IMAP-9.html" REL=next> <LINK HREF="Cyrus-IMAP-7.html" REL=previous> <LINK HREF="Cyrus-IMAP.html#toc8" REL=contents> </HEAD> <BODY> <A HREF="Cyrus-IMAP-9.html">Next</A> <A HREF="Cyrus-IMAP-7.html">Previous</A> <A HREF="Cyrus-IMAP.html#toc8">Contents</A> <HR> <H2><A NAME="s8">8. Cyrus IMAP Implementation</A></H2> <H2><A NAME="ss8.1">8.1 Add the cyrus administrator</A> </H2> <P>Run the following command to set up a user for cyrus <P><CODE>/usr/local/sbin/saslpasswd cyrus</CODE> <H2><A NAME="ss8.2">8.2 Testing Cyrus IMAP</A> </H2> <P> <OL> <LI><CODE>killall -HUP inetd</CODE></LI> <LI><CODE>su cyrus</CODE></LI> <LI><CODE>imtest -m login -p imap localhost</CODE></LI> </OL> <P>Enter your password. If you see something like: <P> <PRE> (L01 OK User logged in means you're in) </PRE> <P>Then the setup has been successful. Type <P> <PRE> . logout </PRE> <P>to log out. <H2><A NAME="ss8.3">8.3 Setting up users</A> </H2> <P>Still as the user cyrus, type the following commands. They will set up the mailbox(es) for each user. Fill in the username where you see the (username). <P> <OL> <LI><CODE>cyradm localhost</CODE></LI> <LI><CODE>cm user.joebob</CODE> (for all the user joebob)</LI> <LI><CODE>quit</CODE></LI> <LI><CODE>exit</CODE> (back as root)</LI> </OL> <P>Now as root, enter a password for each username <P><CODE>saslpasswd (username)</CODE> <H2><A NAME="ss8.4">8.4 Delivery database pruning</A> </H2> <P>If you don't periodically prune the database of deliveries, you can fill up your file system. Adding a cron job which will run once a day is one way to do this. That involves going to <EM>/etc/cron.daily</EM> and creating a file named cyrus-imapd. Inside that file, put the following two lines of code: <P> <PRE> #!/bin/bash su cyrus -s /bin/bash -c '/usr/cyrus/bin/deliver -E 3' </PRE> <P>Make this script executable by running: <CODE>chmod 755 cyrus-imapd</CODE> <P>You should also create the deliverdb directory to store database files in: <P><CODE>mkdir /var/imap/deliverdb</CODE> <H2><A NAME="ss8.5">8.5 Finishing up</A> </H2> <P>Reboot the machine to make sure that everything has been restarted under the new configuration <HR> <A HREF="Cyrus-IMAP-9.html">Next</A> <A HREF="Cyrus-IMAP-7.html">Previous</A> <A HREF="Cyrus-IMAP.html#toc8">Contents</A> </BODY> </HTML>