{"id":7430,"date":"2021-03-05T08:36:38","date_gmt":"2021-03-05T01:36:38","guid":{"rendered":"https:\/\/tino.vn\/?post_type=ht_kb&#038;p=7430"},"modified":"2021-03-05T08:44:28","modified_gmt":"2021-03-05T01:44:28","slug":"huong-dan-nang-cap-http-2-tren-nginx-webserver-cua-directadmin","status":"publish","type":"ht_kb","link":"https:\/\/tino.vn\/blog\/docs\/huong-dan-nang-cap-http-2-tren-nginx-webserver-cua-directadmin\/","title":{"rendered":"H\u01b0\u1edbng d\u1eabn N\u00e2ng c\u1ea5p HTTP\/2 tr\u00ean Nginx Webserver c\u1ee7a DirectAdmin"},"content":{"rendered":"<p>DirectAdmin l\u00e0 ph\u1ea7n m\u1ec1m qu\u1ea3n tr\u1ecb Hosting chuy\u00ean nghi\u1ec7p hi\u1ec7n \u0111ang \u0111\u01b0\u1ee3c s\u1eed d\u1ee5ng b\u1edfi nhi\u1ec1u kh\u00e1ch h\u00e0ng. M\u1eb7c \u0111\u1ecbnh DirectAdmin s\u1eed d\u1ee5ng giao th\u1ee9c HTTP\/1.1 trong c\u1ea5u h\u00ecnh c\u00e0i \u0111\u1eb7t (Custombuild 2.0).<\/p>\n<div id=\"ez-toc-container\" class=\"ez-toc-v2_0_16 counter-hierarchy counter-decimal ez-toc-grey\">\n<div class=\"ez-toc-title-container\">\n<p>H\u01b0\u1edbng d\u1eabn n\u00e0y \u00e1p d\u1ee5ng cho tr\u01b0\u1eddng h\u1ee3p s\u1eed d\u1ee5ng 2 server l\u00e0 Apache v\u00e0 Nginx, trong \u0111\u00f3 Apache l\u00e0 Application server v\u00e0 Nginx l\u00e0 Proxy. N\u1ebfu c\u1ea5u h\u00ecnh DirectAdmin c\u1ee7a b\u1ea1n l\u00e0 Nginx ch\u1ea1y \u0111\u1ed9c l\u1eadp th\u00ec c\u1ea7n thay th\u1ebf file:<\/p>\n<p><code>\/usr\/local\/directadmin\/custombuild\/configure\/nginx_reverse\/configure.nginx<\/code><\/p>\n<p>B\u1eb1ng file<\/p>\n<p><code>\/usr\/local\/directadmin\/custombuild\/configure\/nginx\/configure.nginx<\/code><\/p>\n<p>Tr\u01b0\u1edbc khi b\u1eaft \u0111\u1ea7u ch\u00fang ta c\u00f9ng t\u00ecm hi\u1ec3u s\u01a1 l\u01b0\u1ee3c v\u1ec1 HTTP\/2 v\u00e0 l\u1ee3i \u00edch khi n\u00e2ng c\u1ea5p.<\/p>\n<h2 id=\"HTTP\/2_l\u00e0_g\u00ec?\"><span id=\"HTTP2_la_gi\" class=\"ez-toc-section\"><\/span>HTTP\/2 l\u00e0 g\u00ec?<\/h2>\n<p>HTTP\/2 l\u00e0 giao th\u1ee9c m\u1edbi \u0111\u01b0\u1ee3c ph\u00e1t tri\u1ec3n \u0111\u1ec3 thay th\u1ebf HTTP\/1.x \u2013 hi\u1ec7n \u0111ang l\u00e0 m\u1eb7c \u0111\u1ecbnh c\u00e0i \u0111\u1eb7t tr\u00ean t\u1ea5t c\u1ea3 c\u00e1c webserver.\u00a0HTTP\/2 l\u00e0 phi\u00ean b\u1ea3n ho\u00e0n to\u00e0n m\u1edbi kh\u00f4ng ph\u1ea3i b\u1ea3n ch\u1ec9nh s\u1eeda c\u1ee7a HTTP\/1.x. N\u00f3 nhanh h\u01a1n, \u0111\u01a1n gi\u1ea3n h\u01a1n v\u00e0 m\u1ea1nh h\u01a1n HTTP\/1.x.<\/p>\n<h3 id=\"Khung_thi\u1ebft_k\u1ebf_c\u1ee7a_HTTP\/2\"><span id=\"Khung_thiet_ke_cua_HTTP2\" class=\"ez-toc-section\"><\/span>Khung thi\u1ebft k\u1ebf c\u1ee7a HTTP\/2<\/h3>\n<p>HTTP\/2 c\u00f3 b\u1ed9 khung nh\u1ecb ph\u00e2n ho\u00e0n to\u00e0n m\u1edbi v\u00e0 theo \u0111\u00f3 kh\u00f4ng \u00e1p d\u1ee5ng ng\u01b0\u1ee3c tr\u1edf l\u1ea1i cho HTTP\/1.x. Tuy nhi\u00ean\u00a0 HTTP\/2 v\u1eabn s\u1eed d\u1ee5ng c\u00e1c kh\u00e1i ni\u1ec7m v\u00e0 ng\u1eef ngh\u0129a m\u1ea5u ch\u1ed1t c\u1ee7a giao th\u1ee9c c\u0169 m\u00e0 ch\u1ec9 thay \u0111\u1ed5i c\u00e1c quy \u0111\u1ecbnh khu\u00f4n d\u1ea1ng d\u1eef li\u1ec7u truy\u1ec1n tr\u00ean giao th\u1ee9c ngo\u00e0i ra b\u1ed5 sung th\u00eam kh\u00e1i ni\u1ec7m \u201c<strong>quy\u1ec1n \u01b0u ti\u00ean<\/strong>\u201d v\u00e0 \u201c<strong>server push<\/strong>\u201c.<\/p>\n<p>Chi ti\u1ebft v\u1ec1 HTTP\/2 xin m\u1eddi xem t\u1ea1i \u0111\u00e2y:<\/p>\n<ul>\n<li><a href=\"https:\/\/http2.github.io\/\" target=\"_blank\" rel=\"noopener noreferrer nofollow\">https:\/\/http2.github.io\/<\/a><\/li>\n<li><a href=\"https:\/\/developers.google.com\/web\/fundamentals\/performance\/http2\/\" target=\"_blank\" rel=\"noopener noreferrer nofollow\">https:\/\/developers.google.com\/web\/fundamentals\/performance\/http2\/<\/a><\/li>\n<\/ul>\n<h3 id=\"\u01afu_\u0111i\u1ec3m_c\u1ee7a_HTTP\/2\"><span id=\"Uu_diem_cua_HTTP2\" class=\"ez-toc-section\"><\/span>\u01afu \u0111i\u1ec3m c\u1ee7a HTTP\/2<\/h3>\n<p>T\u0103ng hi\u1ec7u su\u1ea5t v\u1eadn h\u00e0nh c\u1ee7a giao th\u1ee9c th\u00f4ng qua Gi\u1ea3m \u0111\u1ed9 tr\u1ec5 khi ph\u1ea3n h\u1ed3i t\u1edbi ng\u01b0\u1eddi d\u00f9ng cu\u1ed1i (Clients) v\u00e0 S\u1eed d\u1ee5ng t\u00e0i nguy\u00ean m\u1ea1ng c\u1ee7a m\u00e1y ch\u1ee7 (Server Push).<\/p>\n<figure id=\"attachment_416\" class=\"wp-caption alignnone\" aria-describedby=\"caption-attachment-416\"><img decoding=\"async\" class=\"alignnone size-full wp-image-666\" src=\"https:\/\/static-1.jdc.vn\/photo\/help.jdc.vn\/wp-content\/uploads\/2020\/02\/http1-vs-http2-600x250-1.png.webp\" sizes=\"(max-width: 600px) 100vw, 600px\" srcset=\"https:\/\/static-1.jdc.vn\/photo\/help.jdc.vn\/wp-content\/uploads\/2020\/02\/http1-vs-http2-600x250-1.png.webp 600w, https:\/\/static-1.jdc.vn\/photo\/help.jdc.vn\/wp-content\/uploads\/2020\/02\/http1-vs-http2-600x250-1-300x125.png.webp 300w, https:\/\/static-1.jdc.vn\/photo\/help.jdc.vn\/wp-content\/uploads\/2020\/02\/http1-vs-http2-600x250-1-50x21.png.webp 50w, https:\/\/static-1.jdc.vn\/photo\/help.jdc.vn\/wp-content\/uploads\/2020\/02\/http1-vs-http2-600x250-1-320x133.png.webp 320w\" alt=\"http1-vs-http2\" width=\"600\" height=\"250\" title=\"\"><figcaption id=\"caption-attachment-416\" class=\"wp-caption-text\">http1-vs-http2<\/figcaption><\/figure>\n<h2 id=\"H\u01b0\u1edbng_d\u1eabn_n\u00e2ng_c\u1ea5p_HTTP\/2_tr\u00ean_Nginx_Webserver\"><span id=\"Huong_dan_nang_cap_HTTP2_tren_Nginx_Webserver\" class=\"ez-toc-section\"><\/span>H\u01b0\u1edbng d\u1eabn n\u00e2ng c\u1ea5p HTTP\/2 tr\u00ean Nginx Webserver<\/h2>\n<p>Trong b\u00e0i n\u00e0y TinoHost s\u1ebd l\u00e0m v\u00ed d\u1ee5 tr\u00ean trang https:\/\/test.TinoHost.vn<\/p>\n<h3 id=\"B\u01b0\u1edbc_1:_Ki\u1ec3m_tra_tr\u1ea1ng_th\u00e1i_c\u1ee7a_HTTP\/2\"><span id=\"Buoc_1_Kiem_tra_trang_thai_cua_HTTP2\" class=\"ez-toc-section\"><\/span>B\u01b0\u1edbc 1: Ki\u1ec3m tra tr\u1ea1ng th\u00e1i c\u1ee7a HTTP\/2<\/h3>\n<p>\u0110\u1ec3 ki\u1ec3m tra xem server \u0111\u00e3 \u0111\u01b0\u1ee3c n\u00e2ng c\u1ea5p HTTP\/2 hay ch\u01b0a ch\u00fang ta s\u1eed d\u1ee5ng c\u00f4ng c\u1ee5 tr\u1ef1c tuy\u1ebfn\u00a0<a href=\"https:\/\/http2.pro\/\" target=\"_blank\" rel=\"noopener noreferrer nofollow\">https:\/\/http2.pro<\/a><\/p>\n<figure id=\"attachment_417\" class=\"wp-caption alignnone\" aria-describedby=\"caption-attachment-417\"><img decoding=\"async\" width=\"1035\" height=\"709\" class=\"alignnone wp-image-7432 size-full\" src=\"https:\/\/tino.vn\/blog\/wp-content\/uploads\/2021\/03\/Pasted-into-Huong-dan-Nang-cap-HTTP2-tren-Nginx-Webserver-cua-DirectAdmin-1.png\" alt=\"\" title=\"\" srcset=\"https:\/\/tino.vn\/blog\/wp-content\/uploads\/2021\/03\/Pasted-into-Huong-dan-Nang-cap-HTTP2-tren-Nginx-Webserver-cua-DirectAdmin-1.png 1035w, https:\/\/tino.vn\/blog\/wp-content\/uploads\/2021\/03\/Pasted-into-Huong-dan-Nang-cap-HTTP2-tren-Nginx-Webserver-cua-DirectAdmin-1-300x206.png 300w, https:\/\/tino.vn\/blog\/wp-content\/uploads\/2021\/03\/Pasted-into-Huong-dan-Nang-cap-HTTP2-tren-Nginx-Webserver-cua-DirectAdmin-1-1024x701.png 1024w, https:\/\/tino.vn\/blog\/wp-content\/uploads\/2021\/03\/Pasted-into-Huong-dan-Nang-cap-HTTP2-tren-Nginx-Webserver-cua-DirectAdmin-1-768x526.png 768w\" sizes=\"(max-width: 1035px) 100vw, 1035px\" \/><figcaption id=\"caption-attachment-417\" class=\"wp-caption-text\">No HTTP\/2 support<\/figcaption><\/figure>\n<p>N\u1ebfu k\u1ebft qu\u1ea3 hi\u1ec7n ra nh\u01b0 h\u00ecnh tr\u00ean th\u00ec trang c\u1ee7a b\u1ea1n ch\u01b0a h\u1ed7 tr\u1ee3 HTTP\/2, b\u00e2y gi\u1edd ch\u00fang ta sang b\u01b0\u1edbc k\u1ebf ti\u1ebfp.<\/p>\n<h3 id=\"B\u01b0\u1edbc_2:_T\u1ea3i_th\u01b0_vi\u1ec7n_OpenSSL_1.0.2\"><span id=\"Buoc_2_Tai_thu_vien_OpenSSL_102\" class=\"ez-toc-section\"><\/span>B\u01b0\u1edbc 2: T\u1ea3i th\u01b0 vi\u1ec7n OpenSSL 1.0.2<\/h3>\n<p>HTTP\/2 b\u1eaft \u0111\u1ea7u \u0111\u01b0\u1ee3c h\u1ed7 tr\u1ee3 tr\u00ean 1.0.2, m\u00e0 th\u01b0 vi\u1ec7n c\u00e0i \u0111\u1eb7t c\u1ee7a DirectAdmin ph\u1ed5 bi\u1ebfn tr\u00ean phi\u00ean b\u1ea3n 1.50 l\u00e0 1.0.1e.<\/p>\n<p>L\u1ea7n l\u01b0\u1ee3t th\u1ef1c hi\u1ec7n ba l\u1ec7nh sau:<\/p>\n<p><code>cd \/usr\/local\/src\/<br \/>\nwget -O \/usr\/local\/src\/openssl-1.0.2g.tar.gz https:\/\/www.openssl.org\/source\/openssl-1.0.2g.tar.gz<br \/>\ntar -xvzf openssl-1.0.2g.tar.gzwget -O \/usr\/local\/src\/openssl-1.0.2g.tar.gz https:\/\/www.openssl.org\/source\/openssl-1.0.2g.tar.gz<\/code><\/p>\n<h3 id=\"B\u01b0\u1edbc_3:_T\u1ea1o_c\u1ea5u_h\u00ecnh_ri\u00eang_cho_Nginx\"><span id=\"Buoc_3_Tao_cau_hinh_rieng_cho_Nginx\" class=\"ez-toc-section\"><\/span>B\u01b0\u1edbc 3: T\u1ea1o c\u1ea5u h\u00ecnh ri\u00eang cho Nginx<\/h3>\n<p>M\u1ee5c \u0111\u00edch c\u1ee7a b\u01b0\u1edbc n\u00e0y l\u00e0 t\u1ea1o ra b\u1ed9 file c\u1ea5u h\u00ecnh ri\u00eang c\u1ee7a b\u1ea1n, kh\u00f4ng n\u00ean s\u1eeda tr\u1ef1c ti\u1ebfp v\u00e0o file m\u1eb7c \u0111\u1ecbnh c\u1ee7a DirectAdmin.<\/p>\n<p><strong>T\u1ea1o th\u01b0 m\u1ee5c l\u01b0u c\u1ea5u h\u00ecnh ri\u00eang<\/strong><\/p>\n<p><code>mkdir -p \/usr\/local\/directadmin\/custombuild\/custom\/nginx\/conf<br \/>\nmkdir -p \/usr\/local\/directadmin\/data\/templates\/custom\/<\/code><\/p>\n<p>Tham s\u1ed1\u00a0<strong>-p<\/strong>\u00a0c\u00f3 ngh\u0129a l\u00e0 t\u1ea1o th\u01b0 m\u1ee5c theo \u0111\u01b0\u1eddng d\u1eabn, vi\u1ec7c n\u00e0y s\u1ebd r\u00fat ng\u1eafn qu\u00e1 tr\u00ecnh t\u1ea1o th\u01b0 m\u1ee5c<\/p>\n<p><strong>Sao ch\u00e9p file c\u1ea5u h\u00ecnh Nginx<\/strong><\/p>\n<p>Sao ch\u00e9p 3 file c\u1ea5u h\u00ecnh c\u1ee7a Nginx l\u00e0 v\u00e0o th\u01b0 m\u1ee5c\u00a0<strong>custom<\/strong>\u00a0v\u1eeba t\u1ea1o<\/p>\n<ul>\n<li>nginx-vhosts.conf<\/li>\n<li>nginx_server_secure.conf<\/li>\n<li>nginx_server_secure_sub.conf<\/li>\n<\/ul>\n<p>Th\u1ef1c hi\u1ec7n l\u1ea7n l\u01b0\u1ee3t l\u1ec7nh copy file nh\u01b0 sau:<\/p>\n<p><code>cp \/usr\/local\/directadmin\/custombuild\/configure\/nginx\/conf\/nginx-vhosts.conf \/usr\/local\/directadmin\/custombuild\/custom\/nginx\/conf\/nginx-vhosts.conf<br \/>\ncp \/usr\/local\/directadmin\/data\/templates\/nginx_server_secure.conf \/usr\/local\/directadmin\/data\/templates\/custom\/nginx_server_secure.conf<br \/>\ncp \/usr\/local\/directadmin\/data\/templates\/nginx_server_secure_sub.conf \/usr\/local\/directadmin\/data\/templates\/custom\/nginx_server_secure_sub.conf<\/code><\/p>\n<p><strong>S\u1eeda file\u00a0nginx-vhosts.conf<\/strong><\/p>\n<p>b\u1eb1ng l\u1ec7nh<\/p>\n<p><code>nano \/usr\/local\/directadmin\/custombuild\/custom\/nginx\/conf\/nginx-vhosts.conf<\/code><\/p>\n<p>T\u00ecm d\u00f2ng<\/p>\n<p><code># HTTPS server<br \/>\nserver {<br \/>\nlisten |IP|:|PORT_443| ssl|SPACE_HTTP2|;<br \/>\nlisten 127.0.0.1:|PORT_443| ssl|SPACE_HTTP2|;<br \/>\nlisten [::1]:|PORT_443| ssl|SPACE_HTTP2|;<\/code><\/p>\n<p>\u0110\u1ed5i \u0111o\u1ea1n\u00a0<strong>ssl|SPACE_HTTP2|<\/strong>\u00a0th\u00e0nh\u00a0<strong>ssl http2<\/strong><\/p>\n<p>K\u1ebft qu\u1ea3 s\u1ebd nh\u01b0 sau:<\/p>\n<p><code>server {<br \/>\nlisten |IP|:|PORT_443| ssl http2;<br \/>\nlisten 127.0.0.1:|PORT_443| ssl http2;<br \/>\nlisten [::1]:|PORT_443| ssl http2;<\/code><\/p>\n<p>L\u01b0u l\u1ea1i s\u1eeda \u0111\u1ed5i: b\u1ea5m\u00a0<strong>Ctrl + O<\/strong><\/p>\n<p>Tho\u00e1t kh\u1ecfi so\u1ea1n th\u1ea3o: b\u1ea5m\u00a0<strong>Ctrl + X<\/strong><\/p>\n<p><strong>S\u1eeda file nginx_server_secure.conf<\/strong><\/p>\n<p>b\u1eb1ng l\u1ec7nh:<\/p>\n<p><code>nano \/usr\/local\/directadmin\/data\/templates\/custom\/nginx_server_secure.conf<\/code><\/p>\n<p>T\u00ecm d\u00f2ng:<\/p>\n<p><code>listen |IP|:|PORT_443| ssl;<\/code><\/p>\n<p>S\u1eeda th\u00e0nh:<\/p>\n<p><code>listen |IP|:|PORT_443| ssl http2;<\/code><\/p>\n<p>L\u01b0u l\u1ea1i s\u1eeda \u0111\u1ed5i: b\u1ea5m\u00a0<strong>Ctrl + O<\/strong><\/p>\n<p>Tho\u00e1t kh\u1ecfi so\u1ea1n th\u1ea3o: b\u1ea5m\u00a0<strong>Ctrl + X<\/strong><\/p>\n<p><strong>S\u1eeda file nginx_server_secure_sub.conf<\/strong><\/p>\n<p>b\u1eb1ng l\u1ec7nh:<\/p>\n<p><code>nano \/usr\/local\/directadmin\/data\/templates\/custom\/nginx_server_secure_sub.conf<\/code><\/p>\n<p>T\u00ecm d\u00f2ng:<\/p>\n<p><code>listen |IP|:|PORT_443| ssl;<\/code><\/p>\n<p>S\u1eeda th\u00e0nh:<\/p>\n<p><code>listen |IP|:|PORT_443| ssl http2;<\/code><\/p>\n<p>L\u01b0u l\u1ea1i s\u1eeda \u0111\u1ed5i: b\u1ea5m\u00a0<strong>Ctrl + O<\/strong><\/p>\n<p>Tho\u00e1t kh\u1ecfi so\u1ea1n th\u1ea3o: b\u1ea5m\u00a0<strong>Ctrl + X<\/strong><\/p>\n<h3 id=\"B\u01b0\u1edbc_4:_T\u1ea1o_c\u1ea5u_h\u00ecnh_bi\u00ean_d\u1ecbch_l\u1ea1i_Nginx\"><span id=\"Buoc_4_Tao_cau_hinh_bien_dich_lai_Nginx\" class=\"ez-toc-section\"><\/span>B\u01b0\u1edbc 4: T\u1ea1o c\u1ea5u h\u00ecnh bi\u00ean d\u1ecbch l\u1ea1i Nginx<\/h3>\n<p><strong>S\u1eeda file\u00a0configure.nginx<\/strong><\/p>\n<p>Tr\u01b0\u1edbc khi s\u1eeda file \u0111\u1ec3 \u0111\u1ea3m b\u1ea3o an to\u00e0n c\u1ea7n backup, th\u1ef1c hi\u1ec7n c\u00e1c l\u1ec7nh nh\u01b0 sau:<\/p>\n<p><code>cd \/usr\/local\/directadmin\/custombuild\/configure\/nginx_reverse\/<br \/>\ntar -czf configure.nginx.default.tar.gz configure.nginx<\/code><\/p>\n<p>Sau khi backup th\u00ec s\u1eeda file b\u1eb1ng l\u1ec7nh:<\/p>\n<p><code>nano \/usr\/local\/directadmin\/custombuild\/configure\/nginx_reverse\/configure.nginx<\/code><\/p>\n<p>T\u00ecm \u0111\u1ebfn \u0111o\u1ea1n quy \u0111\u1ecbnh http_v2_module nh\u01b0 sau:<\/p>\n<p><code>\"--with-http_v2_module\" \\<br \/>\n\"--with-cc-opt='-D FD_SETSIZE=32768'\"<\/code><br \/>\nTh\u00eam v\u00e0o gi\u1eefa 2 d\u00f2ng tr\u00ean \u0111o\u1ea1n \u0111\u01b0\u1eddng d\u1eabn ch\u01b0a m\u00e3 ngu\u1ed3n OpenSSL 1.0.2 \u0111\u00e3 t\u1ea3i \u1edf tr\u00ean:<\/p>\n<p><code>\"--with-openssl=\/usr\/local\/src\/openssl-1.0.2g\" \\<\/code><\/p>\n<p>K\u1ebft qu\u1ea3 tr\u00f4ng nh\u01b0 sau:<\/p>\n<p><code>\u201c\u2013with-http_v2_module\u201d \\<br \/>\n\u201c\u2013with-openssl=\/usr\/local\/src\/openssl-1.0.2g\u201d \\<br \/>\n\u201c\u2013with-cc-opt=\u2019-D FD_SETSIZE=32768\u2032\u201d<\/code><\/p>\n<p>L\u01b0u l\u1ea1i s\u1eeda \u0111\u1ed5i: b\u1ea5m\u00a0<strong>Ctrl + O<\/strong><\/p>\n<p>Tho\u00e1t kh\u1ecfi so\u1ea1n th\u1ea3o: b\u1ea5m\u00a0<strong>Ctrl + X<\/strong><\/p>\n<h3 id=\"B\u01b0\u1edbc_5:_Th\u1ef1c_hi\u1ec7n_Rebuild_l\u1ea1i_Nginx\"><span id=\"Buoc_5_Thuc_hien_Rebuild_lai_Nginx\" class=\"ez-toc-section\"><\/span><strong>B\u01b0\u1edbc 5: Th\u1ef1c hi\u1ec7n Rebuild l\u1ea1i Nginx<\/strong><\/h3>\n<p><strong>Ghi v\u00e0o Task queue<\/strong><\/p>\n<p><code>echo \"action=rewrite&amp;value=nginx\" &gt;&gt; \/usr\/local\/directadmin\/data\/task.queue<br \/>\n\/usr\/local\/directadmin\/dataskq d<\/code><\/p>\n<p><strong>Ch\u1ea1y Update \u0111\u1ec3 DiectAdmin build l\u1ea1i c\u1ea5u h\u00ecnh Nginx<\/strong><\/p>\n<p>Th\u1ef1c hi\u1ec7n l\u1ea7n l\u01b0\u1ee3t c\u00e1c l\u1ec7nh sau:<\/p>\n<p><code>cd \/usr\/local\/directadmin\/custombuild<br \/>\n.\/build nginx_apache<br \/>\n.\/build rewrite_confs<br \/>\nservice nginx restart<\/code><\/p>\n<p>Qu\u00e1 tr\u00ecnh c\u00e0i \u0111\u1eb7t m\u1ea5t v\u00e0i ph\u00fat, \u0111\u1ebfn khi Nginx kh\u1edfi \u0111\u1ed9ng l\u1ea1i th\u00e0nh c\u00f4ng th\u00ec h\u00e3y ki\u1ec3m tra l\u1ea1i b\u1eb1ng c\u00f4ng c\u1ee5\u00a0<a href=\"https:\/\/http2.pro\/\" target=\"_blank\" rel=\"noopener noreferrer nofollow\">https:\/\/http2.pro<\/a><\/p>\n<figure id=\"attachment_418\" class=\"wp-caption alignnone\" aria-describedby=\"caption-attachment-418\"><img decoding=\"async\" width=\"1080\" height=\"667\" class=\"alignnone wp-image-7433 size-full\" src=\"https:\/\/tino.vn\/blog\/wp-content\/uploads\/2021\/03\/Pasted-into-Huong-dan-Nang-cap-HTTP2-tren-Nginx-Webserver-cua-DirectAdmin-2.png\" alt=\"\" title=\"\" srcset=\"https:\/\/tino.vn\/blog\/wp-content\/uploads\/2021\/03\/Pasted-into-Huong-dan-Nang-cap-HTTP2-tren-Nginx-Webserver-cua-DirectAdmin-2.png 1080w, https:\/\/tino.vn\/blog\/wp-content\/uploads\/2021\/03\/Pasted-into-Huong-dan-Nang-cap-HTTP2-tren-Nginx-Webserver-cua-DirectAdmin-2-300x185.png 300w, https:\/\/tino.vn\/blog\/wp-content\/uploads\/2021\/03\/Pasted-into-Huong-dan-Nang-cap-HTTP2-tren-Nginx-Webserver-cua-DirectAdmin-2-1024x632.png 1024w, https:\/\/tino.vn\/blog\/wp-content\/uploads\/2021\/03\/Pasted-into-Huong-dan-Nang-cap-HTTP2-tren-Nginx-Webserver-cua-DirectAdmin-2-768x474.png 768w\" sizes=\"(max-width: 1080px) 100vw, 1080px\" \/><figcaption id=\"caption-attachment-418\" class=\"wp-caption-text\">HTTP\/2 supported!<\/figcaption><\/figure>\n<p>N\u1ebfu k\u1ebft qu\u1ea3 hi\u1ec7n ra nh\u01b0 tr\u00ean h\u00ecnh th\u00ec \u0111\u00e3 n\u00e2ng c\u1ea5p th\u00e0nh c\u00f4ng HTTP\/2<\/p>\n<\/div>\n<\/div>\n","protected":false},"excerpt":{"rendered":"<p>DirectAdmin l\u00e0 ph\u1ea7n m\u1ec1m qu\u1ea3n tr\u1ecb Hosting chuy\u00ean nghi\u1ec7p hi\u1ec7n \u0111ang \u0111\u01b0\u1ee3c s\u1eed d\u1ee5ng b\u1edfi nhi\u1ec1u kh\u00e1ch h\u00e0ng. M\u1eb7c \u0111\u1ecbnh DirectAdmin s\u1eed d\u1ee5ng giao th\u1ee9c HTTP\/1.1 trong c\u1ea5u h\u00ecnh c\u00e0i \u0111\u1eb7t (Custombuild 2.0). H\u01b0\u1edbng d\u1eabn n\u00e0y \u00e1p d\u1ee5ng cho tr\u01b0\u1eddng h\u1ee3p s\u1eed d\u1ee5ng 2 server l\u00e0 Apache v\u00e0 Nginx, trong \u0111\u00f3 Apache l\u00e0 Application server [&hellip;]<\/p>\n","protected":false},"author":4,"featured_media":16424,"menu_order":0,"comment_status":"open","ping_status":"closed","template":"","format":"standard","meta":{"footnotes":""},"tags":[],"ht_kb_category":[23],"class_list":["post-7430","ht_kb","type-ht_kb","status-publish","format-standard","has-post-thumbnail","hentry","ht_kb_category-control-panel-direct-admin"],"_links":{"self":[{"href":"https:\/\/tino.vn\/blog\/wp-json\/wp\/v2\/ht_kb\/7430","targetHints":{"allow":["GET"]}}],"collection":[{"href":"https:\/\/tino.vn\/blog\/wp-json\/wp\/v2\/ht_kb"}],"about":[{"href":"https:\/\/tino.vn\/blog\/wp-json\/wp\/v2\/types\/ht_kb"}],"author":[{"embeddable":true,"href":"https:\/\/tino.vn\/blog\/wp-json\/wp\/v2\/users\/4"}],"replies":[{"embeddable":true,"href":"https:\/\/tino.vn\/blog\/wp-json\/wp\/v2\/comments?post=7430"}],"version-history":[{"count":0,"href":"https:\/\/tino.vn\/blog\/wp-json\/wp\/v2\/ht_kb\/7430\/revisions"}],"wp:featuredmedia":[{"embeddable":true,"href":"https:\/\/tino.vn\/blog\/wp-json\/wp\/v2\/media\/16424"}],"wp:attachment":[{"href":"https:\/\/tino.vn\/blog\/wp-json\/wp\/v2\/media?parent=7430"}],"wp:term":[{"taxonomy":"post_tag","embeddable":true,"href":"https:\/\/tino.vn\/blog\/wp-json\/wp\/v2\/tags?post=7430"},{"taxonomy":"ht_kb_category","embeddable":true,"href":"https:\/\/tino.vn\/blog\/wp-json\/wp\/v2\/ht_kb_category?post=7430"}],"curies":[{"name":"wp","href":"https:\/\/api.w.org\/{rel}","templated":true}]}}