Skip to Main Content

Berkeley DB Family

Announcement

For appeals, questions and feedback about Oracle Forums, please email oracle-forums-moderators_us@oracle.com. Technical questions should be asked in the appropriate category. Thank you!

BerkeleyDB.4.4 + Python 2.7 + bsddb3

919964Feb 25 2012 — edited Feb 28 2012
Hello ,i had to built a machine for a customer that requested me to install BerkeleyDB.4.4 on redhat , since the gcc version that redhat comes is different than they want to use i installed the compat librarie and built is running the following command:

env CC=/usr/bin/gcc44 CXX=/usr/bin/g++44 ./configure ...

After that i compiled Python2.7 and now they requested me to install bsddb3 , after i installed that they wanted to load the bsddb module but it was failing so i installed python-devel from redhat and ran the setup again for bsdbb3.

bsddb module still fails but i can load bsddb3 module:

[]# python
Python 2.7.2 (default, Jan 3 2012, 17:01:49)
[GCC 4.1.2 20080704 (Red Hat 4.1.2-51)] on linux2
Type "help", "copyright", "credits" or "license" for more information.
import bsddb3
bsddb3.__version__
'5.1.0'
bsddb3.db.version()
(4, 4, 20)
>>>


The problem is they are trying to run a script and that fails with the following message

Traceback (most recent call last):
File "dump-actors.py", line 4, in <module>
import SPackedFS
File "/path/SPackedFS.py", line 3, in <module>
import bsddb, sys, codecs, struct, os, random, re, string
File "/usr/local/lib/python2.7/bsddb/__init__.py", line 67, in <module>
import _bsddb
ImportError: No module named _bsddb

so they changed the script to use bsddb3 and they get this error:

Traceback (most recent call last):
File "dump-actors.py", line 64, in <module>
pfs = SPackedFS.PackedFS(index)
File "/path/SPackedFS.py", line 50, in __init__
self.db = bsddb3.btopen(db_file)
File "/usr/local/lib/python2.7/site-packages/bsddb3/__init__.py", line 379, in btopen
d.open(file, db.DB_BTREE, flags, mode)
bsddb3.db.DBNoSuchFileError: (2, 'No such file or directory')


Im not sure how to continue with this issue, any help would be really appreciated...Thanks in advance
Comments
Locked Post
New comments cannot be posted to this locked post.
Post Details
Locked on Mar 27 2012
Added on Feb 25 2012
1 comment
3,127 views