Im trying to run cardano-cli query ledger-state --mainnet --allegra-era --out-file ledger.json
After some time the commands returns Killed in terminal.
ledger.json is arount 10mb in size and is incomplete so Im unable to parse the json-file.
Could this be a memory och swapfile issue perhaps? I have around 3b of free ram so i dont think its that.
We also dump the ledger state every 5 days to determine the block schedule, and it has never failed for us with 4GB RAM + 8GB swap. We only have 8GB because I’ve seen swap use relays go up to 5GB on relays on rare occasions… never the BP… and I hate things that aren’t powers of 2.
The general rule for UNIX systems is to have swap at least equal to the amount of physical RAM. You may need a bit more in this case because it needs do read the whole ledger into memory before dumping it. The best way to find the block schedule is what you are already doing… you just need to increase the swap even more.