Commit 075aedce authored by Marcin Siodelski's avatar Marcin Siodelski

[5442] Add log messages when packet is dropped.

parent a100b44b
......@@ -404,6 +404,12 @@ will not send a response but will instead ignore the packet. The first
argument contains the client and transaction identification information.
The second argument includes the details of the error.
% DHCP4_PACKET_DROP_0008 %1: DHCP service is globally disabled
This debug message is issued when a packet is dropped because the DHCP service
has been temporarily disabled. This affects all received DHCP packets. The
service may be enabled by the "dhcp-enable" control command or automatically
after a specified amount of time since receiving "dhcp-disable" command.
% DHCP4_PACKET_NAK_0001 %1: failed to select a subnet for incoming packet, src %2, type %3
This error message is output when a packet was received from a subnet
for which the DHCPv4 server has not been configured. The most probable
......
......@@ -806,6 +806,9 @@ Dhcpv4Srv::run_one() {
// If the DHCP service has been globally disabled, drop the packet.
if (network_state_.isServiceEnabled()) {
LOG_DEBUG(bad_packet4_logger, DBG_DHCP4_BASIC,
DHCP4_PACKET_DROP_0008)
.arg(query->getLabel());
processPacket(query, rsp);
}
......
......@@ -409,6 +409,12 @@ server is about to open sockets on the specified port.
A warning message issued when IfaceMgr fails to open and bind a socket. The reason
for the failure is appended as an argument of the log message.
% DHCP6_PACKET_DROP_DHCP_DISABLED %1: DHCP service is globally disabled
This debug message is issued when a packet is dropped because the DHCP service
has been temporarily disabled. This affects all received DHCP packets. The
service may be enabled by the "dhcp-enable" control command or automatically
after a specified amount of time since receiving "dhcp-disable" command.
% DHCP6_PACKET_DROP_PARSE_FAIL failed to parse packet from %1 to %2, received over interface %3, reason: %4
The DHCPv4 server has received a packet that it is unable to
interpret. The reason why the packet is invalid is included in the message.
......
......@@ -470,6 +470,9 @@ void Dhcpv6Srv::run_one() {
// If the DHCP service has been globally disabled, drop the packet.
if (network_state_.isServiceEnabled()) {
LOG_DEBUG(bad_packet6_logger, DBG_DHCP6_DETAIL_DATA,
DHCP6_PACKET_DROP_DHCP_DISABLED)
.arg(query->getLabel());
processPacket(query, rsp);
}
......
Markdown is supported
0% or .
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment