Thursday, February 4, 2016

2137038 - SAP HANA Database: Columnstore history table cannot be accessed due to an exception during deltalog replay

Symptom
SAP HANA Revision 90 and 91:
Access to a column store table (for example via SELECT) fails with an Indexserver crash:
 [CRASH_STACK]  Stacktrace of crash: (9999-01-01 00:00:00 000 Local)
----> Pending exceptions (possible root cause) <----
exception  1: no.3000141  (DataAccess/impl/PersistenceSessionImpl.cpp:1016)
    Consistent change session Session[TransactionContext]@0x00007eec9a4ccc00[TID=72596426, refcnt=2, ts=TS[tcbidx=789,ssn=1], cts=TCB[ACTIVE,refcnt=4,tempTS=TS[tcbidx=789,ssn=1],commitTS=1,hasCursor=false,factory=default,special]@0x00007ee9aa4a8ee0, forceRollback= false, openVFCount= 0 is in invalid state; $condition$=!impl->isRunning(); $impl->m_hStats->m_State$=1
exception throw location:
 1: 0x00007f0f6123ae98 in DataAccess::ConsistentChange::release()+0x3c4 at PersistenceSessionImpl.cpp:1016 (libhdbdataaccess.so)
 2: 0x00007f0f5dfb859d in UnifiedTable::TableContainerImpl::setBaseRowIDForDeltaInMigration(unsigned long, DataAccess::PersistenceSession&, int, unsigned long)+0xd9 at releasable_handle.hpp:460 (libhdbunifiedtable.so)
 3: 0x00007f0f735507da in Delta::log::DeserializerContext::finalize()+0x7b6 at DeserializerContext.cpp:790 (libhdbcsapi.so)
 4: 0x00007f0f73525500 in Delta::log::Replay::replayLog(TrexBase::IndexName const&, TRexCommonObjects::TRexApiError&, TRexConfig::IndexHandle&, bool) const+0x3a0 at Timer.hpp:69 (libhdbcsapi.so)
 5: 0x00007f0f7352b32e in Delta::log::Replay::replayDeltaLog(TrexBase::IndexName const&, TRexConfig::IndexHandle&, TRexConfig::RuntimeWriter&, TRexCommonObjects::TRexApiError&, bool) const+0xfa at Replay.cpp:1477 (libhdbcsapi.so)
 6: 0x00007f0f7352be69 in Delta::log::Replay::migrateAndLoadUTContainer(TrexBase::IndexName const&, TRexConfig::IndexHandle&, TRexCommonObjects::TRexApiError&, TRexConfig::RuntimeWriter&) const+0x965 at Replay.cpp:1822 (libhdbcsapi.so)
 7: 0x00007f0f7352d065 in Delta::log::Replay::replay_normal(TrexBase::IndexName const&, TRexConfig::IndexHandle&, TRexCommonObjects::TRexApiError&) const+0x111 at Replay.cpp:186 (libhdbcsapi.so)
...

SAP HANA Revision 92:
Access to a column store table (for example via SELECT) fails with "[1527] exception during deltalog replay. See trace file for more information".
In the Indexservertrace the following error is reported:
[75547]{347076}[41/296375] 0000-01-01 00:00:00.000000 e DeltaLog_Replaye Replay.cpp(02183) :  replay failed for index <table_name> (539): exception  1: no.6010028  (UnifiedTable/Dictionary/impl/DictionaryStorage.cpp:144)
    Value with ValueId 0 does not exist
exception throw location:
 1: 0x00007f357dc14d45 in UnifiedTable::DictionaryStorage::throwInvalidValueIDException(unsigned int)+0x21 at DictionaryStorage.cpp:142 (libhdbunifiedtable.so)
 2: 0x00007f357dc0f2af in UnifiedTable::DeltaRowIDDictionaryStorage::getRowID(unsigned int) const+0xdb at DeltaRowIDDictionaryStorage.cpp:486 (libhdbunifiedtable.so)
 3: 0x00007f357daf7d58 in UnifiedTable::ColumnFragmentDeltaRowIDObject::getRowID(int) const+0x84 at ColumnFragmentDeltaRowIDObject.cpp:127 (libhdbunifiedtable.so)
 4: 0x00007f357d95d66b in UnifiedTable::FragmentObject::updateRowIDHints(unsigned long, unsigned long, bool)+0x77 at FragmentObject.cpp:2417 (libhdbunifiedtable.so)
 5: 0x00007f357daa625b in UnifiedTable::TableContainerImpl::setBaseRowIDForDeltaInMigration(unsigned long, DataAccess::PersistenceSession&, int, unsigned long)+0xa7 at TableContainerImpl.cpp:5780 (libhdbunifiedtable.so)
 6: 0x00007f359336b8fc in Delta::log::DeserializerContext::finalize()+0x818 at DeserializerContext.cpp:810 (libhdbcsapi.so)
 7: 0x00007f359333fb30 in Delta::log::Replay::replayLog(TrexBase::IndexName const&, TRexCommonObjects::TRexApiError&, TRexConfig::IndexHandle&, bool) const+0x3a0 at Timer.hpp:69 (libhdbcsapi.so)
 ...


Other Terms
HANA, deltalog replay, ValueID, consistent change, Indexserver crash, history table


Reason and Prerequisites
Prerequisites:
  • SAP HANA Database Revisions 90, 91, 92
  • Columnstore history table created before SAP HANA SPS09
Reason:
History tables have extra MVCC entries in delta log without corresponding data. Due to a programming error in SAP HANA database this additional MVCC entry is not handled correctly during L2 Delta migration. This leads to an Indexserver crash in Revision 90 and 91 and to an exception in Revision 92 when accessing the table.


Solution
Apply SAP HANA Database Revision 93 or later.
Remarks:
  • When SAP HANA database Revision 93 or later is applied the table can be accessed again.



Header Data

Released On 04.03.2015 14:00:41
Release Status Released for Customer
Component HAN-DB SAP HANA Database
Priority Hot News
Category Program error

No comments:

Post a Comment