TUN-6778: Cleanup logs about ICMP
This commit is contained in:
parent
013bdbd10c
commit
de00396669
|
@ -202,7 +202,7 @@ func (ip *icmpProxy) Serve(ctx context.Context) error {
|
|||
// In unit test, we found out when the listener listens on 0.0.0.0, the socket reads the full packet after
|
||||
// the second reply
|
||||
if err := ip.handleFullPacket(icmpDecoder, buf[:n]); err != nil {
|
||||
ip.logger.Err(err).Str("dst", from.String()).Msg("Failed to parse ICMP reply as full packet")
|
||||
ip.logger.Debug().Err(err).Str("dst", from.String()).Msg("Failed to parse ICMP reply as full packet")
|
||||
}
|
||||
continue
|
||||
}
|
||||
|
|
|
@ -4,6 +4,7 @@ import (
|
|||
"context"
|
||||
"errors"
|
||||
"fmt"
|
||||
"net"
|
||||
"strings"
|
||||
"time"
|
||||
|
||||
|
@ -155,8 +156,12 @@ func (s *Supervisor) Run(
|
|||
if s.edgeTunnelServer.icmpRouter != nil {
|
||||
go func() {
|
||||
if err := s.edgeTunnelServer.icmpRouter.Serve(ctx); err != nil {
|
||||
if errors.Is(err, net.ErrClosed) {
|
||||
s.log.Logger().Info().Err(err).Msg("icmp router terminated")
|
||||
} else {
|
||||
s.log.Logger().Err(err).Msg("icmp router terminated")
|
||||
}
|
||||
}
|
||||
}()
|
||||
}
|
||||
|
||||
|
|
Loading…
Reference in New Issue