Uploaded image for project: 'WiredTiger'
  1. WiredTiger
  2. WT-5145

Fix the race condition in accessing pinned_timestamp and connection state

    • Type: Icon: Bug Bug
    • Resolution: Fixed
    • Priority: Icon: Major - P3 Major - P3
    • 4.3.1, WT10.0.0, 4.2.2
    • Affects Version/s: None
    • Component/s: None
    • None
    • 8
    • Storage Engines 2019-10-21
    • v4.0

      There's a core dump generated while the eviction server performing an eviction review, captured on wiredtiger-test-format-stress job on margay-aws.

      http://build.wiredtiger.com:8080/job/wiredtiger-test-format-stress/71674/console

      ++ nice catchsegv ./t -1 -c ../../../test/format/CONFIG.stress
      [1569967267:288482][10618:0x7f025efcd700], t, file:wt.wt, eviction-server: __evict_review, 682: __wt_page_is_modified(page) || __wt_txn_visible_all(session, page->modify->rec_max_txn, page->modify->rec_max_timestamp)
      [1569967267:288514][10618:0x7f025efcd700], t, file:wt.wt, eviction-server: __wt_abort, 28: aborting WiredTiger library
      Aborted (core dumped)
      
      (...)
      
      Backtrace:
      /lib/x86_64-linux-gnu/libc.so.6(gsignal+0xc7)[0x7f0260b50e97]
      /lib/x86_64-linux-gnu/libc.so.6(abort+0x141)[0x7f0260b52801]
      /mnt/data0/jenkins/workspace/wiredtiger-test-format-stress/build_posix/../src/os_common/os_alloc.c:33(__wt_calloc)[0x481f6d]
      /mnt/data0/jenkins/workspace/wiredtiger-test-format-stress/build_posix/../src/evict/evict_page.c:689(__evict_review)[0x45e83c]
      /mnt/data0/jenkins/workspace/wiredtiger-test-format-stress/build_posix/../src/evict/evict_page.c:149(__wt_evict)[0x45c930]
      /mnt/data0/jenkins/workspace/wiredtiger-test-format-stress/build_posix/../src/evict/evict_lru.c:2248(__evict_page)[0x4595b2]
      /mnt/data0/jenkins/workspace/wiredtiger-test-format-stress/build_posix/../src/evict/evict_lru.c:1124(__evict_lru_pages)[0x455b0a]
      /mnt/data0/jenkins/workspace/wiredtiger-test-format-stress/build_posix/../src/evict/evict_lru.c:317(__wt_evict_thread_run)[0x453d24]
      /mnt/data0/jenkins/workspace/wiredtiger-test-format-stress/build_posix/../src/support/thread_group.c:31(__thread_run)[0x4db797]
      /lib/x86_64-linux-gnu/libpthread.so.0(+0x76db)[0x7f026154b6db]
      /lib/x86_64-linux-gnu/libc.so.6(clone+0x3f)[0x7f0260c3388f] 

      The configuration:

      ############################################
      #  RUN PARAMETERS
      ############################################
      abort=0
      alter=0
      assert_commit_timestamp=0
      assert_read_timestamp=0
      auto_throttle=1
      backups=0
      bitcnt=7
      bloom=1
      bloom_bit_count=50
      bloom_hash_count=20
      bloom_oldest=1
      cache=213
      cache_minimum=20
      checkpoints=off
      checkpoint_log_size=161
      checkpoint_wait=31
      checksum=uncompressed
      chunk_size=8
      compaction=0
      compression=none
      data_extend=0
      data_source=table
      delete_pct=39
      dictionary=0
      direct_io=0
      encryption=none
      evict_max=3
      file_type=row-store
      firstfit=0
      huffman_key=0
      huffman_value=0
      independent_thread_rng=1
      in_memory=1
      insert_pct=3
      internal_key_truncation=1
      internal_page_max=15
      isolation=snapshot
      key_gap=13
      key_max=32
      key_min=30
      leaf_page_max=10
      leak_memory=0
      logging=0
      logging_archive=0
      logging_compression=snappy
      logging_file_max=242288
      logging_prealloc=1
      long_running_txn=0
      lsm_worker_threads=3
      memory_page_max=8
      merge_max=16
      mmap=1
      modify_pct=14
      ops=0
      prefix_compression=1
      prefix_compression_min=0
      prepare=0
      quiet=1
      random_cursor=0
      read_pct=13
      rebalance=0
      repeat_data_pct=32
      reverse=0
      rows=1000000
      runs=1
      salvage=0
      split_pct=86
      statistics=0
      statistics_server=0
      threads=7
      timer=4
      timing_stress_aggressive_sweep=0
      timing_stress_checkpoint=0
      timing_stress_lookaside_sweep=0
      timing_stress_split_1=0
      timing_stress_split_2=0
      timing_stress_split_3=0
      timing_stress_split_4=0
      timing_stress_split_5=0
      timing_stress_split_6=0
      timing_stress_split_7=0
      timing_stress_split_8=0
      transaction_timestamps=1
      transaction-frequency=100
      truncate=1
      value_max=80
      value_min=15
      verify=0
      wiredtiger_config=
      write_pct=31
      ############################################ 

      SUMMARY:
      During the shutdown of server sometimes it may crash instead of a normal shutdown due to race conditions between transaction and eviction threads.

            Assignee:
            haribabu.kommi@mongodb.com Haribabu Kommi
            Reporter:
            luke.chen@mongodb.com Luke Chen
            Votes:
            0 Vote for this issue
            Watchers:
            5 Start watching this issue

              Created:
              Updated:
              Resolved: