diff options
| author | Sam Varshavchik | 2021-02-18 08:28:11 -0500 |
|---|---|---|
| committer | Sam Varshavchik | 2021-02-18 08:45:12 -0500 |
| commit | 5cba7ab897d2148b68826379218ce15f115d06c5 (patch) | |
| tree | cfb22c40481b0446a8f8707a7083cf13d98a6ba9 /imap | |
| parent | f25a0880d0762e4d8a47cce13ab3cea1a1db01f8 (diff) | |
| download | courier-libs-5cba7ab897d2148b68826379218ce15f115d06c5.tar.bz2 | |
Replace FAM/Gamin with inotify
Diffstat (limited to 'imap')
| -rw-r--r-- | imap/Makefile.am | 6 | ||||
| -rw-r--r-- | imap/imapd.sgml | 201 |
2 files changed, 69 insertions, 138 deletions
diff --git a/imap/Makefile.am b/imap/Makefile.am index dda6235..a363bc1 100644 --- a/imap/Makefile.am +++ b/imap/Makefile.am @@ -74,11 +74,9 @@ imapd_SOURCES=fetch.c fetchinfo.c fetchinfo.h imapd.c imapd.h \ search.c searchinfo.c searchinfo.h \ storeinfo.c storeinfo.h -imapd_DEPENDENCIES=libimapd.la \ - ../maildir/maildir.libdeps @dblibrary@ +imapd_DEPENDENCIES=libimapd.la @dblibrary@ -imapd_LDADD=libimapd.la `cat ../maildir/maildir.libdeps` \ - @dblibrary@ @DEBUGLIB@ @LDAUTH@ -lcourierauth +imapd_LDADD=libimapd.la @dblibrary@ @DEBUGLIB@ @LDAUTH@ -lcourierauth pop3login_SOURCES=pop3login.c pop3dcapa.c proxy.c proxy.h pop3login_DEPENDENCIES=../tcpd/libspipe.la ../tcpd/libspipe.la libpop3d.la diff --git a/imap/imapd.sgml b/imap/imapd.sgml index 43b8ec3..6df09cf 100644 --- a/imap/imapd.sgml +++ b/imap/imapd.sgml @@ -1,5 +1,5 @@ <!DOCTYPE refentry PUBLIC "-//OASIS//DTD DocBook XML V4.4//EN" "http://www.oasis-open.org/docbook/xml/4.4/docbookx.dtd"> -<!-- Copyright 1998 - 2007 Double Precision, Inc. See COPYING for --> +<!-- Copyright 1998 - 2021 Double Precision, Inc. See COPYING for --> <!-- distribution information. --> <refentry id="imapd"> <info><author><firstname>Sam</firstname><surname>Varshavchik</surname><contrib>Author</contrib></author><productname>Courier Mail Server</productname></info> @@ -12,12 +12,12 @@ <refnamediv> <refname>imapd</refname> - <refpurpose>The <application moreinfo="none">Courier</application> IMAP server</refpurpose> + <refpurpose>The <application>Courier</application> IMAP server</refpurpose> </refnamediv> <refsynopsisdiv> <cmdsynopsis sepchar=" "> - <command moreinfo="none">@libexecdir@/couriertcpd</command> + <command>@libexecdir@/couriertcpd</command> <arg choice="req" rep="norepeat">couriertcpd options</arg> <arg choice="req" rep="norepeat">@prefix@/sbin/imaplogin</arg> <arg choice="opt" rep="repeat"><replaceable>modules</replaceable></arg> @@ -26,7 +26,7 @@ </cmdsynopsis> <cmdsynopsis sepchar=" "> - <command moreinfo="none">@prefix@/bin/imapd</command> + <command>@prefix@/bin/imapd</command> <arg choice="req" rep="norepeat">./Maildir</arg> </cmdsynopsis> </refsynopsisdiv> @@ -35,48 +35,48 @@ <title>DESCRIPTION</title> <para> -<command moreinfo="none">imapd</command> is the <application moreinfo="none">Courier</application> +<command>imapd</command> is the <application>Courier</application> IMAP server that provides IMAP access to Maildir mailboxes. -Normally you don't have to worry about it, as <command moreinfo="none">imapd</command> +Normally you don't have to worry about it, as <command>imapd</command> runs automatically after receiving a network connection, accompanied by the appropriate userid and password.</para> <para> -<command moreinfo="none">couriertcpd</command> opens network ports that receive incoming +<command>couriertcpd</command> opens network ports that receive incoming IMAP connections. After an incoming network connections is established, -<command moreinfo="none">couriertcpd</command> +<command>couriertcpd</command> runs the command specified by its first argument, which is -<command moreinfo="none">imaplogin</command> passing the remaining arguments to -<command moreinfo="none">imaplogin</command>. -<command moreinfo="none">imaplogin</command> reads the IMAP login userid and password, +<command>imaplogin</command> passing the remaining arguments to +<command>imaplogin</command>. +<command>imaplogin</command> reads the IMAP login userid and password, then runs the modules specified by its remaining options, which -are <application moreinfo="none">Courier</application> +are <application>Courier</application> server authentication modules described in the <ulink url="authlib.html"><citerefentry><refentrytitle>authlib</refentrytitle><manvolnum>7</manvolnum></citerefentry></ulink> manual page.</para> <para> The last daisy-chained command is -<command moreinfo="none">imapd</command>, which is the actual IMAP server, +<command>imapd</command>, which is the actual IMAP server, which is started from the logged-in account's home directory. -The sole argument to <command moreinfo="none">imapd</command> is the pathname +The sole argument to <command>imapd</command> is the pathname to the default IMAP mailbox, which is usually -<filename moreinfo="none">./Maildir</filename>. +<filename>./Maildir</filename>. Some authentication modules are capable of specifying a different filename, by setting the <envar>MAILDIR</envar> environment variable. </para> <para> -<command moreinfo="none">imapd</command> may also be invoked from the shell prompt, in which -case it issues a <literal moreinfo="none">PREAUTH</literal> response, then changes the +<command>imapd</command> may also be invoked from the shell prompt, in which +case it issues a <literal>PREAUTH</literal> response, then changes the current directory to either its argument, or the contents of the <envar>MAILDIR</envar> environment variable, then attempts to talk IMAP on standard input and output.</para> <para> -<command moreinfo="none">imapd</command> implements IMAP4REV1, as defined by +<command>imapd</command> implements IMAP4REV1, as defined by <ulink url="http://www.rfc-editor.org/rfc/rfc2060.txt">RFC 2060</ulink>.</para> </refsect1> @@ -89,11 +89,11 @@ variable, then attempts to talk IMAP on standard input and output.</para> <term><envar>AUTH*</envar></term> <listitem> <simpara> -<command moreinfo="none">imapd</command> examines several environment variables whose +<command>imapd</command> examines several environment variables whose names start with AUTH - these environment variables are set by -<command moreinfo="none">imaplogin</command> and the authentication modules. +<command>imaplogin</command> and the authentication modules. Their absence tells -<command moreinfo="none">imapd</command> that it's running from the command line. +<command>imapd</command> that it's running from the command line. </simpara> </listitem> </varlistentry> @@ -103,15 +103,15 @@ Their absence tells <listitem> <simpara> <envar>MAILDIR</envar> - if defined, -<command moreinfo="none">imapd</command> changes its directory to the +<command>imapd</command> changes its directory to the one specified by this environment variable. -Otherwise <command moreinfo="none">imapd</command> changes +Otherwise <command>imapd</command> changes its directory to the one specified on the command line.</simpara> </listitem> </varlistentry> <varlistentry> - <term><filename moreinfo="none">`<command moreinfo="none">pwd</command>`/.</filename></term> + <term><filename>`<command>pwd</command>`/.</filename></term> <listitem> <simpara> The current directory is assumed to be the main INBOX @@ -120,7 +120,7 @@ Maildir.</simpara> </varlistentry> <varlistentry> - <term><filename moreinfo="none">`<command moreinfo="none">pwd</command>`/.<replaceable>folder</replaceable></filename></term> + <term><filename>`<command>pwd</command>`/.<replaceable>folder</replaceable></filename></term> <listitem> <simpara> Maildir folders, each one containing their own @@ -131,25 +131,25 @@ tmp, new, cur, etc...</simpara> <para> Other environment variables are initialized from the -<filename moreinfo="none">@sysconfdir@/imapd</filename> and -<filename moreinfo="none">@sysconfdir@/imapd-ssl</filename> configuration files. +<filename>@sysconfdir@/imapd</filename> and +<filename>@sysconfdir@/imapd-ssl</filename> configuration files. These files are loaded into the environment by the system startup script -that runs <command moreinfo="none">couriertcpd</command>.</para> +that runs <command>couriertcpd</command>.</para> <refsect2 id="imapd_realtime_concurrent_folder_status_updates"> <title>Realtime concurrent folder status updates</title> <para> -Setting the <literal moreinfo="none">IMAP_ENHANCEDIDLE</literal> to -<literal moreinfo="none">1</literal> in -<filename moreinfo="none">@sysconfdir@/imapd</filename> enables realtime concurrent folder +Setting the <literal>IMAP_ENHANCEDIDLE</literal> to +<literal>1</literal> in +<filename>@sysconfdir@/imapd</filename> enables realtime concurrent folder status updates. When relatime folder status updates are enabled all IMAP mail clients that have the same folder open will be immediately notified of any changes to the folder's contents.</para> <para> -The <application moreinfo="none">Courier</application> IMAP server always allows +The <application>Courier</application> IMAP server always allows more than one mail client to have the same folder opened. However, when two or more clients have the same folder opened, the mail @@ -161,79 +161,24 @@ No provisions exists to notify the mail client immediately when the folder's contents are modified by another mail client.</para> <para> -The <literal moreinfo="none">IDLE</literal> extension to the base IMAP protocol provides +The <literal>IDLE</literal> extension to the base IMAP protocol provides a delivery mechanism for notifying mail clients of changes to the mail folder's contents. Although at this time it's not known to which extent -the <literal moreinfo="none">IDLE</literal> extension is supported by IMAP mail clients, -the <application moreinfo="none">Courier</application> IMAP server fully implements -the <literal moreinfo="none">IDLE</literal> +the <literal>IDLE</literal> extension is supported by IMAP mail clients, +the <application>Courier</application> IMAP server fully implements +the <literal>IDLE</literal> extension provided that the following requirements are met: </para> <variablelist> <varlistentry> - <term><application moreinfo="none">Gamin</application> or <application moreinfo="none">FAM</application></term> + <term><literal>IDLE</literal> IMAP capability</term> <listitem> <para> -Either <ulink url="http://www.gnome.org/~veillard/gamin/">Gamin</ulink> or -<ulink url="http://oss.sgi.com/projects/fam/">FAM</ulink> -must be properly installed and -configured prior to installing -the <application moreinfo="none">Courier</application> IMAP server.</para> - - <para> -<application moreinfo="none">Gamin</application>/<application moreinfo="none">FAM</application> -is an application library that -provides an interface to the operating system's kernel -that applications can use to be notified when specific files -or directories are changed, and the -<application moreinfo="none">Courier</application> IMAP server leverages this API to -implement realtime concurrent folder status updates. -According to the most recently available documentation, -<application moreinfo="none">Gamin</application> is a Linux-specific library, and -<application moreinfo="none">FAM</application> -builds and runs on Linux and IRIX. -<application moreinfo="none">FAM</application> -should also build on other platforms, but without a supported kernel monitor -FAM will fall back to a polling mode. -At press time, -<application moreinfo="none">FAM</application>'s -web site reports that -<application moreinfo="none">FAM</application> -succesfully builds (in polling mode) on FreeBSD and Solaris.</para> - - <para> -<application moreinfo="none">FAM</application> (but not <application moreinfo="none">Gamin</application>) -also works with NFS filesystems. -On NFS clients <command moreinfo="none">fam</command> transparently forwards file monitoring -requests to a peer <command moreinfo="none">fam</command> process on the NFS server.</para> - - <para> -Installation and configuration of -<application moreinfo="none">Gamin</application> or -<application moreinfo="none">FAM</application> is beyond -the scope of this document. This documentation presumes that Gamin or FAM is -succesfully installed. Use the resources and tools on -<application moreinfo="none">Gamin</application>'s or -<application moreinfo="none">FAM</application>'s web site -for assistance with setting them up. -Systems that use GNOME or KDE desktops already have -<application moreinfo="none">FAM</application> or -<application moreinfo="none">Gamin</application> -installed, as -<application moreinfo="none">FAM</application> or <application moreinfo="none">Gamin</application> -is used by the current versions of both desktops.</para> - </listitem> - </varlistentry> - - <varlistentry> - <term><literal moreinfo="none">IDLE</literal> IMAP capability</term> - <listitem> - <para> -<literal moreinfo="none">IDLE</literal> +<literal>IDLE</literal> must be listed in the <envar>IMAP_CAPABILITY</envar> -setting in the <filename moreinfo="none">@sysconfdir@/imapd</filename> +setting in the <filename>@sysconfdir@/imapd</filename> configuration file.</para> </listitem> </varlistentry> @@ -242,7 +187,7 @@ configuration file.</para> <term><envar>IMAP_USELOCKS</envar></term> <listitem> <para> -This setting in <filename moreinfo="none">@sysconfdir@/imapd</filename> +This setting in <filename>@sysconfdir@/imapd</filename> must be enabled. This setting uses dot-lock files to synchronize updates to folder indexes between multiple IMAP clients that have the same folder opened.</para> @@ -256,13 +201,13 @@ daemon.</para> <varlistentry> <term>An IMAP mail client that fully supports the -<literal moreinfo="none">IDLE</literal> +<literal>IDLE</literal> protocol extension.</term> <listitem> <para> -Of course, an IMAP client that supports the <literal moreinfo="none">IDLE</literal> +Of course, an IMAP client that supports the <literal>IDLE</literal> protocol extension is required. -At press time the status and extent of <literal moreinfo="none">IDLE</literal> support +At press time the status and extent of <literal>IDLE</literal> support in most IMAP mail clients is not known.</para> </listitem> </varlistentry> @@ -271,14 +216,12 @@ in most IMAP mail clients is not known.</para> <term><envar>IMAP_ENHANCEDIDLE</envar></term> <listitem> <para> -This setting in <filename moreinfo="none">@sysconfdir@/imapd</filename> +This setting in <filename>@sysconfdir@/imapd</filename> actually enables concurrent realtime folder status updates using the -<literal moreinfo="none">IDLE</literal> extension. -Note that it is possible to enable the <literal moreinfo="none">IDLE</literal> extension -even if -<application moreinfo="none">FAM</application> or -<application moreinfo="none">Gamin</application> -is not available, or without +<literal>IDLE</literal> extension and the inotify kernel interface. +Note that it is possible to enable the <literal>IDLE</literal> extension +even when Courier-IMAP is compiled on a platform without the inotify +kernel interface, or without enabling either the <envar>IMAP_USELOCKS</envar> and/or <envar>IMAP_ENHANCEDIDLE</envar> settings. The resulting consequences are described are as follows:</para> @@ -297,9 +240,9 @@ confusion that results from this situation.</para> </listitem> <listitem> <para> -Without <application moreinfo="none">FAM</application> or <application moreinfo="none">Gamin</application>, and +Without inotify kernel interface, and <envar>IMAP_ENHANCEDIDLE</envar> set, the -<application moreinfo="none">Courier</application> IMAP server will +<application>Courier</application> IMAP server will manually check for changes to the folder's contents every 60 seconds, in IDLE mode (instead of in real time). </para> @@ -321,8 +264,8 @@ commands. The following instructions describe the procedure for connecting to the IMAP server, and manually issuing IMAP protocol commands, as if they originate from an IMAP client. -The following instructions use "<literal moreinfo="none">C:</literal>" to indicate IMAP -client commands that must be entered, and "<literal moreinfo="none">S:</literal>" to +The following instructions use "<literal>C:</literal>" to indicate IMAP +client commands that must be entered, and "<literal>S:</literal>" to indicate the expected replies from the server.</para> <note> @@ -360,11 +303,11 @@ S:+ entering ENHANCED idle mode </programlisting> <note> <para> -The default <application moreinfo="none">Courier</application> IMAP server +The default <application>Courier</application> IMAP server configuration permits a maximum of four connections from the same IP address. It may be necessary to adjust this setting in -<filename moreinfo="none">@sysconfdir@/imapd</filename> +<filename>@sysconfdir@/imapd</filename> for the duration of this test.</para> </note> @@ -374,14 +317,7 @@ for the duration of this test.</para> <para> The last message from the server must be "entering ENHANCED idle mode". Otherwise, it means that some of the necessary prerequisites have not been -met. -Verify that <application moreinfo="none">FAM</application> -or <application moreinfo="none">Gamin</application> was set up prior to installing -The <application moreinfo="none">Courier</application> IMAP server -(use <citerefentry><refentrytitle>ldd</refentrytitle><manvolnum>1</manvolnum></citerefentry> -to verify that the <command moreinfo="none">imapd</command> executable is linked with -the <filename moreinfo="none">libfam</filename> library), and verify the settings in the -<filename moreinfo="none">@sysconfdir@/imapd</filename>.</para> +met.</para> </listitem> <listitem> @@ -410,14 +346,11 @@ a OK STORE completed. <listitem> <para> -The last command sets the <literal moreinfo="none">\Deleted</literal> flag on the first +The last command sets the <literal>\Deleted</literal> flag on the first message in the folder. Immediately after entering the last command, -"<literal moreinfo="none">* 1 FETCH (FLAGS (\Deleted))</literal>" should also appear +"<literal>* 1 FETCH (FLAGS (\Deleted))</literal>" should also appear in all other terminal windows. -On systems where <application moreinfo="none">FAM</application> uses the fall-back polling -mode this response may appear after a brief delay of a few seconds. -The delay should never exceed 15-20 seconds. </para> </listitem> @@ -425,9 +358,9 @@ The delay should never exceed 15-20 seconds. <para> Verify that all terminal windows reliably receive folder status updates in real time by alternatively entering the commands -"<literal moreinfo="none">a STORE 1 -FLAGS (\Deleted)</literal>" +"<literal>a STORE 1 -FLAGS (\Deleted)</literal>" and -"<literal moreinfo="none">a STORE 1 +FLAGS (\Deleted)</literal>", +"<literal>a STORE 1 +FLAGS (\Deleted)</literal>", to toggle the deleted flag on the first message. Observe that the message is received by all terminal windows quickly, and reliably.</para> @@ -435,8 +368,8 @@ and reliably.</para> <listitem> <para> -With the <literal moreinfo="none">\Deleted</literal> flag set on the first message, -enter the <command moreinfo="none">EXPUNGE</command> command, which removes the deleted +With the <literal>\Deleted</literal> flag set on the first message, +enter the <command>EXPUNGE</command> command, which removes the deleted message from the folder:</para> <programlisting format="linespecific"> @@ -450,7 +383,7 @@ S:a OK EXPUNGE completed <para> The lines that begin with the "*" character should also appear in all other terminal windows (depending on the initial folder state one of the terminal -windows may have a different <literal moreinfo="none">RECENT</literal> message, which is +windows may have a different <literal>RECENT</literal> message, which is fine). </para> </listitem> @@ -470,13 +403,13 @@ messages should appear in every terminal window: <para> The numbers in these messages may be different, depending upon the initial contents of the test mail folder. -One of the terminal windows should have a different <literal moreinfo="none">RECENT</literal> +One of the terminal windows should have a different <literal>RECENT</literal> count, and one of the terminal windows should include a -<literal moreinfo="none">\Recent</literal> flag in the untagged -<literal moreinfo="none">FLAGS</literal> message. +<literal>\Recent</literal> flag in the untagged +<literal>FLAGS</literal> message. These difference are acceptable; the important thing is to make sure that -all terminal windows have the same <literal moreinfo="none">EXISTS</literal> message. +all terminal windows have the same <literal>EXISTS</literal> message. </para> </listitem> </orderedlist> @@ -487,7 +420,7 @@ all terminal windows have the same <literal moreinfo="none">EXISTS</literal> mes <para> <ulink url="authlib.html"><citerefentry><refentrytitle>authlib</refentrytitle><manvolnum>7</manvolnum></citerefentry></ulink>, - + <ulink url="userdb.html"><citerefentry><refentrytitle>userdb</refentrytitle><manvolnum>8</manvolnum></citerefentry></ulink></para> </refsect1> |
