{"action":"created","issue":{"url":"https://api.github.com/repos/scylladb/scylla/issues/698","labels_url":"https://api.github.com/repos/scylladb/scylla/issues/698/labels{/name}","comments_url":"https://api.github.com/repos/scylladb/scylla/issues/698/comments","events_url":"https://api.github.com/repos/scylladb/scylla/issues/698/events","html_url":"https://github.com/scylladb/scylla/issues/698","id":123637743,"number":698,"title":"Infinite loop in lsa","user":{"login":"noamha","id":2642373,"avatar_url":"https://avatars.githubusercontent.com/u/2642373?v=3","gravatar_id":"","url":"https://api.github.com/users/noamha","html_url":"https://github.com/noamha","followers_url":"https://api.github.com/users/noamha/followers","following_url":"https://api.github.com/users/noamha/following{/other_user}","gists_url":"https://api.github.com/users/noamha/gists{/gist_id}","starred_url":"https://api.github.com/users/noamha/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/noamha/subscriptions","organizations_url":"https://api.github.com/users/noamha/orgs","repos_url":"https://api.github.com/users/noamha/repos","events_url":"https://api.github.com/users/noamha/events{/privacy}","received_events_url":"https://api.github.com/users/noamha/received_events","type":"User","site_admin":false},"labels":[{"url":"https://api.github.com/repos/scylladb/scylla/labels/bug","name":"bug","color":"eb6420"},{"url":"https://api.github.com/repos/scylladb/scylla/labels/showstopper","name":"showstopper","color":"e11d21"}],"state":"open","locked":false,"assignee":null,"milestone":{"url":"https://api.github.com/repos/scylladb/scylla/milestones/1","html_url":"https://github.com/scylladb/scylla/milestones/GA","labels_url":"https://api.github.com/repos/scylladb/scylla/milestones/1/labels","id":1164307,"number":1,"title":"GA","description":null,"creator":{"login":"dorlaor","id":1735237,"avatar_url":"https://avatars.githubusercontent.com/u/1735237?v=3","gravatar_id":"","url":"https://api.github.com/users/dorlaor","html_url":"https://github.com/dorlaor","followers_url":"https://api.github.com/users/dorlaor/followers","following_url":"https://api.github.com/users/dorlaor/following{/other_user}","gists_url":"https://api.github.com/users/dorlaor/gists{/gist_id}","starred_url":"https://api.github.com/users/dorlaor/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/dorlaor/subscriptions","organizations_url":"https://api.github.com/users/dorlaor/orgs","repos_url":"https://api.github.com/users/dorlaor/repos","events_url":"https://api.github.com/users/dorlaor/events{/privacy}","received_events_url":"https://api.github.com/users/dorlaor/received_events","type":"User","site_admin":false},"open_issues":166,"closed_issues":41,"state":"open","created_at":"2015-06-15T06:37:52Z","updated_at":"2015-12-23T13:18:00Z","due_on":null,"closed_at":null},"comments":5,"created_at":"2015-12-23T10:43:00Z","updated_at":"2015-12-23T13:22:58Z","closed_at":null,"body":"```\r\n(gdb) thread 7\r\n[Switching to thread 7 (Thread 0x7f389258e700 (LWP 11958))]\r\n#0  get_next (n=<synthetic pointer>) at /usr/include/boost/intrusive/detail/list_node.hpp:58\r\n58      /usr/include/boost/intrusive/detail/list_node.hpp: No such file or directory.\r\n(gdb) bt\r\n#0  get_next (n=<synthetic pointer>) at /usr/include/boost/intrusive/detail/list_node.hpp:58\r\n#1  operator++ (this=<synthetic pointer>) at /usr/include/boost/intrusive/detail/list_iterator.hpp:76\r\n#2  boost::heap::binomial_heap<logalloc::segment*, boost::heap::compare<logalloc::segment_occupancy_descending_less_compare>, boost::heap::allocator<logalloc::prepared_buffers_allocator<logalloc::segment*> >, boost::parameter::void_, boost::parameter::void_>::merge_and_clear_nodes (this=this@entry=0x601000185e30, rhs=...)\r\n    at /usr/include/boost/heap/binomial_heap.hpp:730\r\n#3  0x00000000007e4bdd in boost::heap::binomial_heap<logalloc::segment*, boost::heap::compare<logalloc::segment_occupancy_descending_less_compare>, boost::heap::allocator<logalloc::prepared_buffers_allocator<logalloc::segment*> >, boost::parameter::void_, boost::parameter::void_>::pop (this=this@entry=0x601000185e30)\r\n    at /usr/include/boost/heap/binomial_heap.hpp:410\r\n#4  0x00000000007e5466 in logalloc::region_impl::compact (this=this@entry=0x601000185e10) at utils/logalloc.cc:975\r\n#5  0x00000000007e147b in logalloc::tracker::impl::reclaim (this=0x60100002c0e0, memory_to_release=memory_to_release@entry=10485760) at utils/logalloc.cc:1232\r\n#6  0x00000000007e1dd4 in reclaim (bytes=10485760, this=<optimized out>) at utils/logalloc.cc:95\r\n#7  operator() (__closure=<optimized out>) at utils/logalloc.cc:85\r\n#8  std::_Function_handler<memory::reclaiming_result(), logalloc::tracker::tracker()::<lambda()> >::_M_invoke(const std::_Any_data &) (__functor=...)\r\n    at /usr/include/c++/5.3.1/functional:1857\r\n#9  0x00000000004ec3e6 in operator() (this=<optimized out>) at /usr/include/c++/5.3.1/functional:2271\r\n#10 do_reclaim (this=<optimized out>) at core/memory.hh:100\r\n#11 memory::cpu_pages::run_reclaimers (this=this@entry=0x7f3892588bc0, scope=scope@entry=memory::reclaimer_scope::sync) at core/memory.cc:762\r\n#12 0x00000000004ecadd in memory::cpu_pages::allocate_large_and_trim<memory::cpu_pages::allocate_large(unsigned int)::<lambda(unsigned int, unsigned int)> >(unsigned int, memory::cpu_pages::<lambda(unsigned int, unsigned int)>) (this=0x7f3892588bc0, this@entry=<error reading variable: Asked for position 0 of stack, stack only has 0 elements on it.>,\r\n    n_pages=n_pages@entry=64, trimmer=..., trimmer@entry=...) at core/memory.cc:477\r\n#13 0x00000000004ed1ba in allocate_large (n_pages=<optimized out>, this=<optimized out>) at core/memory.cc:489\r\n#14 memory::allocate_large (size=<optimized out>) at core/memory.cc:922\r\n#15 0x00000000004eda45 in operator new[] (size=<optimized out>) at core/memory.cc:1241\r\n#16 0x00000000007ddd7a in logalloc::segment_pool::refill_emergency_reserve (this=0x7f3892589df0,\r\n    this@entry=<error reading variable: Asked for position 0 of stack, stack only has 0 elements on it.>) at utils/logalloc.cc:313\r\n#17 0x00000000007e1e33 in logalloc::allocating_section::guard::enter (this=this@entry=0x7f3892587070, self=...) at utils/logalloc.cc:1357\r\n#18 0x00000000007c738b in operator()<row_cache::make_reader(const partition_range&)::<lambda()> > (func=<optimized out>, r=..., this=0x601000119508) at utils/logalloc.hh:291\r\n#19 row_cache::make_reader (this=this@entry=0x601000119450, range=...) at row_cache.cc:366\r\n#20 0x000000000071b255 in column_family::make_reader (this=0x601000119108, range=...) at database.cc:311\r\n#21 0x000000000071b48a in column_family::query(query::read_command const&, std::vector<range<dht::ring_position>, std::allocator<range<dht::ring_position> > > const&)::{lambda(query_state&)#1}::operator()(query_state&) const::{lambda()#1}::operator()() const () at database.cc:1479\r\n#22 0x0000000000743641 in column_family::query (this=0x601000119108, cmd=..., partition_ranges=std::vector of length 1, capacity 1 = {...})\r\n    at /usr/src/debug/scylla-server-0.13.2/seastar/core/future-util.hh:146\r\n#23 0x00000000007700c9 in database::query (this=<optimized out>, cmd=..., ranges=std::vector of length 1, capacity 1 = {...}) at database.cc:1516\r\n#24 0x0000000000a8321f in operator() (db=..., __closure=0x60200003d310) at service/storage_proxy.cc:1910\r\n#25 operator() (__closure=0x60200003d308, __closure@entry=0x7f3892587738) at /usr/src/debug/scylla-server-0.13.2/seastar/core/sharded.hh:286\r\n#26 futurize<future<foreign_ptr<lw_shared_ptr<query::result> > > >::apply<seastar::sharded<Service>::invoke_on(unsigned int, Func&&) [with Func = service::storage_proxy::query_singular_local(lw_shared_ptr<query::read_command>, const partition_range&)::<lambda(database&)>; Ret = future<foreign_ptr<lw_shared_ptr<query::result> > >; Service = database]::<lambda()>&>((anonymous namespace)::sharded<database>::<lambda()> &) (func=...) at /usr/src/debug/scylla-server-0.13.2/seastar/core/future.hh:1192\r\n#27 0x0000000000aa0b15 in smp_message_queue::async_work_item<seastar::sharded<Service>::invoke_on(unsigned int, Func&&) [with Func = service::storage_proxy::query_singular_local(lw_shared_ptr<query::read_command>, const partition_range&)::<lambda(database&)>; Ret = future<foreign_ptr<lw_shared_ptr<query::result> > >; Service = database]::<lambda()> >::process(void) (this=0x60200003d300) at /usr/src/debug/scylla-server-0.13.2/seastar/core/reactor.hh:502\r\n#28 0x00000000004a3ab0 in smp_message_queue::process_queue<2ul, smp_message_queue::process_incoming()::<lambda(smp_message_queue::work_item*)> >(smp_message_queue::lf_queue &, smp_message_queue::<lambda(smp_message_queue::work_item*)>) (q=..., process=..., this=<optimized out>) at core/reactor.cc:1628\r\n#29 0x00000000004c1e6e in smp::poll_queues () at core/reactor.cc:1631\r\n#30 0x000000000049dc8a in poll_once (this=0x601000111000) at core/reactor.cc:1401\r\n#31 reactor::run (this=0x601000111000) at core/reactor.cc:1379\r\n#32 0x00000000004acd56 in smp::configure(boost::program_options::variables_map)::{lambda()#1}::operator()() const [clone .constprop.2721] () at core/reactor.cc:2019\r\n#33 0x000000000047231e in dpdk_thread_adaptor (f=<optimized out>) at /usr/include/c++/5.3.1/functional:2271\r\n#34 0x000000000064100b in eal_thread_loop ()\r\n#35 0x00007f389980b555 in start_thread () from /lib64/libpthread.so.0\r\n#36 0x00007f3899546b9d in clone () from /lib64/libc.so.6\r\n```"},"comment":{"url":"https://api.github.com/repos/scylladb/scylla/issues/comments/166892512","html_url":"https://github.com/scylladb/scylla/issues/698#issuecomment-166892512","issue_url":"https://api.github.com/repos/scylladb/scylla/issues/698","id":166892512,"user":{"login":"avikivity","id":1017210,"avatar_url":"https://avatars.githubusercontent.com/u/1017210?v=3","gravatar_id":"","url":"https://api.github.com/users/avikivity","html_url":"https://github.com/avikivity","followers_url":"https://api.github.com/users/avikivity/followers","following_url":"https://api.github.com/users/avikivity/following{/other_user}","gists_url":"https://api.github.com/users/avikivity/gists{/gist_id}","starred_url":"https://api.github.com/users/avikivity/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/avikivity/subscriptions","organizations_url":"https://api.github.com/users/avikivity/orgs","repos_url":"https://api.github.com/users/avikivity/repos","events_url":"https://api.github.com/users/avikivity/events{/privacy}","received_events_url":"https://api.github.com/users/avikivity/received_events","type":"User","site_admin":false},"created_at":"2015-12-23T13:22:58Z","updated_at":"2015-12-23T13:22:58Z","body":"Could be that we had _size=29, called new segment, which freed one segment, which then sneaked into  _emergency_reserve, increasing _size to 30."}}