#13660 [Opn->Fbk]: store extra data in db file on create
| From: | kalowsky@php.net | Date: | Wed, 28 Aug 2002 16:57:41 +0000 |
| Subject: | #13660 [Opn->Fbk]: store extra data in db file on create | ||
| References: | 1 | Groups: | php.bugs |
| Request: | Send a blank email to php-bugs+get-18065@lists.php.net to get a copy of this message | ||
ID: 13660
Updated by: kalowsky@php.net
Reported By: pierre-alain.joye@wanadoo.fr
-Status: Open
+Status: Feedback
Bug Type: DBM/DBA related
Operating System: Linux kernel 2.4.10 i686
PHP Version: 4.0.6
New Comment:
think you can try a recent non-stable snapshot?
Previous Comments:
------------------------------------------------------------------------
[2002-06-11 08:25:08] davidtaylor@pobox.com
For anyone else with this problem:
Apparently calling the optimize function immediately after the create
will set everything back to nulls so the script itself is removed:
$dbRC = dba_optimize($dbID);
I would still like to know how the default size is determined of the
database file. I guess I will look for that info on GNU sites though.
------------------------------------------------------------------------
[2002-05-29 09:22:48] davidtaylor@pobox.com
I have seen the same thing. It only seems to happen to me when I am
including other php files. If I take out all require()'s, the db is
zero'ed out again.
Any suggestions?
------------------------------------------------------------------------
[2001-10-13 11:49:31] pierre-alain.joye@wanadoo.fr
Show the script below the text.
When I create a new db file, extras data has been stored.
In all cases, it was the script itself (ask me if you need
the new db file directly).
I think it's a bug (or a new backup feature ;).
Config details :
gdbm 1.8.0
libc6
kernel 2.4.10
data on a reiserfs partition
Is it due to a default filesize ?
If yes do you make a zero fill of the extra memory used ?
<?
$id = dba_open("/tmp/test2.db","n","gdbm");
if(!$id){
echo "Erreur dba_open";
exit;
}
dba_replace("key","This a test!",$id);
if(dba_exists("key",$id)){
echo dba_fetch("key",$id);
}else{
echo "Not found";
}
dba_close($id);
?>
------------------------------------------------------------------------
--
Edit this bug report at http://bugs.php.net/?id=13660&edit=1