473,386 Members | 1,753 Online
Bytes | Software Development & Data Engineering Community
Post Job

Home Posts Topics Members FAQ

Join Bytes to post your question to a community of 473,386 software developers and data experts.

berkeley db

Hi I'm writing multiprocess server which has to gather information from
the clients and store it to berkeley db. The problem is that BerkeleyDB
adds entries to the base only if they are added from the same proces
within was created all is ok. But when I fork() it the code runs without
any error, but DB adds nothnig :(. How can I solve this problem.

Thank you in advance
--
Wojtek W.
GG: 2182255
Linux-User #341555

Nov 14 '05 #1
2 1922
Wojtek <ad***********@o2.pl> scribbled the following:
Hi I'm writing multiprocess server which has to gather information from
the clients and store it to berkeley db. The problem is that BerkeleyDB
adds entries to the base only if they are added from the same proces
within was created all is ok. But when I fork() it the code runs without
any error, but DB adds nothnig :(. How can I solve this problem.


This has nothing to do with C. Please ask in comp.unix.programmer or a
system-specific newsgroup.

--
/-- Joona Palaste (pa*****@cc.helsinki.fi) ------------- Finland --------\
\-------------------------------------------------------- rules! --------/
"No, Maggie, not Aztec, Olmec! Ol-mec!"
- Lisa Simpson
Nov 14 '05 #2
Berkeley DB handles cannot be shared across a fork, each forked child
should open the DB database environment separately. (You'll almost
certainly need a database environment in the case of a multi-process
application.)

Regards,
--keith

=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=
Keith Bostic bo****@sleepycat.com
Sleepycat Software Inc. keithbosticim (ymsgid)
118 Tower Rd. +1-781-259-3139
Lincoln, MA 01773 http://www.sleepycat.com

Nov 14 '05 #3

This thread has been closed and replies have been disabled. Please start a new discussion.

Similar topics

0
by: Harald Massa | last post by:
I found Berkeley DB XML while searching for XML-Databases. I want to use it from PYHTON - and I found examples.py in the distribution. But... examples.py tries to import from dbxml import *...
1
by: Dan Olsen | last post by:
I am trying to install and use Berkeley XML DB with Python. However, I keep getting errors. The weblog at Sleepy Cat said to build Python with the latest version of Berkeley DB. I can't get it to...
2
by: Oliver Peek | last post by:
Hi all, Probably my fault, I'm opening a Berkeley DB file, iterating through and deleting keys, well making an attempt. I get this error when I try to delete. ---error Traceback (most...
4
by: janeaustine50 | last post by:
It doesn't seem like the python 2.4(and the recent 2.4.1) support berkeley db 4.3. (4.3 fixes some deadlock bugs I occasionally encounter using 4.2.) bsddb3(at pybsddb.sf.net) already supports...
0
by: Martin | last post by:
Hi Anyone have a code example which shows how to access a Berkeley Database from C#? Thanks. Martin
0
by: gemini_kj | last post by:
hi, i am begineer in Berkeley DB , i need some examples which can ilustrate how to store objects in berkely DB. if anybody has plz send on the forum or either mail me at kunal.jethwa@gmail.com ...
2
by: Dan M | last post by:
I'm working on a script that will interface with sendmail on my FreeBSD box. I'm trying to read my access.db file (yes, it's for a quick and dirty SMTP-after-POP application). I'm trying: import...
0
by: Pascal Schmitt | last post by:
Hello! Is there an existant .NET Wrapper for Sleepycat Berkeley DB XML 2.0 (see http://sleepycat.com/products/xml.shtml)? It seems to be the XML-DB of my dreams, but has only a Java-Wrapper...
3
by: HerbAsher | last post by:
Hi! I have some questions. I'm evaluating berkeley db as a embeddable storage engine for a project I'm working on. My questions: 1. Now that Berkeley DB is part of Oracle, is it still...
0
by: Charles Arthur | last post by:
How do i turn on java script on a villaon, callus and itel keypad mobile phone
0
by: aa123db | last post by:
Variable and constants Use var or let for variables and const fror constants. Var foo ='bar'; Let foo ='bar';const baz ='bar'; Functions function $name$ ($parameters$) { } ...
0
by: ryjfgjl | last post by:
If we have dozens or hundreds of excel to import into the database, if we use the excel import function provided by database editors such as navicat, it will be extremely tedious and time-consuming...
0
by: ryjfgjl | last post by:
In our work, we often receive Excel tables with data in the same format. If we want to analyze these data, it can be difficult to analyze them because the data is spread across multiple Excel files...
0
by: emmanuelkatto | last post by:
Hi All, I am Emmanuel katto from Uganda. I want to ask what challenges you've faced while migrating a website to cloud. Please let me know. Thanks! Emmanuel
1
by: nemocccc | last post by:
hello, everyone, I want to develop a software for my android phone for daily needs, any suggestions?
1
by: Sonnysonu | last post by:
This is the data of csv file 1 2 3 1 2 3 1 2 3 1 2 3 2 3 2 3 3 the lengths should be different i have to store the data by column-wise with in the specific length. suppose the i have to...
0
by: Hystou | last post by:
There are some requirements for setting up RAID: 1. The motherboard and BIOS support RAID configuration. 2. The motherboard has 2 or more available SATA protocol SSD/HDD slots (including MSATA, M.2...
0
marktang
by: marktang | last post by:
ONU (Optical Network Unit) is one of the key components for providing high-speed Internet services. Its primary function is to act as an endpoint device located at the user's premises. However,...

By using Bytes.com and it's services, you agree to our Privacy Policy and Terms of Use.

To disable or enable advertisements and analytics tracking please visit the manage ads & tracking page.