niXforums Forum Index
 FAQFAQ   SearchSearch   MemberlistMemberlist   UsergroupsUsergroups   RegisterRegister 
 ProfileProfile   PreferencesPreferences   Log in to check your private messagesLog in to check your private messages   Log inLog in 
·  nixdoc.net ·  man pages ·  Linux HOWTOs ·  FreeBSD Tips ·  Forums
navigation Forum index » Databases » Berkeley DB
No return when DB open, how?
Post new topic   Reply to topic Page 1 of 1 [2 Posts] View previous topic :: View next topic
Author Message
William.P
*nix forums beginner


Joined: 24 Jun 2006
Posts: 4

PostPosted: Thu Jun 29, 2006 4:10 am    Post subject: Re: No return when DB open, how? Reply with quote

I found what's wrong here. Deadlock occur while i use dbd in
multithread, all ok after i remove all thread flag and bsd env.
Now I provide thread-safe mechanism outside the python bsddb
module, But I can't ensure data is safe while program exit abnormally,
DBEnv's recover cant ensure too,
At last, I have to change my database, only use bdb to provide
cache
Back to top
William.P
*nix forums beginner


Joined: 24 Jun 2006
Posts: 4

PostPosted: Mon Jun 26, 2006 11:58 am    Post subject: No return when DB open, how? Reply with quote

i use Python bsddb moudle
create env as above:
flags =
bsddb.db.DB_CREATE|bsddb.db.DB_INIT_TXN|bsddb.db.DB_INIT_MPOOL|bsddb.db.DB_THREAD|
bsddb.db.DB_RECOVER
dbenv = bsddb.db.DBEnv()
dbenv.open(self.__dbpath,flags)

create db:
db = bsddb.db.DB(dbenv)
db.open(self.filename,self.__listname,
bsddb.db.DB_HASH,
bsddb.db.DB_CREATE| bsddb.db.DB_THREAD)


after create some dbs(not the first time), the "DB.open" function never
return again, Sad
i don't know how could this happen, this problem will make me crazy, I
use bdb in multi-thread, but it will let all my thread dead
immediately,
what's wrong with bdb?
Back to top
Google

Back to top
Display posts from previous:   
Post new topic   Reply to topic Page 1 of 1 [2 Posts] View previous topic :: View next topic
The time now is Fri Nov 21, 2008 7:13 am | All times are GMT
navigation Forum index » Databases » Berkeley DB
Jump to:  

Similar Topics
Topic Author Forum Replies Last Post
No new posts Artica-postfix a full Open Source postfix management console dtouzeau Postfix 0 Mon Jun 16, 2008 9:46 pm
No new posts small GTK "Open file" dialog David Siroky Debian 0 Fri Jul 21, 2006 7:30 am
No new posts getimagesize():failed to open stream: sree PHP 0 Fri Jul 21, 2006 6:24 am
No new posts ImportError: libclntsh.so.10.1: cannot open shared object... gmax2006 python 2 Thu Jul 20, 2006 7:05 pm
No new posts Croation government goes Open Source B Gruff Suse 1 Wed Jul 19, 2006 11:47 pm

Mortgages | Loans | Duwayne Burnside | Hosting | Personal Loans
Copyright © 2004-2005 DeniX Solutions SRL
 
Other DeniX Solutions sites: Unix/Linux blog |  electronics forum |  medicine forum |  science forum | 
Privacy Policy


Powered by phpBB © 2001, 2005 phpBB Group
[ Time: 0.3866s ][ Queries: 20 (0.3065s) ][ GZIP on - Debug on ]