procmail
[Top] [All Lists]

Re: "mailbox as soft link" problem

2008-07-23 05:18:46
Am 2008-07-14 11:02:37, schrieb Markus Krause:
Hmm, all users on the mail server are refused to login directly, /etc/passwd
is similar to:

  rztest:asdfasdfasdf:111:111:Test-Account:/home/mail/rztest:/bin/false

OK

##### SPAM #####
:0
* ^Subject:.*\*\*\*SPAM\*\*\*
SPAM
      ^
If you use Maildir, you need a "/" at the end.

:0
* ^Subject:.*test
test
      ^
Here too

  :0
  * ^Subject:.*test
  test/

works without any problems

Jul 14 10:45:47 test-mail02 procmail[14593]: Couldn't rename bogus
"/var/spool/mail/test" into "/var/spool/mail/BOGUS.test.8uGN"

Because the missing "/" at the end procmail think, it is a file.

This happens when the permissions on /var/spool/mail are set to 755 (and the
actuall delivery seems to work) otherwise procmail would remove the symbolic
link and create a new "real" file as inbox file.
Is there no way to prevent this? Where does procmail get the information
that the inbox has to be /var/spool/mail/$USER?
Does this behaviour change when using maildir instead of mbox? (i will be
moving as soon as possible but i really need a workaround for this for some
time ...)

----[ '/etc/login.defs' ]-----------------------------------------------
# *REQUIRED*
#   Directory where mailboxes reside, _or_ name of file, relative to the
#   home directory.  If you _do_ define both, MAIL_DIR takes precedence.
#   QMAIL_DIR is for Qmail (or any maildir-compatible MTA, such as Exim or
#   Postfix when suitably configured).
# 
#   Essentially, MAIL_DIR defines the $MAIL environmental variable
#   (for mbox use) by appending the username to MAIL_DIR as defined
#   below.  MAIL_FILE defines the $MAIL environment variable as the
#   fully-qualified filename obtained by prepending the user home
#   directory before $MAIL_FILE, and QMAIL_DIR defines the MAIL
#   environment variable as the fully-qualified directory name
#   obtained by prepending the user home directory before $QMAIL_DIR.
#
# NOTE: This is used to setup your MAIL environment variable, and also
# used by userdel to determine if any mail spools need to be removed when
# removing a user. If you change this, you should also change the
# pam_mail.so module setup in /etc/pam.d/login, which affects the "You
# have mail" message on login, and, in default setup, overrides this setting
# in determining the $MAIL environmental variable.
# 
QMAIL_DIR      Maildir/
#MAIL_DIR        /var/mail
#MAIL_FILE      .mail
------------------------------------------------------------------------

I have set it up to  use  ${HOME}/Maildir  since  I  have  created  unix
accounts for my mailusers and since I use courier-imap it use  ~/Maildir
by default without any further interfention...

And of course, since the ${HOME} for each  ${USER}  is  defined  in  the
/etc/passwd you can arrange it on any hardrives or volumes you want.

Some times ago @customer I have migrated  to  courier  and  switched  to
Maildir/ and written a script, which read in the /var/spool/mail/${USER}
and push it using formail into procmail which was setup to use Maildir/.

80 users with 5 GByte messages in around 4 hours an a  very  small  PIII
which was already setup to accept messages from outside...

So, fast migration should be no problem...

Thanks in advance for any hints! (and sorry for my stubborness in
understanding this ...)

regards
   markus



Thanks, Greetings and nice Day/Evening
    Michelle Konzack
    Systemadministrator
    24V Electronic Engineer
    Tamay Dogan Network
    Debian GNU/Linux Consultant


-- 
Linux-User #280138 with the Linux Counter, http://counter.li.org/
##################### Debian GNU/Linux Consultant #####################
Michelle Konzack   Apt. 917                  ICQ #328449886
+49/177/9351947    50, rue de Soultz         MSN LinuxMichi
+33/6/61925193     67100 Strasbourg/France   IRC #Debian (irc.icq.com)

____________________________________________________________
procmail mailing list   Procmail homepage: http://www.procmail.org/
procmail(_at_)lists(_dot_)RWTH-Aachen(_dot_)DE
http://MailMan.RWTH-Aachen.DE/mailman/listinfo/procmail

<Prev in Thread] Current Thread [Next in Thread>