db-derby-user mailing list archives

Site index · List index
Message view « Date » · « Thread »
Top « Date » · « Thread »
From "Inns, Jeff" <ji...@extol.com>
Subject RE: Metadata Container RAF Exception
Date Thu, 06 Mar 2008 13:13:06 GMT
Fellas,
Thanks for the suggestions.  The "M:" is the drive letter of the second
partition on the disk (it has two "C:" and "M:").

I think I will pursue the "anti-virus", "journaling" theory.  This looks
promising.

Again - thanks for all your help.

Jeff

-----Original Message-----
From: Thomas.Nielsen@Sun.COM [mailto:Thomas.Nielsen@Sun.COM] 
Sent: Wednesday, March 05, 2008 2:38 PM
To: Derby Discussion
Subject: Re: Metadata Container RAF Exception

Jeffrey,

With "M:" as your drive letter, I'm guessing you have the files on a 
mapped network share? Are you using Samba?
There used to be file locking problems with Samba. Not sure whether they

have been fixed or not, nor what versions were affected/fixed. Google is

your friend here. The Samba locking problems would probably materialize 
like what you see in java. Might be worth checking if you're using
Samba.

Like Jim suggests, some process on the/that machine could actually be 
accessing the file. I agree antivirus software is a good guess - even 
more so if it's mapped from another windows host.
Or it could be some journalling sw/task running on the/that host 
(new/radically changed file, happens within 1hr after compress)?

HTH,
Thomas

Jim Newsham wrote:
>
> It looks to me like an external process is getting a lock on the file,

> which prevents Derby/Java from accessing it. The hints are:
>
> (a) the error message is generated in native code (at 
> java.io.RandomAccessFile.open(Native Method))
>
> (b) searching google for the exact error message produces a lot of 
> hits that are all related to Windows OS, and none related to Java
>
> When it comes to native code I don't know much. Such as, under what 
> circumstances does the OS (or do clients) lock files so that they 
> cannot be read. Could it be a virus scanner?
>
> Jim
>
>
------------------------------------------------------------------------
>
> *From:* Inns, Jeff [mailto:jinns@extol.com]
> *Sent:* Wednesday, March 05, 2008 5:51 AM
> *To:* derby-user@db.apache.org
> *Subject:* Metadata Container RAF Exception
>
> Hi folks,
>
> We've run into this problem intermittently and were wondering if you 
> can suggest some ideas about what the problem may be or configuration 
> changes that might help alleviate the problem. By intermittently, I 
> mean 3 times in the past two months. The software runs 24x7, so it 
> occurs very infrequently when compared to the number of accesses that 
> are made to the database.
>
> Here's the pertinent environment information:
>
> Platform: Windows 2003 Server 64 bit
>
> JVM: jre-1_5_0_14-windows-amd64
>
> Derby: 10.2.2
>
> Note - we are have our software running on multiple platforms (RHEL, 
> Windows 32bit/64bit/XP/Server, Mac, i5/OS), and have only experienced 
> this exception on Windows 2003 Server 64 bit.
>
> About an hour before we received this exception, we compressed the 
> database, reducing the total size of the DB from 10GB to 1.5GB. The 
> largest database file was about 350MB (I'm not sure about the number 
> of records).
>
> Now for the error:
>
> java.sql.BatchUpdateException: Meta-data for Container 
> org.apache.derby.impl.store.raw.data.RAFContainer@12406ab2 could not 
> be accessed
>
> at org.apache.derby.impl.jdbc.EmbedStatement.executeBatch(Unknown
Source)
>
> at
com.extol.util.jdbc.CacheStatement.executeBatch(CacheStatement.java:51)
>
> <<our code>> <<snip>>
>
> ERROR XSDG3: Meta-data for Container 
> org.apache.derby.impl.store.raw.data.RAFContainer@12406ab2 could not 
> be accessed
>
> at org.apache.derby.iapi.error.StandardException.newException(Unknown 
> Source)
>
> at org.apache.derby.impl.store.raw.data.RAFContainer.run(Unknown
Source)
>
> at java.security.AccessController.doPrivileged(Native Method)
>
> at 
>
org.apache.derby.impl.store.raw.data.RAFContainer.openContainer(Unknown 
> Source)
>
> at org.apache.derby.impl.store.raw.data.FileContainer.setIdent(Unknown

> Source)
>
> at 
> org.apache.derby.impl.store.raw.data.RAFContainer.setIdentity(Unknown 
> Source)
>
> at 
> org.apache.derby.impl.services.cache.CachedItem.takeOnIdentity(Unknown

> Source)
>
> at org.apache.derby.impl.services.cache.Clock.addEntry(Unknown Source)
>
> at org.apache.derby.impl.services.cache.Clock.find(Unknown Source)
>
> at org.apache.derby.impl.store.raw.data.CachedPage.writePage(Unknown 
> Source)
>
> at org.apache.derby.impl.store.raw.data.CachedPage.clean(Unknown
Source)
>
> at org.apache.derby.impl.services.cache.CachedItem.clean(Unknown
Source)
>
> at org.apache.derby.impl.services.cache.Clock.rotateClock(Unknown
Source)
>
> at org.apache.derby.impl.services.cache.Clock.findFreeItem(Unknown
Source)
>
> at org.apache.derby.impl.services.cache.Clock.find(Unknown Source)
>
> at 
> org.apache.derby.impl.store.raw.data.FileContainer.getUserPage(Unknown

> Source)
>
> at org.apache.derby.impl.store.raw.data.FileContainer.getPage(Unknown 
> Source)
>
> at 
>
org.apache.derby.impl.store.raw.data.BaseContainerHandle.getPage(Unknown

> Source)
>
> at org.apache.derby.impl.store.access.btree.ControlRow.Get(Unknown
Source)
>
> at org.apache.derby.impl.store.access.btree.ControlRow.Get(Unknown
Source)
>
> at 
>
org.apache.derby.impl.store.access.btree.BranchControlRow.getChildPageAt
Slot(Unknown 
> Source)
>
> at 
>
org.apache.derby.impl.store.access.btree.BranchControlRow.search(Unknown

> Source)
>
> at 
>
org.apache.derby.impl.store.access.btree.BranchControlRow.search(Unknown

> Source)
>
> at 
>
org.apache.derby.impl.store.access.btree.BranchControlRow.search(Unknown

> Source)
>
> at 
> org.apache.derby.impl.store.access.btree.BTreeController.doIns(Unknown

> Source)
>
> at 
>
org.apache.derby.impl.store.access.btree.BTreeController.insert(Unknown 
> Source)
>
> at 
>
org.apache.derby.impl.store.access.btree.index.B2IController.insert(Unkn
own 
> Source)
>
> at 
>
org.apache.derby.impl.sql.execute.IndexChanger.insertAndCheckDups(Unknow
n 
> Source)
>
> at org.apache.derby.impl.sql.execute.IndexChanger.doInsert(Unknown
Source)
>
> at org.apache.derby.impl.sql.execute.IndexChanger.insert(Unknown
Source)
>
> at org.apache.derby.impl.sql.execute.IndexSetChanger.insert(Unknown 
> Source)
>
> at org.apache.derby.impl.sql.execute.RowChangerImpl.insertRow(Unknown 
> Source)
>
> at 
>
org.apache.derby.impl.sql.execute.InsertResultSet.normalInsertCore(Unkno
wn 
> Source)
>
> at org.apache.derby.impl.sql.execute.InsertResultSet.open(Unknown
Source)
>
> at org.apache.derby.impl.sql.GenericPreparedStatement.execute(Unknown 
> Source)
>
> at org.apache.derby.impl.jdbc.EmbedStatement.executeStatement(Unknown 
> Source)
>
> at 
>
org.apache.derby.impl.jdbc.EmbedPreparedStatement.executeBatchElement(Un
known 
> Source)
>
> at org.apache.derby.impl.jdbc.EmbedStatement.executeBatch(Unknown
Source)
>
> <<our code>> <<snip>>
>
> java.io.FileNotFoundException: M:\database\xdb1\seg0\c1250.dat (The 
> process cannot access the file because it is being used by another 
> process)
>
> at java.io.RandomAccessFile.open(Native Method)
>
> at java.io.RandomAccessFile.<init>(RandomAccessFile.java:212)
>
> at org.apache.derby.impl.io.DirRandomAccessFile.<init>(Unknown Source)
>
> at org.apache.derby.impl.io.DirRandomAccessFile4.<init>(Unknown
Source)
>
> at org.apache.derby.impl.io.DirFile4.getRandomAccessFile(Unknown
Source)
>
> at org.apache.derby.impl.store.raw.data.RAFContainer.run(Unknown
Source)
>
> at java.security.AccessController.doPrivileged(Native Method)
>
> at 
>
org.apache.derby.impl.store.raw.data.RAFContainer.openContainer(Unknown 
> Source)
>
> at org.apache.derby.impl.store.raw.data.FileContainer.setIdent(Unknown

> Source)
>
> at 
> org.apache.derby.impl.store.raw.data.RAFContainer.setIdentity(Unknown 
> Source)
>
> at 
> org.apache.derby.impl.services.cache.CachedItem.takeOnIdentity(Unknown

> Source)
>
> at org.apache.derby.impl.services.cache.Clock.addEntry(Unknown Source)
>
> at org.apache.derby.impl.services.cache.Clock.find(Unknown Source)
>
> at org.apache.derby.impl.store.raw.data.CachedPage.writePage(Unknown 
> Source)
>
> at org.apache.derby.impl.store.raw.data.CachedPage.clean(Unknown
Source)
>
> at org.apache.derby.impl.services.cache.CachedItem.clean(Unknown
Source)
>
> at org.apache.derby.impl.services.cache.Clock.rotateClock(Unknown
Source)
>
> at org.apache.derby.impl.services.cache.Clock.findFreeItem(Unknown
Source)
>
> at org.apache.derby.impl.services.cache.Clock.find(Unknown Source)
>
> at 
> org.apache.derby.impl.store.raw.data.FileContainer.getUserPage(Unknown

> Source)
>
> at org.apache.derby.impl.store.raw.data.FileContainer.getPage(Unknown 
> Source)
>
> at 
>
org.apache.derby.impl.store.raw.data.BaseContainerHandle.getPage(Unknown

> Source)
>
> at org.apache.derby.impl.store.access.btree.ControlRow.Get(Unknown
Source)
>
> at org.apache.derby.impl.store.access.btree.ControlRow.Get(Unknown
Source)
>
> at 
>
org.apache.derby.impl.store.access.btree.BranchControlRow.getChildPageAt
Slot(Unknown 
> Source)
>
> at 
>
org.apache.derby.impl.store.access.btree.BranchControlRow.search(Unknown

> Source)
>
> at 
>
org.apache.derby.impl.store.access.btree.BranchControlRow.search(Unknown

> Source)
>
> at 
>
org.apache.derby.impl.store.access.btree.BranchControlRow.search(Unknown

> Source)
>
> at 
> org.apache.derby.impl.store.access.btree.BTreeController.doIns(Unknown

> Source)
>
> at 
>
org.apache.derby.impl.store.access.btree.BTreeController.insert(Unknown 
> Source)
>
> at 
>
org.apache.derby.impl.store.access.btree.index.B2IController.insert(Unkn
own 
> Source)
>
> at 
>
org.apache.derby.impl.sql.execute.IndexChanger.insertAndCheckDups(Unknow
n 
> Source)
>
> at org.apache.derby.impl.sql.execute.IndexChanger.doInsert(Unknown
Source)
>
> at org.apache.derby.impl.sql.execute.IndexChanger.insert(Unknown
Source)
>
> at org.apache.derby.impl.sql.execute.IndexSetChanger.insert(Unknown 
> Source)
>
> at org.apache.derby.impl.sql.execute.RowChangerImpl.insertRow(Unknown 
> Source)
>
> at 
>
org.apache.derby.impl.sql.execute.InsertResultSet.normalInsertCore(Unkno
wn 
> Source)
>
> at org.apache.derby.impl.sql.execute.InsertResultSet.open(Unknown
Source)
>
> at org.apache.derby.impl.sql.GenericPreparedStatement.execute(Unknown 
> Source)
>
> at org.apache.derby.impl.jdbc.EmbedStatement.executeStatement(Unknown 
> Source)
>
> at 
>
org.apache.derby.impl.jdbc.EmbedPreparedStatement.executeBatchElement(Un
known 
> Source)
>
> at org.apache.derby.impl.jdbc.EmbedStatement.executeBatch(Unknown
Source)
>
> <<our code>> <<snip>>
>
> Jeffrey Inns
>
> Application Support, Development
>
> EXTOL International, Inc.
>
> Web: www.extol.com <http://www.extol.com>
>
> Tech Support: 866.398.6524
>
> Direct Dial: 570.621.7879
>


Mime
View raw message