Manual "dictionary" indices are empty after DB crash
Hi, I think I have found a problem with the latest 1.6.0-snapshot version (downloaded this morning). In short: After a system crash, all manual dictionaries are empty.
Step to reproduce the bug: Environment: Windows 7 or CentOS 6.2 OrientDB version: 1.6.0-snapshot downloaded on October 23th 2013 Step to reproduce the behaviour: start the console and then input the following commands:
create database plocal:/temp/test admin admin plocal graph
create index testdictionary dictionary
insert into V (name) values ("test")
insert into index:testdictionary (key,rid) values ("key",#9:0)
Note: the '#9:0' RID is the document just created at statement 4 Check the index:
orientdb> select from index:testdictionary
----+------+----+----
# |@RID |key |rid
----+------+----+----
0 |#-1:-1|key |#9:0
----+------+----+----
Now close the terminal WITHOUT exiting from within the console, in this way we simulate a system crash. This works in Windows. Now let's reconnect to the db in a new terminal window:
OrientDB console v.1.6.0-SNAPSHOT (build @BUILD@) www.orientechnologies.com
Type 'help' to display all the commands supported.
Installing extensions for GREMLIN language v.2.5.0-SNAPSHOT
orientdb> connect plocal:/temp/test admin admin
Connecting to database [plocal:/temp/test] with user 'admin'...
2013-10-23 18:18:30:526 WARN segment file 'database.ocf' was not closed correctly last time [OSingleFileSegment]
2013-10-23 18:18:30:579 WARN Storage test was not closed properly. Will try to restore from write ahead log. [OLocalPaginatedStorage]
2013-10-23 18:18:30:584 WARN Record OCheckpointEndRecord{lsn=OLogSequenceNumber{segment=0, position=136810}} will be skipped during data restore. [OLo
calPaginatedStorage]
OK
orientdb>
2013-10-23 18:18:30:954 SEVE getDataSegmentIdByName: Local paginated storage does not support data segments. -1 will be returned for data segment inde
x. [OLocalPaginatedStorage]
2013-10-23 18:18:30:983 SEVE addDataSegment: Local paginated storage does not support data segments, segment index will not be added in directory null
. [OLocalPaginatedStorage]
Check the index:
orientdb> select from index:testdictionary
0 item(s) found. Query executed in 0.0010 sec(s).
orientdb>
Hi, any news on this?
HI, We need to implement special atomic operation propagation approach we are working on this but it is not in 1.6.
On Mon, Oct 28, 2013 at 11:43 AM, giastfader [email protected]:
Hi, any news on this?
— Reply to this email directly or view it on GitHubhttps://github.com/orientechnologies/orientdb/issues/1761#issuecomment-27198757 .
Best regards, Andrey Lomakin.
Orient Technologies the Company behind OrientDB
mmm, so bad because server crash could cause information lost. Is there a workaround? Are other indices affected too?
Thanks!
Hi, No of course not ). There are several modes of work with indexes:
- In tx mode index and data operations are logged and restored after server crash. I can use following modes: rollback only for indexes, full restore. In rollback only mode indexes are rebuilt in full mode they are restored from operations log. 2 In non tx mode data operations are logged and indexes are rebuilt.
On Mon, Oct 28, 2013 at 12:34 PM, giastfader [email protected]:
mmm, so bad because server crash could cause information lost. Is there a workaround? Are other indices affected too?
Thanks!
— Reply to this email directly or view it on GitHubhttps://github.com/orientechnologies/orientdb/issues/1761#issuecomment-27201444 .
Best regards, Andrey Lomakin.
Orient Technologies the Company behind OrientDB
We should configure manual indexes to always use WAL
@laa what's the ETA to always configure WAL with manual indexes?
@lvca I set it.