{ "version": "https://jsonfeed.org/version/1.1", "user_comment": "This feed allows you to read the posts from this site in any feed reader that supports the JSON Feed format. To add this feed to your reader, copy the following URL -- https://matoken.org/blog/tag/moreutils/feed/json/ -- and add it your reader.", "home_page_url": "https://matoken.org/blog/tag/moreutils/", "feed_url": "https://matoken.org/blog/tag/moreutils/feed/json/", "language": "ja", "title": "moreutils – matoken's blog", "description": "Is there no plan B?", "icon": "https://matoken.org/blog/wp-content/uploads/2025/03/cropped-1865f695c4eecc844385acef2f078255036adccd42c254580ea3844543ab56d9.jpeg", "items": [ { "id": "https://matoken.org/blog/?p=3838", "url": "https://matoken.org/blog/2023/02/05/moreutils-ts/", "title": "\u6a19\u6e96\u5165\u529b\u306b\u30bf\u30a4\u30e0\u30b9\u30bf\u30f3\u30d7\u3092\u4ed8\u3051\u3066\u304f\u308c\u308bmoreutils \u306e ts \u30b3\u30de\u30f3\u30c9\u304c\u4fbf\u5229", "content_html": "
\n

moreutils \u306e ts \u30b3\u30de\u30f3\u30c9\u304c\u4fbf\u5229\u3060\u3063\u305f\u306e\u3067\u7d39\u4ecb\uff0e

\n
\n

\n
\n

\u901a\u5e38\u306eping\u306f\u3053\u3093\u306a\u611f\u3058

\n
\n
\n
\n
$ ping ::1\nPING ::1(::1) 56 data bytes\n64 bytes from ::1: icmp_seq=1 ttl=64 time=0.052 ms\n64 bytes from ::1: icmp_seq=2 ttl=64 time=0.051 ms\n64 bytes from ::1: icmp_seq=3 ttl=64 time=0.040 ms\n64 bytes from ::1: icmp_seq=4 ttl=64 time=0.049 ms\n^C\n--- ::1 ping statistics ---\n4 packets transmitted, 4 received, 0% packet loss, time 3067ms\nrtt min/avg/max/mdev = 0.040/0.048/0.052/0.004 ms
\n
\n
\n
\n

http(s) \u306e\u758e\u901a\u78ba\u8a8d\u306e\u51fa\u6765\u308b httping \u306b\u306f --timestamp/--ts \u30aa\u30d7\u30b7\u30e7\u30f3\u304c\u3042\u308a\u30bf\u30a4\u30e0\u30b9\u30bf\u30f3\u30d7\u304c\u4ed8\u3051\u3089\u308c\u3066\u4fbf\u5229\u3067\u3059\uff0e

\n
\n
\n
\n
\n
\n
--timestamp or --ts\n       Put a timestamp before the result-lines. Use -v to also show a date.
\n
\n
\n
\n
\n
\n
\n
$ httping 192.168.1.1\nPING 192.168.1.1:80 (/):\nconnected to 192.168.1.1:80 (234 bytes), seq=0 time= 12.53 ms\nconnected to 192.168.1.1:80 (234 bytes), seq=1 time= 13.34 ms\nconnected to 192.168.1.1:80 (234 bytes), seq=2 time= 13.16 ms\n^CGot signal 2\n--- http://192.168.1.1/ ping statistics ---\n3 connects, 3 ok, 0.00% failed, time 2578ms\nround-trip min/avg/max = 12.5/13.0/13.3 ms\n$ httping --timestamp 192.168.1.1\nPING 192.168.1.1:80 (/):\n22:05:30.798 connected to 192.168.1.1:80 (172 bytes), seq=0 time= 14.99 ms\n22:05:31.813 connected to 192.168.1.1:80 (172 bytes), seq=1 time= 14.45 ms\n22:05:32.827 connected to 192.168.1.1:80 (172 bytes), seq=2 time= 13.28 ms\n^CGot signal 2\n--- http://192.168.1.1/ ping statistics ---\n3 connects, 3 ok, 0.00% failed, time 2658ms\nround-trip min/avg/max = 13.3/14.2/15.0 ms
\n
\n
\n
\n

ping \u30b3\u30de\u30f3\u30c9\u306eman \u306b\u306f\u305d\u308c\u3089\u3057\u3044\u3082\u306e\u306f\u898b\u5f53\u305f\u3089\u306a\u304b\u3063\u305f\u306e\u3067\uff0c\u3053\u3093\u306a\u611f\u3058\u3067 date \u30b3\u30de\u30f3\u30c9\u306e\u7d50\u679c\u3092\u7e4b\u3044\u3060\u308a\u3057\u3066\u3044\u307e\u3057\u305f\uff0e

\n
\n
\n
\n
$ ping ::1 | sed -s \"s/^/`date +%F\\ %T`\\t/\"\n2023-02-05 21:58:50     PING ::1(::1) 56 data bytes\n2023-02-05 21:58:50     64 bytes from ::1: icmp_seq=1 ttl=64 time=0.068 ms\n2023-02-05 21:58:50     64 bytes from ::1: icmp_seq=2 ttl=64 time=0.066 ms\n2023-02-05 21:58:50     64 bytes from ::1: icmp_seq=3 ttl=64 time=0.042 ms\n^C
\n
\n
\n
\n

\u540c\u3058\u3088\u3046\u306a\u3053\u3068\u3092\u3057\u3066\u304f\u308c\u308b moreutils \u5185\u306e ts \u30b3\u30de\u30f3\u30c9\u304c\u3042\u308a\u307e\u3057\u305f\uff0e

\n
\n
\n
\n
\n

ts: timestamp standard input

\n
\n
\n
\n
\n
\n
$ ping ::1 | ts\nFeb 05 22:01:20 PING ::1(::1) 56 data bytes\nFeb 05 22:01:20 64 bytes from ::1: icmp_seq=1 ttl=64 time=0.121 ms\nFeb 05 22:01:21 64 bytes from ::1: icmp_seq=2 ttl=64 time=0.118 ms\nFeb 05 22:01:22 64 bytes from ::1: icmp_seq=3 ttl=64 time=0.115 ms\n^C
\n
\n
\n
\n

\u30d5\u30a9\u30fc\u30de\u30c3\u30c8( strftime(3) )\u3092\u6307\u5b9a\u3057\u3066\u81ea\u5206\u597d\u307f\u306b\u3082\uff0e

\n
\n
\n
\n
$ ping ::1 | ts -m \"%F %T\"\n2023-02-05 22:02:16 PING ::1(::1) 56 data bytes\n2023-02-05 22:02:16 64 bytes from ::1: icmp_seq=1 ttl=64 time=0.038 ms\n2023-02-05 22:02:17 64 bytes from ::1: icmp_seq=2 ttl=64 time=0.044 ms\n2023-02-05 22:02:18 64 bytes from ::1: icmp_seq=3 ttl=64 time=0.066 ms\n^C
\n
\n
\n
\n

sed \u306a\u3069\u3067\u66f8\u304f\u3088\u308a\u826f\u3055\u305d\u3046\u3067\u3059\uff0e(moreutils\u306e\u5c0e\u5165\u304c\u5fc5\u8981\u3060\u3051\u3069)

\n
\n
\n\n
\n
\n
\u74b0\u5883
\n
\n
$ dpkg-query -W iputils-ping moreutils httping\nhttping 2.5-5.2+b1\niputils-ping    3:20221126-1\nmoreutils       0.67-1\n$ lsb_release -a\nNo LSB modules are available.\nDistributor ID: Debian\nDescription:    Debian GNU/Linux bookworm/sid\nRelease:        n/a\nCodename:       bookworm\n$ arch\nx86_64
\n
\n
\n", "content_text": "moreutils \u306e ts \u30b3\u30de\u30f3\u30c9\u304c\u4fbf\u5229\u3060\u3063\u305f\u306e\u3067\u7d39\u4ecb\uff0e\n\n\n\n\u901a\u5e38\u306eping\u306f\u3053\u3093\u306a\u611f\u3058\n\n\n\n$ ping ::1\nPING ::1(::1) 56 data bytes\n64 bytes from ::1: icmp_seq=1 ttl=64 time=0.052 ms\n64 bytes from ::1: icmp_seq=2 ttl=64 time=0.051 ms\n64 bytes from ::1: icmp_seq=3 ttl=64 time=0.040 ms\n64 bytes from ::1: icmp_seq=4 ttl=64 time=0.049 ms\n^C\n--- ::1 ping statistics ---\n4 packets transmitted, 4 received, 0% packet loss, time 3067ms\nrtt min/avg/max/mdev = 0.040/0.048/0.052/0.004 ms\n\n\n\nhttp(s) \u306e\u758e\u901a\u78ba\u8a8d\u306e\u51fa\u6765\u308b httping \u306b\u306f --timestamp/--ts \u30aa\u30d7\u30b7\u30e7\u30f3\u304c\u3042\u308a\u30bf\u30a4\u30e0\u30b9\u30bf\u30f3\u30d7\u304c\u4ed8\u3051\u3089\u308c\u3066\u4fbf\u5229\u3067\u3059\uff0e\n\n\n\n\n\n--timestamp or --ts\n Put a timestamp before the result-lines. Use -v to also show a date.\n\n\n\n\n\n\n$ httping 192.168.1.1\nPING 192.168.1.1:80 (/):\nconnected to 192.168.1.1:80 (234 bytes), seq=0 time= 12.53 ms\nconnected to 192.168.1.1:80 (234 bytes), seq=1 time= 13.34 ms\nconnected to 192.168.1.1:80 (234 bytes), seq=2 time= 13.16 ms\n^CGot signal 2\n--- http://192.168.1.1/ ping statistics ---\n3 connects, 3 ok, 0.00% failed, time 2578ms\nround-trip min/avg/max = 12.5/13.0/13.3 ms\n$ httping --timestamp 192.168.1.1\nPING 192.168.1.1:80 (/):\n22:05:30.798 connected to 192.168.1.1:80 (172 bytes), seq=0 time= 14.99 ms\n22:05:31.813 connected to 192.168.1.1:80 (172 bytes), seq=1 time= 14.45 ms\n22:05:32.827 connected to 192.168.1.1:80 (172 bytes), seq=2 time= 13.28 ms\n^CGot signal 2\n--- http://192.168.1.1/ ping statistics ---\n3 connects, 3 ok, 0.00% failed, time 2658ms\nround-trip min/avg/max = 13.3/14.2/15.0 ms\n\n\n\nping \u30b3\u30de\u30f3\u30c9\u306eman \u306b\u306f\u305d\u308c\u3089\u3057\u3044\u3082\u306e\u306f\u898b\u5f53\u305f\u3089\u306a\u304b\u3063\u305f\u306e\u3067\uff0c\u3053\u3093\u306a\u611f\u3058\u3067 date \u30b3\u30de\u30f3\u30c9\u306e\u7d50\u679c\u3092\u7e4b\u3044\u3060\u308a\u3057\u3066\u3044\u307e\u3057\u305f\uff0e\n\n\n\n$ ping ::1 | sed -s \"s/^/`date +%F\\ %T`\\t/\"\n2023-02-05 21:58:50 PING ::1(::1) 56 data bytes\n2023-02-05 21:58:50 64 bytes from ::1: icmp_seq=1 ttl=64 time=0.068 ms\n2023-02-05 21:58:50 64 bytes from ::1: icmp_seq=2 ttl=64 time=0.066 ms\n2023-02-05 21:58:50 64 bytes from ::1: icmp_seq=3 ttl=64 time=0.042 ms\n^C\n\n\n\n\u540c\u3058\u3088\u3046\u306a\u3053\u3068\u3092\u3057\u3066\u304f\u308c\u308b moreutils \u5185\u306e ts \u30b3\u30de\u30f3\u30c9\u304c\u3042\u308a\u307e\u3057\u305f\uff0e\n\n\n\n\nts: timestamp standard input\n\n\n\n\n\n$ ping ::1 | ts\nFeb 05 22:01:20 PING ::1(::1) 56 data bytes\nFeb 05 22:01:20 64 bytes from ::1: icmp_seq=1 ttl=64 time=0.121 ms\nFeb 05 22:01:21 64 bytes from ::1: icmp_seq=2 ttl=64 time=0.118 ms\nFeb 05 22:01:22 64 bytes from ::1: icmp_seq=3 ttl=64 time=0.115 ms\n^C\n\n\n\n\u30d5\u30a9\u30fc\u30de\u30c3\u30c8( strftime(3) )\u3092\u6307\u5b9a\u3057\u3066\u81ea\u5206\u597d\u307f\u306b\u3082\uff0e\n\n\n\n$ ping ::1 | ts -m \"%F %T\"\n2023-02-05 22:02:16 PING ::1(::1) 56 data bytes\n2023-02-05 22:02:16 64 bytes from ::1: icmp_seq=1 ttl=64 time=0.038 ms\n2023-02-05 22:02:17 64 bytes from ::1: icmp_seq=2 ttl=64 time=0.044 ms\n2023-02-05 22:02:18 64 bytes from ::1: icmp_seq=3 ttl=64 time=0.066 ms\n^C\n\n\n\nsed \u306a\u3069\u3067\u66f8\u304f\u3088\u308a\u826f\u3055\u305d\u3046\u3067\u3059\uff0e(moreutils\u306e\u5c0e\u5165\u304c\u5fc5\u8981\u3060\u3051\u3069)\n\n\n\nmoreutils\n\n\n\n\u74b0\u5883\n\n$ dpkg-query -W iputils-ping moreutils httping\nhttping 2.5-5.2+b1\niputils-ping 3:20221126-1\nmoreutils 0.67-1\n$ lsb_release -a\nNo LSB modules are available.\nDistributor ID: Debian\nDescription: Debian GNU/Linux bookworm/sid\nRelease: n/a\nCodename: bookworm\n$ arch\nx86_64", "date_published": "2023-02-05T22:38:16+09:00", "date_modified": "2023-02-05T22:38:16+09:00", "authors": [ { "name": "matoken", "url": "https://matoken.org/blog/author/matoken/", "avatar": "https://secure.gravatar.com/avatar/38f5f3b575c5eb45cda6aa659bca119ac7a5e16b46565e869d0030e3bd66981d?s=512&d=mm&r=g" } ], "author": { "name": "matoken", "url": "https://matoken.org/blog/author/matoken/", "avatar": "https://secure.gravatar.com/avatar/38f5f3b575c5eb45cda6aa659bca119ac7a5e16b46565e869d0030e3bd66981d?s=512&d=mm&r=g" }, "tags": [ "moreutils", "bookworm", "Debian", "Linux", "testing" ] } ] }