Linux + ifconfigまたはIPの切断を監視する方法

Linux + ifconfigまたはIPの切断を監視する方法

Linux 7でtcpdumpを使用してRXドロップパケットを監視する方法は?

それとも別の方法がありますか?

それでは、RXオフラインとは何ですか?

eth1のifconfig結果:

    # ifconfig -a | grep RX | grep dropped
    RX errors 0  dropped 123136  overruns 0  frame 0
    RX errors 0  dropped 140938047  overruns 0  frame 0
    RX errors 0  dropped 0  overruns 0  frame 0

    # ifconfig -a | grep RX | grep dropped
    RX errors 0  dropped 123136  overruns 0  frame 0
    RX errors 0  dropped 140938083  overruns 0  frame 0  <--------------  after second
    RX errors 0  dropped 0  overruns 0  frame 0

ベストアンサー1

リアルタイムで視聴したい場合は、以下を使用してください。

watch -tn 1  "ifconfig -a | grep -A 5 eth1 | grep 'RX packets' | sed 's/^.* dropped:\\([0-9]\\{1,\\}\\) .*\$/\1/g'"

ここが正しい回答なぜこれが起こるのですか?

おすすめ記事