1

Closed

Page read error header invalid, number = 1

description

When inserting a simple new document, at random times I get:

System.AggregateException: One or more errors occurred. ---> System.Exception: Page read error header invalid, number = 1
at RaptorDB.IndexFile1.LoadPageFromPageNumber(Int32 number) in <path>RaptorDB\Indexes\IndexFile.cs:line 329
at RaptorDB.MGIndex
1.LoadPage(T key, PageInfo& pageinfo) in <path>RaptorDB\Indexes\MGIndex.cs:line 413
at RaptorDB.MGIndex1.doEqualOp(RDBExpression exp, T key) in <path>RaptorDB\Indexes\MGIndex.cs:line 328
at RaptorDB.MGIndex
1.Query(RDBExpression exp, T from) in <path>RaptorDB\Indexes\MGIndex.cs:line 113
at RaptorDB.TypeIndexes1.Query(RDBExpression ex, Object from) in <path>RaptorDB\Indexes\Indexes.cs:line 34
at RaptorDB.Views.ViewHandler.SaveAndIndex(Dictionary
2 rows) in <path>RaptorDB\Views\ViewHandler.cs:line 149
at RaptorDB.Views.ViewHandler.Insert[T](Guid guid, T doc) in <path>RaptorDB\Views\ViewHandler.cs:line 141
at RaptorDB.Views.ViewManager.<>c__DisplayClass21.<Insert>b__0() in <path>RaptorDB\Views\ViewManager.cs:line 126
at System.Threading.Tasks.Task.InnerInvoke()
at System.Threading.Tasks.Task.Execute()
--- End of inner exception stack trace ---
at System.Threading.Tasks.Task.WaitAll(Task[] tasks, Int32 millisecondsTimeout, CancellationToken cancellationToken)
at RaptorDB.Views.TaskQueue.Shutdown() in <path>RaptorDB\Views\TaskQueue.cs:line 64
at RaptorDB.Views.ViewManager.ShutDown() in <path>RaptorDB\Views\ViewManager.cs:line 216
at RaptorDB.RaptorDB.Shutdown() in <path>RaptorDB\RaptorDB.cs:line 294
at RaptorDbTest.Program.Main(String[] args) in <path>RaptorDbTest\RaptorDbTest\Program.cs:line 36
---> (Inner Exception #0) System.Exception: Page read error header invalid, number = 1
at RaptorDB.IndexFile
1.LoadPageFromPageNumber(Int32 number) in <path>RaptorDB\Indexes\IndexFile.cs:line 329
at RaptorDB.MGIndex1.LoadPage(T key, PageInfo& pageinfo) in <path>RaptorDB\Indexes\MGIndex.cs:line 413
at RaptorDB.MGIndex
1.doEqualOp(RDBExpression exp, T key) in <path>RaptorDB\Indexes\MGIndex.cs:line 328
at RaptorDB.MGIndex1.Query(RDBExpression exp, T from) in <path>RaptorDB\Indexes\MGIndex.cs:line 113
at RaptorDB.TypeIndexes
1.Query(RDBExpression ex, Object from) in <path>RaptorDB\Indexes\Indexes.cs:line 34
at RaptorDB.Views.ViewHandler.SaveAndIndex(Dictionary2 rows) in <path>RaptorDB\Views\ViewHandler.cs:line 149
at RaptorDB.Views.ViewHandler.Insert[T](Guid guid, T doc) in <path>RaptorDB\Views\ViewHandler.cs:line 141
at RaptorDB.Views.ViewManager.<>c__DisplayClass2
1.<Insert>b__0() in <path>RaptorDB\Views\ViewManager.cs:line 126
at System.Threading.Tasks.Task.InnerInvoke()
at System.Threading.Tasks.Task.Execute()<---


It seems that it is a timing issue, as I cannot reproduce it in the debugger. IndexFile.cs's line numbers might be off slightly, as I edited it to include debugging output: b[0] through b[3] appear to all be 0, and so they do not match the magic numbers of _BlockHeader (PAGE).
Closed Jan 24, 2015 at 6:11 AM by MGholam

comments