UBSAN storage/rocksdb/rocksdb/util/coding.h:384:3: runtime error: load of misaligned address

Description

just a few tests that illustrate the issue:
rocksdb.rpl.rpl_rocksdb_row_img_blobs 'row-write-prepared'
rocksdb.rpl.rpl_rocksdb_row_img_idx_min 'row-write-prepared'
rocksdb.rpl.rpl_rocksdb_row_img_idx_full 'row-write-prepared'
rocksdb.rpl.rpl_rocksdb_row_img_idx_noblob 'row-write-prepared'
rocksdb.rpl.rpl_rocksdb_row_img_idx_noblob 'row-write-committed'

storage/rocksdb/rocksdb/util/coding.h:384:3: runtime error: load of misaligned address 0x60e0000024ac for type 'const long unsigned int', which requires 8 byte alignment 0x60e0000024ac: note: pointer points here 01 00 be be 00 00 00 00 02 00 00 00 01 00 be be 00 00 00 00 00 00 00 00 b9 96 6e cc 00 00 00 00 ^ #0 0x7f3a8d991ced in void rocksdb::GetUnaligned<unsigned long>(unsigned long const*, unsigned long*) /home/glorch/dev/8.0/percona-server/storage/rocksdb/rocksdb/util/coding.h:384 #1 0x7f3a8d991ced in rocksdb::SerializeSingleOptionHelper(char const*, rocksdb::OptionType, std::__cxx11::basic_string<char, std::char_traits<char>, std::allocator<char> >*) /home/glorch/dev/8.0/percona-server/storage/rocksdb/rocksdb/options/options_helper.cc:559 #2 0x7f3a8dbb6ef3 in SerializeSingleBlockBasedTableOption /home/glorch/dev/8.0/percona-server/storage/rocksdb/rocksdb/table/block_based_table_factory.cc:256 #3 0x7f3a8dbb6ef3 in rocksdb::BlockBasedTableFactory::GetOptionString(std::__cxx11::basic_string<char, std::char_traits<char>, std::allocator<char> >*, std::__cxx11::basic_string<char, std::char_traits<char>, std::allocator<char> > const&) const /home/glorch/dev/8.0/percona-server/storage/rocksdb/rocksdb/table/block_based_table_factory.cc:277 #4 0x7f3a8dac4af0 in rocksdb::PersistRocksDBOptions(rocksdb::DBOptions const&, std::vector<std::__cxx11::basic_string<char, std::char_traits<char>, std::allocator<char> >, std::allocator<std::__cxx11::basic_string<char, std::char_traits<char>, std::allocator<char> > > > const&, std::vector<rocksdb::ColumnFamilyOptions, std::allocator<rocksdb::ColumnFamilyOptions> > const&, std::__cxx11::basic_string<char, std::char_traits<char>, std::allocator<char> > const&, rocksdb::Env*) /home/glorch/dev/8.0/percona-server/storage/rocksdb/rocksdb/options/options_parser.cc:89 #5 0x7f3a8cb79f13 in rocksdb::DBImpl::WriteOptionsFile(bool, bool) /home/glorch/dev/8.0/percona-server/storage/rocksdb/rocksdb/db/db_impl.cc:2568

Environment

None

Smart Checklist

Activity

Show:

George Lorch September 19, 2018 at 8:33 PM

Upstream RocksDB actually has this mostly handled when building stand alone. The problem is that MyRocks does not build RocksDB as a subproject, instead is 'sources' the files directly into the MyRocks compilation module. By doing this, the CMakeLists.txt magic that sets up RocksDB for UBSAN runs within the RocksDB project is never invoked.

This should be sent upstream.

Done

Details

Assignee

Reporter

Time tracking

30m logged

Components

Fix versions

Affects versions

Priority

Smart Checklist

Created September 19, 2018 at 2:50 PM
Updated March 6, 2024 at 12:50 PM
Resolved November 14, 2018 at 9:17 PM

Flag notifications