db-derby-user mailing list archives

Site index · List index
Message view « Date » · « Thread »
Top « Date » · « Thread »
From Sunitha Kambhampati <ksunitha...@gmail.com>
Subject Re: Occaisonal rollback on reboot
Date Mon, 29 Aug 2005 16:31:53 GMT
Scotty Allen wrote:

> Hi all,
> We've been having some problems with occasional rollbacks of an embedded
> database when the application is shutdown and restarted.  The pattern
> seems to be that you shut down our application, and then restart it, and
> the database is in the same state it was the time before last that you
> started it up.  In other words, the whole last session seems to have
> been lost.
> The main machine I've been seeing it on is a Mac OS X machine running
> tiger 10.4, with java 1.4.2.  We're running Derby, with
> derby.storage.fileSyncTransactionLog set to true.  However, we think we
> may have seen this problem on a Win XP machine as well.
> Has anyone seen anything like this?  Any thoughts about how to
> troubleshoot?  I just found derby.infolog.append tonight, so I'll start
> using that and see if I can see anything funky in the logs when it
> happens (I haven't seen anything yet, but haven't always checked the log
> prior to starting up, to know if the shutdown the last time was clean).
That seems strange.  I dont use Mac, but have not noticed any problems 
on windows/linux.. By default, on a restart( reboot), the database is 
guranteed to be in a consistent state, that is you will see  only the 
transactions that have been committed  and not result of any uncommitted 
transactions.  Maybe you have already checked this, but are you sure you 
are committing all the transactions in your last sesssion ?  that you 
dont see on a reboot.    Do you see any exceptions when running the 
program that may cause a commit to not be issued ?

You could set derby.language.logStatementText=true and 
derby.infolog.append=true and check the derby.log to look for commit 
debug statements in there and what statements are executed.

Also, are you using any other derby properties for the database  apart 
from the derby.storage.fileSyncTransaction:Log=true  ?


> This whole problem feels very much like a transaction log is not getting
> committed and then is getting lost, or something of that nature.  Should
> we be doing anything special on system shutdown, to make sure everything
> gets synced properly?
> Thanks,
> Scotty

View raw message