Uploaded image for project: 'IMPALA'
  1. IMPALA
  2. IMPALA-1873

DCHECK: Validate() in impala::BufferedBlockMgr::WriteComplete

    XMLWordPrintableJSON

    Details

    • Type: Bug
    • Status: Resolved
    • Priority: Blocker
    • Resolution: Fixed
    • Affects Version/s: Impala 2.2
    • Fix Version/s: Impala 2.2
    • Component/s: None
    • Labels:
      None

      Description

      There were 4 randomly generated queries executing concurrently on the 10 node CDH5 cluster on tpch300gb_parquet DB. mem_limit was not set.

      Stack Trace:

      #0  0x0000003e5e4328e5 in raise () from /lib64/libc.so.6
      #0  0x0000003e5e4328e5 in raise () from /lib64/libc.so.6
      #1  0x0000003e5e4340c5 in abort () from /lib64/libc.so.6
      #2  0x0000000001f0de09 in google::DumpStackTraceAndExit () at src/utilities.cc:147
      #3  0x0000000001f0542d in google::LogMessage::Fail () at src/logging.cc:1315
      #4  0x0000000001f08fc7 in google::LogMessage::SendToLog (this=0x7f67c924e5f0) at src/logging.cc:1269
      #5  0x0000000001f079fa in google::LogMessage::Flush (this=0x7f67c924e5f0) at src/logging.cc:1138
      #6  0x0000000001f07ccd in google::LogMessageFatal::~LogMessageFatal (this=0x7f67c924e5f0, __in_chrg=<value optimized out>) at src/logging.cc:1836
      #7  0x0000000000f53c61 in impala::BufferedBlockMgr::WriteComplete (this=0x47f41a00, block=0x4da766c0, write_status=...) at /usr/src/debug/impala-2.2.0-cdh5.5.0-SNAPSHOT/be/src/runtime/buffered-block-mgr.cc:688
      #8  0x0000000000f63270 in boost::_mfi::mf2<void, impala::BufferedBlockMgr, impala::BufferedBlockMgr::Block*, impala::Status const&>::operator() (this=0x48fe8480, p=0x47f41a00, a1=0x4da766c0, a2=...) at /opt/toolchain/boost-pic-1.55.0/include/boost/bind/mem_fn_template.hpp:280
      #9  0x0000000000f62fc3 in boost::_bi::list3<boost::_bi::value<impala::BufferedBlockMgr*>, boost::_bi::value<impala::BufferedBlockMgr::Block*>, boost::arg<1> >::operator()<boost::_mfi::mf2<void, impala::BufferedBlockMgr, impala::BufferedBlockMgr::Block*, impala::Status const&>, boost::_bi::list1<impala::Status const&> > (this=0x48fe8490, f=..., a=...) at /opt/toolchain/boost-pic-1.55.0/include/boost/bind/bind.hpp:392
      #10 0x0000000000f62a44 in boost::_bi::bind_t<boost::_bi::unspecified, boost::_mfi::mf2<void, impala::BufferedBlockMgr, impala::BufferedBlockMgr::Block*, impala::Status const&>, boost::_bi::list3<boost::_bi::value<impala::BufferedBlockMgr*>, boost::_bi::value<impala::BufferedBlockMgr::Block*>, boost::arg<1> > >::operator()<impala::Status> (this=0x48fe8480, a1=...) at /opt/toolchain/boost-pic-1.55.0/include/boost/bind/bind_template.hpp:47
      #11 0x0000000000f620ea in boost::detail::function::void_function_obj_invoker1<boost::_bi::bind_t<boost::_bi::unspecified, boost::_mfi::mf2<void, impala::BufferedBlockMgr, impala::BufferedBlockMgr::Block*, impala::Status const&>, boost::_bi::list3<boost::_bi::value<impala::BufferedBlockMgr*>, boost::_bi::value<impala::BufferedBlockMgr::Block*>, boost::arg<1> > >, void, impala::Status const&>::invoke (function_obj_ptr=..., a0=...) at /opt/toolchain/boost-pic-1.55.0/include/boost/function/function_template.hpp:153
      #12 0x0000000000f76594 in boost::function1<void, impala::Status const&>::operator() (this=0xa570ca0, a0=...) at /opt/toolchain/boost-pic-1.55.0/include/boost/function/function_template.hpp:767
      #13 0x0000000000f7c66c in impala::DiskIoMgr::RequestContext::Cancel (this=0x85ea2000, status=...) at /usr/src/debug/impala-2.2.0-cdh5.5.0-SNAPSHOT/be/src/runtime/disk-io-mgr-reader-context.cc:83
      #14 0x0000000000f6cd4e in impala::DiskIoMgr::CancelContext (this=0x8987560, context=0x85ea2000, wait_for_disks_completion=true) at /usr/src/debug/impala-2.2.0-cdh5.5.0-SNAPSHOT/be/src/runtime/disk-io-mgr.cc:377
      #15 0x0000000000f6c976 in impala::DiskIoMgr::UnregisterContext (this=0x8987560, reader=0x85ea2000) at /usr/src/debug/impala-2.2.0-cdh5.5.0-SNAPSHOT/be/src/runtime/disk-io-mgr.cc:345
      #16 0x0000000000f50eed in impala::BufferedBlockMgr::~BufferedBlockMgr (this=0x47f41a00, __in_chrg=<value optimized out>) at /usr/src/debug/impala-2.2.0-cdh5.5.0-SNAPSHOT/be/src/runtime/buffered-block-mgr.cc:472
      #17 0x0000000000f625ca in boost::checked_delete<impala::BufferedBlockMgr> (x=0x47f41a00) at /opt/toolchain/boost-pic-1.55.0/include/boost/checked_delete.hpp:34
      #18 0x0000000000f6365e in boost::detail::sp_counted_impl_p<impala::BufferedBlockMgr>::dispose (this=0x1ccfe280) at /opt/toolchain/boost-pic-1.55.0/include/boost/smart_ptr/detail/sp_counted_impl.hpp:78
      #19 0x0000000000e5ceec in boost::detail::sp_counted_base::release (this=0x1ccfe280) at /opt/toolchain/boost-pic-1.55.0/include/boost/smart_ptr/detail/sp_counted_base_gcc_x86.hpp:146
      #20 0x0000000000e5cf7b in boost::detail::shared_count::~shared_count (this=0x7f67c924ee58, __in_chrg=<value optimized out>) at /opt/toolchain/boost-pic-1.55.0/include/boost/smart_ptr/detail/shared_count.hpp:371
      #21 0x0000000000f384ca in boost::shared_ptr<impala::BufferedBlockMgr>::~shared_ptr (this=0x7f67c924ee50, __in_chrg=<value optimized out>) at /opt/toolchain/boost-pic-1.55.0/include/boost/smart_ptr/shared_ptr.hpp:329
      #22 0x0000000000f390cb in boost::shared_ptr<impala::BufferedBlockMgr>::reset (this=0xaa2cd30) at /opt/toolchain/boost-pic-1.55.0/include/boost/smart_ptr/shared_ptr.hpp:619
      #23 0x0000000000f33beb in impala::RuntimeState::~RuntimeState (this=0xaa2c700, __in_chrg=<value optimized out>) at /usr/src/debug/impala-2.2.0-cdh5.5.0-SNAPSHOT/be/src/runtime/runtime-state.cc:97
      #24 0x0000000001076209 in boost::checked_delete<impala::RuntimeState> (x=0xaa2c700) at /opt/toolchain/boost-pic-1.55.0/include/boost/checked_delete.hpp:34
      #25 0x0000000001072737 in boost::scoped_ptr<impala::RuntimeState>::~scoped_ptr (this=0xb5cd978, __in_chrg=<value optimized out>) at /opt/toolchain/boost-pic-1.55.0/include/boost/smart_ptr/scoped_ptr.hpp:82
      #26 0x0000000001438bb5 in impala::PlanFragmentExecutor::~PlanFragmentExecutor (this=0xb5cd810, __in_chrg=<value optimized out>) at /usr/src/debug/impala-2.2.0-cdh5.5.0-SNAPSHOT/be/src/runtime/plan-fragment-executor.cc:75
      #27 0x000000000108f159 in impala::FragmentMgr::FragmentExecState::~FragmentExecState (this=0xb5cd600, __in_chrg=<value optimized out>) at /usr/src/debug/impala-2.2.0-cdh5.5.0-SNAPSHOT/be/src/service/fragment-exec-state.h:42
      #28 0x00000000010906bc in boost::checked_delete<impala::FragmentMgr::FragmentExecState> (x=0xb5cd600) at /opt/toolchain/boost-pic-1.55.0/include/boost/checked_delete.hpp:34
      #29 0x00000000010921d6 in boost::detail::sp_counted_impl_p<impala::FragmentMgr::FragmentExecState>::dispose (this=0x1d4d9900) at /opt/toolchain/boost-pic-1.55.0/include/boost/smart_ptr/detail/sp_counted_impl.hpp:78
      #30 0x0000000000e5ceec in boost::detail::sp_counted_base::release (this=0x1d4d9900) at /opt/toolchain/boost-pic-1.55.0/include/boost/smart_ptr/detail/sp_counted_base_gcc_x86.hpp:146
      #31 0x0000000000e5cf7b in boost::detail::shared_count::~shared_count (this=0x7f67c924f888, __in_chrg=<value optimized out>) at /opt/toolchain/boost-pic-1.55.0/include/boost/smart_ptr/detail/shared_count.hpp:371
      #32 0x000000000101aa9e in boost::shared_ptr<impala::FragmentMgr::FragmentExecState>::~shared_ptr (this=0x7f67c924f880, __in_chrg=<value optimized out>) at /opt/toolchain/boost-pic-1.55.0/include/boost/smart_ptr/shared_ptr.hpp:329
      #33 0x000000000108dd99 in impala::FragmentMgr::FragmentExecThread (this=0xa010540, exec_state=0xb5cd600) at /usr/src/debug/impala-2.2.0-cdh5.5.0-SNAPSHOT/be/src/service/fragment-mgr.cc:100
      #34 0x00000000010920f0 in boost::_mfi::mf1<void, impala::FragmentMgr, impala::FragmentMgr::FragmentExecState*>::operator() (this=0xa0624a0, p=0xa010540, a1=0xb5cd600) at /opt/toolchain/boost-pic-1.55.0/include/boost/bind/mem_fn_template.hpp:165
      #35 0x0000000001091ea9 in boost::_bi::list2<boost::_bi::value<impala::FragmentMgr*>, boost::_bi::value<impala::FragmentMgr::FragmentExecState*> >::operator()<boost::_mfi::mf1<void, impala::FragmentMgr, impala::FragmentMgr::FragmentExecState*>, boost::_bi::list0> (this=0xa0624b0, f=..., a=...) at /opt/toolchain/boost-pic-1.55.0/include/boost/bind/bind.hpp:313
      #36 0x0000000001091791 in boost::_bi::bind_t<void, boost::_mfi::mf1<void, impala::FragmentMgr, impala::FragmentMgr::FragmentExecState*>, boost::_bi::list2<boost::_bi::value<impala::FragmentMgr*>, boost::_bi::value<impala::FragmentMgr::FragmentExecState*> > >::operator() (this=0xa0624a0) at /opt/toolchain/boost-pic-1.55.0/include/boost/bind/bind_template.hpp:20
      #37 0x00000000010910df in boost::detail::function::void_function_obj_invoker0<boost::_bi::bind_t<void, boost::_mfi::mf1<void, impala::FragmentMgr, impala::FragmentMgr::FragmentExecState*>, boost::_bi::list2<boost::_bi::value<impala::FragmentMgr*>, boost::_bi::value<impala::FragmentMgr::FragmentExecState*> > >, void>::invoke (function_obj_ptr=...) at /opt/toolchain/boost-pic-1.55.0/include/boost/function/function_template.hpp:153
      #38 0x0000000000f21725 in boost::function0<void>::operator() (this=0x7f67c924fcc0) at /opt/toolchain/boost-pic-1.55.0/include/boost/function/function_template.hpp:767
      #39 0x000000000117a090 in impala::Thread::SuperviseThread (name="exec-plan-fragment", category="impala-server", functor=..., thread_started=0x7f67e687db90) at /usr/src/debug/impala-2.2.0-cdh5.5.0-SNAPSHOT/be/src/util/thread.cc:311
      #40 0x000000000118322c in boost::_bi::list4<boost::_bi::value<std::basic_string<char, std::char_traits<char>, std::allocator<char> > >, boost::_bi::value<std::basic_string<char, std::char_traits<char>, std::allocator<char> > >, boost::_bi::value<boost::function<void()> >, boost::_bi::value<impala::Promise<long int>*> >::operator()<void (*)(const std::string&, const std::string&, impala::Thread::ThreadFunctor, impala::Promise<long int>*), boost::_bi::list0>(boost::_bi::type<void>, void (*&)(const std::string &, const std::string &, impala::Thread::ThreadFunctor, impala::Promise<long> *), boost::_bi::list0 &, int) (this=0x8ea03c0, f=@0x8ea03b8, a=...) at /opt/toolchain/boost-pic-1.55.0/include/boost/bind/bind.hpp:457
      #41 0x0000000001183173 in boost::_bi::bind_t<void, void (*)(const std::string&, const std::string&, impala::Thread::ThreadFunctor, impala::Promise<long int>*), boost::_bi::list4<boost::_bi::value<std::basic_string<char, std::char_traits<char>, std::allocator<char> > >, boost::_bi::value<std::basic_string<char, std::char_traits<char>, std::allocator<char> > >, boost::_bi::value<boost::function<void()> >, boost::_bi::value<impala::Promise<long int>*> > >::operator()(void) (this=0x8ea03b8) at /opt/toolchain/boost-pic-1.55.0/include/boost/bind/bind_template.hpp:20
      #42 0x0000000001183132 in boost::detail::thread_data<boost::_bi::bind_t<void, void (*)(const std::string&, const std::string&, impala::Thread::ThreadFunctor, impala::Promise<long int>*), boost::_bi::list4<boost::_bi::value<std::basic_string<char, std::char_traits<char>, std::allocator<char> > >, boost::_bi::value<std::basic_string<char, std::char_traits<char>, std::allocator<char> > >, boost::_bi::value<boost::function<void()> >, boost::_bi::value<impala::Promise<long int>*> > > >::run(void) (this=0x8ea0200) at /opt/toolchain/boost-pic-1.55.0/include/boost/thread/detail/thread.hpp:117
      #43 0x00000000015e3793 in thread_proxy ()
      #44 0x0000003e5e807851 in start_thread () from /lib64/libpthread.so.0
      #45 0x0000003e5e4e894d in clone () from /lib64/libc.so.6
      

      Location where DCHECK Fails:

      void BufferedBlockMgr::WriteComplete(Block* block, const Status& write_status) {
        outstanding_writes_counter_->Add(-1);
        lock_guard<mutex> lock(lock_);
        DCHECK(Validate()) << endl << DebugInternal(); //<<<<<<<<<<<<<<<<<<<<<< Failed
        DCHECK(block->in_write_) << "WriteComplete() for block not in write."
                                 << endl << block->DebugString();
        if (!block->client_local_) {
          DCHECK_GT(num_outstanding_writes_, 0) << block->DebugString();
          --num_outstanding_writes_;
        }
      

      Validate() case that failed:

      I0310 13:16:22.408202 57724 runtime-state.cc:230] Error from query 2b4b7a72d79fb0a4:6d50ea6b73d12084: Cancelled
      E0310 13:16:22.408335 57724 buffered-block-mgr.cc:151] Deleted block in use - Block: 0x7dc6b8c0
        Buffer Desc: 0xa7fbe80
        Data Len: 3306288
        Num Rows: 206643
        Deleted: 1
        Pinned: 0
        Write Issued: 0
        Client Local: 0
      E0310 13:16:22.408669 57724 buffered-block-mgr.cc:982] buffer->block inconsistent.
      Block: 0x7dc6b8c0
        Buffer Desc: 0xa7fbe80
        Data Len: 3306288
        Num Rows: 206643
        Deleted: 1
        Pinned: 0
        Write Issued: 0
        Client Local: 0
      F0310 13:16:22.408864 57724 buffered-block-mgr.cc:688] Check failed: Validate()
      Buffered block mgr
        Num writes outstanding: 0
        Num free io buffers: 732
        Num unpinned blocks: 0
        Num available buffers: 865
        Total pinned buffers: 409
        Unfullfilled reserved buffers: 253
        Remaining memory: 3235662233 (#blocks=385)
        Block write threshold: 22
      
      

      Additional information is located on e1120.halxg.cloudera.com in /data/4/IMPALA-1873 directory.

        Attachments

          Activity

            People

            • Assignee:
              ippokratis Ippokratis Pandis
              Reporter:
              tarasbob Taras Bobrovytsky
            • Votes:
              0 Vote for this issue
              Watchers:
              3 Start watching this issue

              Dates

              • Created:
                Updated:
                Resolved: