avalanchego icon indicating copy to clipboard operation
avalanchego copied to clipboard

Run Node with Indexer enabled, but logs say that address transaction indexing is disabled

Open minzak opened this issue 3 years ago • 0 comments

I have the latest 1.8.6 Avalanche node and enabled indexer in service, but when running requests in logs I see that the indexer is not enabled address transaction indexing is disabled

Here is part of avalanche.service where i use --index-enabled

WorkingDirectory=/opt/avalanchego
ExecStart=/opt/avalanchego/avalanchego --public-ip=5.254.XX.XX --http-host=127.0.0.1 --http-port=9650 --api-admin-enabled \
 --db-dir="/opt/avalanchego/db" --index-enabled \
 --log-dir="/var/log/avalanche" --log-level=info \
 --staking-enabled --staking-port=9651 --staking-tls-cert-file="/opt/avalanchego/staking/staker.crt" --staking-tls-key-file="/opt/avalanchego/staking/staker.key" \
 --http-tls-enabled --http-tls-cert-file="/opt/cert/fullchain.pem" --http-tls-key-file="/opt/cert/privkey.pem"

I run CURL:

POST https://127.0.0.1:9650/ext/bc/X
Content-Type: application/json;
{
    "jsonrpc": "2.0",
    "id": 1,
    "method": "avm.getAddressTxs",
    "params": {
        "address": "X-avax1zuw4nzzxx00k2anppkvk8w9zf27vkayssznc9c",
        "assetID": "FvwEAhmxKfeiG8SnEvq42hc6whRyY3EFYAvebMqDNDGCgxN5Z"
    }
}

I got response result:

{
    "jsonrpc": "2.0",
    "result": {
        "txIDs": null,
        "cursor": "0"
    },
    "id": 1
}

Also in X.log of avalanche i see:

[09-26|15:46:55.568] INFO <X Chain> avm/vm.go:458 fee asset is established {"alias": "AVAX", "assetID": "FvwEAhmxKfeiG8SnEvq42hc6whRyY3EFYAvebMqDNDGCgxN5Z"}
[09-26|15:46:55.568] INFO <X Chain> avm/vm.go:240 address transaction indexing is disabled
[09-26|15:46:55.569] INFO <X Chain> avalanche/transitive.go:74 initializing consensus engine
[09-26|15:46:55.571] INFO <X Chain> bootstrap/bootstrapper.go:313 starting bootstrap
[09-26|15:47:03.885] INFO <X Chain> common/bootstrapper.go:248 bootstrapping started syncing {"numVerticesInFrontier": 2}
[09-26|15:47:06.276] INFO <X Chain> bootstrap/bootstrapper.go:533 executing transactions
[09-26|15:47:08.512] INFO <X Chain> queue/jobs.go:191 executing operations {"numExecuted": 2500, "numToExecute": 3197, "eta": "1s"}
[09-26|15:47:09.399] INFO <X Chain> queue/jobs.go:210 executed operations {"numExecuted": 3197}
[09-26|15:47:09.399] INFO <X Chain> bootstrap/bootstrapper.go:544 executing vertices
[09-26|15:47:10.950] INFO <X Chain> queue/jobs.go:191 executing operations {"numExecuted": 2500, "numToExecute": 3196, "eta": "0s"}
[09-26|15:47:11.375] INFO <X Chain> queue/jobs.go:210 executed operations {"numExecuted": 3196}
[09-26|16:53:06.505] INFO <X Chain> avalanche/transitive.go:346 consensus starting {"lenFrontier": 1}

I do not understand Indexer is enabled or not? What is wrong?

minzak avatar Sep 27 '22 12:09 minzak