These are chat archives for anacrolix/torrent

8th
Feb 2018
Matt Joiner
@anacrolix
Feb 08 2018 03:02
I noticed @burekas7 has very few connections with header encryption, and none at all with RC4 encryption.
shit why is encryption disabled
Matt Joiner
@anacrolix
Feb 08 2018 03:39
Check the GitHub issue. I suspect we've found the main reason it's slower than Quasar
Denis
@elgatito
Feb 08 2018 05:38
i've posted a response. encryption is controlled by user
Denis
@elgatito
Feb 08 2018 06:04
ouch.. go 1.9.4 gives error when compiling go-libutp
Matt Joiner
@anacrolix
Feb 08 2018 09:28
yeah i don't know why they rushed that release
there's going to be so many issues from that
i really think you should do the ip blocklist stuff, i have it all bundled with my production stuff, i haven't really provided defaults in the torrent package
Denis
@elgatito
Feb 08 2018 09:31
we use the same as it is in confluence
Matt Joiner
@anacrolix
Feb 08 2018 09:31
ah ok. i didn't see it in the config, unless you did it with SetIPBlocklist?
Denis
@elgatito
Feb 08 2018 09:32
blocklist, err := iplist.MMapPacked("packed-blocklist")
...
IPBlocklist: blocklist,
it's not right usage?
Matt Joiner
@anacrolix
Feb 08 2018 09:33
looks right but i see this in his log: IPBlocklist:iplist.Ranger(nil)
Denis
@elgatito
Feb 08 2018 09:36

hm

blocklist, err := iplist.MMapPacked("packed-blocklist")

no error, but blocklist is nil

Matt Joiner
@anacrolix
Feb 08 2018 09:39
that's not good :P
Denis
@elgatito
Feb 08 2018 09:44
func MMapPacked(filename string) (ret Ranger, err error) {
    f, err := os.Open(filename)
    if os.IsNotExist(err) {
        err = nil
        return
    }
Matt Joiner
@anacrolix
Feb 08 2018 09:44
well spotted
thanks
that's leaked from confluence
i'll also expose the NumRanges in the client status
Denis
@elgatito
Feb 08 2018 09:45
should i really use file based ip blocklist?
it's like banning bad peers for ever?
Matt Joiner
@anacrolix
Feb 08 2018 09:45
ah nah blocklist is different
it's a list of known bad ranges
you probably never want to talk to them
Use NewFromPacked directly if you don't want to use a file
ie some other source
Denis
@elgatito
Feb 08 2018 09:57
empty file is not working, throwing "invalid argument" from somewhere
Matt Joiner
@anacrolix
Feb 08 2018 09:57
yeah you can't mmap empty files
Denis
@elgatito
Feb 08 2018 09:58
and NewFromPacked([]byte{}) throws a slice index err
Matt Joiner
@anacrolix
Feb 08 2018 10:00
an empty slice is not valid
Denis
@elgatito
Feb 08 2018 10:50
what is the supposed way with ipblocklist? create mmap file, provide it to MMapPacked()?
Matt Joiner
@anacrolix
Feb 08 2018 11:42
get a peerguardian/p2p blocklist format file
expose it as an iplist.Ranger, I used the pack-blocklist command to convert it to a binary search tree and mmap that in (it can be very large, so it's more efficient in memory as a big block)
i really need documentation for this, but it's sort of general torrenting knowledge
been using that since 2004
Denis
@elgatito
Feb 08 2018 11:52
oh... 3.5mb gzip...
Denis
@elgatito
Feb 08 2018 12:16
okay, i have converted the file and added to the client
will bundle it with the plugin
Matt Joiner
@anacrolix
Feb 08 2018 12:16
very nice
i'll fix that thing to error
i'm doing it now and got bogged fixing other stuff
Denis
@elgatito
Feb 08 2018 12:16
it should be updated from time to time?
(the file)
Matt Joiner
@anacrolix
Feb 08 2018 12:17
i haven't updated it in years
Denis
@elgatito
Feb 08 2018 12:17
have you counted filtered connections?
it is really doing the job?
Matt Joiner
@anacrolix
Feb 08 2018 12:18
"acceptReject": 1049,
"acceptTCP": 22675,
"acceptUTP": 52264,
Denis
@elgatito
Feb 08 2018 12:19
huh. good. becoming better each day :D
Matt Joiner
@anacrolix
Feb 08 2018 12:20
yeah, true
the ipblocklist stuff hasn't changed in 3 years tho
i just noticed there's no counter for new peers that are filtered, so i'll add that too
so we know that it's blocking added peers too
Matt Joiner
@anacrolix
Feb 08 2018 12:26
i'm also going to boost the pending peer high water
from 200 which is too low now i think
Denis
@elgatito
Feb 08 2018 12:26
I don't yet understand what is low/high water limitation about :)
Matt Joiner
@anacrolix
Feb 08 2018 12:26
i'ts an optimization technique
Matt Joiner
@anacrolix
Feb 08 2018 13:18
RoaringBitmap/roaring#149