cvt_cyrusdb fail to convert deliver.db created by cyrus21-common

Bug #53496 reported by Etienne Goyer
4
Affects Status Importance Assigned to Milestone
cyrus-imapd-2.2 (Ubuntu)
Invalid
Medium
Unassigned

Bug Description

Hi,

When upgrading from cyrus21-common to cyrus-common-2.2, the cvt_cyrusdb included in cyrus-common-2.2 fail to convert the deliver.db file created by cyrus22-common. I believe this may be related to cvt_cyrusdb being linked to a different version of libdb.

The output of running cvt_cyrusdb from cyrus-common-2.2 on a deliver.db created by cyrus2.2-common is the following :

------------------
etienne@morbo:~$ sudo cvt_cyrusdb /var/lib/cyrus/deliver.db berkeley /var/lib/cyrus/deliver.db.flat flat
Converting from /var/lib/cyrus/deliver.db (berkeley) to /var/lib/cyrus/deliver.db.flat (flat)
fatal error: can't open old database
-------------------

Here is the output of db4.3_dump on the deliver.db file in question :

-------------------
etienne@morbo:~$ sudo db4.3_dump /var/lib/cyrus/deliver.db
VERSION=3
format=bytevalue
type=btree
db_pagesize=4096
HEADER=END
DATA=END
---------------------

Using ldd on cvt_cyrusdb from cyrus22-common :

---------------------
etienne@morbo:~$ dpkg -S /usr/sbin/cvt_cyrusdb
cyrus21-common: /usr/sbin/cvt_cyrusdb
etienne@morbo:~$ ldd /usr/sbin/cvt_cyrusdb
        linux-gate.so.1 => (0xffffe000)
        libsasl2.so.2 => /usr/lib/libsasl2.so.2 (0xb7fa8000)
        libresolv.so.2 => /lib/tls/i686/cmov/libresolv.so.2 (0xb7f95000)
        libdb3.so.3 => /usr/lib/libdb3.so.3 (0xb7eec000)
        libssl.so.0.9.8 => /usr/lib/i686/cmov/libssl.so.0.9.8 (0xb7eaf000)
        libcrypto.so.0.9.8 => /usr/lib/i686/cmov/libcrypto.so.0.9.8 (0xb7d81000)
        libc.so.6 => /lib/tls/i686/cmov/libc.so.6 (0xb7c52000)
        libdl.so.2 => /lib/tls/i686/cmov/libdl.so.2 (0xb7c4f000)
        libz.so.1 => /usr/lib/libz.so.1 (0xb7c3b000)
        /lib/ld-linux.so.2 (0xb7fca000)
---------------------

Using ldd on cvt_cyrusdb from cyrus-common-2.2 :

---------------------
etienne@morbo:~$ dpkg -S /usr/sbin/cvt_cyrusdb
cyrus-common-2.2: /usr/sbin/cvt_cyrusdb
etienne@morbo:~$ ldd /usr/sbin/cvt_cyrusdb
        linux-gate.so.1 => (0xffffe000)
        libsasl2.so.2 => /usr/lib/libsasl2.so.2 (0xb7f8d000)
        libresolv.so.2 => /lib/tls/i686/cmov/libresolv.so.2 (0xb7f7a000)
        libdb-4.3.so => /usr/lib/libdb-4.3.so (0xb7e9d000)
        libssl.so.0.9.8 => /usr/lib/i686/cmov/libssl.so.0.9.8 (0xb7e60000)
        libcrypto.so.0.9.8 => /usr/lib/i686/cmov/libcrypto.so.0.9.8 (0xb7d32000)
        libc.so.6 => /lib/tls/i686/cmov/libc.so.6 (0xb7c03000)
        libdl.so.2 => /lib/tls/i686/cmov/libdl.so.2 (0xb7c00000)
        libz.so.1 => /usr/lib/libz.so.1 (0xb7bec000)
        /lib/ld-linux.so.2 (0xb7faf000)
----------------------

We can see that the version of Berkeley db cvt_cyrusdb is liked against differ. I do not know anything about the bdb API, so I cannot presume this is actually the cause of the incompatibility, but it appear plausible to me.

I understand that the data stored in deliver.db is volatile and need to purged periodically. Thus, I suppose an acceptable work-around for this problem could be to simply move the file away and let Cyrus start fresh with an empty one.

If fixing cvt_cyrusdb in cyrus-common-2.2 to handle db3 file produced by cyrus21-common is not a possibility, we might want to document it in /usr/share/doc/cyrus-common-2.2/README.Debian.database.gz : either convert *before* the upgrade, or start with a fresh deliver.db.

Revision history for this message
Lionel Le Folgoc (mrpouit) wrote :

Thank you for taking the time to report this bug and helping to make Ubuntu better. You reported this bug a while ago and there hasn't been any activity in it recently. We were wondering is this still an issue for you? Thanks in advance.

Changed in cyrus-imapd-2.2:
importance: Undecided → Medium
status: New → Incomplete
Revision history for this message
Etienne Goyer (etienne-goyer-outlands) wrote :

cyrus21-common and friends have been removed from gutsy. I presume this bug can this be closed, as it is unlikely to be worth a fix in older releases.

The problem remain valid, though.

Revision history for this message
Gareth Fitzworthington (mapping-gp-deactivatedaccount) wrote :

Closing. To reopen the report you can click on the current status, under the Status column, and change the Status back to "New". Thanks again!

Changed in cyrus-imapd-2.2:
status: Incomplete → Invalid
To post a comment you must log in.
This report contains Public information  
Everyone can see this information.

Other bug subscribers

Remote bug watches

Bug watches keep track of this bug in other bug trackers.