miningcore icon indicating copy to clipboard operation
miningcore copied to clipboard

MonitorMode: False

Open david739 opened this issue 1 year ago • 6 comments

hello, the system shows an error out of nowhere, does anyone know why, everything was fine until yesterday

[2023-02-10 11:21:02.1601] [I] [IpRateLimitMiddleware] Request get:/api/pools from IP xxx has been blocked, quota 8/1s exceeded by 1. Blocked by rule *, TraceIdentifier 0HMOBA1FF08VN:0000000F. MonitorMode: False

david739 avatar Feb 10 '23 10:02 david739

That isn't an error. Some client just hit the rate limit you configured for the API.

jon4hz avatar Feb 11 '23 19:02 jon4hz

hi, I have configured the api, where can I change it please?

david739 avatar Feb 14 '23 16:02 david739

Somewhere in your api config you probably have:

"rules": [
    {
        "Endpoint": "*",
        "Period": "1s",
        "Limit": 8
    }
]

Just change the limit to something higher and you'll be fine.

jon4hz avatar Feb 14 '23 17:02 jon4hz

hi, I didn't find any apiconfig in the miningcore folder, I only have config.schema.json there, and if it's not that, where should I look for the file

"ApiConfig": { "type": [ "object", "null" ], "properties": { "adminIpWhitelist": { "type": [ "array", "null" ], "items": { "type": [ "string", "null" ] } }, "adminPort": { "type": [ "integer", "null" ] }, "enabled": { "type": "boolean" }, "legacyNullValueHandling": { "type": "boolean" }, "listenAddress": { "type": [ "string", "null" ] }, "metricsIpWhitelist": { "type": [ "array", "null" ], "items": { "type": [ "string", "null" ] } }, "metricsPort": { "type": [ "integer", "null" ] }, "port": { "type": "integer" }, "rateLimiting": { "$ref": "#/definitions/ApiRateLimitConfig" }, "tls": { "$ref": "#/definitions/ApiTlsConfig" } } }, "ApiRateLimitConfig": { "type": [ "object", "null"

david739 avatar Feb 14 '23 17:02 david739

the api config is part of the cluster config, probably named just "config.json". The file where you put all the other configuration for your pools, database, etc.

jon4hz avatar Feb 14 '23 17:02 jon4hz

I already have it, I overlooked it, thanks a lot

david739 avatar Feb 14 '23 17:02 david739