您好,登錄后才能下訂單哦!
本篇內容介紹了“centos7下nginx-qat的安裝教程”的有關知識,在實際案例的操作過程中,不少人都會遇到這樣的困境,接下來就讓小編帶領大家學習一下如何處理這些情況吧!希望大家仔細閱讀,能夠學有所成!
qat的資料主要在intel官網和github上找
intel官網:https://01.org/zh/packet-processing/intel%C2%AE-quickassist-technology-drivers-and-patches?langredirect=1&tdsourcetag=s_pcqq_aiomsg
github:https://github.com/intel/asynch_mode_nginx
官網上主要是驅動的安裝包,安裝說明,配置文件和其它說明,根據自己的qat卡型號,在官網上下載對應的驅動,查看對應的安裝說明進行安裝。然后安裝nginx-qat先跑通所有的測試,最后根據需要去查看配置文件和其它說明的pdf修改對應的配置文件
環境:
qat : Intel QuickAssist Technology DH895xCC kernel: 3.10.0-693.el7.x86_64
環境變量設置
# export NGINX_INSTALL_DIR=/usr/local/nginx # export OPENSSL_LIB=/usr/local/ssl # export QZ_ROOT=/root/nginx-qat/QATzip # export ICP_ROOT=/root/nginx-qat/QAT_Driver # export NGINX_SRC_DIR=/root/nginx-qat/asynch_mode_nginx # export QATZIP_SRC_DIR=/root/nginx-qat/QATzip # export OPENSSL_SRC_DIR=/root/nginx-qat/openssl-1.1.1c # export PERL5LIB=$PERL5LIB:/root/nginx-qat/openssl-1.1.1c # export LD_LIBRARY_PATH=/root/nginx-qat/QAT_Driver/build
1.安裝 qat_driver
# cd ~ # mkdir nginx-qat # cd nginx-qat # mkdir QAT_Driver # cd QAT_Driver # wget https://01.org/zh/packet-processing/intel%C2%AE-quickassist-technology-drivers-and-patches?langredirect=1&tdsourcetag=s_pcqq_aiomsg # tar -zxvf qat1.7.l.4.6.0-00025.tar.gz # ./configure # make # make install # lsmod | fgrep qa
2.安裝openssl
# cd ~/nginx-qat/openssl # ./config --prefix=/usr/local/ssl -Wl,-rpath=/usr/local/ssl/lib # make depend # make # make install # export OPENSSL_ENGINES=/usr/local/ssl/lib/engines-1.1
3.安裝 qat_engine,安裝完測試是否可以使用qat卡進行加解密
# cd ~/nginx-qat # git clone https://github.com/intel/QAT_Engine.git # cd QAT_Engine/ # ./autogen.sh # ./configure --with-qat_dir=/root/nginx-qat/QAT_Driver --with-openssl_dir=/root/nginx-qat/openssl-1.1.1c --with-openssl_install_dir=/usr/local/ssl --enable-upstream_driver --enable-usdm # make # make install # cp qat/config/c6xx/multi_process_optimized/c6xx_dev* /etc/ # service qat_service restart # /usr/local/ssl/bin/openssl engine -t -c -vvvv qat
4.安裝qat_zip
# cd ~/nginx-qat # git clone https://github.com/intel/QATzip.git # cd QATzip/ # service qat_service stop # echo 1024 > /sys/kernel/mm/hugepages/hugepages-2048kB/nr_hugepages # rmmod usdm_drv # insmod $ICP_ROOT/build/usdm_drv.ko max_huge_pages=1024 max_huge_pages_per_process=16 # ./configure --with-ICP_ROOT=$ICP_ROOT # make clean # make all install # cp config_file/c6xx/multiple_process_opt/c6xx_dev* /etc/ # service qat_service restart # ./setenv.sh # cd $QZ_ROOT/test/performance_tests # ./run_perf_test.sh
5.安裝nginx-test
# cd ~/nginx-qat/ # git clone https://github.com/intel/asynch_mode_nginx.git # ./configure --prefix=$NGINX_INSTALL_DIR --with-http_ssl_module --add-dynamic-module=modules/nginx_qatzip_module --add-dynamic-module=modules/nginx_qat_module/ --with-cc-opt="-DNGX_SECURE_MEM -I$OPENSSL_LIB/include -I$QZ_ROOT/include -Wno-error=deprecated-declarations" --with-ld-opt="-Wl,-rpath=$OPENSSL_LIB/lib -L$OPENSSL_LIB/lib -L$QZ_ROOT/src -lqatzip -lz" # make # make install
6.運行test(在這之前要修改qat驅動的配置文件) 詳見下面這個issue https://github.com/intel/asynch_mode_nginx/issues/28
# cd ~/nginx-qat/asynch_mode_nginx/test # ./nginx-test qat
“centos7下nginx-qat的安裝教程”的內容就介紹到這里了,感謝大家的閱讀。如果想了解更多行業相關的知識可以關注億速云網站,小編將為大家輸出更多高質量的實用文章!
免責聲明:本站發布的內容(圖片、視頻和文字)以原創、轉載和分享為主,文章觀點不代表本網站立場,如果涉及侵權請聯系站長郵箱:is@yisu.com進行舉報,并提供相關證據,一經查實,將立刻刪除涉嫌侵權內容。