This discussion is archived
4 Replies Latest reply: Aug 6, 2012 7:55 PM by 953409 RSS

Environment invalid because of previous exception

953409 Newbie
Currently Being Moderated
Hi all,my program running a long time,suddenly occur an error,the following message:
java.lang.RuntimeException: Environment invalid because of previous exception: com.sleepycat.je.log.DbChecksumException: (JE 3.3.82) Read invalid log entry type: 46 lsn= 0x0/0x205c69 logSource=com.sleepycat.je.log.FileHandleSource@568ee2b9
+     at wisers.crawler.batch.store.ArticleStoreImpl.contains(ArticleStoreImpl.java:63)+
+     at wisers.crawler.batch.extractor.ListingExtractor.extract(ListingExtractor.java:93)+
+     at wisers.crawler.batch.processor.CrawlWorkerImpl.execute(CrawlWorkerImpl.java:276)+
+     at wisers.crawler.batch.schedule.JobManager$Runner$1.run(JobManager.java:73)+
+     at java.util.concurrent.Executors$RunnableAdapter.call(Executors.java:441)+
+     at java.util.concurrent.FutureTask$Sync.innerRun(FutureTask.java:303)+
+     at java.util.concurrent.FutureTask.run(FutureTask.java:138)+
+     at java.util.concurrent.ThreadPoolExecutor$Worker.runTask(ThreadPoolExecutor.java:886)+
+     at java.util.concurrent.ThreadPoolExecutor$Worker.run(ThreadPoolExecutor.java:908)+
+     at java.lang.Thread.run(Thread.java:662)+
Caused by: Environment invalid because of previous exception: com.sleepycat.je.log.DbChecksumException: (JE 3.3.82) Read invalid log entry type: 46 lsn= 0x0/0x205c69 logSource=com.sleepycat.je.log.FileHandleSource@568ee2b9
+     at com.sleepycat.je.log.LogEntryHeader.(LogEntryHeader.java:94)+
+     at com.sleepycat.je.log.LogManager.getLogEntryFromLogSource(LogManager.java:699)+
+     at com.sleepycat.je.log.LogManager.getLogEntry(LogManager.java:664)+
+     at com.sleepycat.je.tree.IN.fetchTarget(IN.java:1215)+
+     at com.sleepycat.je.dbi.CursorImpl.fetchCurrent(CursorImpl.java:2320)+
+     at com.sleepycat.je.dbi.CursorImpl.getCurrentAlreadyLatched(CursorImpl.java:1427)+
+     at com.sleepycat.je.dbi.CursorImpl.getNextWithKeyChangeStatus(CursorImpl.java:1573)+
+     at com.sleepycat.je.dbi.CursorImpl.getNext(CursorImpl.java:1499)+
+     at com.sleepycat.je.cleaner.UtilizationProfile.getObsoleteDetail(UtilizationProfile.java:953)+
+     at com.sleepycat.je.cleaner.FileProcessor.processFile(FileProcessor.java:326)+
+     at com.sleepycat.je.cleaner.FileProcessor.doClean(FileProcessor.java:233)+
+     at com.sleepycat.je.cleaner.FileProcessor.onWakeup(FileProcessor.java:138)+
+     at com.sleepycat.je.utilint.DaemonThread.run(DaemonThread.java:141)+
+     ... 1 more+


after that,I use com.sleepycat.je.util.DbVerify try to examines the identified database for errors,get the following information:
Verifying database wm_cyolcn
Checking tree for wm_cyolcn
Error encountered (continuing):
com.sleepycat.je.DatabaseException: (JE 3.3.82) fetchTarget of 0x0/0x205e59 parent IN=2281 IN class=com.sleepycat.je.tree.BIN lastFullVersion=0x0/0x4adf10 parent.getDirty()=false state=0 com.sleepycat.je.log.DbChecksumException: (JE 3.3.82) Read invalid log entry type: 108 lsn= 0x0/0x205e59 logSource=com.sleepycat.je.log.FileHandleSource@5210f6d3
Error Key 687474703a2f2f6865616c74682e63796f6c2e636f6d2f636f6e74656e742f323031312d30382f31392f636f6e74656e745f343739363335312e68746d http://health.cyol.com/content/2011-08/19/content_4796351.htm
Error Data UNKNOWN
Error encountered (continuing):
com.sleepycat.je.DatabaseException: (JE 3.3.82) fetchTarget of 0x0/0x23110a parent IN=2281 IN class=com.sleepycat.je.tree.BIN lastFullVersion=0x0/0x4adf10 parent.getDirty()=false state=0 Environment invalid because of previous exception: com.sleepycat.je.log.DbChecksumException: (JE 3.3.82) Read invalid log entry type: 108 lsn= 0x0/0x205e59 logSource=com.sleepycat.je.log.FileHandleSource@5210f6d3
Error Key 687474703a2f2f6865616c74682e63796f6c2e636f6d2f636f6e74656e742f323031312d30382f31392f636f6e74656e745f343739363335332e68746d http://health.cyol.com/content/2011-08/19/content_4796353.htm
Error Data UNKNOWN
Error encountered (continuing):
com.sleepycat.je.DatabaseException: (JE 3.3.82) fetchTarget of 0x0/0x230efd parent IN=2281 IN class=com.sleepycat.je.tree.BIN lastFullVersion=0x0/0x4adf10 parent.getDirty()=false state=0 Environment invalid because of previous exception: com.sleepycat.je.log.DbChecksumException: (JE 3.3.82) Read invalid log entry type: 108 lsn= 0x0/0x205e59 logSource=com.sleepycat.je.log.FileHandleSource@5210f6d3
Error Key 687474703a2f2f6865616c74682e63796f6c2e636f6d2f636f6e74656e742f323031312d30382f31392f636f6e74656e745f343739363935342e68746d http://health.cyol.com/content/2011-08/19/content_4796954.htm
Error Data UNKNOWN
Error encountered (continuing):
com.sleepycat.je.DatabaseException: (JE 3.3.82) fetchTarget of 0x0/0x235d78 parent IN=2281 IN class=com.sleepycat.je.tree.BIN lastFullVersion=0x0/0x4adf10 parent.getDirty()=false state=0 Environment invalid because of previous exception: com.sleepycat.je.log.DbChecksumException: (JE 3.3.82) Read invalid log entry type: 108 lsn= 0x0/0x205e59 logSource=com.sleepycat.je.log.FileHandleSource@5210f6d3
Error Key 687474703a2f2f6865616c74682e63796f6c2e636f6d2f636f6e74656e742f323031312d30382f31392f636f6e74656e745f343739373039382e68746d http://health.cyol.com/content/2011-08/19/content_4797098.htm
Error Data UNKNOWN
Error encountered (continuing):
com.sleepycat.je.DatabaseException: (JE 3.3.82) fetchTarget of 0x0/0x235b6b parent IN=2281 IN class=com.sleepycat.je.tree.BIN lastFullVersion=0x0/0x4adf10 parent.getDirty()=false state=0 Environment invalid because of previous exception: com.sleepycat.je.log.DbChecksumException: (JE 3.3.82) Read invalid log entry type: 108 lsn= 0x0/0x205e59 logSource=com.sleepycat.je.log.FileHandleSource@5210f6d3
Error Key 687474703a2f2f6865616c74682e63796f6c2e636f6d2f636f6e74656e742f323031312d30382f32392f636f6e74656e745f343833323435352e68746d http://health.cyol.com/content/2011-08/29/content_4832455.htm
Error Data UNKNOWN
Error encountered (continuing):
com.sleepycat.je.DatabaseException: (JE 3.3.82) fetchTarget of 0x0/0x343eda parent IN=2281 IN class=com.sleepycat.je.tree.BIN lastFullVersion=0x0/0x4adf10 parent.getDirty()=false state=0 Environment invalid because of previous exception: com.sleepycat.je.log.DbChecksumException: (JE 3.3.82) Read invalid log entry type: 108 lsn= 0x0/0x205e59 logSource=com.sleepycat.je.log.FileHandleSource@5210f6d3
Error Key 687474703a2f2f6865616c74682e63796f6c2e636f6d2f636f6e74656e742f323031312d31302f32362f636f6e74656e745f353037363133322e68746d http://health.cyol.com/content/2011-10/26/content_5076132.htm
Error Data UNKNOWN
Error encountered (continuing):
com.sleepycat.je.DatabaseException: (JE 3.3.82) fetchTarget of 0x0/0x343d7c parent IN=2281 IN class=com.sleepycat.je.tree.BIN lastFullVersion=0x0/0x4adf10 parent.getDirty()=false state=0 Environment invalid because of previous exception: com.sleepycat.je.log.DbChecksumException: (JE 3.3.82) Read invalid log entry type: 108 lsn= 0x0/0x205e59 logSource=com.sleepycat.je.log.FileHandleSource@5210f6d3
Error Key 687474703a2f2f6865616c74682e63796f6c2e636f6d2f636f6e74656e742f323031312d31322f32302f636f6e74656e745f353338383837322e68746d http://health.cyol.com/content/2011-12/20/content_5388872.htm
Error Data UNKNOWN
Error encountered (continuing):
com.sleepycat.je.DatabaseException: (JE 3.3.82) fetchTarget of 0x0/0x4004f2 parent IN=2281 IN class=com.sleepycat.je.tree.BIN lastFullVersion=0x0/0x4adf10 parent.getDirty()=false state=0 Environment invalid because of previous exception: com.sleepycat.je.log.DbChecksumException: (JE 3.3.82) Read invalid log entry type: 108 lsn= 0x0/0x205e59 logSource=com.sleepycat.je.log.FileHandleSource@5210f6d3
Error Key 687474703a2f2f6865616c74682e63796f6c2e636f6d2f636f6e74656e742f323031312d31322f32322f636f6e74656e745f353430353431352e68746d http://health.cyol.com/content/2011-12/22/content_5405415.htm
Error Data UNKNOWN
Error encountered (continuing):
com.sleepycat.je.DatabaseException: (JE 3.3.82) fetchTarget of 0x0/0x400394 parent IN=2281 IN class=com.sleepycat.je.tree.BIN lastFullVersion=0x0/0x4adf10 parent.getDirty()=false state=0 Environment invalid because of previous exception: com.sleepycat.je.log.DbChecksumException: (JE 3.3.82) Read invalid log entry type: 108 lsn= 0x0/0x205e59 logSource=com.sleepycat.je.log.FileHandleSource@5210f6d3
Error Key 687474703a2f2f6865616c74682e63796f6c2e636f6d2f636f6e74656e742f323031312d31322f32322f636f6e74656e745f353430383033302e68746d http://health.cyol.com/content/2011-12/22/content_5408030.htm
Error Data UNKNOWN
Error encountered (continuing):
com.sleepycat.je.DatabaseException: (JE 3.3.82) fetchTarget of 0x0/0x4026d3 parent IN=2281 IN class=com.sleepycat.je.tree.BIN lastFullVersion=0x0/0x4adf10 parent.getDirty()=false state=0 Environment invalid because of previous exception: com.sleepycat.je.log.DbChecksumException: (JE 3.3.82) Read invalid log entry type: 108 lsn= 0x0/0x205e59 logSource=com.sleepycat.je.log.FileHandleSource@5210f6d3
Error Key 687474703a2f2f6865616c74682e63796f6c2e636f6d2f636f6e74656e742f323031312d31322f32322f636f6e74656e745f353430383033322e68746d http://health.cyol.com/content/2011-12/22/content_5408032.htm
Error Data UNKNOWN
Error encountered (continuing):
com.sleepycat.je.DatabaseException: (JE 3.3.82) fetchTarget of 0x0/0x4069fd parent IN=2281 IN class=com.sleepycat.je.tree.BIN lastFullVersion=0x0/0x4adf10 parent.getDirty()=false state=0 Environment invalid because of previous exception: com.sleepycat.je.log.DbChecksumException: (JE 3.3.82) Read invalid log entry type: 108 lsn= 0x0/0x205e59 logSource=com.sleepycat.je.log.FileHandleSource@5210f6d3
Error Key 687474703a2f2f6865616c74682e63796f6c2e636f6d2f636f6e74656e742f323031312d31322f32362f636f6e74656e745f353432383330312e68746d http://health.cyol.com/content/2011-12/26/content_5428301.htm
Error Data UNKNOWN
Error encountered (continuing):
com.sleepycat.je.DatabaseException: (JE 3.3.82) fetchTarget of 0x0/0x4067f0 parent IN=2281 IN class=com.sleepycat.je.tree.BIN lastFullVersion=0x0/0x4adf10 parent.getDirty()=false state=0 Environment invalid because of previous exception: com.sleepycat.je.log.DbChecksumException: (JE 3.3.82) Read invalid log entry type: 108 lsn= 0x0/0x205e59 logSource=com.sleepycat.je.log.FileHandleSource@5210f6d3
Error Key 687474703a2f2f6865616c74682e63796f6c2e636f6d2f636f6e74656e742f323031312d31322f32362f636f6e74656e745f353432383431302e68746d http://health.cyol.com/content/2011-12/26/content_5428410.htm
Error Data UNKNOWN
Error encountered (continuing):
com.sleepycat.je.DatabaseException: (JE 3.3.82) fetchTarget of 0x0/0x40cd5e parent IN=2281 IN class=com.sleepycat.je.tree.BIN lastFullVersion=0x0/0x4adf10 parent.getDirty()=false state=0 Environment invalid because of previous exception: com.sleepycat.je.log.DbChecksumException: (JE 3.3.82) Read invalid log entry type: 108 lsn= 0x0/0x205e59 logSource=com.sleepycat.je.log.FileHandleSource@5210f6d3
Error Key 687474703a2f2f6865616c74682e63796f6c2e636f6d2f636f6e74656e742f323031312d31322f33302f636f6e74656e745f353436313733372e68746d http://health.cyol.com/content/2011-12/30/content_5461737.htm
Error Data UNKNOWN
Error encountered (continuing):
com.sleepycat.je.DatabaseException: (JE 3.3.82) fetchTarget of 0x0/0x4110dd parent IN=2281 IN class=com.sleepycat.je.tree.BIN lastFullVersion=0x0/0x4adf10 parent.getDirty()=false state=0 Environment invalid because of previous exception: com.sleepycat.je.log.DbChecksumException: (JE 3.3.82) Read invalid log entry type: 108 lsn= 0x0/0x205e59 logSource=com.sleepycat.je.log.FileHandleSource@5210f6d3
Error Key 687474703a2f2f6865616c74682e63796f6c2e636f6d2f636f6e74656e742f323031312d31322f33312f636f6e74656e745f353436393237382e68746d http://health.cyol.com/content/2011-12/31/content_5469278.htm
Error Data UNKNOWN
Error encountered (continuing):
com.sleepycat.je.DatabaseException: (JE 3.3.82) fetchTarget of 0x0/0x4136bf parent IN=2281 IN class=com.sleepycat.je.tree.BIN lastFullVersion=0x0/0x4adf10 parent.getDirty()=false state=0 Environment invalid because of previous exception: com.sleepycat.je.log.DbChecksumException: (JE 3.3.82) Read invalid log entry type: 108 lsn= 0x0/0x205e59 logSource=com.sleepycat.je.log.FileHandleSource@5210f6d3
Error Key 687474703a2f2f6865616c74682e63796f6c2e636f6d2f636f6e74656e742f323031322d30312f30362f636f6e74656e745f353439313038392e68746d http://health.cyol.com/content/2012-01/06/content_5491089.htm
Error Data UNKNOWN
Error encountered (continuing):
com.sleepycat.je.DatabaseException: (JE 3.3.82) fetchTarget of 0x0/0x4738d2 parent IN=2281 IN class=com.sleepycat.je.tree.BIN lastFullVersion=0x0/0x4adf10 parent.getDirty()=false state=0 Environment invalid because of previous exception: com.sleepycat.je.log.DbChecksumException: (JE 3.3.82) Read invalid log entry type: 108 lsn= 0x0/0x205e59 logSource=com.sleepycat.je.log.FileHandleSource@5210f6d3
Error Key UNKNOWN
Error Data UNKNOWN
numBottomInternalNodes=103
level 1: count=103
numInternalNodes=3
level 2: count=2
level 3: count=1
numLeafNodes=6620
numDeletedLeafNodes=0
numDuplicateCountLeafNodes=0
mainTreeMaxDepth=3
duplicateTreeMaxDepth=0

Environment invalid because of previous exception: com.sleepycat.je.log.DbChecksumException: (JE 3.3.82) Read invalid log entry type: 108 lsn= 0x0/0x205e59 logSource=com.sleepycat.je.log.FileHandleSource@5210f6d3
at com.sleepycat.je.log.LogEntryHeader.<init>(LogEntryHeader.java:94)
at com.sleepycat.je.log.LogManager.getLogEntryFromLogSource(LogManager.java:699)
at com.sleepycat.je.log.LogManager.getLogEntry(LogManager.java:664)
at com.sleepycat.je.tree.IN.fetchTarget(IN.java:1215)
at com.sleepycat.je.dbi.CursorImpl.fetchCurrent(CursorImpl.java:2320)
at com.sleepycat.je.dbi.CursorImpl.getCurrentAlreadyLatched(CursorImpl.java:1427)
at com.sleepycat.je.dbi.CursorImpl.getNextWithKeyChangeStatus(CursorImpl.java:1573)
at com.sleepycat.je.dbi.CursorImpl.getNext(CursorImpl.java:1499)
at com.sleepycat.je.dbi.DatabaseImpl.walkDatabaseTree(DatabaseImpl.java:1355)
at com.sleepycat.je.dbi.DatabaseImpl.verify(DatabaseImpl.java:1303)
at com.sleepycat.je.util.DbVerify.verifyOneDbImpl(DbVerify.java:371)
at com.sleepycat.je.util.DbVerify.verify(DbVerify.java:275)
at com.sleepycat.je.util.DbVerify.main(DbVerify.java:94)
Exit status = false

I want to know,the db file can repair it?And how do I do?
Thanks so much!
  • 1. Re: Environment invalid because of previous exception
    Linda Lee Journeyer
    Currently Being Moderated
    Hopefully the DbDump and DbLoad utilities willl help you recover and reload your data. Start http://docs.oracle.com/cd/E17277_02/html/GettingStartedGuide/commandlinetools.html#DbDump, or with DbDump at http://docs.oracle.com/cd/E17277_02/html/java/com/sleepycat/je/util/DbDump.html, and try first the -r and then the -R options.
  • 2. Re: Environment invalid because of previous exception
    Charles Lamb Pro
    Currently Being Moderated
    You are using a really old release of JE (3.3.82). Although upgrading to a new release won't fix this problem in the database, once you recover your data (using DbScavenger as my colleague Linda suggested), you should still upgrade to help prevent this from occurring in the future. But first, you'll have to recover your data from the disk corruption that has occurred.

    Charles Lamb
  • 3. Re: Environment invalid because of previous exception
    greybird Expert
    Currently Being Moderated
    To add to what Charles and Linda have said, I see that file 00000000.jdb has at least two corrupt locations. This indicates you had a storage device or file system failure of some kind. If you can recover your data, you should restore to a disk that you know is working properly.

    As an alternative to using DbDump as Linda suggested, you could try restoring file 00000000.jdb from a backup, if it is the only file that is corrupt. But first be sure that the backup and other .jdb files are not corrupt by running DbPrintLog to read these files and check for errors. You can discard the output to stdout from DbPrintLog, since any exceptions (such as the DbChecksumException) will be printed to stderr. (In later releases, DbVerifyLog should be used instead of DbPrintLog.)

    --mark                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                           
  • 4. Re: Environment invalid because of previous exception
    953409 Newbie
    Currently Being Moderated
    The way you said, I have successfully repaired it.
    Thank you very much!

    Steps are as follows:
    1./usr/local/jdk/bin/java -cp "/godbk/deploy/crawler-war/WEB-INF/lib/je-3.3.82.jar" com.sleepycat.je.util.DbDump -h . -r -s wm_cyolcn

    2.Clear the old files(*.jdb,*.lck),in addition to the dump file.

    3./usr/local/jdk/bin/java -cp "/godbk/deploy/crawler-war/WEB-INF/lib/je-3.3.82.jar" com.sleepycat.je.util.DbLoad -c dupsort=false -h . -s wm_cyolcn -f wm_cyolcn.dump -v

Legend

  • Correct Answers - 10 points
  • Helpful Answers - 5 points