Farmer only has 10 connected peers

Hi everyone!

My farmer has been running great for a week after having to reinstall everything. I was connected to 80 peers as usual. 2 nights ago my internet went out for about 2 hours overnight, and then when it came back online I found I am online connected to 10 peers now (it hovers been 9 and 10).

I have been forwarding on port 8444 for a while( double checked this and the port is open and router settings have not changed). I have restarted chia about 3 times, and my router also, and it makes no difference. It will only connect to a max of 10 peers, and this began after the brief internet outage. Iā€™ve checked the config file and nothing changed in there (it still says 80 peers max, 10 peers max outbound).

Any ideas as to what is causing this? Is only being connected to 10 peers something to be concerned about? I have a pretty powerful farming machine (32 core Xeon v2).

Thanks in advance!

What version chia are you on? And windows or linux? Do have enough space where the database are stored? Any other internet issues that you can find out? Some some questions so other might be able to just in quicker for you.

1 Like

Iā€™m on the latest version, 1.3.3, and running Ubuntu. Plenty of free space on the internal SSD and running DB V2. No other internet issues once it came back on the other night. Thanks!

I would change the outbound count to 12, and restart. If you get 12, we are certain that you have problem with your inbound connection (router or local iptables/firewalld).

Although, someone mentioned similar thing a couple of weeks ago or so, and also after some problems with the ISP. Maybe this is a temporary problem related to how introducer works. It may be sticking to your old IP address until someone gives it a solid kick.

Still, having 10 peers is not a problem at all, so at least this is not a pressing issue.

1 Like

Thank you! I will do this and see what happens.

1 Like

Outbound peers is what needs altering.
After updating to latest version I had 8 peers.

My outbound peer count was at 8.
Put it to 40, I now have 40.

Itā€™s odd, as the line beneath it says target peer count 80, but itā€™s clearly using the outbound no not the target no.

I read this from jacek hereā€¦

2 Likes

Yup, that works great, but it implies that the inbound peers are not connecting (port not forwarded, no UPnP, local firewall blocks it). However, whether the node connects to other nodes, or other nodes connect to it, it really doesnā€™t matter, as far as connections go.

So, I put my target per count at about 5 more than the outbound, so if needed can check whether inbound connections are working. Also, what I have noticed is that with inbound connections open, I usually get a couple of wallets connecting to my node. I guess, we may see more of those wallets connecting, as those may be just pure wallets (without the local blockchain db).

I think I messed up the install lol.
You get the box that asks if you want to let it through the firewall, I hit cancel by mistake .

But if it runs fine Iā€™ll leave it.

1 Like

Just stop it and reinstall it. I have done that when my mouse was tired, had to reinstall it and answer yes. to make it open.

1 Like

Just wanted to send a follow up. I believe the issue is most definitely related to my ISP. I did not touch any settings and I am currently connected to 13 nodes. I checked this morning and my ISP (Verizon) is still reporting an outage at my location (even though my internet is working). I guess the outage is affecting certain things and port forwarding might be one of them. So I will sit tight and wait to see what happens. Thanks again for everyones help!

I find it hard to imagine ( but it could be so ) that any outage is anything but that.
Your router port forwards, not the providerā€¦

I think your just not part of the outage , or only partially affected possibly, but prob many in ur area are, hence you see this info from your provider.

Few weeks ago I had issues with Internet provider and after 2 days he fixed the line, but now I have new IP Address.
After internet was fixed - I had serious issues with my connections - no changes into the configuration and NAT is working as expected. I leave it - and now 2-3 weeks later I have between 50 and 70 connections (no any configuration changes or reboots) and they are growing very slowly. I think that there is a some kind of problems with nodes addresses distrubution.

You have to remember that other people are rebooting their machines also and their connection is now dropped etc. They will come back in time.

Then we need to define time.

Assuming that there are 200k nodes out there, mostly stable (applying patches once a month) and that the max round trip between any two nodes is around 200-300ms, one could expect to connect to 1 node in just a few seconds (how long does it take to load google.com or any other HTTPS site?). So, what would be the explanation to jump from seconds per connection to days per 20-80 connections?

Also, assuming that those nodes are going down (ā€œpeople are rebooting their machinesā€) that would imply that we would see plenty of nodes showing up and then disappearing, and we rarely see that (peers are only shown when connections are at least partially established).

I dropped one node and monitored debug.log. The node established a new connection after ~40 seconds from when it logged the first ā€˜cannot connect to hostā€™ line. It could not connect to 3 peers. Those 3 disconnections came a second apart or so. (I am not sure what took that 40 second to connect to the fourth node, though.) Still, that is 1 minute per peer, and we can assume that when node needs to establish all the connections when starting, it can chase not just one peer at a time, but rather try to get n nodes in one shot. And even if we assume that it takes 1 minute to establish one connection, and those connections are serialized, that is just an hour or so.

By the way, all that is not to say that having 10 nodes is bad (as mentioned above, it is plenty good). It is an orthogonal issue.

Took me a good few hrs to hit 40 peers after I altered .yaml.

Like many many hours, but under 12 I think.
Of course my firewall is blocking also, but it got there.

Noticed it had dropped to 37, next check back to 40.

Hard to define time, time is x, system specifics alter xā€™s value .

What I was trying to say is that when you program on the network level, the timings that you are dealing with are sub-second. There are no slow things, even if the code is sloppy. Therefore, the issue is not really on that side, and it would be good to know what the source is. My take is that it is most likely the chiaā€™s introducer that may be providing stale data, or the same data over and over.

Whatā€™s the issue with only 10 connected peers?

Thatā€™s what I have always had :worried:

1 Like

Also, one thing worth to notice is that when chia is started, it starts syncing when the very first node is there, and when getting next connections is slow, that one node is good enough to get fully synced.

As stated many times (also in this thread), nothing.

1 Like

Just a question, I have bunches of full nodes connected to me with the height number, I also have Wallets but no height number?? What gives?

Nodes show their height, as that represent blockchain state, so how that is potentially relevant to your node.

On the other hand, those wallets are most likely syncing from scratch wallets (Down MiB is always zero, I think), or maybe just pure wallet setups (i.e., no blockchain db behind). So, maybe it was decided that wallet height is irrelevant.

(When your blockchain is fully synced, I think that the wallet is not connecting anymore to any other peers. Chia has a notion of trusted peers, and my take is that in this case the wallet ā€œprefersā€ that trusted connection over talking to other nodes. Although, I donā€™t know what wallet does when syncing from scratch and having the local node fully synced (as I noticed it when my bc db was v1 and/or not fully synced). There is new Connections section on the Wallet panel that you can check what your wallet is doing.)

1 Like