Skip to content

Conversation

maflcko
Copy link
Member

@maflcko maflcko commented Dec 14, 2020

This adds some random fixed seeds for signet. They might not work, but it is better than nothing.

@maflcko
Copy link
Member Author

maflcko commented Dec 14, 2020

Can be tested as specified in #20637 with an empty datadir:


... (init)

# reading vSeeds:

2020-12-14T09:33:36Z trying connection ntv3mtqw5wt63red.onion:38333 lastseen=0.0hrs
2020-12-14T09:33:36Z Cannot create socket for ntv3mtqw5wt63red.onion:38333: unsupported network
2020-12-14T09:33:37Z trying connection 178.128.221.177 lastseen=0.0hrs
...
2020-12-14T09:33:38Z received: sendaddrv2 (0 bytes) peer=0
2020-12-14T09:33:38Z disconnecting peer=0


... (wait)

# reading vFixedSeeds:

2020-12-14T09:34:37Z Adding fixed seed nodes as DNS doesn't seem to be available.
2020-12-14T09:34:37Z IP 165.232.44.123 mapped to AS0 belongs to new bucket 527
2020-12-14T09:34:37Z IP 106.157.214.199 mapped to AS0 belongs to new bucket 668
2020-12-14T09:34:37Z IP 31.14.40.19 mapped to AS0 belongs to new bucket 313
2020-12-14T09:34:37Z IP 134.209.26.10 mapped to AS0 belongs to new bucket 668
2020-12-14T09:34:37Z IP 178.128.221.177 mapped to AS0 belongs to new bucket 367
2020-12-14T09:34:37Z IP 103.16.128.63 mapped to AS0 belongs to new bucket 843
2020-12-14T09:34:37Z IP 153.126.143.201 mapped to AS0 belongs to new bucket 744
2020-12-14T09:34:37Z IP 192.241.163.142 mapped to AS0 belongs to new bucket 830
2020-12-14T09:34:37Z trying connection 153.126.143.201:38333 lastseen=292.6hrs
2020-12-14T09:34:37Z Added connection peer=1
2020-12-14T09:34:37Z sending version (103 bytes) peer=1
2020-12-14T09:34:37Z send version message: version 70016, blocks=0, us=[::]:0, peer=1

@jonatack
Copy link
Member

Maybe for mainnet tor v3 as well for bootstrapping connections in 0.21.0

@DrahtBot
Copy link
Contributor

DrahtBot commented Dec 14, 2020

The following sections might be updated with supplementary metadata relevant to reviewers and maintainers.

Conflicts

Reviewers, this pull request conflicts with the following ones:

If you consider this pull request important, please also help to review the conflicting pull requests. Ideally, start with the one that should be merged first.

@laanwj
Copy link
Member

laanwj commented Dec 14, 2020

Concept ACK

@maflcko
Copy link
Member Author

maflcko commented Dec 14, 2020

Maybe for mainnet tor v3 as well for bootstrapping connections in 0.21.0

I'll leave that for a follow-up

@Saibato
Copy link
Contributor

Saibato commented Dec 14, 2020

@jonatack

Maybe for mainnet tor v3 as well for bootstrapping connections in 0.21.0

tyi, long V3 addresses cant be fixed encode, in the old style manner, since ADDRv2 breaks the logic to hide them in ipv6,
So i suggest to add them in chainparams, same effect since Tor skips anyway always the DNS logic and does connect to the seeder .onion anyway and does then the ADDR/ADDRv2. msg bootstrap .

i.e.
vSeeds.emplace_back("178.128.221.177");
vSeeds.emplace_back("2a01:7c8:d005:390::5");
vSeeds.emplace_back("ntv3mtqw5wt63red.onion:38333");
vSeeds.emplace_back("signetsuperv3boostrapxxxxxxxxxxx.onion:38333"); // V3 onion addres

btw, that is even backwards and backport compatible since all old node software is capable to do V3 bootstrap over the ADDR message if the Tor stack on there crufts is updated and Tor V3 aware.

edit@saibato

concept ACK, better than nothing since not all have Tor enabled stacks.

Copy link
Member

@jonatack jonatack left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Tested and this appears to work.

2020-12-14T15:45:25Z init message: Loading P2P addresses...
2020-12-14T15:45:25Z ERROR: DeserializeFileDB: Failed to open file /home/jon/projects/bitcoin/bitcoin/datadir/signet/peers.dat
2020-12-14T15:45:25Z Invalid or missing peers.dat; recreating
2020-12-14T15:45:25Z tor: Got service ID t5acztv2shwvbbyfh6xktlgmryfhsw4ukloo2svlkhllfuwbzahtxlad, advertising service t5acztv2shwvbbyfh6xktlgmryfhsw4ukloo2svlkhllfuwbzahtxlad.onion:38333
2020-12-14T15:45:25Z AddLocal(t5acztv2shwvbbyfh6xktlgmryfhsw4ukloo2svlkhllfuwbzahtxlad.onion:38333,4)
2020-12-14T15:45:25Z ERROR: DeserializeFileDB: Failed to open file /home/jon/projects/bitcoin/bitcoin/datadir/signet/anchors.dat
2020-12-14T15:45:25Z 0 block-relay-only anchors will be tried for connections.
2020-12-14T15:45:25Z init message: Starting network threads...
2020-12-14T15:45:25Z addcon thread start
2020-12-14T15:45:25Z init message: Done loading
2020-12-14T15:45:25Z opencon thread start
2020-12-14T15:45:25Z dnsseed thread start
2020-12-14T15:45:25Z net thread start
2020-12-14T15:45:25Z msghand thread start
2020-12-14T15:45:25Z Loading addresses from DNS seed 178.128.221.177
2020-12-14T15:45:25Z Loading addresses from DNS seed 2a01:7c8:d005:390::5
2020-12-14T15:45:25Z Loading addresses from DNS seed ntv3mtqw5wt63red.onion:38333
2020-12-14T15:45:25Z 0 addresses found from DNS seeds
2020-12-14T15:45:25Z dnsseed thread exit
2020-12-14T15:45:27Z New outbound peer connected: version: 70016, blocks=15997, peer=0 (full-relay)
2020-12-14T15:46:26Z Adding fixed seed nodes as DNS doesn't seem to be available.
2020-12-14T15:46:26Z New outbound peer connected: version: 70016, blocks=15997, peer=1 (full-relay)
2020-12-14T15:46:27Z Synchronizing blockheaders, height: 2000 (~12.21%)

@maflcko
Copy link
Member Author

maflcko commented Dec 15, 2020

Added to 0.21.1 milestone

Copy link
Contributor

@kallewoof kallewoof left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

utACK fae6558

@laanwj
Copy link
Member

laanwj commented Dec 21, 2020

There's no instructions in the release notes for updating this. I'm not sure this is necessary, but for example the testnet hardcoded seeds haven't been updated in ages, for example, and it's unclear how useful they still are.

@maflcko
Copy link
Member Author

maflcko commented Dec 21, 2020

The list was generated with getpeerinfo | grep addr. I am happy to add that to the release notes, but surely there are better ways to get a list in the future. Maybe someone will even run a dnsseeder.

@ajtowns
Copy link
Contributor

ajtowns commented Dec 23, 2020

Looks okay to me

@Sjors
Copy link
Member

Sjors commented Dec 30, 2020

What problem is this solving? More signet seeds just in case?

@maflcko
Copy link
Member Author

maflcko commented Jan 31, 2021

What problem is this solving? More signet seeds just in case?

fixed seeds are used as fallback seeds when the dns seeds can't be queried for some reason

@maflcko maflcko removed this from the 0.21.1 milestone Feb 19, 2021
MarcoFalke added 3 commits February 19, 2021 13:10
-BEGIN VERIFY SCRIPT-
./contrib/seeds/generate-seeds.py ./contrib/seeds/ > src/chainparamsseeds.h
-END VERIFY SCRIPT-
@maflcko maflcko force-pushed the 2012-chainFixedSeedsSignet branch from fae6558 to fae1a64 Compare February 19, 2021 12:13
@maflcko
Copy link
Member Author

maflcko commented Feb 19, 2021

Rebased to get rid of already merged hunks. No other changes.

Copy link
Contributor

@ajtowns ajtowns left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

utACK fae1a64

I suppose running a dns seed and getting statistics from there for populating nodes_signet.txt is the way to get good values here.

178.128.221.177:38333
103.16.128.63:38333
153.126.143.201:38333
192.241.163.142:38333
Copy link
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Only:

    "address": "178.128.221.177",
    "address": "103.16.128.63",
    "address": "153.126.143.201",
    "address": "192.241.163.142",

seem to still be present?

Copy link
Member Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

I think without a dns seeder or other software to track uptime, there will always be nodes in the list that are not reachable

@maflcko maflcko closed this Apr 1, 2021
@maflcko maflcko deleted the 2012-chainFixedSeedsSignet branch April 1, 2021 06:50
@laanwj
Copy link
Member

laanwj commented Apr 1, 2021

Hadn't really noticed this before it conflicted with the TorV3 one. Why close this?

@maflcko
Copy link
Member Author

maflcko commented Apr 1, 2021

Didn't seem a lot of appetite and v3 for mainnet is more important than signet

@bitcoin bitcoin locked and limited conversation to collaborators Oct 31, 2022
Sign up for free to subscribe to this conversation on GitHub. Already have an account? Sign in.
Labels
Projects
None yet
Development

Successfully merging this pull request may close these issues.

8 participants