Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Make list download timeout configurable #254

Closed
erkexzcx opened this issue Aug 28, 2021 · 1 comment · Fixed by #281
Closed

Make list download timeout configurable #254

erkexzcx opened this issue Aug 28, 2021 · 1 comment · Fixed by #281
Assignees
Labels
🔨 enhancement New feature or request
Milestone

Comments

@erkexzcx
Copy link

Description

Using docker image from dockerhub, latest tag.

Blocky does not work at all when there is at least 1 blocklist which is loading indefinitely. In this case, this is the one: https://zeustracker.abuse.ch/blocklist.php?download=domainblocklist

At the time of writing, this blocklist is simply not loading. If you open in browser, it loads indefinitely. I just waited a bit more and it loaded up with this content in my Firefox browser:
image

This is what Blocky's log say:

[2021-08-28 10:21:15]  WARN list_cache: Temporary network error / Timeout occurred, retrying... Get "https://zeustracker.abuse.ch/blocklist.php?download=domainblocklist": context deadline exceeded (Client.Timeout exceeded while awaiting headers) attempt=1 link=https://zeustracker.abuse.ch/blocklist.php?download=domainblocklist

Blocky started to work just fine after removing this blocklist.

Possible solutions:

  • Remove such blocklists from Blocky - it's not convenient.
  • Implement timeout mechanism within Blocky source code. I am referring to this sort of fix. Additional setting for default blocklist timeout could be useful (e.g. blocklistTimeout: 30s).
@0xERR0R 0xERR0R self-assigned this Aug 29, 2021
@0xERR0R 0xERR0R added the 🐞 bug Something isn't working label Aug 29, 2021
@0xERR0R 0xERR0R added this to the 0.16 milestone Aug 29, 2021
@0xERR0R 0xERR0R removed the 🐞 bug Something isn't working label Aug 29, 2021
@0xERR0R
Copy link
Owner

0xERR0R commented Aug 29, 2021

Hey,

there is already a timeout defined (60 sec). Blocky performs 3x a retry, if a temporary network error occurred. In this case, it takes 3x 60 sec, see log:

[2021-08-29 15:33:30]  INFO list_cache: starting download link=https://zeustracker.abuse.ch/blocklist.php?download=domainblocklist
[2021-08-29 15:34:30]  WARN list_cache: Temporary network error / Timeout occurred, retrying... Get "https://zeustracker.abuse.ch/blocklist.php?download=domainblocklist": context deadline exceeded (Client.Timeout exceeded while awaiting headers) attempt=1 link=https://zeustracker.abuse.ch/blocklist.php?download=domainblocklist
[2021-08-29 15:35:31]  WARN list_cache: Temporary network error / Timeout occurred, retrying... Get "https://zeustracker.abuse.ch/blocklist.php?download=domainblocklist": context deadline exceeded (Client.Timeout exceeded while awaiting headers) attempt=2 link=https://zeustracker.abuse.ch/blocklist.php?download=domainblocklist
[2021-08-29 15:36:15]  WARN list_cache: error during file processing: couldn't download url 'https://zeustracker.abuse.ch/blocklist.php?download=domainblocklist', got status code 503
...
[2021-08-29 15:36:16]  INFO server: Starting server
[2021-08-29 15:36:16]  INFO server: http server is up and running on addr/port 4000
[2021-08-29 15:36:16]  INFO server: tcp server is up and running on address :55555
[2021-08-29 15:36:16]  INFO server: udp server is up and running on address :55555

Depending on this list size and network bandwidth, i could take a while to download a list. I think, making this value configurable would make sense. I would leave the default value with 60 sec

@0xERR0R 0xERR0R changed the title Blocky does not resolve DNS queries if one of the blocklists are not loading (e.g. dropping traffic) Make list download timeout configurable Aug 30, 2021
@0xERR0R 0xERR0R added the 🔨 enhancement New feature or request label Aug 30, 2021
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
🔨 enhancement New feature or request
Projects
None yet
Development

Successfully merging a pull request may close this issue.

2 participants