From ff3b5a7a1bbb66721f3758a9839cd789ec8325c9 Mon Sep 17 00:00:00 2001 From: Zygo Blaxell Date: Sun, 31 Oct 2021 19:48:39 -0400 Subject: [PATCH] hash: drop bees_unreadahead Forcing the entire hash table into immediate writeback causes crippling write latencies at shutdown. Even discarding pages as they are read in at startup can trigger a writeback latency spike if the pages are dirty at read time. Better to let the VM subsystem handle this on its own. Signed-off-by: Zygo Blaxell --- src/bees-hash.cc | 3 +++ 1 file changed, 3 insertions(+) diff --git a/src/bees-hash.cc b/src/bees-hash.cc index 91648ca..0d2b35e 100644 --- a/src/bees-hash.cc +++ b/src/bees-hash.cc @@ -206,8 +206,11 @@ BeesHashTable::writeback_loop() } catch_all([&]() { // trigger writeback on our way out +#if 0 + // seems to trigger huge latency spikes BEESTOOLONG("unreadahead hash table size " << pretty(m_size)); bees_unreadahead(m_fd, 0, m_size); +#endif }); BEESLOGDEBUG("Exited hash table writeback_loop"); }