[Net] peers.dat, banlist.dat recreated when missing #7458

pull kirkalx wants to merge 1 commits into bitcoin:master from kirkalx:master changing 1 files +7 −2
  1. kirkalx commented at 9:51 am on February 2, 2016: contributor

    In response to issue #7452. Still leaves an error message for the missing file in the logs though.

    My first PR, so be nice please :)

  2. kirkalx renamed this:
    peers.dat, banlist.dat recreated when missing
    [Net] peers.dat, banlist.dat recreated when missing
    on Feb 2, 2016
  3. kirkalx commented at 10:38 am on February 2, 2016: contributor
    Sorry if I’ve messed this up with the 2nd commit, jumped the gun a little…
  4. laanwj added the label P2P on Feb 2, 2016
  5. laanwj commented at 11:26 am on February 2, 2016: member

    Welcome @kirkalx

    The number of commits doesn’t matter; better too many than too few, you can always use git rebase -i and force-push to squash commits together, if that results in clearer or more atomic changes. Separating them out is a bit more tricky.

    Looks good to me. utACK.

  6. kirkalx commented at 8:01 pm on February 2, 2016: contributor
    Thanks Wladimir. I’ll stop making changes now as I obviously need to learn a bit about GitHub.
  7. laanwj commented at 12:57 pm on February 3, 2016: member

    Tested ACK Without the patch: no banlist.dat written With patch:

     0$ mkdir /store2/tmp/testbtc4
     1$ src/bitcoind -datadir=/store2/tmp/testbtc4 -printtoconsole -disablewallet
     22016-02-03 12:48:10 ERROR: Read: Failed to open file /store2/tmp/testbtc4/peers.dat
     32016-02-03 12:48:10 Invalid or missing peers.dat; recreating
     42016-02-03 12:48:11 init message: Loading banlist...
     52016-02-03 12:48:11 ERROR: Read: Failed to open file /store2/tmp/testbtc4/banlist.dat
     62016-02-03 12:48:11 Invalid or missing banlist.dat; recreating
     7^C
     8$ ls  /store2/tmp/testbtc4
     9banlist.dat  blocks  chainstate  debug.log  fee_estimates.dat  onion_private_key  peers.dat
    10$ src/bitcoind -datadir=/store2/tmp/testbtc4 -printtoconsole -disablewallet                                                           
    112016-02-03 12:50:10 init message: Loading addresses...
    122016-02-03 12:50:10 Loaded 141 addresses from peers.dat  1ms
    132016-02-03 12:50:10 init message: Loading banlist...
    

    Before merging, can you please squash these changes into one commit? e.g.

    0$ git rebase -i 196ad69
    

    In the editor, replace the bottom three ‘pick’ with ‘f’, then save and exit. Then, force-push the result to this branch with

    0git push -f origin master
    
  8. peers.dat, banlist.dat recreated when missing c77c6625f3
  9. kirkalx commented at 11:05 pm on February 3, 2016: contributor
    Thanks for the help with that Wladimir, seems to have worked. I’ll try to come back next week and get rid of the error messages in the logs as well.
  10. laanwj merged this on Feb 4, 2016
  11. laanwj closed this on Feb 4, 2016

  12. laanwj referenced this in commit 898fedf42f on Feb 4, 2016
  13. laanwj added the label Needs backport on Feb 4, 2016
  14. luke-jr referenced this in commit e54f412930 on Feb 12, 2016
  15. laanwj removed the label Needs backport on Sep 26, 2016
  16. laanwj added this to the milestone 0.12.2 on Sep 26, 2016
  17. laanwj added the label Needs backport on Sep 26, 2016
  18. fanquake removed the label Needs backport on Mar 7, 2018
  19. zkbot referenced this in commit d0b67191e2 on Apr 5, 2018
  20. zkbot referenced this in commit bf0f1cbee9 on Mar 6, 2020
  21. zkbot referenced this in commit 2d9a9aaa83 on Nov 11, 2020
  22. zkbot referenced this in commit f40121446d on Nov 12, 2020
  23. zkbot referenced this in commit 049951dc45 on Feb 11, 2021
  24. zkbot referenced this in commit b3a6729944 on Feb 16, 2021
  25. zkbot referenced this in commit e85265fbd5 on Feb 17, 2021
  26. zkbot referenced this in commit b4b07a1bbd on Feb 17, 2021
  27. MarcoFalke locked this on Sep 8, 2021


kirkalx laanwj

Labels
P2P

Milestone
0.12.branch


github-metadata-mirror

This is a metadata mirror of the GitHub repository bitcoin/bitcoin. This site is not affiliated with GitHub. Content is generated from a GitHub metadata backup.
generated: 2025-07-19 03:13 UTC

This site is hosted by @0xB10C
More mirrored repositories can be found on mirror.b10c.me