Testnet p2p - no transaction count

Hi guys,

I’ve been running a BP node on the testnet recently using p2p, but I can’t seem to get a transaction count (generally a bad sign for a BP).

Just a note that I am running the BP directly on the testnet, i.e. no relay (I know, I know, but I only have one spare server for the testnet).

tracemempool is true, I’ve got plenty of peers, but I do notice I only have 5 incoming and that hasn’t increased since I started.

Is anyone else getting similar behaviour? (testnet or mainnet using p2p)

Are there any special/different tracing settings for 1.34.1 on p2p?

Screenshot from 2022-06-13 18-13-10

I see people running it on mainnet so it should work, but I don’t know the details (you can ask there)

Thanks Alex. The screenshot there has a 0 count as well…

Asking a different question. How can I know my node is processing transactions if the count isn’t working? i.e. it could just be an issue with gLiveView.

It’s only because TraceMemPool is disabled. If you enable it you will see transaction count.

Yeah, I do have tracemempool enabled. So that’s why I am concerned it isn’t behaving correctly.

Hi,

What happens if you run this:

curl -s  127.0.0.1:12798/metrics | grep "cardano_node_metrics_txsInMempool_int"

Returns nothing.

Another note, I get a transaction count when I run in non-p2p mode. So I know the node does work correctly and the transaction count does work.

So I am worried there is something with my p2p setup that doesn’t work right.

What is your ticker/poolid on testnet?

Can you share your testnet-topology.json and testnet-config.json files?

topology

                                                                               
  "LocalRoots": {                                                               
    "groups": [                                                                 
      {                                                                         
        "localRoots": {                                                         
          "accessPoints": [                                                     
            {                                                                   
              "address": "0.tcp.au.ngrok.io",                                 
              "port": 14112                                                      
            }                                                               
         
          ],
          "advertise": false
        },
        "valency": 3
      }
    ]
  },
  "PublicRoots": [
    {
      "publicRoots" : {
        "accessPoints": [
          {
            "address": "relays-new.cardano-mainnet.iohk.io",
            "port": 3001
          }
        ],
        "advertise": false
      },
      "valency": 2
    }
  ],
  "useLedgerAfterSlot": 0
}

config

{
  "AlonzoGenesisFile": "testnet-alonzo-genesis.json",
  "AlonzoGenesisHash": "7e94a15f55d1e82d10f09203fa1d40f8eede58fd8066542cf6566008068ed874",
  "ApplicationName": "cardano-sl",
  "ApplicationVersion": 0,
  "ByronGenesisFile": "testnet-byron-genesis.json",
  "ByronGenesisHash": "96fceff972c2c06bd3bb5243c39215333be6d56aaf4823073dca31afe5038471",
  "LastKnownBlockVersion-Alt": 0,
  "LastKnownBlockVersion-Major": 3,
  "LastKnownBlockVersion-Minor": 0,
  "MaxKnownMajorProtocolVersion": 2,
  "Protocol": "Cardano",
  "RequiresNetworkMagic": "RequiresMagic",
  "ShelleyGenesisFile": "testnet-shelley-genesis.json",
  "ShelleyGenesisHash": "849a1764f152e1b09c89c0dfdbcbdd38d711d1fec2db5dfa0f87cf2737a0eaf4",
  "TraceAcceptPolicy": true,
  "TraceBlockFetchClient": false,
  "TraceBlockFetchDecisions": true,
  "TraceBlockFetchProtocol": false,
  "TraceBlockFetchProtocolSerialised": false,
  "TraceBlockFetchServer": false,
  "TraceChainDb": true,
  "TraceChainSyncBlockServer": false,
  "TraceChainSyncClient": false,
  "TraceChainSyncHeaderServer": false,
  "TraceChainSyncProtocol": false,
  "TraceConnectionManager": true,
  "TraceDNSResolver": true,
  "TraceDNSSubscription": true,
  "TraceDiffusionInitialization": true,
  "TraceErrorPolicy": true,
  "TraceForge": true,
  "TraceHandshake": false,
  "TraceInboundGovernor": true,
  "TraceIpSubscription": true,
  "TraceLedgerPeers": true,
  "TraceLocalChainSyncProtocol": false,
  "TraceLocalErrorPolicy": true,
  "TraceLocalHandshake": false,
  "TraceLocalRootPeers": true,
  "TraceLocalTxSubmissionProtocol": false,
  "TraceLocalTxSubmissionServer": false,
  "TraceMempool": true,
  "TraceMux": true,
  "TracePeerSelection": true,
  "TracePeerSelectionActions": true,
  "TracePublicRootPeers": true,
  "TraceServer": true,
  "TraceTxInbound": true,
  "TraceTxOutbound": true,
  "TraceTxSubmissionProtocol": false,
  "TracingVerbosity": "NormalVerbosity",
  "TurnOnLogMetrics": true,
  "TurnOnLogging": true,
  "TestEnableDevelopmentNetworkProtocols": true,
  "EnableP2P": true, 
  "MaxConcurrencyBulkSync": 2,
  "MaxConcurrencyDeadline": 4,
  "TargetNumberOfRootPeers": 100,
  "TargetNumberOfKnownPeers": 100,
  "TargetNumberOfEstablishedPeers": 50,
  "TargetNumberOfActivePeers": 20,
  "defaultBackends": [
    "KatipBK"
  ],
  "defaultScribes": [
    [
      "StdoutSK",
      "stdout"
    ]
  ],
  "hasEKG": 12788,
  "hasPrometheus": [
    "127.0.0.1",
    12798
  ],
  "minSeverity": "Info",
  "options": {
    "mapBackends": {
      "cardano.node.metrics": [
        "EKGViewBK"
      ],
      "cardano.node.resources": [
        "EKGViewBK"
      ]
    },
    "mapSubtrace": {
      "cardano.node.metrics": {
        "subtrace": "Neutral"
      }
    }
  },
  "rotation": {
    "rpKeepFilesNum": 10,
    "rpLogLimitBytes": 5000000,
    "rpMaxAgeHours": 24
  },
  "setupBackends": [
    "KatipBK"
  ],
  "setupScribes": [
    {
      "scFormat": "ScText",
      "scKind": "StdoutSK",
      "scName": "stdout",
      "scRotation": null
    }
  ]
}

What do you reckon?

Hi,

First of all you should have Valency=1 in your case if you have just one IP behind that DNS name, additionally you have wrong server for testnet - relays-new.cardano-mainnet.iohk.io it should be relays-new.cardano-testnet.iohkdev.io.

Here is my topology, what should work, adjusted for you:

{
	"LocalRoots": {
		"groups": [
			{
				"localRoots": {
					"accessPoints": [
						{
							"address": "0.tcp.au.ngrok.io",
							"port": 3001
						}
					],
					"advertise": false
				},
				"valency": 1
			}
		]
	},
	"PublicRoots": [
		{
			"publicRoots": {
				"accessPoints": [
					{
						"address": "relays-new.cardano-testnet.iohkdev.io",
						"port": 3001
					}
				],
				"advertise": true
			}
		}
	],
	"useLedgerAfterSlot": 0
}

Additionally seems you disabled some metrics in your config. On that point I would enable them all, at least to check if it helps with transaction counts.

Additionally, I do some test on Vasil-testnet and I find some weird things happening with p2p enabled on BP, so it maybe related. Try as last resort to disable TestEnableDevelopmentNetworkProtocols

Here is my config what works on my relay, updated for you:

{
  "AlonzoGenesisFile": "testnet-alonzo-genesis.json",
  "AlonzoGenesisHash": "7e94a15f55d1e82d10f09203fa1d40f8eede58fd8066542cf6566008068ed874",
  "ApplicationName": "cardano-sl",
  "ApplicationVersion": 0,
  "ByronGenesisFile": "testnet-byron-genesis.json",
  "ByronGenesisHash": "96fceff972c2c06bd3bb5243c39215333be6d56aaf4823073dca31afe5038471",
  "LastKnownBlockVersion-Alt": 0,
  "LastKnownBlockVersion-Major": 3,
  "LastKnownBlockVersion-Minor": 0,
  "MaxKnownMajorProtocolVersion": 2,
  "Protocol": "Cardano",
  "RequiresNetworkMagic": "RequiresMagic",
  "ShelleyGenesisFile": "testnet-shelley-genesis.json",
  "ShelleyGenesisHash": "849a1764f152e1b09c89c0dfdbcbdd38d711d1fec2db5dfa0f87cf2737a0eaf4",
  "TraceAcceptPolicy": true,
  "TraceBlockFetchClient": true,
  "TraceBlockFetchDecisions": true,
  "TraceBlockFetchProtocol": true,
  "TraceBlockFetchProtocolSerialised": true,
  "TraceBlockFetchServer": true,
  "TraceChainDb": true,
  "TraceChainSyncBlockServer": true,
  "TraceChainSyncClient": true,
  "TraceChainSyncHeaderServer": true,
  "TraceChainSyncProtocol": true,
  "TraceConnectionManager": true,
  "TraceDNSResolver": true,
  "TraceDNSSubscription": true,
  "TraceDiffusionInitialization": true,
  "TraceErrorPolicy": true,
  "TraceForge": true,
  "TraceHandshake": true,
  "TraceInboundGovernor": true,
  "TraceIpSubscription": true,
  "TraceLedgerPeers": true,
  "TraceLocalChainSyncProtocol": true,
  "TraceLocalErrorPolicy": true,
  "TraceLocalHandshake": true,
  "TraceLocalRootPeers": true,
  "TraceLocalTxSubmissionProtocol": true,
  "TraceLocalTxSubmissionServer": true,
  "TraceMempool": true,
  "TraceMux": true,
  "TracePeerSelection": true,
  "TracePeerSelectionActions": true,
  "TracePublicRootPeers": true,
  "TraceServer": true,
  "TraceTxInbound": true,
  "TraceTxOutbound": true,
  "TraceTxSubmissionProtocol": true,
  "TracingVerbosity": "NormalVerbosity",
  "TurnOnLogMetrics": true,
  "TurnOnLogging": true,
  "TestEnableDevelopmentNetworkProtocols": false,
  "EnableP2P": true,
  "defaultBackends": [
    "KatipBK"
  ],
  "defaultScribes": [
    [
      "StdoutSK",
      "stdout"
    ]
  ],
  "hasEKG": 12788,
  "hasPrometheus": [
    "127.0.0.1",
    12798
  ],
  "minSeverity": "Info",
  "options": {
    "mapBackends": {
      "cardano.node.metrics": [
        "EKGViewBK"
      ],
      "cardano.node.resources": [
        "EKGViewBK"
      ]
    },
    "mapSubtrace": {
      "cardano.node.metrics": {
        "subtrace": "Neutral"
      }
    }
  },
  "rotation": {
    "rpKeepFilesNum": 10,
    "rpLogLimitBytes": 5000000,
    "rpMaxAgeHours": 24
  },
  "setupBackends": [
    "KatipBK"
  ],
  "setupScribes": [
    {
      "scFormat": "ScText",
      "scKind": "StdoutSK",
      "scName": "stdout",
      "scRotation": null
    }
  ]
}

Thanks. And yes, some obvious mistakes there that I didn’t spot!! I’ll tweak and see what happens.

sigh nope, still nothing. I wonder if I roll it back to 1.33.0?

actually, I’ll try go to 1.35.0-rc3 move up in the world!

I doubt that it is version related, I have p2p running for several months without any major problem. I ran it on 1.34.1, 1.35.2 & 1.35.3 and etc.

So what is your current status? Have you tried my configs? Particularly testnet-config.json ?

1 Like

Yeah, I have changed the topology and the config as you had suggested but I still can’t get the transaction count increasing.

I get a transaction count when running on non p2p but I can’t get it on p2p.

Hi,

what is your ticker or better poolid?

Are you sure that your BP is reachable on port 3001 from whole internet and you registered your pool with DNS 0.tcp.au.ngrok.io and 3001 port? For example right now, port 3001 on 0.tcp.au.ngrok.io is closed:

I would like to add that I just copied my config files from this topic - testnet-config and testnet-topology(only updated to respective port and DNS for my testnet pool) and it worked for me, I see mempool transactions.

So I assume maybe your BP is not reachable from outside world?

Thanks for the reply.

I am using a tcp tunnel via ngrok, it is just internally forwarded to the BP port. I have a CGNat connection (starlink) so I have to have a way to get around that. This avoids my having to make a cloud based server or a VPN connection. I have been successfully running this on my mainnet pool [46S] for over a year now, obviously non-p2p though.

My testnet port is currently 0.tcp.au.ngrok.io:19552 The node is up and running now, so you should be able to ping it if you wanted.

A key issue that I may be facing is that my reported address and port, i.e. 0.tcp.au.ngrok.io:19552, doesn’t match my “public” ip address, given I am on CGNat. This messed up the topology updated API but a workout was developed for that. I am hoping that p2p avoids this issue.

I have plenty of incoming and outgoing peers, so I can’t believe that it is a connection issue, but more likely something wrong with my node config.

I’ll get a few things tidied up on it and try a few other ideas.

Ultimately, it is good to know that p2p doesn’t break the transaction count, i.e. you’re getting a count happily, so it means I have something going wrong. The alternative was that the count wasn’t working on 1.34.1 and p2p which mean I was on a wild goose chase.

Hi,

what is your ticker or better poolid in testnet?

Sorry, I’ve just caught covid, so I’m a bit slow at replying now,

ID is e902ca3028ad5a383e526c78abf2dd8ba53807f91aba20565266bed5

I re-did the pool registration as I had lost the keys from my last testnet pool. But a node should process transactions whether or not it is a registered pool. The pool won’t mint blocks obviously, but it should process transactions.

If you don’t have registered your pool, then how you will start your BP without necessary files like:

KES=${NODE_HOME}/kes.skey
VRF=${NODE_HOME}/vrf.skey
CERT=${NODE_HOME}/node.cert