From e5592c4bab058e154f68858dcb41eed6c2f0f18a Mon Sep 17 00:00:00 2001 From: moneromooo-monero Date: Sun, 17 Jun 2018 22:07:15 +0100 Subject: rpc: add blockchain disk size to getinfo This should help new nodes predict how much disk space will be needed for a full sync --- src/rpc/core_rpc_server.cpp | 2 ++ 1 file changed, 2 insertions(+) (limited to 'src/rpc/core_rpc_server.cpp') diff --git a/src/rpc/core_rpc_server.cpp b/src/rpc/core_rpc_server.cpp index dc7b6b30f..357ef72be 100644 --- a/src/rpc/core_rpc_server.cpp +++ b/src/rpc/core_rpc_server.cpp @@ -207,6 +207,7 @@ namespace cryptonote boost::shared_lock lock(m_bootstrap_daemon_mutex); res.was_bootstrap_ever_used = m_was_bootstrap_ever_used; } + res.database_size = m_core.get_blockchain_storage().get_db().get_database_size(); return true; } //------------------------------------------------------------------------------------------------------------------------------ @@ -1577,6 +1578,7 @@ namespace cryptonote boost::shared_lock lock(m_bootstrap_daemon_mutex); res.was_bootstrap_ever_used = m_was_bootstrap_ever_used; } + res.database_size = m_core.get_blockchain_storage().get_db().get_database_size(); return true; } //------------------------------------------------------------------------------------------------------------------------------ -- cgit v1.2.3