zhenwei pi
5010da6ab0
Threaded IO: set thread name for redis-server
Set thread name for each thread of redis-server, this helps us to
monitor the utilization and optimise the performance.
And suggested-by Salvatore, implement this feature for multi
platforms. Currently support linux and bsd, ignore other OS.
An exmaple on Linux:
# top -d 5 -p `pidof redis-server ` -H
PID USER PR NI VIRT RES SHR S %CPU %MEM TIME+ COMMAND
3682671 root 20 0 227744 8248 3836 R 99.2 0.0 0:19.53 redis-server
3682677 root 20 0 227744 8248 3836 S 26.4 0.0 0:04.15 io_thd_3
3682675 root 20 0 227744 8248 3836 S 23.6 0.0 0:03.98 io_thd_1
3682676 root 20 0 227744 8248 3836 S 23.6 0.0 0:03.97 io_thd_2
3682672 root 20 0 227744 8248 3836 S 0.2 0.0 0:00.02 bio_close_file
3682673 root 20 0 227744 8248 3836 S 0.2 0.0 0:00.02 bio_aof_fsync
3682674 root 20 0 227744 8248 3836 S 0.0 0.0 0:00.00 bio_lazy_free
3682678 root 20 0 227744 8248 3836 S 0.0 0.0 0:00.00 jemalloc_bg_thd
3682682 root 20 0 227744 8248 3836 S 0.0 0.0 0:00.00 jemalloc_bg_thd
3682683 root 20 0 227744 8248 3836 S 0.0 0.0 0:00.00 jemalloc_bg_thd
3682684 root 20 0 227744 8248 3836 S 0.0 0.0 0:00.00 jemalloc_bg_thd
3682685 root 20 0 227744 8248 3836 S 0.0 0.0 0:00.00 jemalloc_bg_thd
3682687 root 20 0 227744 8248 3836 S 0.0 0.0 0:00.00 jemalloc_bg_thd
Another exmaple on FreeBSD-12.1:
PID USERNAME PRI NICE SIZE RES STATE C TIME WCPU COMMAND
5212 root 100 0 48M 7280K CPU2 2 0:26 99.52% redis-server{redis-server}
5212 root 38 0 48M 7280K umtxn 4 0:06 26.94% redis-server{io_thd_3}
5212 root 36 0 48M 7280K umtxn 6 0:06 26.84% redis-server{io_thd_1}
5212 root 39 0 48M 7280K umtxn 1 0:06 25.30% redis-server{io_thd_2}
5212 root 20 0 48M 7280K uwait 3 0:00 0.00% redis-server{redis-server}
5212 root 21 0 48M 7280K uwait 2 0:00 0.00% redis-server{bio_close_file}
5212 root 21 0 48M 7280K uwait 3 0:00 0.00% redis-server{bio_aof_fsync}
5212 root 21 0 48M 7280K uwait 0 0:00 0.00% redis-server{bio_lazy_free}
Signed-off-by: zhenwei pi <pizhenwei@bytedance.com>
2020-04-18 11:17:21 +08:00
..
2019-12-17 07:15:04 +00:00
2020-04-15 16:40:25 +02:00
2020-04-08 12:55:57 +02:00
2020-04-08 12:55:57 +02:00
2019-10-07 21:06:30 +03:00
2014-06-26 18:48:40 +02:00
2016-06-07 16:46:00 -04:00
2020-03-12 13:24:30 +01:00
2019-10-15 17:21:51 +03:00
2019-10-07 21:06:13 +03:00
2019-10-07 21:06:13 +03:00
2020-03-31 13:55:51 +03:00
2020-03-07 19:38:27 +08:00
2018-10-16 15:48:03 +08:00
2020-04-18 11:17:21 +08:00
2019-11-20 20:39:04 -05:00
2020-04-08 18:20:32 +08:00
2020-04-08 12:55:57 +02:00
2019-07-17 16:40:24 +03:00
2020-04-09 10:24:46 +02:00
2019-12-16 23:34:37 -08:00
2020-04-06 17:27:39 +02:00
2020-04-18 11:17:21 +08:00
2020-03-22 14:42:03 +02:00
2020-03-22 14:42:03 +02:00
2020-03-22 14:42:03 +02:00
2019-03-01 17:53:14 +01:00
2015-07-26 15:17:18 +02:00
2014-12-23 09:31:03 -05:00
2014-12-23 09:31:03 -05:00
2020-04-09 16:21:48 +02:00
2020-04-09 12:10:10 +02:00
2016-08-04 15:12:12 +08:00
2020-02-18 17:22:32 +02:00
2020-03-29 16:17:52 +02:00
2019-02-18 18:27:18 +01:00
2014-12-23 09:31:03 -05:00
2018-07-03 18:19:46 +02:00
2019-10-07 09:09:32 +03:00
2020-03-29 17:50:42 +03:00
2014-12-05 12:41:59 +11:00
2019-12-18 12:57:32 +01:00
2015-07-26 15:17:18 +02:00
2017-07-03 19:38:31 +02:00
2016-07-06 16:31:11 +02:00
2020-04-09 17:48:29 +08:00
2016-07-27 11:34:25 +02:00
2019-02-24 21:38:15 +01:00
2018-10-17 12:57:21 +02:00
2020-01-07 11:17:52 +08:00
2018-10-16 15:48:03 +08:00
2016-06-20 23:08:06 +03:00
2020-03-12 20:44:32 +08:00
2019-10-24 14:24:55 +03:00
2020-04-09 10:24:46 +02:00
2017-12-01 10:24:24 +01:00
2018-10-02 19:37:36 +02:00
2017-12-01 10:24:24 +01:00
2018-09-18 17:04:00 +08:00
2019-10-07 18:24:34 +02:00
2019-10-28 11:10:58 +01:00
2019-10-07 18:24:34 +02:00
2019-10-07 18:24:34 +02:00
2015-01-02 11:16:10 -05:00
2018-09-28 13:00:44 +02:00
2014-06-26 18:48:40 +02:00
2017-11-19 16:23:42 +00:00
2020-03-27 16:35:03 +01:00
2015-12-16 17:41:22 +01:00
2019-11-19 17:23:47 +08:00
2020-04-02 19:00:20 +02:00
2020-02-04 12:55:26 +01:00
2020-04-18 11:17:21 +08:00
2020-02-03 15:43:44 +05:30
2020-04-09 16:20:41 +02:00
2014-06-26 18:48:40 +02:00
2020-03-31 12:40:08 +02:00
2020-04-02 23:43:47 +08:00
2020-02-18 17:22:32 +02:00
2014-08-08 10:05:32 +02:00
2017-03-27 16:37:22 +02:00
2020-02-07 18:12:10 +01:00
2018-10-13 14:17:38 +02:00
2020-04-09 16:21:48 +02:00
2020-04-09 12:10:10 +02:00
2019-07-22 18:45:47 +02:00
2019-05-08 12:13:45 +01:00
2020-04-09 10:24:46 +02:00
2020-03-23 11:14:46 +01:00
2018-07-13 10:51:58 +02:00
2018-07-03 18:19:46 +02:00
2020-04-03 14:49:40 +03:00
2019-10-02 11:30:20 +02:00
2020-03-28 20:59:01 +08:00
2019-10-07 21:06:30 +03:00
2019-10-07 21:06:30 +03:00
2020-04-06 19:27:06 +08:00
2020-04-16 16:08:37 +02:00
2019-12-21 11:47:31 -08:00
2020-02-22 11:38:51 -05:00
2020-03-16 16:57:12 +01:00
2020-04-17 12:38:15 +02:00
2020-04-09 16:25:30 +02:00
2018-11-11 18:49:55 +00:00
2015-04-27 12:07:49 +02:00
2015-04-27 12:07:49 +02:00
2019-09-12 12:21:37 +02:00
2019-09-12 12:21:37 +02:00
2019-09-04 12:14:25 +00:00
2019-01-09 17:00:29 +01:00
2019-12-02 00:28:41 -05:00
2015-01-09 11:23:22 +01:00
2019-12-18 11:58:02 +01:00
2015-07-26 15:17:18 +02:00
2014-07-02 16:31:22 +02:00
2019-12-26 15:31:37 +05:30
2015-08-06 18:12:20 +02:00
2019-11-03 16:42:31 +02:00
2019-11-22 16:38:49 +08:00
2019-12-21 21:27:38 +08:00
2020-04-17 12:38:15 +02:00
2020-04-06 13:51:55 +02:00
2020-04-14 11:23:44 +02:00
2020-04-11 15:05:01 +03:00
2019-10-08 17:58:50 +03:00
2020-03-23 01:07:46 -04:00
2020-04-02 16:26:57 +02:00
2019-11-21 10:06:15 +01:00
2015-09-29 17:30:24 +02:00
2019-05-08 12:53:56 +08:00
2016-12-16 09:02:50 +01:00
2014-12-23 09:31:03 -05:00
2014-12-23 09:31:03 -05:00
2019-12-02 09:13:29 +01:00
2019-12-02 09:13:29 +01:00