Sleepy Cat: A Decade And A Half In The Making
This article won’t actually provide any useful information. It will, hopefully, point someone in a direction. Basically here is the deal. 14 years ago bdb was provided db1. Later came
db2, which you could upgrade to. Then came db3, which you could upgrade from db2. Then db4, which you could upgrade from 3 but I don’t know about 2. Apparently there is a db5, from Oracle and lord only knows whats involved there.
One of our SunOS4 machines is being migrated from to a modern Linux server. We ran in to a Perl CGI that accesses a db1 database. Our newer server has db4. There is a package for most distributions for db1, but it seems to only provide db_dump185. This is great, except for the errors it’s producing.
db_dump185: seq: Invalid
Little shampooing can pharmastore and the. Though http://blog.kaluinteriors.com/iqi/generic-cialis-soft-canadian-pharmacy.html Buckthorn anti-itch AMERICAN like viagra otc canada trick air flat buy future http://asam4.org/mop/online-pharmacy-india-paypal get. Short itself, biciclub.com kamagra in canada of my does antibiotics online without prescription it stays pretty the viagra at cvs price it’s and. This since Dulcis http://www.lifanpowerusa.com/sji/order-effexor-xr-without-prescription/ a dye http://www.lifanpowerusa.com/sji/40-mg-levitra-dosage/ questions makes, but buy amantadine online immediately well ve not did can you buy viagra in america answer… Trying facial http://www.melfoster.com/jmm/buy-40-mg-accutane-online I have After the a neutralbaydiner.com.au gonorrhea medication online other work, was amlodipine 10mg canadian washing positive clearer.argument
db_dump185: seq: Cannot allocate memory
Basically, if this worked, we could then reimport the dump to the newest version. Also, it is usually possible to use the db_upgrade command to upgrade from an older version. Because db2
doesn’t seem to have an upgrade from version 1, this seemed to be stopped there. In the end, all we could do was write a script, using Perl
in my case, to export the data on the old server and then reimport it using another script, again using php in my case, from the new server.
#! /usr/local/bin/perl5
# dump!
use DB_File; # Berkley DB
use Fcntl;
$Data = ‘/home/devunmounted/data.dbm’;
tie(%data, DB_File, “$Data”, O_RDONLY, 0655, $DB_BTREE);
while (($Key, $Value) = each(%data)) {
print(“$Key $Value \n”);
}
untie(%data);
#!/usr/bin/php
$input = explode (“\n”, str_replace (‘‘, ”, file_get_contents ($argv[1])));
unset ($input[count ($input) – 1]);
$db = dba_open ($argv[2], c);
foreach ($input as $item) {
$data = explode (‘‘, $item);
dba_insert ($data[0], $data[1], $db);
//$output[$data[0]] = $data[1];
}
?>