1

I'm migrating an existing website from Apache 2.2.4 on Gentoo 32-bit to Apache 2.2.27 on CentOS 64-bit. This particular site uses DBM for authentication with encrypted passwords.

On the old system if I type:

htdbm -l access.db

I get a list of the users in the file.

On the new system, the same command outputs:

Error opening database access.db
No such file or directory

I've checked permissions on access.db and I've tried running htdbm as root. It has to be a format error.

Then, I discovered that Apache hadn't been compiled with --with-berkeley-db, so I enabled that and recompiled Apache.

However, now the result is:

Dumping records from database -- access.db
    Username                         Comment
Total #records : 0

I know that this particular file contains 68 records.

Interestingly, this file is reported as:

access.db: Berkeley DB (Hash, version 7, native byte-order)

Whereas I found another BDB file that did work on this system, and it showed:

restricted.db: Berkeley DB (Hash, version 8, native byte-order)

What more can I do to find out why the first file can't be read? If it's the version, how can I convert the file to the newer version?

1 Answers1

0

My solution at this point is to use

db_dump 

on the old server, and

db_load

on the new server.

I presume I could do this all on the new server if I got an old version of the BDB libraries and compiled them in using the

 ---with-dbm

flag.

However, at this time since I have working versions in both places, this is the fastest solution for me right now.