diff --git "a/\351\276\231\350\234\245\344\270\200\345\210\273/KeentuneAI\350\260\203\344\274\230\344\273\273\345\212\241/keentune_docs/KeenTune_install.md" "b/\351\276\231\350\234\245\344\270\200\345\210\273/KeentuneAI\350\260\203\344\274\230\344\273\273\345\212\241/keentune_docs/KeenTune_install.md" index 408c56441d3a05b139707139e46c210b263401cd..d01db5791276626afe4599b74031eca98b0e0fd0 100644 --- "a/\351\276\231\350\234\245\344\270\200\345\210\273/KeentuneAI\350\260\203\344\274\230\344\273\273\345\212\241/keentune_docs/KeenTune_install.md" +++ "b/\351\276\231\350\234\245\344\270\200\345\210\273/KeentuneAI\350\260\203\344\274\230\344\273\273\345\212\241/keentune_docs/KeenTune_install.md" @@ -1,8 +1,8 @@ # KeenTune 安装配置手册 ## 单机部署 -### 方法一 Alinux3 YUM安装(适用于普通用户) +### 方法一 Alinux3 YUM安装 添加yum源 -```java +```s # keentune服务对应的yum源 [keentune] name=keentune-os @@ -17,18 +17,29 @@ yum clean all # 生成新缓存 yum makecache ``` + 安装keentune服务及相关的依赖包 -```java -# 安装python36和python36开发包(提供头文件和静态链接库) +```s yum install python36 python36-devel rust openssl-devel -# 安装应用所需的Python依赖包,最好先更新一下pip:pip3 install --upgrade pip -pip3 install numpy==1.19.5 POAP==0.1.26 tornado==6.1 hyperopt==0.2.5 ultraopt==0.1.1 bokeh==2.3.2 requests==2.25.1 pySOT==0.3.3 scikit_learn==0.24.2 paramiko==2.7.2 PyYAML==5.4.1 pynginxconfig shap xgboost +pip3 install --upgrade pip +pip3 install tornado==6.1 +pip3 install pynginxconfig +pip3 install numpy==1.19.5 +pip3 install POAP==0.1.26 +pip3 install hyperopt==0.2.5 +pip3 install ultraopt==0.1.1 +pip3 install requests==2.25.1 +pip3 install pySOT==0.3.3 +pip3 install scikit_learn==0.24.2 +pip3 install shap +pip3 install xgboost #yum源安装keentune各组件 yum install keentuned keentune-brain keentune-bench keentune-target ``` + 启动各组件 -```java +```s # 启动keentuned服务 systemctl start keentuned # 启动keentune-brain服务 @@ -38,13 +49,15 @@ systemctl start keentune-bench # 启动keentune-target服务 systemctl start keentune-target ``` + 检查各组件启动状态 -```java +```s ps -ef|grep -E 'keentuned|keentune-brain|keentune-target|keentune-bench' ``` -### 方法二 源码安装(适用于开发者) + +### 方法二 源码安装 设置环境变量 -```java +```s #go编译器安装 yum install go @@ -56,473 +69,136 @@ go version go env -w GO111MODULE=on go env -w GOPROXY=https://goproxy.cn,direct ``` + 安装依赖包 -解决各组件所需依赖 -```java +```s # 安装python36和python36开发包(提供头文件和静态链接库) -yum install python36 python36-devel rust openssl-devel git -# 安装应用所需的Python依赖包 -pip3 install numpy==1.19.5 POAP==0.1.26 tornado==6.1 hyperopt==0.2.5 ultraopt==0.1.1 bokeh==2.3.2 requests==2.25.1 pySOT==0.3.3 scikit_learn==0.24.2 paramiko==2.7.2 PyYAML==5.4.1 pynginxconfig shap xgboost +yum install python36 python36-devel rust openssl-devel +# 安装python依赖包 +pip3 install --upgrade pip +pip3 install tornado==6.1 +pip3 install pynginxconfig +pip3 install numpy==1.19.5 +pip3 install POAP==0.1.26 +pip3 install hyperopt==0.2.5 +pip3 install ultraopt==0.1.1 +pip3 install requests==2.25.1 +pip3 install pySOT==0.3.3 +pip3 install scikit_learn==0.24.2 +pip3 install shap +pip3 install xgboost ``` + 下载源码 -```java +```s git clone https://gitee.com/anolis/keentuned.git git clone https://gitee.com/anolis/keentune_brain.git git clone https://gitee.com/anolis/keentune_target.git git clone https://gitee.com/anolis/keentune_bench.git ``` -编译安装 -keentuned -```java + +编译安装各组件(在各组件git目录下分别执行以下命令) ++ keentuned +```s cd keentuned ./keentuned_install.sh ``` -keentune-brain -```java ++ keentune-brain +```s cd keentune_brain sudo python3 setup.py install ``` -keentune-target -```java ++ keentune-target +```s cd keentune_target sudo python3 setup.py install ``` -keentune-bench -```java ++ keentune-bench +```s cd keentune_bench sudo python3 setup.py install ``` -启动各组件 -```java + +启动各组件(可以使用tmux,nohub或多个窗口运行的方式启动) +```s # 启动keentuned服务 keentuned +# 或者 +nohup keentuned > keentuned.log 2>&1 & + # 启动keentune-brain服务 keentune-brain +# 或者 +nohup keentune-brain > brain.log 2>&1 & + # 启动keentune-bench服务 keentune-bench +# 或者 +nohup keentune-bench > bench.log 2>&1 & + # 启动keentune-target服务 keentune-target +# 或者 +nohup keentune-target > target.log 2>&1 & ``` 检查各组件启动状态 ```java ps -ef|grep -E 'keentuned|keentune-brain|keentune-target|keentune-bench' ``` -## 分布式部署 -KeenTune包含四个组件,在分布式部署的情况下,部署的拓扑关系如下图所示: -![](assets/22.png) -注意: -keentune-target:部署在需要调优的业务环境上 -keentune-bench:(仅在需要进行动态参数调优的情况下部署),部署在benchmarksql所在环境 -keentuned和keentune-brain:可以部署在集群内任意机器上,注意keentune-brain对算力和内存有一定要求 -### 方法一 Alinux3 YUM安装( 适用于普通用户) -keentune-target(部署在业务环境) -```java -# 安装python36和python36开发包(提供头文件和静态链接库) -yum install python36 python36-devel rust openssl-devel -# 安装应用所需的Python依赖包 -pip3 install tornado==6.1 pynginxconfig - -# 安装keentune-target -yum install keentune-target -``` -keentune-bench(部署在benchmark环境,仅动态调优需要) -```java -# 安装python36和python36开发包(提供头文件和静态链接库) -yum install python36 python36-devel rust openssl-devel -# 安装应用所需的Python依赖包 -pip3 install tornado==6.1 -# 安装keentune-bench -yum install keentune-bench -keentuned(集群内网络可达机器) -# 安装keentuned -yum install keentuned -``` -keentune-brain(集群内网络可达机器) -```java -# 安装python36和python36开发包(提供头文件和静态链接库) -yum install python36 python36-devel rust openssl-devel -# 安装应用所需的Python依赖包,最好先更新一下pip:pip3 install --upgrade pip -pip3 install numpy==1.19.5 POAP==0.1.26 tornado==6.1 hyperopt==0.2.5 ultraopt==0.1.1 bokeh==2.3.2 requests==2.25.1 pySOT==0.3.3 scikit_learn==0.24.2 paramiko==2.7.2 PyYAML==5.4.1 shap xgboost - -# 安装keentune-brain -yum install keentune-brain -``` -### 方法二 源码安装(适用于开发者) - -keentune-target(部署在业务环境) -安装依赖包 -```java -# 安装python36和python36开发包(提供头文件和静态链接库) -yum install python36 python36-devel rust openssl-devel git -# 安装应用所需的Python依赖包 -pip3 install tornado==6.1 pynginxconfig -``` -下载源码 -```java -git clone https://gitee.com/anolis/keentune_target.git -``` -编译安装 -```java -cd keentune_target -sudo python3 setup.py install -``` -启动 -```java -keentune-target -``` -检查启动状态 -```java -ps -ef|grep 'keentune-target' -``` -keentune-bench(部署在benchmark环境,仅动态调优需要) -安装依赖包 -```java -# 安装python36和python36开发包(提供头文件和静态链接库) -yum install python36 python36-devel rust openssl-devel git -# 安装应用所需的Python依赖包 -pip3 install tornado==6.1 -``` -下载源码 -```java -git clone https://gitee.com/anolis/keentune_bench.git -``` -编译安装 -```java -cd keentune_bench -python3 setup.py install -``` -启动 -```java -keentune-bench -``` -检查启动状态 -```java -ps -ef|grep 'keentune-bench' -``` -keentuned(集群内网络可达机器) -设置环境变量 -```java -#go编译器安装 -yum install go - -#验证go编译器 -go env -go version - -#配置go环境 -go env -w GO111MODULE=on -go env -w GOPROXY=https://goproxy.cn,direct -``` -下载源码 -```java -git clone https://gitee.com/anolis/keentuned.git -``` -编译安装 -```java -cd keentuned -./keentuned_install.sh -``` - -启动 -```java -keentuned -``` -检查启动状态 -```java -ps -ef|grep 'keentuned' -``` -keentune-brain(集群内网络可达机器) -安装依赖包 -```java -# 安装python36和python36开发包(提供头文件和静态链接库) -yum install python36 python36-devel rust openssl-devel git -# 安装应用所需的Python依赖包,最好先更新一下pip:pip3 install --upgrade pip -pip3 install numpy==1.19.5 POAP==0.1.26 tornado==6.1 hyperopt==0.2.5 ultraopt==0.1.1 bokeh==2.3.2 requests==2.25.1 pySOT==0.3.3 scikit_learn==0.24.2 paramiko==2.7.2 PyYAML==5.4.1 shap xgboost -``` -下载源码 -```java -git clone https://gitee.com/anolis/keentune_brain.git -``` -编译安装 -```java -cd keentune_brain -sudo python3 setup.py install -``` -启动 -```java -keentune-brain -``` -检查启动状态 -```java -ps -ef|grep 'keentune-brain' -``` -各组件对应节点IP -```java -keentuned/keentune-brain:127.0.0.1 -keentune-target:127.0.0.2 -keentune-bench:127.0.0.3 -``` ### 配置文件说明 配置文件主要用于各服务的配置操作,包括服务的ip、端口、算法选择、调优参数的选择等操作。安装服务时是按默认的配置文件安装的,安装好后如果需要修改配置直接在/etc/keentune/conf目录下找到对应服务的配置文件进行修改,修改完成后重启服务即可生效。(注:在源配置文件修改时,需要重新安装、启动服务才可生效,在/etc/keentune/conf目录下修改对应的配置文件时,只需重启服务就可生效) -keentuned服务 -配置文件:keentuned/keentuned.conf -```java + +#### keentund 配置文件:/etc/keentune/conf/keentuned.conf +```conf [keentuned] -# Attributes used in KeenTuned -# KeenTuned depository location KEENTUNED_HOME = /etc/keentune -# KeenTuned access port PORT = 9871 -# Heartbeat detection interval(unit: seconds), recommended value 30 HEARTBEAT_TIME = 30 [brain] -# Attributes used to connect brain environment -# Brain machine ip BRAIN_IP = localhost -# Brain machine access port BRAIN_PORT = 9872 -# Brain optimization algorithm, available value: tpe, hord, random ALGORITHM = tpe [target-group-1] -# Attributes used to connect target group environment -# Target tuned machine ips, e.g. "ip1,ip2,...,ipn", Multiple groups TARGET_IP cannot be duplicated TARGET_IP = localhost -# Target tuned machine access port TARGET_PORT = 9873 -# Specifies the parameter file for the tuning scenario PARAMETER = sysctl.json -#[target-group-2] -#TARGET_IP = 1.2.3.4 -#TARGET_PORT = 9873 -#PARAMETER = nginx.json - [bench-group-1] -# Attributes used to connect benchmark environment -# Benchmark machine ip BENCH_SRC_IP = localhost -# Suppress target machine ip BENCH_DEST_IP = localhost -# Benchmark machine access port BENCH_SRC_PORT = 9874 -# Suppress target machine access port BENCH_DEST_PORT = 9875 -# Benchmark execution rounds of baseline -BASELINE_BENCH_ROUND = 5 -# Benchmark execution rounds during tuning execution -TUNING_BENCH_ROUND = 3 -# Benchmark execution rounds after tuning for recheck -RECHECK_BENCH_ROUND = 4 -# Specifies the benchmark profile for the tuning scenario +BASELINE_BENCH_ROUND = 2 +TUNING_BENCH_ROUND = 1 +RECHECK_BENCH_ROUND = 1 BENCH_CONFIG = bench_wrk_nginx_long.json [dump] -# Baseline configuration storage enable DUMP_BASELINE_CONFIGURATION = false -# Configuring storage enable in tuning execution DUMP_TUNING_CONFIGURATION = false -# Best configuration storage enable DUMP_BEST_CONFIGURATION = true -# Dump home is the output folder for keentuned exec result DUMP_HOME = /var/keentune [sensitize] -# algorithm of sensitive parameter tuning, at present, scope enum: random, lhs ALGORITHM = random -# Benchmark execution rounds during sensitive parameter tuning execution; scope [1,10] -BENCH_ROUND = 3 +BENCH_ROUND = 2 [log] -# Attributes used in keentuned log -# logfile log level, enum:INFO, DEBUG, WARN, FATAL; recommend:DEBUG LOGFILE_LEVEL = DEBUG LOGFILE_NAME = keentuned.log -# logfile interval, unit: day LOGFILE_INTERVAL = 2 -# logfile backup count LOGFILE_BACKUP_COUNT = 14 [version] -# Record the version number of keentune VERSION_NUM = 1.1.0 -keentune-brain服务 -配置文件:keentune_brain/brain/brain.conf -[home] -# KeenTune install path -KeenTune_HOME = /etc/keentune/ - -# KeenTune workspace -KeenTune_WORKSPACE = /var/keentune/ - -[brain] -# brain algorithm port -ALGO_PORT = 9872 -# brain sensitive port -GRAPH_PORT = 9000 - -[log] -# Logging level of terminal output -CONSOLE_LEVEL = ERROR - -# The log level of log file output -LOGFILE_LEVEL = DEBUG - -# Log File Name -LOGFILE_PATH = /var/log/keentune/brain.log - -# The time interval of the log file -LOGFILE_INTERVAL = 1 - -# Number of log files saved -LOGFILE_BACKUP_COUNT = 14 - -[algorithm] -# Max search space size for a parameter -MAX_SEARCH_SPACE = 1000 - -[hord] -# HORD surrogate: RBFInterpolant, PolyRegressor, GPRegressor -SURROGATE = RBFInterpolant -# HORD strategy: DYCORSStrategy, SRBFStrategy, SOPStrategy, EIStrategy -STRATEGY = DYCORSStrategy - -[sensi] -# supporting four methods: gp, lasso, univariate, shap -explainer = shap -# number of trials for sensitize analysis -trials = 0 -# number of epochs for training xgboost -epoch = 5 -# top N parameters recommended -topN = 10 -# confidence threshold for accumulated sensitivity scores -threshold = 0.9 -keentune-target服务 -配置文件:keentune_target/target/target.conf -[home] -# Keentune install path -KeenTune_HOME = /etc/keentune/ - -# Keentune workspace -KeenTune_WORKSPACE = /var/keentune/ - -[target] -# Keentune-target runs the port -TARGET_PORT = 9873 - -[log] -# Logging level of terminal output -CONSOLE_LEVEL = ERROR - -# The log level of log file output -LOGFILE_LEVEL = DEBUG - -# Log File Name -LOGFILE_PATH = /var/log/keentune/target.log - -# The time interval of the log file -LOGFILE_INTERVAL = 1 - -# Number of log files saved -LOGFILE_BACKUP_COUNT = 14 -``` -keentune-bench服务 -配置文件:keentune_bench/bench/bench.conf -```java -[home] -# KeenTune install path -KEENTUNE_HOME = /etc/keentune/ - -# KeenTune workspace -KEENTUNE_WORKSPACE = /var/keentune/ - -[bench] -# KeenTune-bench runs the port -BENCH_PORT = 9874 - -[log] -# Logging level of terminal output -CONSOLE_LEVEL = ERROR - -# The log level of log file output -LOGFILE_LEVEL = DEBUG - -# Log File Name -LOGFILE_PATH = /var/log/keentune/bench.log - -# The time interval of the log file -LOGFILE_INTERVAL = 1 - -# Number of log files saved -LOGFILE_BACKUP_COUNT = 14 -[algorithm] -# Max search space size for a parameter -MAX_SEARCH_SPACE = 1000 - -[hord] -# HORD surrogate: RBFInterpolant, PolyRegressor, GPRegressor -SURROGATE = RBFInterpolant -# HORD strategy: DYCORSStrategy, SRBFStrategy, SOPStrategy, EIStrategy -STRATEGY = DYCORSStrategy - -[sensi] -# supporting four methods: gp, lasso, univariate, shap -explainer = shap -# number of trials for sensitize analysis -trials = 0 -# number of epochs for training xgboost -epoch = 5 -# top N parameters recommended -topN = 10 -# confidence threshold for accumulated sensitivity scores -threshold = 0.9 ``` -keentune-target服务 -配置文件:keentune_target/target/target.conf -```java -[home] -# Keentune install path -KeenTune_HOME = /etc/keentune/ -# Keentune workspace -KeenTune_WORKSPACE = /var/keentune/ -[target] -# Keentune-target runs the port -TARGET_PORT = 9873 -[log] -# Logging level of terminal output -CONSOLE_LEVEL = ERROR -# The log level of log file output -LOGFILE_LEVEL = DEBUG -# Log File Name -LOGFILE_PATH = /var/log/keentune/target.log -# The time interval of the log file -LOGFILE_INTERVAL = 1 -# Number of log files saved -LOGFILE_BACKUP_COUNT = 14 -``` -keentune-bench服务 -配置文件:keentune_bench/bench/bench.conf -```java -[home] -# KeenTune install path -KEENTUNE_HOME = /etc/keentune/ -# KeenTune workspace -KEENTUNE_WORKSPACE = /var/keentune/ -[bench] -# KeenTune-bench runs the port -BENCH_PORT = 9874 -[log] -# Logging level of terminal output -CONSOLE_LEVEL = ERROR -# The log level of log file output -LOGFILE_LEVEL = DEBUG -# Log File Name -LOGFILE_PATH = /var/log/keentune/bench.log -# The time interval of the log file -LOGFILE_INTERVAL = 1 -# Number of log files saved -LOGFILE_BACKUP_COUNT = 14 -``` \ No newline at end of file ++ brain.BRAIN_IP: keentune-brain组件部署ip ++ brain.ALGORITHM: brain中使用的tuning算法 ++ target-group-1.TARGET_IP: keentune-target组件部署ip ++ target-group-1.PARAMETER: keentune-target中调整的参数域 ++ bench-group-1.BENCH_SRC_IP: keentune-bench组件部署ip ++ bench-group-1.BENCH_DEST_IP: keentune-bench组件发压目标ip,一般是target ip ++ bench-group-1.BENCH_CONFIG: keentune-bench中运行的benchmark脚本配置 \ No newline at end of file diff --git "a/\351\276\231\350\234\245\344\270\200\345\210\273/KeentuneAI\350\260\203\344\274\230\344\273\273\345\212\241/\351\242\230\347\233\256\346\214\207\345\257\274\346\211\213\345\206\214/KeenTune\344\270\223\345\256\266\350\260\203\344\274\230\345\256\236\350\267\265\342\200\224\342\200\224IO\351\253\230\345\220\236\345\220\220.md" "b/\351\276\231\350\234\245\344\270\200\345\210\273/KeentuneAI\350\260\203\344\274\230\344\273\273\345\212\241/\351\242\230\347\233\256\346\214\207\345\257\274\346\211\213\345\206\214/KeenTune\344\270\223\345\256\266\350\260\203\344\274\230\345\256\236\350\267\265\342\200\224\342\200\224IO\351\253\230\345\220\236\345\220\220.md" index 74c9f025a5b0914086e78e5995c45c51d90e24eb..2e971dc474d187bf318cb50eb77de7737519ba3e 100644 --- "a/\351\276\231\350\234\245\344\270\200\345\210\273/KeentuneAI\350\260\203\344\274\230\344\273\273\345\212\241/\351\242\230\347\233\256\346\214\207\345\257\274\346\211\213\345\206\214/KeenTune\344\270\223\345\256\266\350\260\203\344\274\230\345\256\236\350\267\265\342\200\224\342\200\224IO\351\253\230\345\220\236\345\220\220.md" +++ "b/\351\276\231\350\234\245\344\270\200\345\210\273/KeentuneAI\350\260\203\344\274\230\344\273\273\345\212\241/\351\242\230\347\233\256\346\214\207\345\257\274\346\211\213\345\206\214/KeenTune\344\270\223\345\256\266\350\260\203\344\274\230\345\256\236\350\267\265\342\200\224\342\200\224IO\351\253\230\345\220\236\345\220\220.md" @@ -98,6 +98,4 @@ gpgcheck=0 ``` + **如何指定调优机器** -修改文件`/etc/keentune/conf/keentuned.conf`下的配置项`target-group-1 -> TARGET_IP`和`bench-group-1 -> BENCH_DEST_IP`为调优机器的ip **(也是你安装nginx的机器)** - -##### LEARN MORE:KeenTune介绍和演示视频:https://youtu.be/Q18aC9dA2_8 \ No newline at end of file +修改文件`/etc/keentune/conf/keentuned.conf`下的配置项`target-group-1 -> TARGET_IP`和`bench-group-1 -> BENCH_DEST_IP`为调优机器的ip **(也是你安装nginx的机器)** \ No newline at end of file diff --git "a/\351\276\231\350\234\245\344\270\200\345\210\273/KeentuneAI\350\260\203\344\274\230\344\273\273\345\212\241/\351\242\230\347\233\256\346\214\207\345\257\274\346\211\213\345\206\214/KeenTune\344\270\223\345\256\266\350\260\203\344\274\230\345\256\236\350\267\265\342\200\224\342\200\224\347\275\221\347\273\234\344\275\216\346\227\266\345\273\266.md" "b/\351\276\231\350\234\245\344\270\200\345\210\273/KeentuneAI\350\260\203\344\274\230\344\273\273\345\212\241/\351\242\230\347\233\256\346\214\207\345\257\274\346\211\213\345\206\214/KeenTune\344\270\223\345\256\266\350\260\203\344\274\230\345\256\236\350\267\265\342\200\224\342\200\224\347\275\221\347\273\234\344\275\216\346\227\266\345\273\266.md" index 1f4832f9a87dcfd4c3abbae3baaa9f99bd8a2b2c..103a1e900dcb713d8b73e0900e2f083acef84852 100644 --- "a/\351\276\231\350\234\245\344\270\200\345\210\273/KeentuneAI\350\260\203\344\274\230\344\273\273\345\212\241/\351\242\230\347\233\256\346\214\207\345\257\274\346\211\213\345\206\214/KeenTune\344\270\223\345\256\266\350\260\203\344\274\230\345\256\236\350\267\265\342\200\224\342\200\224\347\275\221\347\273\234\344\275\216\346\227\266\345\273\266.md" +++ "b/\351\276\231\350\234\245\344\270\200\345\210\273/KeentuneAI\350\260\203\344\274\230\344\273\273\345\212\241/\351\242\230\347\233\256\346\214\207\345\257\274\346\211\213\345\206\214/KeenTune\344\270\223\345\256\266\350\260\203\344\274\230\345\256\236\350\267\265\342\200\224\342\200\224\347\275\221\347\273\234\344\275\216\346\227\266\345\273\266.md" @@ -49,7 +49,4 @@ gpgcheck=0 ``` + **如何指定调优机器** -修改文件`/etc/keentune/conf/keentuned.conf`下的配置项`target-group-1 -> TARGET_IP`和`bench-group-1 -> BENCH_DEST_IP`为调优机器的ip **(也是你安装nginx的机器)** - - -##### LEARN MORE:KeenTune介绍和演示视频:https://youtu.be/Q18aC9dA2_8 \ No newline at end of file +修改文件`/etc/keentune/conf/keentuned.conf`下的配置项`target-group-1 -> TARGET_IP`和`bench-group-1 -> BENCH_DEST_IP`为调优机器的ip **(也是你安装nginx的机器)** \ No newline at end of file diff --git "a/\351\276\231\350\234\245\344\270\200\345\210\273/KeentuneAI\350\260\203\344\274\230\344\273\273\345\212\241/\351\242\230\347\233\256\346\214\207\345\257\274\346\211\213\345\206\214/KeenTune\344\270\223\345\256\266\350\260\203\344\274\230\345\256\236\350\267\265\342\200\224\342\200\224\347\275\221\347\273\234\351\253\230\345\220\236\345\220\220.md" "b/\351\276\231\350\234\245\344\270\200\345\210\273/KeentuneAI\350\260\203\344\274\230\344\273\273\345\212\241/\351\242\230\347\233\256\346\214\207\345\257\274\346\211\213\345\206\214/KeenTune\344\270\223\345\256\266\350\260\203\344\274\230\345\256\236\350\267\265\342\200\224\342\200\224\347\275\221\347\273\234\351\253\230\345\220\236\345\220\220.md" index 4fe6ba4f7e6c224a09e8ce51ad22de29e2b9d440..39ab33766d0066f057df0172af2327ee7988ff96 100644 --- "a/\351\276\231\350\234\245\344\270\200\345\210\273/KeentuneAI\350\260\203\344\274\230\344\273\273\345\212\241/\351\242\230\347\233\256\346\214\207\345\257\274\346\211\213\345\206\214/KeenTune\344\270\223\345\256\266\350\260\203\344\274\230\345\256\236\350\267\265\342\200\224\342\200\224\347\275\221\347\273\234\351\253\230\345\220\236\345\220\220.md" +++ "b/\351\276\231\350\234\245\344\270\200\345\210\273/KeentuneAI\350\260\203\344\274\230\344\273\273\345\212\241/\351\242\230\347\233\256\346\214\207\345\257\274\346\211\213\345\206\214/KeenTune\344\270\223\345\256\266\350\260\203\344\274\230\345\256\236\350\267\265\342\200\224\342\200\224\347\275\221\347\273\234\351\253\230\345\220\236\345\220\220.md" @@ -1,4 +1,4 @@ -# KeenTune专家调优实践——网络低时延 +# KeenTune专家调优实践——网络高吞吐   内核参数的调整往往能够影响系统和应用的性能,但内核参数数量太多,针对不同的应用我们如何选择和调整参数值?KeenTune中内置了几个内核参数配置方案,可以通过KeenTune设置到你的测试环境中,并在一定程度上提升应用的性能。在这个题目中,我们希望你使用KeenTune工具对测试环境进行优化,并使用benchmark工具验证优化效果。 @@ -49,6 +49,4 @@ gpgcheck=0 ``` + **如何指定调优机器** -修改文件`/etc/keentune/conf/keentuned.conf`下的配置项`target-group-1 -> TARGET_IP`和`bench-group-1 -> BENCH_DEST_IP`为调优机器的ip **(也是你安装nginx的机器)** - -##### LEARN MORE:KeenTune介绍和演示视频:https://youtu.be/Q18aC9dA2_8 \ No newline at end of file +修改文件`/etc/keentune/conf/keentuned.conf`下的配置项`target-group-1 -> TARGET_IP`和`bench-group-1 -> BENCH_DEST_IP`为调优机器的ip **(也是你安装nginx的机器)** \ No newline at end of file diff --git "a/\351\276\231\350\234\245\344\270\200\345\210\273/KeentuneAI\350\260\203\344\274\230\344\273\273\345\212\241/\351\242\230\347\233\256\346\214\207\345\257\274\346\211\213\345\206\214/KeenTune\346\225\217\346\204\237\345\217\202\346\225\260\350\257\206\345\210\253\342\200\224\342\200\224http long.md" "b/\351\276\231\350\234\245\344\270\200\345\210\273/KeentuneAI\350\260\203\344\274\230\344\273\273\345\212\241/\351\242\230\347\233\256\346\214\207\345\257\274\346\211\213\345\206\214/KeenTune\346\225\217\346\204\237\345\217\202\346\225\260\350\257\206\345\210\253\342\200\224\342\200\224http long.md" index ff4c53baaaeab25d338911f71dfa279d6da9179d..6766ac4ce17e23e8ba83613245d61d00a6c262f9 100644 --- "a/\351\276\231\350\234\245\344\270\200\345\210\273/KeentuneAI\350\260\203\344\274\230\344\273\273\345\212\241/\351\242\230\347\233\256\346\214\207\345\257\274\346\211\213\345\206\214/KeenTune\346\225\217\346\204\237\345\217\202\346\225\260\350\257\206\345\210\253\342\200\224\342\200\224http long.md" +++ "b/\351\276\231\350\234\245\344\270\200\345\210\273/KeentuneAI\350\260\203\344\274\230\344\273\273\345\212\241/\351\242\230\347\233\256\346\214\207\345\257\274\346\211\213\345\206\214/KeenTune\346\225\217\346\204\237\345\217\202\346\225\260\350\257\206\345\210\253\342\200\224\342\200\224http long.md" @@ -76,5 +76,3 @@ systemctl restart keentune-brain + 在哪能找到敏感参数识别的结果文件 文件夹`/var/keentune/sensitize/`下可以找到对应的json文件,日志中也会告诉你具体路径 - -##### LEARN MORE:KeenTune介绍和演示视频:https://youtu.be/Q18aC9dA2_8 \ No newline at end of file diff --git "a/\351\276\231\350\234\245\344\270\200\345\210\273/KeentuneAI\350\260\203\344\274\230\344\273\273\345\212\241/\351\242\230\347\233\256\346\214\207\345\257\274\346\211\213\345\206\214/KeenTune\346\225\217\346\204\237\345\217\202\346\225\260\350\257\206\345\210\253\342\200\224\342\200\224http short.md" "b/\351\276\231\350\234\245\344\270\200\345\210\273/KeentuneAI\350\260\203\344\274\230\344\273\273\345\212\241/\351\242\230\347\233\256\346\214\207\345\257\274\346\211\213\345\206\214/KeenTune\346\225\217\346\204\237\345\217\202\346\225\260\350\257\206\345\210\253\342\200\224\342\200\224http short.md" index 5def30de90272b913d907b8a541d64461b8bcd92..76d1051f39c607b8d8178e61bc19b313e81a6098 100644 --- "a/\351\276\231\350\234\245\344\270\200\345\210\273/KeentuneAI\350\260\203\344\274\230\344\273\273\345\212\241/\351\242\230\347\233\256\346\214\207\345\257\274\346\211\213\345\206\214/KeenTune\346\225\217\346\204\237\345\217\202\346\225\260\350\257\206\345\210\253\342\200\224\342\200\224http short.md" +++ "b/\351\276\231\350\234\245\344\270\200\345\210\273/KeentuneAI\350\260\203\344\274\230\344\273\273\345\212\241/\351\242\230\347\233\256\346\214\207\345\257\274\346\211\213\345\206\214/KeenTune\346\225\217\346\204\237\345\217\202\346\225\260\350\257\206\345\210\253\342\200\224\342\200\224http short.md" @@ -76,5 +76,3 @@ systemctl restart keentune-brain + 在哪能找到敏感参数识别的结果文件 文件夹`/var/keentune/sensitize/`下可以找到对应的json文件,日志中也会告诉你具体路径 - -##### LEARN MORE:KeenTune介绍和演示视频:https://youtu.be/Q18aC9dA2_8 \ No newline at end of file diff --git "a/\351\276\231\350\234\245\344\270\200\345\210\273/KeentuneAI\350\260\203\344\274\230\344\273\273\345\212\241/\351\242\230\347\233\256\346\214\207\345\257\274\346\211\213\345\206\214/KeenTune\346\225\217\346\204\237\345\217\202\346\225\260\350\257\206\345\210\253\342\200\224\342\200\224https long.md" "b/\351\276\231\350\234\245\344\270\200\345\210\273/KeentuneAI\350\260\203\344\274\230\344\273\273\345\212\241/\351\242\230\347\233\256\346\214\207\345\257\274\346\211\213\345\206\214/KeenTune\346\225\217\346\204\237\345\217\202\346\225\260\350\257\206\345\210\253\342\200\224\342\200\224https long.md" index dc465d334cc846d586a9d1668f8c1dba1b9b1487..dfd4ca0812fdcaa92a2d64b86e7db217dcb75784 100644 --- "a/\351\276\231\350\234\245\344\270\200\345\210\273/KeentuneAI\350\260\203\344\274\230\344\273\273\345\212\241/\351\242\230\347\233\256\346\214\207\345\257\274\346\211\213\345\206\214/KeenTune\346\225\217\346\204\237\345\217\202\346\225\260\350\257\206\345\210\253\342\200\224\342\200\224https long.md" +++ "b/\351\276\231\350\234\245\344\270\200\345\210\273/KeentuneAI\350\260\203\344\274\230\344\273\273\345\212\241/\351\242\230\347\233\256\346\214\207\345\257\274\346\211\213\345\206\214/KeenTune\346\225\217\346\204\237\345\217\202\346\225\260\350\257\206\345\210\253\342\200\224\342\200\224https long.md" @@ -78,5 +78,3 @@ systemctl restart keentune-brain + 在哪能找到敏感参数识别的结果文件 文件夹`/var/keentune/sensitize/`下可以找到对应的json文件,日志中也会告诉你具体路径 - -##### LEARN MORE:KeenTune介绍和演示视频:https://youtu.be/Q18aC9dA2_8 \ No newline at end of file diff --git "a/\351\276\231\350\234\245\344\270\200\345\210\273/KeentuneAI\350\260\203\344\274\230\344\273\273\345\212\241/\351\242\230\347\233\256\346\214\207\345\257\274\346\211\213\345\206\214/KeenTune\346\225\217\346\204\237\345\217\202\346\225\260\350\257\206\345\210\253\342\200\224\342\200\224https short.md" "b/\351\276\231\350\234\245\344\270\200\345\210\273/KeentuneAI\350\260\203\344\274\230\344\273\273\345\212\241/\351\242\230\347\233\256\346\214\207\345\257\274\346\211\213\345\206\214/KeenTune\346\225\217\346\204\237\345\217\202\346\225\260\350\257\206\345\210\253\342\200\224\342\200\224https short.md" index 73b8c5b77f4206db31f814eca697dd73c5699dbf..db2281c9f66a26b355ec57ebdfd7de4e04871525 100644 --- "a/\351\276\231\350\234\245\344\270\200\345\210\273/KeentuneAI\350\260\203\344\274\230\344\273\273\345\212\241/\351\242\230\347\233\256\346\214\207\345\257\274\346\211\213\345\206\214/KeenTune\346\225\217\346\204\237\345\217\202\346\225\260\350\257\206\345\210\253\342\200\224\342\200\224https short.md" +++ "b/\351\276\231\350\234\245\344\270\200\345\210\273/KeentuneAI\350\260\203\344\274\230\344\273\273\345\212\241/\351\242\230\347\233\256\346\214\207\345\257\274\346\211\213\345\206\214/KeenTune\346\225\217\346\204\237\345\217\202\346\225\260\350\257\206\345\210\253\342\200\224\342\200\224https short.md" @@ -78,5 +78,3 @@ systemctl restart keentune-brain + 在哪能找到敏感参数识别的结果文件 文件夹`/var/keentune/sensitize/`下可以找到对应的json文件,日志中也会告诉你具体路径 - -##### LEARN MORE:KeenTune介绍和演示视频:https://youtu.be/Q18aC9dA2_8 \ No newline at end of file diff --git "a/\351\276\231\350\234\245\344\270\200\345\210\273/KeentuneAI\350\260\203\344\274\230\344\273\273\345\212\241/\351\242\230\347\233\256\346\214\207\345\257\274\346\211\213\345\206\214/KeenTune\346\231\272\350\203\275\345\217\202\346\225\260\350\260\203\344\274\230\342\200\224\342\200\224Nginx\345\217\202\346\225\260+HORD.md" "b/\351\276\231\350\234\245\344\270\200\345\210\273/KeentuneAI\350\260\203\344\274\230\344\273\273\345\212\241/\351\242\230\347\233\256\346\214\207\345\257\274\346\211\213\345\206\214/KeenTune\346\231\272\350\203\275\345\217\202\346\225\260\350\260\203\344\274\230\342\200\224\342\200\224Nginx\345\217\202\346\225\260+HORD.md" index 2a209d8a9d990c736e4f1a11048384391165757a..c512e935c751cbb06584dc6ed1dd1761d37de6d2 100644 --- "a/\351\276\231\350\234\245\344\270\200\345\210\273/KeentuneAI\350\260\203\344\274\230\344\273\273\345\212\241/\351\242\230\347\233\256\346\214\207\345\257\274\346\211\213\345\206\214/KeenTune\346\231\272\350\203\275\345\217\202\346\225\260\350\260\203\344\274\230\342\200\224\342\200\224Nginx\345\217\202\346\225\260+HORD.md" +++ "b/\351\276\231\350\234\245\344\270\200\345\210\273/KeentuneAI\350\260\203\344\274\230\344\273\273\345\212\241/\351\242\230\347\233\256\346\214\207\345\257\274\346\211\213\345\206\214/KeenTune\346\231\272\350\203\275\345\217\202\346\225\260\350\260\203\344\274\230\342\200\224\342\200\224Nginx\345\217\202\346\225\260+HORD.md" @@ -1,7 +1,7 @@ -# KeenTune智能参数调优——Nginx参数+HORD +# KeenTune智能参数调优——HORDNginx参数调优   内核参数的调整往往能够影响系统和应用的性能,但内核参数数量太多,针对不同的应用我们如何选择和调整参数值?智能调优在系统优化领域有着重要的应用,KeenTune也提供了参数智能调优的功能,并内置了多种参数优化算法,可以对操作系统内核参数和应用参数进行智能化调优,与专家调优方案不同,参数智能调优需要耗费的时间更长。 -  在这个题目中,我们希望你使用KeenTune对内核参数进行智能调优,提升Nginx的服务性能,并使用Benchmark工具验证调优效果。 +  在这个题目中,我们希望你使用KeenTune对nginx参数进行智能调优,提升Nginx的服务性能,并使用Benchmark工具验证调优效果。 # 1. KeenTune安装和配置 ## 1.1. KeenTune安装 @@ -17,6 +17,12 @@ TARGET_IP = [ip address of vm B] TARGET_PORT = 9873 PARAMETER = nginx.json + +[bench-group-1] +BENCH_DEST_IP = [ip address of vm B] + +[brain] +ALGORITHM = hord ``` ##### 注意:修改keentuned的配置文件之后需要重启keentuned服务 @@ -128,6 +134,4 @@ systemctl restart keentuned 修改文件`/etc/keentune/conf/keentuned.conf`下的配置项`bench-group-1 -> BENCH_CONFIG`, 配置为`bench_wrk_nginx_long.json`即可。然后**重启keentuned**。 ```shell systemctl restart keentuned -``` - -##### LEARN MORE:KeenTune介绍和演示视频:https://youtu.be/Q18aC9dA2_8 \ No newline at end of file +``` \ No newline at end of file diff --git "a/\351\276\231\350\234\245\344\270\200\345\210\273/KeentuneAI\350\260\203\344\274\230\344\273\273\345\212\241/\351\242\230\347\233\256\346\214\207\345\257\274\346\211\213\345\206\214/KeenTune\346\231\272\350\203\275\345\217\202\346\225\260\350\260\203\344\274\230\342\200\224\342\200\224Nginx\345\217\202\346\225\260+TPE.md" "b/\351\276\231\350\234\245\344\270\200\345\210\273/KeentuneAI\350\260\203\344\274\230\344\273\273\345\212\241/\351\242\230\347\233\256\346\214\207\345\257\274\346\211\213\345\206\214/KeenTune\346\231\272\350\203\275\345\217\202\346\225\260\350\260\203\344\274\230\342\200\224\342\200\224Nginx\345\217\202\346\225\260+TPE.md" index 2a209d8a9d990c736e4f1a11048384391165757a..418df491d7b67deb83a6533eb18d26c9e66e00c7 100644 --- "a/\351\276\231\350\234\245\344\270\200\345\210\273/KeentuneAI\350\260\203\344\274\230\344\273\273\345\212\241/\351\242\230\347\233\256\346\214\207\345\257\274\346\211\213\345\206\214/KeenTune\346\231\272\350\203\275\345\217\202\346\225\260\350\260\203\344\274\230\342\200\224\342\200\224Nginx\345\217\202\346\225\260+TPE.md" +++ "b/\351\276\231\350\234\245\344\270\200\345\210\273/KeentuneAI\350\260\203\344\274\230\344\273\273\345\212\241/\351\242\230\347\233\256\346\214\207\345\257\274\346\211\213\345\206\214/KeenTune\346\231\272\350\203\275\345\217\202\346\225\260\350\260\203\344\274\230\342\200\224\342\200\224Nginx\345\217\202\346\225\260+TPE.md" @@ -1,7 +1,7 @@ -# KeenTune智能参数调优——Nginx参数+HORD +# KeenTune智能参数调优——TPENginx参数调优   内核参数的调整往往能够影响系统和应用的性能,但内核参数数量太多,针对不同的应用我们如何选择和调整参数值?智能调优在系统优化领域有着重要的应用,KeenTune也提供了参数智能调优的功能,并内置了多种参数优化算法,可以对操作系统内核参数和应用参数进行智能化调优,与专家调优方案不同,参数智能调优需要耗费的时间更长。 -  在这个题目中,我们希望你使用KeenTune对内核参数进行智能调优,提升Nginx的服务性能,并使用Benchmark工具验证调优效果。 +  在这个题目中,我们希望你使用KeenTune对nginx参数进行智能调优,提升Nginx的服务性能,并使用Benchmark工具验证调优效果。 # 1. KeenTune安装和配置 ## 1.1. KeenTune安装 @@ -17,6 +17,12 @@ TARGET_IP = [ip address of vm B] TARGET_PORT = 9873 PARAMETER = nginx.json + +[bench-group-1] +BENCH_DEST_IP = [ip address of vm B] + +[brain] +ALGORITHM = tpe ``` ##### 注意:修改keentuned的配置文件之后需要重启keentuned服务 @@ -128,6 +134,4 @@ systemctl restart keentuned 修改文件`/etc/keentune/conf/keentuned.conf`下的配置项`bench-group-1 -> BENCH_CONFIG`, 配置为`bench_wrk_nginx_long.json`即可。然后**重启keentuned**。 ```shell systemctl restart keentuned -``` - -##### LEARN MORE:KeenTune介绍和演示视频:https://youtu.be/Q18aC9dA2_8 \ No newline at end of file +``` \ No newline at end of file diff --git "a/\351\276\231\350\234\245\344\270\200\345\210\273/KeentuneAI\350\260\203\344\274\230\344\273\273\345\212\241/\351\242\230\347\233\256\346\214\207\345\257\274\346\211\213\345\206\214/KeenTune\346\231\272\350\203\275\345\217\202\346\225\260\350\260\203\344\274\230\342\200\224\342\200\224\345\206\205\346\240\270\345\217\202\346\225\260+HORD.md" "b/\351\276\231\350\234\245\344\270\200\345\210\273/KeentuneAI\350\260\203\344\274\230\344\273\273\345\212\241/\351\242\230\347\233\256\346\214\207\345\257\274\346\211\213\345\206\214/KeenTune\346\231\272\350\203\275\345\217\202\346\225\260\350\260\203\344\274\230\342\200\224\342\200\224\345\206\205\346\240\270\345\217\202\346\225\260+HORD.md" index ddda7108ebe77b52c328cf9cd1a3ed650f651ed3..910e65a2e355972803b7ed91437874f0a15f1307 100644 --- "a/\351\276\231\350\234\245\344\270\200\345\210\273/KeentuneAI\350\260\203\344\274\230\344\273\273\345\212\241/\351\242\230\347\233\256\346\214\207\345\257\274\346\211\213\345\206\214/KeenTune\346\231\272\350\203\275\345\217\202\346\225\260\350\260\203\344\274\230\342\200\224\342\200\224\345\206\205\346\240\270\345\217\202\346\225\260+HORD.md" +++ "b/\351\276\231\350\234\245\344\270\200\345\210\273/KeentuneAI\350\260\203\344\274\230\344\273\273\345\212\241/\351\242\230\347\233\256\346\214\207\345\257\274\346\211\213\345\206\214/KeenTune\346\231\272\350\203\275\345\217\202\346\225\260\350\260\203\344\274\230\342\200\224\342\200\224\345\206\205\346\240\270\345\217\202\346\225\260+HORD.md" @@ -1,4 +1,5 @@ -# KeenTune智能参数调优——内核参数+HORD +# KeenTune智能参数调优——HORD内核参数调优 +   内核参数的调整往往能够影响系统和应用的性能,但内核参数数量太多,针对不同的应用我们如何选择和调整参数值?智能调优在系统优化领域有着重要的应用,KeenTune也提供了参数智能调优的功能,并内置了多种参数优化算法,可以对操作系统内核参数和应用参数进行智能化调优,与专家调优方案不同,参数智能调优需要耗费的时间更长。   在这个题目中,我们希望你使用KeenTune对内核参数进行智能调优,提升Nginx的服务性能,并使用Benchmark工具验证调优效果。 @@ -17,6 +18,12 @@ TARGET_IP = [ip address of vm B] TARGET_PORT = 9873 PARAMETER = sysctl.json + +[bench-group-1] +BENCH_DEST_IP = [ip address of vm B] + +[brain] +ALGORITHM = hord ``` ##### 注意:修改keentuned的配置文件之后需要重启keentuned服务 @@ -128,6 +135,4 @@ systemctl restart keentuned 修改文件`/etc/keentune/conf/keentuned.conf`下的配置项`bench-group-1 -> BENCH_CONFIG`, 配置为`bench_wrk_nginx_long.json`即可。然后**重启keentuned**。 ```shell systemctl restart keentuned -``` - -##### LEARN MORE:KeenTune介绍和演示视频:https://youtu.be/Q18aC9dA2_8 \ No newline at end of file +``` \ No newline at end of file diff --git "a/\351\276\231\350\234\245\344\270\200\345\210\273/KeentuneAI\350\260\203\344\274\230\344\273\273\345\212\241/\351\242\230\347\233\256\346\214\207\345\257\274\346\211\213\345\206\214/KeenTune\346\231\272\350\203\275\345\217\202\346\225\260\350\260\203\344\274\230\342\200\224\342\200\224\345\206\205\346\240\270\345\217\202\346\225\260+TPE.md" "b/\351\276\231\350\234\245\344\270\200\345\210\273/KeentuneAI\350\260\203\344\274\230\344\273\273\345\212\241/\351\242\230\347\233\256\346\214\207\345\257\274\346\211\213\345\206\214/KeenTune\346\231\272\350\203\275\345\217\202\346\225\260\350\260\203\344\274\230\342\200\224\342\200\224\345\206\205\346\240\270\345\217\202\346\225\260+TPE.md" index e215fb1d7d7eb97de38fb1f938d0d9d5bc7a6045..7595cbfa77edb9ef7c8b7afeef6cf415f69f3300 100644 --- "a/\351\276\231\350\234\245\344\270\200\345\210\273/KeentuneAI\350\260\203\344\274\230\344\273\273\345\212\241/\351\242\230\347\233\256\346\214\207\345\257\274\346\211\213\345\206\214/KeenTune\346\231\272\350\203\275\345\217\202\346\225\260\350\260\203\344\274\230\342\200\224\342\200\224\345\206\205\346\240\270\345\217\202\346\225\260+TPE.md" +++ "b/\351\276\231\350\234\245\344\270\200\345\210\273/KeentuneAI\350\260\203\344\274\230\344\273\273\345\212\241/\351\242\230\347\233\256\346\214\207\345\257\274\346\211\213\345\206\214/KeenTune\346\231\272\350\203\275\345\217\202\346\225\260\350\260\203\344\274\230\342\200\224\342\200\224\345\206\205\346\240\270\345\217\202\346\225\260+TPE.md" @@ -1,4 +1,5 @@ -# KeenTune智能参数调优——Nginx参数+TPE +# KeenTune智能参数调优——TPE内核参数调优 +   内核参数的调整往往能够影响系统和应用的性能,但内核参数数量太多,针对不同的应用我们如何选择和调整参数值?智能调优在系统优化领域有着重要的应用,KeenTune也提供了参数智能调优的功能,并内置了多种参数优化算法,可以对操作系统内核参数和应用参数进行智能化调优,与专家调优方案不同,参数智能调优需要耗费的时间更长。   在这个题目中,我们希望你使用KeenTune对内核参数进行智能调优,提升Nginx的服务性能,并使用Benchmark工具验证调优效果。 @@ -17,6 +18,12 @@ TARGET_IP = [ip address of vm B] TARGET_PORT = 9873 PARAMETER = sysctl.json + +[bench-group-1] +BENCH_DEST_IP = [ip address of vm B] + +[brain] +ALGORITHM = tpe ``` ##### 注意:修改keentuned的配置文件之后需要重启keentuned服务 @@ -128,6 +135,4 @@ systemctl restart keentuned 修改文件`/etc/keentune/conf/keentuned.conf`下的配置项`bench-group-1 -> BENCH_CONFIG`, 配置为`bench_wrk_nginx_long.json`即可。然后**重启keentuned**。 ```shell systemctl restart keentuned -``` - -##### LEARN MORE:KeenTune介绍和演示视频:https://youtu.be/Q18aC9dA2_8 \ No newline at end of file +``` \ No newline at end of file diff --git "a/\351\276\231\350\234\245\344\270\200\345\210\273/KeentuneAI\350\260\203\344\274\230\344\273\273\345\212\241/\351\242\230\347\233\256\346\214\207\345\257\274\346\211\213\345\206\214/KeenTune\346\231\272\350\203\275\345\217\202\346\225\260\350\260\203\344\274\230\342\200\224\342\200\224\350\201\224\345\220\210\350\260\203\344\274\230+HORD.md" "b/\351\276\231\350\234\245\344\270\200\345\210\273/KeentuneAI\350\260\203\344\274\230\344\273\273\345\212\241/\351\242\230\347\233\256\346\214\207\345\257\274\346\211\213\345\206\214/KeenTune\346\231\272\350\203\275\345\217\202\346\225\260\350\260\203\344\274\230\342\200\224\342\200\224\350\201\224\345\220\210\350\260\203\344\274\230+HORD.md" index cea10a916bec24ca0730c301bfef45158ced1365..68df9c0b3c80280d42fc2c73f0fba8adfccb8ceb 100644 --- "a/\351\276\231\350\234\245\344\270\200\345\210\273/KeentuneAI\350\260\203\344\274\230\344\273\273\345\212\241/\351\242\230\347\233\256\346\214\207\345\257\274\346\211\213\345\206\214/KeenTune\346\231\272\350\203\275\345\217\202\346\225\260\350\260\203\344\274\230\342\200\224\342\200\224\350\201\224\345\220\210\350\260\203\344\274\230+HORD.md" +++ "b/\351\276\231\350\234\245\344\270\200\345\210\273/KeentuneAI\350\260\203\344\274\230\344\273\273\345\212\241/\351\242\230\347\233\256\346\214\207\345\257\274\346\211\213\345\206\214/KeenTune\346\231\272\350\203\275\345\217\202\346\225\260\350\260\203\344\274\230\342\200\224\342\200\224\350\201\224\345\220\210\350\260\203\344\274\230+HORD.md" @@ -1,7 +1,8 @@ -# KeenTune智能参数调优——联合调优+HORD +# KeenTune智能参数调优——HORD混合参数调优 +   内核参数的调整往往能够影响系统和应用的性能,但内核参数数量太多,针对不同的应用我们如何选择和调整参数值?智能调优在系统优化领域有着重要的应用,KeenTune也提供了参数智能调优的功能,并内置了多种参数优化算法,可以对操作系统内核参数和应用参数进行智能化调优,与专家调优方案不同,参数智能调优需要耗费的时间更长。 -  在这个题目中,我们希望你使用KeenTune对内核参数进行智能调优,提升Nginx的服务性能,并使用Benchmark工具验证调优效果。 +  在这个题目中,我们希望你使用KeenTune对内核参数和Nginx参数进行智能调优,提升Nginx的服务性能,并使用Benchmark工具验证调优效果。 # 1. KeenTune安装和配置 ## 1.1. KeenTune安装 @@ -17,6 +18,12 @@ TARGET_IP = [ip address of vm B] TARGET_PORT = 9873 PARAMETER = sysctl.json, nginx.json + +[bench-group-1] +BENCH_DEST_IP = [ip address of vm B] + +[brain] +ALGORITHM = hord ``` ##### 注意:修改keentuned的配置文件之后需要重启keentuned服务 @@ -36,14 +43,6 @@ systemctl restart keentuned ## 2.3. benchmark脚本准备   我们需要为wrk实现一个自动化脚本使keentune-bench能够自动运行benchmark工具,我们已经实现好了这个[脚本](https://gitee.com/anolis/keentuned/blob/master/daemon/examples/benchmark/wrk/ack_nginx_http_long_base.py),并为其写好了[配置文件](https://gitee.com/anolis/keentuned/blob/master/daemon/examples/benchmark/wrk/bench_wrk_nginx_long.json),你可以直接使用。可以看到,对于wrk工具,我们会关注Requests_sec, Transfer_sec, Latency_90和Latency_99四个指标。 -## 2.4. benchmark配置 -手动编辑`/etc/keentune/conf/keentuned.conf`文件 -```conf -[bench-group-1] -BENCH_DEST_IP = [ip address of vm B] -... -``` - # 3. Nginx服务端安装   Nginx是我们的优化目标,我们需要在虚拟机B上安装Nginx服务并启动,具体操作步骤见[《nginx安装配置手册》](../benchmark_docs/Nginx.md) @@ -127,6 +126,4 @@ systemctl restart keentuned 修改文件`/etc/keentune/conf/keentuned.conf`下的配置项`bench-group-1 -> BENCH_CONFIG`, 配置为`bench_wrk_nginx_long.json`即可。然后**重启keentuned**。 ```shell systemctl restart keentuned -``` - -##### LEARN MORE:KeenTune介绍和演示视频:https://youtu.be/Q18aC9dA2_8 \ No newline at end of file +``` \ No newline at end of file diff --git "a/\351\276\231\350\234\245\344\270\200\345\210\273/KeentuneAI\350\260\203\344\274\230\344\273\273\345\212\241/\351\242\230\347\233\256\346\214\207\345\257\274\346\211\213\345\206\214/KeenTune\346\231\272\350\203\275\345\217\202\346\225\260\350\260\203\344\274\230\342\200\224\342\200\224\350\201\224\345\220\210\350\260\203\344\274\230+TPE.md" "b/\351\276\231\350\234\245\344\270\200\345\210\273/KeentuneAI\350\260\203\344\274\230\344\273\273\345\212\241/\351\242\230\347\233\256\346\214\207\345\257\274\346\211\213\345\206\214/KeenTune\346\231\272\350\203\275\345\217\202\346\225\260\350\260\203\344\274\230\342\200\224\342\200\224\350\201\224\345\220\210\350\260\203\344\274\230+TPE.md" index 54fbbac69a914b539044b0b08537a07f89961a8c..3cfadda03e7589d2cdb39c1d93fbc620b18a88cf 100644 --- "a/\351\276\231\350\234\245\344\270\200\345\210\273/KeentuneAI\350\260\203\344\274\230\344\273\273\345\212\241/\351\242\230\347\233\256\346\214\207\345\257\274\346\211\213\345\206\214/KeenTune\346\231\272\350\203\275\345\217\202\346\225\260\350\260\203\344\274\230\342\200\224\342\200\224\350\201\224\345\220\210\350\260\203\344\274\230+TPE.md" +++ "b/\351\276\231\350\234\245\344\270\200\345\210\273/KeentuneAI\350\260\203\344\274\230\344\273\273\345\212\241/\351\242\230\347\233\256\346\214\207\345\257\274\346\211\213\345\206\214/KeenTune\346\231\272\350\203\275\345\217\202\346\225\260\350\260\203\344\274\230\342\200\224\342\200\224\350\201\224\345\220\210\350\260\203\344\274\230+TPE.md" @@ -1,7 +1,8 @@ -# KeenTune智能参数调优——联合调优+TPE +# KeenTune智能参数调优——TPE混合参数调优 +   内核参数的调整往往能够影响系统和应用的性能,但内核参数数量太多,针对不同的应用我们如何选择和调整参数值?智能调优在系统优化领域有着重要的应用,KeenTune也提供了参数智能调优的功能,并内置了多种参数优化算法,可以对操作系统内核参数和应用参数进行智能化调优,与专家调优方案不同,参数智能调优需要耗费的时间更长。 -  在这个题目中,我们希望你使用KeenTune对内核参数进行智能调优,提升Nginx的服务性能,并使用Benchmark工具验证调优效果。 +  在这个题目中,我们希望你使用KeenTune对内核参数和Nginx参数进行智能调优,提升Nginx的服务性能,并使用Benchmark工具验证调优效果。 # 1. KeenTune安装和配置 ## 1.1. KeenTune安装 @@ -17,6 +18,12 @@ TARGET_IP = [ip address of vm B] TARGET_PORT = 9873 PARAMETER = sysctl.json, nginx.json + +[bench-group-1] +BENCH_DEST_IP = [ip address of vm B] + +[brain] +ALGORITHM = tpe ``` ##### 注意:修改keentuned的配置文件之后需要重启keentuned服务 @@ -36,14 +43,6 @@ systemctl restart keentuned ## 2.3. benchmark脚本准备   我们需要为wrk实现一个自动化脚本使keentune-bench能够自动运行benchmark工具,我们已经实现好了这个[脚本](https://gitee.com/anolis/keentuned/blob/master/daemon/examples/benchmark/wrk/ack_nginx_http_long_base.py),并为其写好了[配置文件](https://gitee.com/anolis/keentuned/blob/master/daemon/examples/benchmark/wrk/bench_wrk_nginx_long.json),你可以直接使用。可以看到,对于wrk工具,我们会关注Requests_sec, Transfer_sec, Latency_90和Latency_99四个指标。 -## 2.4. benchmark配置 -手动编辑`/etc/keentune/conf/keentuned.conf`文件 -```conf -[bench-group-1] -BENCH_DEST_IP = [ip address of vm B] -... -``` - # 3. Nginx服务端安装   Nginx是我们的优化目标,我们需要在虚拟机B上安装Nginx服务并启动,具体操作步骤见[《nginx安装配置手册》](../benchmark_docs/Nginx.md) @@ -128,6 +127,4 @@ systemctl restart keentuned 修改文件`/etc/keentune/conf/keentuned.conf`下的配置项`bench-group-1 -> BENCH_CONFIG`, 配置为`bench_wrk_nginx_long.json`即可。然后**重启keentuned**。 ```shell systemctl restart keentuned -``` - -##### LEARN MORE:KeenTune介绍和演示视频:https://youtu.be/Q18aC9dA2_8 \ No newline at end of file +``` \ No newline at end of file diff --git "a/\351\276\231\350\234\245\344\270\200\345\210\273/KeentuneAI\350\260\203\344\274\230\344\273\273\345\212\241/\351\242\230\347\233\256\346\214\207\345\257\274\346\211\213\345\206\214/demo.json" "b/\351\276\231\350\234\245\344\270\200\345\210\273/KeentuneAI\350\260\203\344\274\230\344\273\273\345\212\241/\351\242\230\347\233\256\346\214\207\345\257\274\346\211\213\345\206\214/demo.json" deleted file mode 100644 index 257921cdbd942f4d21419df8db57ad16b9dc598f..0000000000000000000000000000000000000000 --- "a/\351\276\231\350\234\245\344\270\200\345\210\273/KeentuneAI\350\260\203\344\274\230\344\273\273\345\212\241/\351\242\230\347\233\256\346\214\207\345\257\274\346\211\213\345\206\214/demo.json" +++ /dev/null @@ -1,31 +0,0 @@ -{ - "parameters": [ - { - "domain": "nginx", - "name": "gzip_min_length", - "range": [ - 1024, - 102400 - ], - "dtype": "int", - "value": 3200, - "base": "" - }, - { - "domain": "nginx", - "name": "client_header_buffer_size", - "options": [ - "2k", - "4k", - "8k", - "16k", - "32k", - "64k" - ], - "dtype": "string", - "value": "4k", - "base": "" - } - ], - "current_round": 64 -} \ No newline at end of file