Skip to main content

getmemoryinfo

Overview

The 'getmemoryinfo' RPC Method returns an object that contains information regarding memory usage.

Request

wget --no-check-certificate --quiet \
--method POST \
--timeout=0 \
--header 'Content-Type: application/json' \
--header 'accept: application/json' \
--header 'X-CoinAPI-Key: 4303fb63-adec-42dc-b571-74bc2f2a5167' \
--body-data '{"jsonrpc":"2.0","id":1,"method":"getmemoryinfo","params": [ ]}' \
'https://bitcoin-mainnet.node.coinapi.io'

Request Parameters

mode (string): It determines what kind of information is returned. "stats" returns general statistics about memory usage in the daemon and "mallocinfo" returns an XML string describing low-level heap state

Response

{
"result": {
"locked": {
"used": 240,
"free": 65296,
"total": 65536,
"locked": 65536,
"chunks_used": 1,
"chunks_free": 1
}
},
"error": null,
"id": 1
}

locked: Information about locked memory manager used: Number of bytes used free: Number of bytes available in current arenas total: Total number of bytes managed locked: Amount of bytes that succeeded locking. If this number is smaller than total, locking pages failed at some point and key data could be swapped to disk chunks_used: Number allocated chunks chunks_free: Number of unused chunks