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

[BR]: Warning at startup: fail2ban.configreader [7602]: WARNING 'allowipv6' not defined in 'Definition'. Using default one: 'auto' #3420

Closed
2 of 3 tasks
sbraz opened this issue Nov 26, 2022 · 3 comments
Labels

Comments

@sbraz
Copy link
Contributor

sbraz commented Nov 26, 2022

Environment:

  • Fail2Ban version : 1.0.2
  • OS, including release name/version : Gentoo unstable ~amd64
  • Fail2Ban installed via OS/distribution mechanisms
  • You have not applied any additional foreign patches to the codebase
  • Some customizations were done to the configuration (provide details below is so)

The issue:

When starting fail2ban with a default configuration, warnings appear.

Steps to reproduce

Install fail2ban and start /usr/bin/fail2ban-server.

Expected behavior

No warning appears

Observed behavior

I see 2022-11-26 11:20:55,251 fail2ban.configreader [14118]: WARNING 'allowipv6' not defined in 'Definition'. Using default one: 'auto'.

Any additional information

I worked around the issue by creating a fail2ban.local file with:

[DEFAULT]
allowipv6 = auto

Why is this value commented out in

#allowipv6 = auto
? Maybe it should be set instead, like other keys such as dbpurgeage.

Configuration, dump and another helpful excerpts

N/A

Any customizations done to /etc/fail2ban/ configuration

None, this is with the default config.

Relevant parts of /var/log/fail2ban.log file:

N/A

Relevant lines from monitored log files:

N/A

@sbraz sbraz added the bug label Nov 26, 2022
@sebres
Copy link
Contributor

sebres commented Nov 28, 2022

Why is this value commented out

Default values are not really needed to be set. I just forgot that there may be warning in that case.
Since I don't think this warning is necessary (and even with info level it would be too much), I'll lower this to a debug level.

@RealBC
Copy link

RealBC commented Mar 22, 2024

if the warning

fail2ban.configreader [41804]: WARNING 'allowipv6' not defined in 'Definition'. Using default one: 'auto'

seems ugly to you GOTO fail2ban.local (not jail.local like an absent minded person)

solution

sudo cp /etc/fail2ban/fail2ban.conf /etc/fail2ban/fail2ban.local => As @sebres said this is not good

just put the value you want to modifiy..
sudo vim /etc/fail2ban/fail2ban.local

[Definition]
allowipv6 = auto
...
that's it

@sebres
Copy link
Contributor

sebres commented Mar 22, 2024

Yes.
Although, this one ...

sudo cp /etc/fail2ban/fail2ban.conf /etc/fail2ban/fail2ban.local

is not good - please, don't copy stock config files to the local files, they shall only contain the values you want to overwrite.
For details see #3699 (comment) or https://github.com/fail2ban/fail2ban/wiki/Proper-fail2ban-configuration

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
Projects
None yet
Development

No branches or pull requests

3 participants