<html xmlns:v="urn:schemas-microsoft-com:vml" xmlns:o="urn:schemas-microsoft-com:office:office" xmlns:w="urn:schemas-microsoft-com:office:word" xmlns="http://www.w3.org/TR/REC-html40">
<head>
<meta http-equiv=Content-Type content="text/html; charset=us-ascii">
<meta name=Generator content="Microsoft Word 11 (filtered medium)">
<style>
<!--
/* Style Definitions */
p.MsoNormal, li.MsoNormal, div.MsoNormal
{margin:0cm;
margin-bottom:.0001pt;
font-size:12.0pt;
font-family:"Times New Roman";}
a:link, span.MsoHyperlink
{color:blue;
text-decoration:underline;}
a:visited, span.MsoHyperlinkFollowed
{color:purple;
text-decoration:underline;}
p.MsoPlainText, li.MsoPlainText, div.MsoPlainText
{margin:0cm;
margin-bottom:.0001pt;
font-size:10.0pt;
font-family:"Courier New";}
span.E-mailStijl18
{mso-style-type:personal;
font-family:Arial;
color:windowtext;}
span.E-mailStijl19
{mso-style-type:personal;
font-family:Arial;
color:navy;}
span.E-mailStijl20
{mso-style-type:personal;
font-family:Arial;
color:navy;}
span.E-mailStijl21
{mso-style-type:personal-reply;
font-family:Arial;
color:navy;}
@page Section1
{size:595.3pt 841.9pt;
margin:70.85pt 69.6pt 70.85pt 69.6pt;}
div.Section1
{page:Section1;}
/* List Definitions */
@list l0
{mso-list-id:486094042;
mso-list-type:hybrid;
mso-list-template-ids:-1382392474 794955432 68354073 68354075 68354063 68354073 68354075 68354063 68354073 68354075;}
@list l0:level1
{mso-level-text:"%1\)";
mso-level-tab-stop:36.0pt;
mso-level-number-position:left;
text-indent:-18.0pt;
font-family:Arial;}
ol
{margin-bottom:0cm;}
ul
{margin-bottom:0cm;}
-->
</style>
<!--[if gte mso 9]><xml>
<o:shapedefaults v:ext="edit" spidmax="1026" />
</xml><![endif]--><!--[if gte mso 9]><xml>
<o:shapelayout v:ext="edit">
<o:idmap v:ext="edit" data="1" />
</o:shapelayout></xml><![endif]-->
</head>
<body lang=NL link=blue vlink=purple>
<div class=Section1>
<p class=MsoNormal><font size=2 face="Courier New"><span lang=EN-GB
style='font-size:10.0pt;font-family:"Courier New"'>I investigated the deliver
with quota’s bug a little more (rc10, mysql, virtual domains, maildir). My
log files reads:<o:p></o:p></span></font></p>
<p class=MsoNormal><font size=2 face="Courier New"><span lang=EN-GB
style='font-size:10.0pt;font-family:"Courier New"'><o:p> </o:p></span></font></p>
<p class=MsoNormal><font size=2 face="Courier New"><span lang=EN-GB
style='font-size:10.0pt;font-family:"Courier New"'>deliver(test@ruijs.cc):
Info: msgid=<000f01c6fac1$bd4e8670$8801a8c0@Moskou>: save failed to INBOX<o:p></o:p></span></font></p>
<p class=MsoNormal><font size=2 face="Courier New"><span lang=EN-GB
style='font-size:10.0pt;font-family:"Courier New"'>deliver(test@ruijs.cc):
Info: sieve runtime error: Keep: Generic Error<o:p></o:p></span></font></p>
<p class=MsoNormal><font size=2 face="Courier New"><span lang=EN-GB
style='font-size:10.0pt;font-family:"Courier New"'>deliver(test@ruijs.cc):
Info: msgid=<000f01c6fac1$bd4e8670$8801a8c0@Moskou>: save failed to INBOX<o:p></o:p></span></font></p>
<p class=MsoNormal><font size=2 face="Courier New"><span lang=EN-GB
style='font-size:10.0pt;font-family:"Courier New"'>deliver(test@ruijs.cc):
Error:
open(ruijs.cc/test//.temp.in2sports2.vianetworks.nl.13210.72d247ac698d0019)
failed: No such file or directory<o:p></o:p></span></font></p>
<p class=MsoNormal><font size=2 face="Courier New"><span lang=EN-GB
style='font-size:10.0pt;font-family:"Courier New"'>deliver(mark@ruijs.cc):
Info: msgid=<dovecot-1162066721-407295-0@in2sports2.vianetworks.nl>:
saved mail to Junk<o:p></o:p></span></font></p>
<p class=MsoNormal><font size=2 face="Courier New"><span lang=EN-GB
style='font-size:10.0pt;font-family:"Courier New"'><o:p> </o:p></span></font></p>
<p class=MsoNormal><font size=2 face="Courier New"><span lang=EN-GB
style='font-size:10.0pt;font-family:"Courier New"'>Dovecot tries to deliver,
but notices quota exceeded. I don’t think Sieve is playing a role here
– I added Sieve before I encountered the problem.<o:p></o:p></span></font></p>
<p class=MsoNormal><font size=2 face="Courier New"><span lang=EN-GB
style='font-size:10.0pt;font-family:"Courier New"'><o:p> </o:p></span></font></p>
<p class=MsoNormal><font size=2 face="Courier New"><span lang=EN-GB
style='font-size:10.0pt;font-family:"Courier New"'>Two problems:<o:p></o:p></span></font></p>
<p class=MsoNormal style='margin-left:36.0pt;text-indent:-18.0pt;mso-list:l0 level1 lfo1'><![if !supportLists]><font
size=2 face=Arial><span lang=EN-GB style='font-size:10.0pt;font-family:Arial'><span
style='mso-list:Ignore'>1)<font size=1 face="Times New Roman"><span
style='font:7.0pt "Times New Roman"'> </span></font></span></span></font><![endif]><font
size=2 face="Courier New"><span lang=EN-GB style='font-size:10.0pt;font-family:
"Courier New"'>The .dovecot.lda-dupes can’t be written (that’s what
the open...failed notice is about).<o:p></o:p></span></font></p>
<p class=MsoNormal style='margin-left:36.0pt;text-indent:-18.0pt;mso-list:l0 level1 lfo1'><![if !supportLists]><font
size=2 face=Arial><span lang=EN-GB style='font-size:10.0pt;font-family:Arial'><span
style='mso-list:Ignore'>2)<font size=1 face="Times New Roman"><span
style='font:7.0pt "Times New Roman"'> </span></font></span></span></font><![endif]><font
size=2 face="Courier New"><span lang=EN-GB style='font-size:10.0pt;font-family:
"Courier New"'>The Quota Exceed mail seem to contain mal-formed headers
(that’s why it the notice-mail ends in my junk-folder).<o:p></o:p></span></font></p>
<p class=MsoNormal><font size=2 face="Courier New"><span lang=EN-GB
style='font-size:10.0pt;font-family:"Courier New"'><o:p> </o:p></span></font></p>
<p class=MsoNormal><font size=2 face="Courier New"><span lang=EN-GB
style='font-size:10.0pt;font-family:"Courier New"'>Digging into deliver.c, I
noticed that auth_client_put_user_env() changes the HOME environment from
/var/mail (which is ok), to ruijs.cc/test/ (which is the maildir, relative to
/var/mail). And then fopen fails (see the trace below). So I think that the
code<o:p></o:p></span></font></p>
<p class=MsoNormal><font size=2 face="Courier New"><span lang=EN-GB
style='font-size:10.0pt;font-family:"Courier New"'><o:p> </o:p></span></font></p>
<p class=MsoNormal><font size=2 face="Courier New"><span lang=EN-GB
style='font-size:10.0pt;font-family:"Courier New"'>
auth_socket = getenv("AUTH_SOCKET_PATH");<o:p></o:p></span></font></p>
<p class=MsoNormal><font size=2 face="Courier New"><span lang=EN-GB
style='font-size:10.0pt;font-family:"Courier New"'> if
(auth_socket == NULL)<o:p></o:p></span></font></p>
<p class=MsoNormal><font size=2 face="Courier New"><span lang=EN-GB
style='font-size:10.0pt;font-family:"Courier New"'>
auth_socket = DEFAULT_AUTH_SOCKET_PATH;<o:p></o:p></span></font></p>
<p class=MsoNormal><font size=2 face="Courier New"><span lang=EN-GB
style='font-size:10.0pt;font-family:"Courier New"'><o:p> </o:p></span></font></p>
<p class=MsoNormal><font size=2 face="Courier New"><span lang=EN-GB
style='font-size:10.0pt;font-family:"Courier New"'> ret =
auth_client_put_user_env(ioloop, auth_socket,<o:p></o:p></span></font></p>
<p class=MsoNormal><font size=2 face="Courier New"><span lang=EN-GB
style='font-size:10.0pt;font-family:"Courier New"'>
destination, process_euid);<o:p></o:p></span></font></p>
<p class=MsoNormal><font size=2 face="Courier New"><span lang=EN-GB
style='font-size:10.0pt;font-family:"Courier New"'> if (ret
!= 0)<o:p></o:p></span></font></p>
<p class=MsoNormal><font size=2 face="Courier New"><span lang=EN-GB
style='font-size:10.0pt;font-family:"Courier New"'>
return ret;<o:p></o:p></span></font></p>
<p class=MsoNormal><font size=2 face="Courier New"><span lang=EN-GB
style='font-size:10.0pt;font-family:"Courier New"'><o:p> </o:p></span></font></p>
<p class=MsoNormal><font size=2 face="Courier New"><span lang=EN-GB
style='font-size:10.0pt;font-family:"Courier New"'> home =
getenv("HOME");<o:p></o:p></span></font></p>
<p class=MsoNormal><font size=2 face="Courier New"><span lang=EN-GB
style='font-size:10.0pt;font-family:"Courier New"'> if (home
!= NULL) {<o:p></o:p></span></font></p>
<p class=MsoNormal><font size=2 face="Courier New"><span lang=EN-GB
style='font-size:10.0pt;font-family:"Courier New"'>
/* If possible chdir to home directory so core file<o:p></o:p></span></font></p>
<p class=MsoNormal><font size=2 face="Courier New"><span lang=EN-GB
style='font-size:10.0pt;font-family:"Courier New"'>
could be written. If it fails, don't worry. </span></font><font size=2
face="Courier New"><span style='font-size:10.0pt;font-family:"Courier New"'>*/<o:p></o:p></span></font></p>
<p class=MsoNormal><font size=2 face="Courier New"><span style='font-size:10.0pt;
font-family:"Courier New"'> (void)chdir(home);<o:p></o:p></span></font></p>
<p class=MsoNormal><font size=2 face="Courier New"><span style='font-size:10.0pt;
font-family:"Courier New"'><o:p> </o:p></span></font></p>
<p class=MsoNormal><font size=2 face="Courier New"><span style='font-size:10.0pt;
font-family:"Courier New"'>is the key. </span></font><font size=2
face="Courier New"><span lang=EN-GB style='font-size:10.0pt;font-family:"Courier New"'>Should
the chdir be done *<b><span style='font-weight:bold'>before</span></b>* the
call to auth_client_put_user_env()? I’m not familiar with the internal
workings of the Dovecot LDA, so I won’t suggest a proper fix. Who
will…<o:p></o:p></span></font></p>
<p class=MsoNormal><font size=2 face="Courier New"><span lang=EN-GB
style='font-size:10.0pt;font-family:"Courier New"'><o:p> </o:p></span></font></p>
<p class=MsoNormal><font size=2 face="Courier New"><span lang=EN-GB
style='font-size:10.0pt;font-family:"Courier New"'>As for the mal-formed
headers, I’ll take a look at it later.<o:p></o:p></span></font></p>
<p class=MsoNormal><font size=2 face="Courier New"><span lang=EN-GB
style='font-size:10.0pt;font-family:"Courier New"'><o:p> </o:p></span></font></p>
<p class=MsoNormal><font size=2 face="Courier New"><span lang=EN-GB
style='font-size:10.0pt;font-family:"Courier New"'>Mark<o:p></o:p></span></font></p>
<p class=MsoNormal><font size=2 face="Courier New"><span lang=EN-GB
style='font-size:10.0pt;font-family:"Courier New"'><o:p> </o:p></span></font></p>
<p class=MsoNormal><font size=2 face="Courier New"><span lang=EN-GB
style='font-size:10.0pt;font-family:"Courier New"'>#0 i_error
(format=0x80ac5f7 "open(%s) failed: %m") at failures.c:203<o:p></o:p></span></font></p>
<p class=MsoNormal><font size=2 face="Courier New"><span lang=EN-GB
style='font-size:10.0pt;font-family:"Courier New"'>#1 0x0809f900 in
dotlock_create (path=0x9ece2c0 "ruijs.cc/test//.dovecot.lda-dupes",
dotlock=0x9edfc48, flags=Variable "flags" is not available.<o:p></o:p></span></font></p>
<p class=MsoNormal><font size=2 face="Courier New"><span lang=EN-GB
style='font-size:10.0pt;font-family:"Courier New"'>) at file-dotlock.c:265<o:p></o:p></span></font></p>
<p class=MsoNormal><font size=2 face="Courier New"><span lang=EN-GB
style='font-size:10.0pt;font-family:"Courier New"'>#2 0x0809fb71 in file_dotlock_open
(set=0x80b9c90, path=0x9ece2c0 "ruijs.cc/test//.dovecot.lda-dupes",
flags=0, dotlock_r=0x9ee7920) at file-dotlock.c:614<o:p></o:p></span></font></p>
<p class=MsoNormal><font size=2 face="Courier New"><span lang=EN-GB
style='font-size:10.0pt;font-family:"Courier New"'>#3 0x08056ec5 in
duplicate_new (path=0x9ece2c0 "ruijs.cc/test//.dovecot.lda-dupes") at
duplicate.c:157<o:p></o:p></span></font></p>
<p class=MsoNormal><font size=2 face="Courier New"><span lang=EN-GB
style='font-size:10.0pt;font-family:"Courier New"'>#4 0x080571c6 in
duplicate_mark (id=0x9ece270, id_size=55, user=0xbf9edb45
"test@ruijs.cc", time=1162163205) at duplicate.c:195<o:p></o:p></span></font></p>
<p class=MsoNormal><font size=2 face="Courier New"><span lang=EN-GB
style='font-size:10.0pt;font-family:"Courier New"'>#5 0x080573c9 in
mail_send_rejection (mail=0x9ede7e0, recipient=0xbf9edb45
"test@ruijs.cc", reason=0x9edc218 "Quota exceeded") at
mail-send.c:51<o:p></o:p></span></font></p>
<p class=MsoNormal><font size=2 face="Courier New"><span lang=EN-GB
style='font-size:10.0pt;font-family:"Courier New"'>#6 0x08056c51 in main
(argc=5, argv=0xbf9ec5d4) at deliver.c:595<o:p></o:p></span></font></p>
<p class=MsoNormal><font size=2 face="Courier New"><span lang=EN-GB
style='font-size:10.0pt;font-family:"Courier New"'><o:p> </o:p></span></font></p>
</div>
</body>
</html>