Aller au contenu

Photo

Database issue with Linux server


  • Veuillez vous connecter pour répondre
3 réponses à ce sujet

#1
Ondaderthad

Ondaderthad
  • Members
  • 6 messages
While developing the PLATEMAIL module  nwvault.ign.com/View.php we run into a problem with the databases growing to unacceptable sizes.

I am aware that Knat mentioned this problem in his implementation of NBDE
Here> nwvault.ign.com/View.php
Knat's comments (on page 2) was:
Attention:
I got several reports that DeleteCampaignDatabase doesn't work
right or at
all under linux.
NBDE won't work properly without this
function (database will grow RAPIDLY).
Nothing i can do about this, it's most
likely an engine bug. I do NOT
recommend to use NBDE under linux !


But that was a long time ago. I wonder if someone has found a solution since.

#2
Lightfoot8

Lightfoot8
  • Members
  • 2 535 messages
Are you useing Knat's system ?
The main problen as I understand it with Knat's system and the DB not being deleted is that the DB will incrsses in size by the full size of the active DB every time you change anything in it. 
The NWN DB does this on a single entry level.   If you change a entry in the DB it never deletes the old entry, It just adds a new one and marks the old one as unused.   This is a problem that happens with complex data typs in the DB.   Simple data types like an intenger actualy gets replaced in the DB and not duplicated.   Since Knats system uses just one large complex data type to store the DB, It basicly increases the DB by the size of all data every time it fails to delete the old DB befor flushing.  
You can run into so of the same problems with the standard system If you are constantly storing large data types.  It slows access to the DB but it is better so store more intengers then strings  from a DB growth stand point.
I do not know if it works with the linux version or not, But the windows version came with a utility to pack the data base back down.  it is called  DataPack.exe and is located in the utils folder in nwn  

#3
Ondaderthad

Ondaderthad
  • Members
  • 6 messages
Thanks for the reply.

The way I understand Knat's NBDE system is that it stores the complex item in memory until a "flush" command is given.

The flush deletes the old database and rewrites a new one.



This works very well under Windows but for some reason Linux never deletes the old file.

#4
Lightfoot8

Lightfoot8
  • Members
  • 2 535 messages
Yes, that is my understanding also.



I have not heard anything about that bug being fixed. It would be easy to test out however if you are running linux. Just create a new module and store a couple things in a DB and then delete the DB right after. just place the script in the on module load. run the module shut it down and check you data folder in the NWN folder for the DB. If it is still there they are still not getting deleted.