hostapd debug level configuration [closed]
Asked Answered
C

1

9

From what I understand so far, hostapd is a binary which is able to do some network configurations.

However, to enable hostapd debug level, do I need to rebuild the binary? Is there any other approach I can take instead of rebuilding a new one ?

Cuspidor answered 25/8, 2015 at 13:19 Comment(0)
R
14

Executing hostapd with no arguments reveals that specifying -d or -dd enables debug messages:

-d show more debug messages (-dd for even more)

It is also possible to configure the event logger verbosity via hostapd's configuration file:

# hostapd event logger configuration
#
# Two output method: syslog and stdout (only usable if not forking to
# background).
#
# Module bitfield (ORed bitfield of modules that will be logged; -1 = all
# modules):
# bit 0 (1) = IEEE 802.11
# bit 1 (2) = IEEE 802.1X
# bit 2 (4) = RADIUS
# bit 3 (8) = WPA
# bit 4 (16) = driver interface
# bit 5 (32) = IAPP
# bit 6 (64) = MLME
#
# Levels (minimum value for logged events):
#  0 = verbose debugging
#  1 = debugging
#  2 = informational messages
#  3 = notification
#  4 = warning
#
logger_syslog=-1
logger_syslog_level=2
logger_stdout=-1
logger_stdout_level=2
Rubbery answered 25/8, 2015 at 16:50 Comment(3)
Is there a way to let hostapd to log MAC addresses which attempted to connect but not yet added into hostapd.accept? I tried log level 4 but still not find such info in the logs.Kiely
First of all, try log level 0, which is the most verbose one. Secondly, the log message won't necessarily include a descriptive reason. You can inspect hostapd's source code and see how the code behaves after returning from the functions hostapd_allowed_address(...) and hostapd_check_acl(...) (the former invokes the latter) in order to know what to expect.Rubbery
Thank you, Yoel!Kiely

© 2022 - 2024 — McMap. All rights reserved.