Netcraftのuptime

Netcraftuptime、FAQのWhich operating systems provide uptime information ?によれば

Operating systems that do not provide uptime information include;
* Linux on Intel x86 processor from kernel version 2.5.25

と書かれていて、実際、kernel 2.6.1にしたらグラフが延びなくなったんだけど、そういやどういう仕組みで稼働時間を取得しているの?っつーことでちと調べてみた。

Apacheのレスポンスヘッダにはそんな情報はないはずだし、OSによってできる/できないが変わるっつーことはIPかTCPのスタックが関係あるのかなぁと思い、nmap(1)を見てみると、

The -O option also enables several other tests. One is the "Uptime" measurement, which uses the TCP timestamp option (RFC 1323) to guess when a machine was last rebooted. This is only reported for machines which provide this information.

というのを発見。
更に「RFC 1323 linux」あたりでぐぐってみると、

というのを見つける。

で、kernel 2.6.1(Debian 3.0r2ベース)なマシンをみてみるとtcp_timestampsは1になってる。nmap (v3.48)で-Oしてみても確かにuptimeが表示された。因みにgentoo-sources-2.4.22-r4なマシンはtcp_timestampsが有効になっていてもなぜかnmap (v3.48とv3.50)でuptimeが表示されなかった。

結局は、NetcraftのスキャナがLinuxTCP timestampに対応していないんだろうなぁという推測で納得することに。早く対応してくれないかなぁ。