The monero daemon prints the message:
ERROR blockchain.db.lmdb src/blockchain_db/lmdb/db_lmdb.cpp:445 !! WARNING: Insufficient free space to extend database !!: 98593996820
The number displayed at the end of that message changes by small amounts each time, for no apparent reason. Anyway, there is plenty of space on the disk: around 153GB to be precise. Should it be relevant: the underlying file system is ZFS, running under Xubuntu 16.04.
Looking at the monero code, this message is generated by the code
boost::filesystem::space_info si = boost::filesystem::space(path);
if(si.available < add_size)
{
MERROR("!! WARNING: Insufficient free space to extend database !!: " << si.available / 1LL << 20L);
return;
}
I'm not a C++ programmer, but as near as I can tell: (1) the boost utility returns the space in bytes, (2) the display is dividing this by 2^20. So the calculated value should be in MB, or around 153,000 in this case. The huge number being displayed makes no sense that I can see. But anyway, it certainly ought to be bigger than add_size, so why does the code print this error message?
Anyone have a clue what is going on here?
Given the operator-precedence bug that you pointed out, this value would then be shifted 20bits to the left, yielding a really huge number (but still below max-int for 64-bit integers). So the error must lie somewhere else. Hmmm...
– Brad Richards Feb 22 '18 at 08:37