unexpunge segfaults with -l on some mailboxes
David R Bosso
dbosso+lists.cyrus at lsit.ucsb.edu
Mon Mar 23 19:08:47 EDT 2009
--On March 13, 2009 10:18:53 AM -0300 Patrick Boutilier
<boutilpj at ednet.ns.ca> wrote:
<snip>
>> This will be real easy to test though. I will just run ipurge on a
>> subfolder of my mailbox and see if it corrupts it. :-)
FWIW we see the same corruption here with ipurge. We use ipurge to clean
out old messages from a spam box for each user. We've worked around it
currently by reconstructing the box after the ipurge which adds a lot of
work to our nightly maintenance.
I'd love to see a fix for this.
-David
> I can duplicate the corruption by following steps similar to this report:
>
> http://archives.devshed.com/forums/networking-100/cyr-expire-sigsegv-2146
> 878.html
>
>
> Current directory here is /var/imap/metadata/G/user/boutilpj/Testmail
>
>
> Clean mailbox:
>
>
> [cyrus at student2 Testmail]$ ll
> total 60
> -rw------- 1 cyrus cyrus 49612 Mar 13 10:03 cyrus.cache
> -rw------- 1 cyrus cyrus 189 Mar 13 10:03 cyrus.header
> -rw------- 1 cyrus cyrus 3792 Mar 13 10:03 cyrus.index
>
>
> Quick way to show number of messages in the folder:
>
>
>
> [cyrus at student2 Testmail]$ cat cyrus.cache |grep -a Prec|wc -l
> 42
>
>
> Delete 11 messages through IMAP client:
>
> [cyrus at student2 Testmail]$ ll
> total 64
> -rw------- 1 cyrus cyrus 49612 Mar 13 10:03 cyrus.cache
> -rw------- 1 cyrus cyrus 1064 Mar 13 10:05 cyrus.expunge
> -rw------- 1 cyrus cyrus 189 Mar 13 10:03 cyrus.header
> -rw------- 1 cyrus cyrus 2824 Mar 13 10:05 cyrus.index
>
>
> Run ipurge with a number high enough not to delete anything. I purge
> only sees 31 messages and removes them from cyrus.cache:
>
>
> [cyrus at student2 Testmail]$ /usr/local/cyrus/bin/ipurge -f -d 2333
> user.boutilpj.Testmail
> Working on user.boutilpj.Testmail...
> total messages 31
> total bytes 539400
> Deleted messages 0
> Deleted bytes 0
> Remaining messages 31
> Remaining bytes 539400
>
> [cyrus at student2 Testmail]$ ll
> total 48
> -rw------- 1 cyrus cyrus 36652 Mar 13 10:08 cyrus.cache
> -rw------- 1 cyrus cyrus 1064 Mar 13 10:05 cyrus.expunge
> -rw------- 1 cyrus cyrus 189 Mar 13 10:03 cyrus.header
> -rw------- 1 cyrus cyrus 2824 Mar 13 10:08 cyrus.index
>
> [cyrus at student2 Testmail]$ cat cyrus.cache |grep -a Prec|wc -l
> 31
>
>
> Run cyr_expire and corruption occurs:
>
> [cyrus at student2 Testmail]$ /usr/local/cyrus/bin/cyr_expire -E 333 -X 7 -p
> user.boutilpj.Testmail -v
> Expunging deleted messages in mailboxes older than 7 days
>
> Expunged 0 out of 33 messages from 1 mailboxes
> [cyrus at student2 Testmail]$ ll
> total 96
> -rw------- 1 cyrus cyrus 36652 Mar 13 10:08 cyrus.cache
> -rw------- 1 cyrus cyrus 37852 Mar 13 10:15 cyrus.cache.NEW
> -rw------- 1 cyrus cyrus 1064 Mar 13 10:05 cyrus.expunge
> -rw------- 1 cyrus cyrus 272 Mar 13 10:15 cyrus.expunge.NEW
> -rw------- 1 cyrus cyrus 189 Mar 13 10:03 cyrus.header
> -rw------- 1 cyrus cyrus 2824 Mar 13 10:08 cyrus.index
> -rw------- 1 cyrus cyrus 2824 Mar 13 10:15 cyrus.index.NEW
>
>
> Mar 13 10:15:40 student2 cyr_expire[8725]: IOERROR: reading cache record
> for user.boutilpj.Testmail: item 1 has bogus offset 576450680 of 36652
> for 2/11; mailbox needs a reconstruct
>
>
>
>
>>
>>> Bron.
>>
>> ----
>> Cyrus Home Page: http://cyrusimap.web.cmu.edu/
>> Cyrus Wiki/FAQ: http://cyrusimap.web.cmu.edu/twiki
>> List Archives/Info: http://asg.web.cmu.edu/cyrus/mailing-list.html
>
More information about the Info-cyrus
mailing list