【问题标题】:What's the format of tm->when in /proc/net/tcp?/proc/net/tcp 中的 tm->when 的格式是什么?
【发布时间】:2013-11-11 03:02:53
【问题描述】:

我需要知道tm->when 是什么意思,但proc(5) 没有提到任何有用的信息,

那么,它是否存储了套接字的创建时间?每次查看文件时,数字似乎都在减少。

root@ubuntu-vm:~# cat /proc/net/tcp
  sl  local_address rem_address   st tx_queue rx_queue tr tm->when retrnsmt   uid  timeout inode                                                     
   0: 00000000:0CEA 00000000:0000 0A 00000000:00000000 00:00000000 00000000   104        0 17410 1 dddb6d00 100 0 0 10 -1                            
   1: 00000000:0016 00000000:0000 0A 00000000:00000000 00:00000000 00000000     0        0 7959 1 dddb4500 100 0 0 10 -1                             
   2: B238A8C0:0016 0138A8C0:9C96 01 00000000:00000000 02:00061444 00000000     0        0 8243 4 daa3c000 20 4 27 10 16                             
   3: B238A8C0:0CEA 0138A8C0:8753 01 00000000:00000000 02:0009C787 00000000   104        0 19467 2 daa3e300 20 4 18 10 -1

【问题讨论】:

    标签: sockets linux-kernel proc


    【解决方案1】:

    来自Exploring the /proc/net/ Directory

    tr 字段指示此套接字的定时器是否处于活动状态。零值表示计时器未激活。 tm->when 字段表示超时发生前的剩余时间(以 jiffies 为单位)。

    【讨论】:

    • 有趣的是,Google 现在在谷歌搜索 linux tcp tm->when 时会指出你的答案 :-)
    • @LucioPaiva 这很有趣。我已从答案中删除了该循环评论。
    猜你喜欢
    • 1970-01-01
    • 2012-08-21
    • 2011-04-01
    • 1970-01-01
    • 1970-01-01
    • 1970-01-01
    • 2020-02-18
    • 2010-11-25
    • 1970-01-01
    相关资源
    最近更新 更多