• tcpdump 报文超过 MTU tso


    root@-x86:~# ethtool -K eno3 gso on
    root@-x86:~# ethtool -k eno3|grep generic-
    generic-segmentation-offload: on
    generic-receive-offload: on
    root@-x86:~# ethtool -K eno3 gso off
    root@z-x86:~# ethtool -k eno3|grep generic-
    generic-segmentation-offload: off
    generic-receive-offload: on
    root@-x86:~#

    root@-x86:~# ethtool -k eno3|grep tcp
    tcp-segmentation-offload: on
    tx-tcp-segmentation: on
    tx-tcp-ecn-segmentation: on
    tx-tcp-mangleid-segmentation: on
    tx-tcp6-segmentation: on
    root@-x86:~# ethtool -K eno3 tso off
    root@-x86:~# ethtool -k eno3|grep tcp
    tcp-segmentation-offload: off
    tx-tcp-segmentation: off
    tx-tcp-ecn-segmentation: off
    tx-tcp-mangleid-segmentation: off
    tx-tcp6-segmentation: off
    root@zj-x86:~#

    如果开启了 TSO,使用 tcpdump 分析网络流量看到的数据是不一样的,下面给个对比。

    • 开启 TSO

     

    root@ -x86:~# ethtool -k eno3 | grep so
    tx-gso-robust: off [fixed]
    tx-gso-partial: on
    root@ -x86:~# ethtool -K eno3 tso off
    root@ -x86:~# ethtool -K eno3 gso off
    root@ -x86:~# ethtool -k eno3 | grep so
    tx-gso-robust: off [fixed]
    tx-gso-partial: on
    root@ -x86:~# ethtool -K eno3 gso on
    root@ -x86:~# ethtool -K eno3 tso on
    root@ -x86:~# ethtool -k eno3 | grep so
    tx-gso-robust: off [fixed]
    tx-gso-partial: on
    root@ -x86:~# ethtool -k eno3 | grep so
    tx-gso-robust: off [fixed]
    tx-gso-partial: on
    root@ -x86:~#
    root@-x86:~# scp /data/ubuntu-18.04-x86.qcow2 root@10.11.16.81:/data1
    root@10.11.16.81's password:
    Permission denied, please try again.
    root@10.11.16.81's password:
    ubuntu-18.04-x86.qcow2

     

    • 关闭 TSO

     

    root@-x86:~# ethtool -k eno4 | grep so
    tx-gso-robust: off [fixed]
    tx-gso-partial: on
    root@-x86:~# ethtool -K eno3 gso off
    root@-x86:~# ethtool -K eno3 tso off
    root@-x86:~# ethtool -k eno3 | grep so
    tx-gso-robust: off [fixed]
    tx-gso-partial: on
    root@-x86:~# scp  /data/ubuntu-18.04-x86.qcow2  root@10.11.16.81:/data1 
    root@10.11.16.81's password: 
    ubuntu-18.04-x86.qcow2  

    关闭tso,开gso

    root@-x86:~# ethtool -K eno3 tso off
    root@-x86:~# ethtool -K eno3 gso on
    root@-x86:~# scp  /data/ubuntu-18.04-x86.qcow2  root@10.11.16.81:/data1 
    root@10.11.16.81's password: 
    ubuntu-18.04-x86-new.qcow2     

    开tso,关gso

    root@-x86:~# ethtool -K eno3 gso off
    root@-x86:~# ethtool -K eno3 tso on
    root@-x86:~# scp  /data/ubuntu-18.04-x8.qcow2  root@10.11.16.81:/data1 
    root@10.11.16.81's password: 
    ubuntu-18.04-x86.qcow2                                                                                                                                                                                                100%  617MB  79.0MB/s   00:07    
    root@-x86:~# 

  • 相关阅读:
    Ubuntu中pip的疑难杂症
    Python 分类方法记录
    Python 绘制热图
    脚本学习
    Ubuntu 基础使用教程
    机器学习各种相似性度量及Python实现
    Ubuntu 16.04安装R及Rstudio
    机器学习和数据挖掘领域大牛
    vux+vue-cli3.0坑
    函数的抖动以及节流
  • 原文地址:https://www.cnblogs.com/dream397/p/14513824.html
Copyright © 2020-2023  润新知