After an evaluation, GNOME has moved from Bugzilla to GitLab. Learn more about GitLab.
No new issues can be reported in GNOME Bugzilla anymore.
To report an issue in a GNOME project, go to GNOME GitLab.
Do not go to GNOME Gitlab for: Bluefish, Doxygen, GnuCash, GStreamer, java-gnome, LDTP, NetworkManager, Tomboy.
Bug 339146 - address book missing on first start
address book missing on first start
Status: RESOLVED FIXED
Product: evolution
Classification: Applications
Component: Contacts
2.10.x (obsolete)
Other Linux
: Normal normal
: ---
Assigned To: evolution-addressbook-maintainers
Evolution QA team
Depends on:
Blocks:
 
 
Reported: 2006-04-20 10:00 UTC by Sebastien Bacher
Modified: 2007-04-26 14:55 UTC
See Also:
GNOME target: ---
GNOME version: 2.17/2.18


Attachments
Potential fix (664 bytes, patch)
2007-01-26 17:07 UTC, Ross Burton
none Details | Review

Description Sebastien Bacher 2006-04-20 10:00:33 UTC
That bug has been described on https://launchpad.net/distros/ubuntu/+source/evolution/+bug/38016

"When evolution is started for the first time by a new user, it complaines about a missing address book file. After that, evolution starts up normally, and the error isn't shown on next startup.
...
>> It'd probably help if you'd make a screenshot of that dialog.
...
OK, a screenshot of the error dialog is at http://mills.free.fr/screenshot.png
...
> Could you provide informations about what the dialog ask for when you get the message?
...
It doesn't ask for anything, the dialog comes up, and once you've clicked on OK you never see or hear of it again, and everything works normally."
Comment 1 Devashish Sharma 2006-05-15 11:17:45 UTC
I assume eds is runnung.
Run both evolution and eds from terminal and attach the terminal messages when this happens to the bug.
Comment 2 André Klapper 2006-09-14 18:25:22 UTC
seb, is this still an issue? any updates?
Comment 3 Sebastien Bacher 2006-09-14 19:20:50 UTC
That is still happening with GNOME 2.16.0:

evolution doesn't print any message about that, from evolution-data-server:

when starting evolution:
"cal = 0x5368c0
cal = 0x536920
impl_GNOME_Evolution_Addressbook_BookFactory_getBook
 + file:///home/ubuntu/.evolution/addressbook/local/system
 => 0x5369e0
impl_GNOME_Evolution_Addressbook_Book_open (0x5369e0)

(evolution-data-server:31147): libebook-WARNING **: "e_book_get_book_view" on book before "e_book_open"
cal = 0x53af00
cal = 0x536a40"

when switching to the contacts component:
"impl_GNOME_Evolution_Addressbook_BookFactory_getBook
 + file:///home/ubuntu/.evolution/addressbook/local/system
 => 0x536b60
impl_GNOME_Evolution_Addressbook_Book_open (0x536b60)
in server_log_handler

(evolution-data-server:31147): libebookbackend-WARNING **: libdb error: DB->put: attempt to modify a read-only database
in server_log_handler

(evolution-data-server:31147): libebookbackend-WARNING **: e_book_backend_file_maybe_upgrade_db failed"


It happens everytime after deleting the .evolution directory and restarting evolution
Comment 4 Ross Burton 2007-01-26 17:06:16 UTC
This is caused by BDB changing behaviour between 4.1.25 (the statically linked copy) and 4.3.29 (in Ubuntu).  They actually are enforcing previously documented behaviour but 4.1.25 wasn't as strict.

e_book_backend_file_load_source() creates a DB handle with db_create() and then tries to db->open().  If that fails, it tries again with a different set of options, creates the parent folders, as relevant.  Eventually it will generally succeed to open the database.

However, with the behaviour change, if db->open() returns an error, the handle should be disposed of and cannot be used again.  Thus, when the first attempt to open the file fails, the handle is invalid.  The second attempt is useless and will fail again.

That is my theory anyway. I'm about to attach a patch for someone else to replicate this problem with and to verify that it cures it for them too.
Comment 5 Ross Burton 2007-01-26 17:07:06 UTC
Created attachment 81276 [details] [review]
Potential fix

If this fix works then the same change needs to be made a few times as the re-open() happens more than once.
Comment 6 Ted Percival 2007-04-18 13:28:19 UTC
*** Bug 431006 has been marked as a duplicate of this bug. ***
Comment 7 Sebastien Bacher 2007-04-26 14:55:06 UTC
likely identic to bug #425512 which has been fixed now