{"id":483455,"date":"2026-06-12T17:50:21","date_gmt":"2026-06-12T17:50:21","guid":{"rendered":"https:\/\/savepearlharbor.com\/?p=483455"},"modified":"-0001-11-30T00:00:00","modified_gmt":"-0001-11-29T21:00:00","slug":"","status":"publish","type":"post","link":"https:\/\/savepearlharbor.com\/?p=483455","title":{"rendered":"OpenWrt \u0432 Proxmox \u043a\u0430\u043a \u0434\u043e\u043c\u0430\u0448\u043d\u0438\u0439 \u0443\u043c\u043d\u044b\u0439 \u0448\u043b\u044e\u0437: DHCP, DNS, sing-box \u0438 \u0432\u044b\u0431\u043e\u0440\u043e\u0447\u043d\u044b\u0439 VPN \u0434\u043b\u044f \u0432\u0441\u0435\u0439 \u0441\u0435\u0442\u0438"},"content":{"rendered":"<div xmlns=\"http:\/\/www.w3.org\/1999\/xhtml\">\n<h2>\u0417\u0430\u0447\u0435\u043c \u044f \u0432\u043e\u043e\u0431\u0449\u0435 \u0432 \u044d\u0442\u043e \u043f\u043e\u043b\u0435\u0437<\/h2>\n<p>\u0412 \u043a\u0430\u043a\u043e\u0439-\u0442\u043e \u043c\u043e\u043c\u0435\u043d\u0442 \u044f \u043f\u043e\u0439\u043c\u0430\u043b \u0441\u0435\u0431\u044f \u043d\u0430 \u0441\u0442\u0440\u0430\u043d\u043d\u043e\u0439 \u043c\u044b\u0441\u043b\u0438: \u0434\u043e\u043c\u0430 \u0435\u0441\u0442\u044c \u0441\u0435\u0440\u0432\u0435\u0440 \u043f\u043e\u0434 Proxmox, \u043d\u043e\u0440\u043c\u0430\u043b\u044c\u043d\u0430\u044f \u043b\u043e\u043a\u0430\u043b\u044c\u043d\u0430\u044f \u0441\u0435\u0442\u044c, \u043d\u0435\u0441\u043a\u043e\u043b\u044c\u043a\u043e \u043f\u043e\u0441\u0442\u043e\u044f\u043d\u043d\u044b\u0445 \u0443\u0441\u0442\u0440\u043e\u0439\u0441\u0442\u0432, \u0430 VPN \u0432\u0441\u0435 \u0440\u0430\u0432\u043d\u043e \u0436\u0438\u0432\u0435\u0442 \u043d\u0430 \u043a\u0430\u0436\u0434\u043e\u043c \u043a\u043b\u0438\u0435\u043d\u0442\u0435 \u043e\u0442\u0434\u0435\u043b\u044c\u043d\u043e. \u041d\u0430 \u043d\u043e\u0443\u0442\u0431\u0443\u043a\u0435 \u043e\u0434\u0438\u043d \u043a\u043b\u0438\u0435\u043d\u0442, \u043d\u0430 \u0442\u0435\u043b\u0435\u0444\u043e\u043d\u0435 \u0434\u0440\u0443\u0433\u043e\u0439, \u043d\u0430 \u0440\u0430\u0431\u043e\u0447\u0435\u0439 \u043c\u0430\u0448\u0438\u043d\u0435 \u043b\u0443\u0447\u0448\u0435 \u0432\u043e\u043e\u0431\u0449\u0435 \u043d\u0438\u0447\u0435\u0433\u043e \u043b\u0438\u0448\u043d\u0435\u0433\u043e \u043d\u0435 \u0442\u0440\u043e\u0433\u0430\u0442\u044c, \u043d\u0430 \u0442\u0435\u043b\u0435\u0432\u0438\u0437\u043e\u0440\u0435 \u043f\u043e\u0441\u0442\u0430\u0432\u0438\u0442\u044c \u043d\u043e\u0440\u043c\u0430\u043b\u044c\u043d\u044b\u0439 \u043a\u043b\u0438\u0435\u043d\u0442 \u043f\u043e\u0447\u0442\u0438 \u043d\u0435\u0432\u043e\u0437\u043c\u043e\u0436\u043d\u043e.<\/p>\n<p>\u0421\u043d\u0430\u0447\u0430\u043b\u0430 \u044d\u0442\u043e \u043d\u0435 \u0432\u044b\u0433\u043b\u044f\u0434\u0438\u0442 \u043f\u0440\u043e\u0431\u043b\u0435\u043c\u043e\u0439. \u041d\u0443 \u043f\u043e\u0441\u0442\u0430\u0432\u0438\u043b VPN \u043d\u0430 \u043d\u043e\u0443\u0442\u0431\u0443\u043a. \u041f\u043e\u0442\u043e\u043c \u043d\u0430 \u0442\u0435\u043b\u0435\u0444\u043e\u043d. \u041f\u043e\u0442\u043e\u043c \u0435\u0449\u0435 \u0440\u0430\u0437 \u043d\u0430 \u0432\u0442\u043e\u0440\u043e\u0439 \u043d\u043e\u0443\u0442\u0431\u0443\u043a. \u041d\u043e \u0434\u0430\u043b\u044c\u0448\u0435 \u043d\u0430\u0447\u0438\u043d\u0430\u0435\u0442\u0441\u044f \u043e\u0431\u044b\u0447\u043d\u044b\u0439 \u0431\u044b\u0442\u043e\u0432\u043e\u0439 \u0445\u0430\u043e\u0441: \u0433\u0434\u0435-\u0442\u043e VPN \u0437\u0430\u0431\u044b\u043b\u0438 \u0432\u043a\u043b\u044e\u0447\u0438\u0442\u044c, \u0433\u0434\u0435-\u0442\u043e \u043e\u043d \u043c\u0435\u0448\u0430\u0435\u0442 \u043b\u043e\u043a\u0430\u043b\u043a\u0435, \u0433\u0434\u0435-\u0442\u043e \u043b\u043e\u043c\u0430\u0435\u0442 \u0431\u0430\u043d\u043a\u043e\u0432\u0441\u043a\u043e\u0435 \u043f\u0440\u0438\u043b\u043e\u0436\u0435\u043d\u0438\u0435, \u0433\u0434\u0435-\u0442\u043e \u0442\u044f\u043d\u0435\u0442 \u0432\u0435\u0441\u044c \u0442\u0440\u0430\u0444\u0438\u043a \u0447\u0435\u0440\u0435\u0437 \u0443\u0434\u0430\u043b\u0435\u043d\u043d\u044b\u0439 \u0441\u0435\u0440\u0432\u0435\u0440 \u0431\u0435\u0437 \u043d\u0435\u043e\u0431\u0445\u043e\u0434\u0438\u043c\u043e\u0441\u0442\u0438.<\/p>\n<p>\u041e\u0442\u0434\u0435\u043b\u044c\u043d\u0430\u044f \u0431\u043e\u043b\u044c: \u0443\u0441\u0442\u0440\u043e\u0439\u0441\u0442\u0432\u0430, \u043d\u0430 \u043a\u043e\u0442\u043e\u0440\u044b\u0435 VPN-\u043a\u043b\u0438\u0435\u043d\u0442 \u043d\u043e\u0440\u043c\u0430\u043b\u044c\u043d\u043e \u043d\u0435 \u043f\u043e\u0441\u0442\u0430\u0432\u0438\u0442\u044c. \u0422\u0435\u043b\u0435\u0432\u0438\u0437\u043e\u0440\u044b, \u043f\u0440\u0438\u0441\u0442\u0430\u0432\u043a\u0438, \u0443\u043c\u043d\u044b\u0435 \u043a\u043e\u043b\u043e\u043d\u043a\u0438, IoT, \u0433\u043e\u0441\u0442\u0435\u0432\u044b\u0435 \u0442\u0435\u043b\u0435\u0444\u043e\u043d\u044b. \u0414\u0430 \u0438 \u043e\u0431\u044a\u044f\u0441\u043d\u044f\u0442\u044c \u043a\u0430\u0436\u0434\u043e\u043c\u0443 \u0434\u043e\u043c\u0430\u0448\u043d\u0435\u043c\u0443 \u043f\u043e\u043b\u044c\u0437\u043e\u0432\u0430\u0442\u0435\u043b\u044e, \u043a\u043e\u0433\u0434\u0430 \u0432\u043a\u043b\u044e\u0447\u0430\u0442\u044c VPN, \u0430 \u043a\u043e\u0433\u0434\u0430 \u0432\u044b\u043a\u043b\u044e\u0447\u0430\u0442\u044c, \u0442\u043e\u0436\u0435 \u043d\u0435 \u0445\u043e\u0447\u0435\u0442\u0441\u044f.<\/p>\n<p>\u0422\u0430\u043a \u043f\u043e\u044f\u0432\u0438\u043b\u0430\u0441\u044c \u0438\u0434\u0435\u044f \u0432\u044b\u043d\u0435\u0441\u0442\u0438 \u043b\u043e\u0433\u0438\u043a\u0443 \u043d\u0430 \u0448\u043b\u044e\u0437. \u041f\u0443\u0441\u0442\u044c \u043a\u043b\u0438\u0435\u043d\u0442 \u043f\u0440\u043e\u0441\u0442\u043e \u043f\u043e\u0434\u043a\u043b\u044e\u0447\u0430\u0435\u0442\u0441\u044f \u043a Wi-Fi \u0438\u043b\u0438 \u043a\u0430\u0431\u0435\u043b\u044e \u0438 \u043f\u043e\u043b\u0443\u0447\u0430\u0435\u0442 \u0438\u043d\u0442\u0435\u0440\u043d\u0435\u0442. \u0410 \u0434\u0430\u043b\u044c\u0448\u0435 \u0443\u0436\u0435 \u0434\u043e\u043c\u0430\u0448\u043d\u0438\u0439 \u0448\u043b\u044e\u0437 \u0441\u0430\u043c \u0440\u0435\u0448\u0430\u0435\u0442, \u0447\u0442\u043e \u043e\u0442\u043f\u0440\u0430\u0432\u0438\u0442\u044c \u043d\u0430\u043f\u0440\u044f\u043c\u0443\u044e, \u0430 \u0447\u0442\u043e \u0437\u0430\u0432\u0435\u0440\u043d\u0443\u0442\u044c \u0447\u0435\u0440\u0435\u0437 \u0442\u0443\u043d\u043d\u0435\u043b\u044c.<\/p>\n<p>\u0413\u043b\u0430\u0432\u043d\u0430\u044f \u0446\u0435\u043b\u044c \u0431\u044b\u043b\u0430 \u043d\u0435 \u0441\u0434\u0435\u043b\u0430\u0442\u044c \u201c\u0432\u0435\u0441\u044c \u0438\u043d\u0442\u0435\u0440\u043d\u0435\u0442 \u0447\u0435\u0440\u0435\u0437 VPN\u201d. \u041d\u0430\u043e\u0431\u043e\u0440\u043e\u0442, \u0445\u043e\u0442\u0435\u043b\u043e\u0441\u044c \u043d\u043e\u0440\u043c\u0430\u043b\u044c\u043d\u044b\u0439 split routing \u043d\u0430 \u0443\u0440\u043e\u0432\u043d\u0435 \u0441\u0435\u0442\u0438. \u041e\u0431\u044b\u0447\u043d\u044b\u0435 \u0441\u0430\u0439\u0442\u044b, \u043e\u0431\u043d\u043e\u0432\u043b\u0435\u043d\u0438\u044f, \u043b\u043e\u043a\u0430\u043b\u044c\u043d\u044b\u0435 \u0441\u0435\u0440\u0432\u0438\u0441\u044b \u0438 \u0442\u044f\u0436\u0435\u043b\u044b\u0435 \u0437\u0430\u0433\u0440\u0443\u0437\u043a\u0438 \u043f\u0443\u0441\u0442\u044c \u0438\u0434\u0443\u0442 \u043d\u0430\u043f\u0440\u044f\u043c\u0443\u044e. \u0427\u0435\u0440\u0435\u0437 \u0442\u0443\u043d\u043d\u0435\u043b\u044c \u043d\u0443\u0436\u043d\u044b \u0442\u043e\u043b\u044c\u043a\u043e \u043a\u043e\u043d\u043a\u0440\u0435\u0442\u043d\u044b\u0435 \u0434\u043e\u043c\u0435\u043d\u044b \u0438 IP: YouTube, Telegram, WhatsApp, Discord, OpenAI \u0438 \u043f\u043e\u0445\u043e\u0436\u0438\u0435 \u0441\u0435\u0440\u0432\u0438\u0441\u044b.<\/p>\n<h2>\u0427\u0442\u043e \u0432 \u0438\u0442\u043e\u0433\u0435 \u0441\u043e\u0431\u0438\u0440\u0430\u0435\u043c<\/h2>\n<p>\u0412 \u0444\u0438\u043d\u0430\u043b\u0435 \u0441\u0445\u0435\u043c\u0430 \u0432\u044b\u0433\u043b\u044f\u0434\u0438\u0442 \u0442\u0430\u043a: OpenWrt \u0437\u0430\u043f\u0443\u0449\u0435\u043d \u0432\u0438\u0440\u0442\u0443\u0430\u043b\u044c\u043d\u043e\u0439 \u043c\u0430\u0448\u0438\u043d\u043e\u0439 \u0432 Proxmox, \u0440\u0430\u0437\u0434\u0430\u0435\u0442 DHCP, \u043e\u0431\u0441\u043b\u0443\u0436\u0438\u0432\u0430\u0435\u0442 DNS \u0438 \u0441\u0442\u0430\u043d\u043e\u0432\u0438\u0442\u0441\u044f \u043e\u0441\u043d\u043e\u0432\u043d\u044b\u043c gateway \u0434\u043b\u044f \u043a\u043b\u0438\u0435\u043d\u0442\u043e\u0432. TCP-\u0442\u0440\u0430\u0444\u0438\u043a \u043a\u043b\u0438\u0435\u043d\u0442\u043e\u0432 \u0447\u0435\u0440\u0435\u0437 nftables \u043f\u0435\u0440\u0435\u043d\u0430\u043f\u0440\u0430\u0432\u043b\u044f\u0435\u0442\u0441\u044f \u043d\u0430 \u043b\u043e\u043a\u0430\u043b\u044c\u043d\u044b\u0439 \u043f\u043e\u0440\u0442 sing-box. \u0410 sing-box \u0443\u0436\u0435 \u0440\u0435\u0448\u0430\u0435\u0442, \u043a\u0443\u0434\u0430 \u043e\u0442\u043f\u0440\u0430\u0432\u0438\u0442\u044c \u0441\u043e\u0435\u0434\u0438\u043d\u0435\u043d\u0438\u0435: direct \u0438\u043b\u0438 \u0447\u0435\u0440\u0435\u0437 Xray\/VLESS Reality \u0438\u0437 Amnezia.<\/p>\n<figure class=\"\"><img decoding=\"async\" src=\"https:\/\/habrastorage.org\/r\/w1560\/webt\/fc\/68\/fc\/fc68fc74ea2bb62b63aa353e21f8e851.png\" sizes=\"(max-width: 780px) 100vw, 50vw\" srcset=\"https:\/\/habrastorage.org\/r\/w780\/webt\/fc\/68\/fc\/fc68fc74ea2bb62b63aa353e21f8e851.png 780w,&#10;       https:\/\/habrastorage.org\/r\/w1560\/webt\/fc\/68\/fc\/fc68fc74ea2bb62b63aa353e21f8e851.png 781w\" loading=\"lazy\" decode=\"async\"\/><\/figure>\n<p><em>\u0420\u0438\u0441\u0443\u043d\u043e\u043a 1. \u0418\u0441\u0445\u043e\u0434\u043d\u0430\u044f \u0441\u0445\u0435\u043c\u0430: OpenWrt \u0437\u0430\u043f\u0443\u0449\u0435\u043d \u0432 Proxmox \u0438 \u043d\u0430\u0445\u043e\u0434\u0438\u0442\u0441\u044f \u0432 \u0442\u043e\u0439 \u0436\u0435 \u043f\u043e\u0434\u0441\u0435\u0442\u0438, \u0447\u0442\u043e \u0438 \u043a\u043b\u0438\u0435\u043d\u0442\u044b.<\/em> <\/p>\n<p>\u0421\u0430\u043c\u044b\u0439 \u0432\u0430\u0436\u043d\u044b\u0439 \u043c\u043e\u043c\u0435\u043d\u0442: OpenWrt \u043d\u0430\u0445\u043e\u0434\u0438\u0442\u0441\u044f \u0432 \u0442\u043e\u0439 \u0436\u0435 \u043f\u043e\u0434\u0441\u0435\u0442\u0438, \u0447\u0442\u043e \u0438 \u043a\u043b\u0438\u0435\u043d\u0442\u044b. \u042d\u0442\u043e \u043d\u0435 \u043a\u043b\u0430\u0441\u0441\u0438\u0447\u0435\u0441\u043a\u0430\u044f \u0441\u0445\u0435\u043c\u0430 \u0441 \u043e\u0442\u0434\u0435\u043b\u044c\u043d\u044b\u043c LAN \u0438 \u043e\u0442\u0434\u0435\u043b\u044c\u043d\u044b\u043c WAN. \u041a\u043b\u0438\u0435\u043d\u0442 \u043f\u043e\u043b\u0443\u0447\u0430\u0435\u0442 gateway 192.168.0.2, \u0441\u0430\u043c OpenWrt \u0434\u0430\u043b\u044c\u0448\u0435 \u043e\u0442\u043f\u0440\u0430\u0432\u043b\u044f\u0435\u0442 \u043e\u0431\u044b\u0447\u043d\u044b\u0439 \u0442\u0440\u0430\u0444\u0438\u043a \u043d\u0430 \u043e\u0441\u043d\u043e\u0432\u043d\u043e\u0439 \u0440\u043e\u0443\u0442\u0435\u0440 192.168.0.1.<\/p>\n<p>\u0418\u0437-\u0437\u0430 \u044d\u0442\u043e\u0433\u043e \u043d\u0435\u043a\u043e\u0442\u043e\u0440\u044b\u0435 \u0441\u0442\u0430\u043d\u0434\u0430\u0440\u0442\u043d\u044b\u0435 \u043a\u0440\u0430\u0441\u0438\u0432\u044b\u0435 \u0432\u0430\u0440\u0438\u0430\u043d\u0442\u044b, \u043d\u0430\u043f\u0440\u0438\u043c\u0435\u0440 TUN \u0441 auto_route \u0438 auto_redirect, \u043f\u043e\u0432\u0435\u043b\u0438 \u0441\u0435\u0431\u044f \u043d\u0435 \u0442\u0430\u043a, \u043a\u0430\u043a \u0445\u043e\u0442\u0435\u043b\u043e\u0441\u044c. \u041e\u043d\u0438 \u0445\u043e\u0440\u043e\u0448\u043e \u0441\u043c\u043e\u0442\u0440\u044f\u0442\u0441\u044f \u0432 \u043f\u0440\u0438\u043c\u0435\u0440\u0430\u0445, \u043d\u043e \u0432 \u043c\u043e\u0435\u0439 \u0441\u0445\u0435\u043c\u0435 \u043d\u0430\u0447\u0430\u043b\u0438 \u043b\u043e\u0432\u0438\u0442\u044c \u0442\u0440\u0430\u0444\u0438\u043a \u0441\u0430\u043c\u043e\u0433\u043e OpenWrt \u0438 \u043b\u043e\u043c\u0430\u0442\u044c DNS.<\/p>\n<h3>\u041f\u043b\u0430\u043d \u0430\u0434\u0440\u0435\u0441\u0430\u0446\u0438\u0438<\/h3>\n<p>\u0427\u0442\u043e\u0431\u044b \u0434\u0430\u043b\u044c\u0448\u0435 \u043a\u043e\u043c\u0430\u043d\u0434\u044b \u0447\u0438\u0442\u0430\u043b\u0438\u0441\u044c \u043d\u043e\u0440\u043c\u0430\u043b\u044c\u043d\u043e, \u0437\u0430\u0444\u0438\u043a\u0441\u0438\u0440\u0443\u0435\u043c \u0443\u0441\u043b\u043e\u0432\u043d\u044b\u0435 \u0430\u0434\u0440\u0435\u0441\u0430. \u0415\u0441\u043b\u0438 \u0443 \u0432\u0430\u0441 \u0434\u0440\u0443\u0433\u0430\u044f \u0441\u0435\u0442\u044c, \u043c\u0435\u043d\u044f\u0439\u0442\u0435 \u0438\u0445 \u043f\u043e\u0434 \u0441\u0435\u0431\u044f.<\/p>\n<pre><code class=\"bash\">\u041e\u0441\u043d\u043e\u0432\u043d\u0430\u044f \u0441\u0435\u0442\u044c:        192.168.0.0\/24\u041e\u0441\u043d\u043e\u0432\u043d\u043e\u0439 \u0440\u043e\u0443\u0442\u0435\u0440:      192.168.0.1OpenWrt VM:           192.168.0.2DHCP-\u0434\u0438\u0430\u043f\u0430\u0437\u043e\u043d:        192.168.0.100-192.168.0.199\u0422\u0435\u0441\u0442\u043e\u0432\u0430\u044f LAN OpenWrt: 192.168.50.0\/24OpenWrt LAN IP:       192.168.50.1sing-box redirect:    7892\/tcpXray\/VLESS server:    &lt;XRAY_SERVER_IP&gt;:443<\/code><div class=\"code-explainer\"><a href=\"https:\/\/sourcecraft.dev\/\" class=\"tm-button code-explainer__link\" style=\"visibility: hidden;\"><img style=\"width:87px;height:14px;object-fit:cover;object-position:left;\"\/><\/a><\/div><\/pre>\n<h3>\u0427\u0442\u043e \u043f\u043e\u043d\u0430\u0434\u043e\u0431\u0438\u0442\u0441\u044f<\/h3>\n<ul>\n<li>\n<p>\u0441\u0435\u0440\u0432\u0435\u0440 \u0441 Proxmox, \u043a\u043e\u0442\u043e\u0440\u044b\u0439 \u043f\u043e\u0441\u0442\u043e\u044f\u043d\u043d\u043e \u0432\u043a\u043b\u044e\u0447\u0435\u043d;<\/p>\n<\/li>\n<li>\n<p>\u0432\u0438\u0440\u0442\u0443\u0430\u043b\u044c\u043d\u0430\u044f \u043c\u0430\u0448\u0438\u043d\u0430 OpenWrt x86_64;<\/p>\n<\/li>\n<li>\n<p>\u0434\u043e\u0441\u0442\u0443\u043f \u043a \u043a\u043e\u043d\u0441\u043e\u043b\u0438 OpenWrt \u0447\u0435\u0440\u0435\u0437 Proxmox, \u0447\u0442\u043e\u0431\u044b \u043d\u0435 \u043f\u043e\u0442\u0435\u0440\u044f\u0442\u044c\u0441\u044f \u043f\u0440\u0438 \u043e\u0448\u0438\u0431\u043a\u0430\u0445 \u0441 \u0441\u0435\u0442\u044c\u044e;<\/p>\n<\/li>\n<li>\n<p>\u043e\u0441\u043d\u043e\u0432\u043d\u043e\u0439 \u0440\u043e\u0443\u0442\u0435\u0440 192.168.0.1;<\/p>\n<\/li>\n<li>\n<p>\u0432\u043e\u0437\u043c\u043e\u0436\u043d\u043e\u0441\u0442\u044c \u0432\u044b\u043a\u043b\u044e\u0447\u0438\u0442\u044c DHCP \u043d\u0430 \u043e\u0441\u043d\u043e\u0432\u043d\u043e\u043c \u0440\u043e\u0443\u0442\u0435\u0440\u0435;<\/p>\n<\/li>\n<li>\n<p>\u0433\u043e\u0442\u043e\u0432\u044b\u0439 \u0440\u0430\u0431\u043e\u0447\u0438\u0439 \u043a\u043e\u043d\u0444\u0438\u0433 Xray\/VLESS Reality, \u043d\u0430\u043f\u0440\u0438\u043c\u0435\u0440 \u044d\u043a\u0441\u043f\u043e\u0440\u0442\u0438\u0440\u043e\u0432\u0430\u043d\u043d\u044b\u0439 \u0438\u0437 Amnezia;<\/p>\n<\/li>\n<li>\n<p>\u043d\u0435\u043c\u043d\u043e\u0433\u043e \u0442\u0435\u0440\u043f\u0435\u043d\u0438\u044f, \u043f\u043e\u0442\u043e\u043c\u0443 \u0447\u0442\u043e \u0441\u0435\u0442\u044c \u043b\u043e\u043c\u0430\u0435\u0442\u0441\u044f \u0431\u044b\u0441\u0442\u0440\u043e, \u0430 \u0447\u0438\u043d\u0438\u0442\u0441\u044f \u0432\u043d\u0438\u043c\u0430\u0442\u0435\u043b\u044c\u043d\u043e\u0439 \u043f\u0440\u043e\u0432\u0435\u0440\u043a\u043e\u0439 \u043f\u043e \u0441\u043b\u043e\u044f\u043c.<\/p>\n<\/li>\n<\/ul>\n<blockquote>\n<p><strong>\u0412\u0430\u0436\u043d\u043e:<\/strong> \u041f\u0435\u0440\u0435\u0434 \u0438\u0437\u043c\u0435\u043d\u0435\u043d\u0438\u044f\u043c\u0438 \u043b\u0443\u0447\u0448\u0435 \u0441\u0434\u0435\u043b\u0430\u0442\u044c snapshot VM \u0432 Proxmox. \u0415\u0441\u043b\u0438 \u0441\u043b\u043e\u043c\u0430\u0435\u0442\u0441\u044f DHCP, firewall \u0438\u043b\u0438 \u043c\u0430\u0440\u0448\u0440\u0443\u0442\u044b, \u043e\u0442\u043a\u0430\u0442 snapshot \u044d\u043a\u043e\u043d\u043e\u043c\u0438\u0442 \u043c\u043d\u043e\u0433\u043e \u043d\u0435\u0440\u0432\u043e\u0432.<\/p>\n<\/blockquote>\n<h2>\u0428\u0430\u0433 1. \u0421\u043a\u0430\u0447\u0430\u0442\u044c \u043e\u0431\u0440\u0430\u0437 OpenWrt \u0438 \u043f\u043e\u0434\u0433\u043e\u0442\u043e\u0432\u0438\u0442\u044c VM \u0432 Proxmox<\/h2>\n<p>\u0412\u043e\u0442 \u044d\u0442\u043e\u0433\u043e \u0434\u0435\u0439\u0441\u0442\u0432\u0438\u0442\u0435\u043b\u044c\u043d\u043e \u0447\u0430\u0441\u0442\u043e \u043d\u0435 \u0445\u0432\u0430\u0442\u0430\u0435\u0442 \u0432 \u0438\u043d\u0441\u0442\u0440\u0443\u043a\u0446\u0438\u044f\u0445. \u041e\u0431\u044b\u0447\u043d\u043e \u043f\u0438\u0448\u0443\u0442 \u201c\u0441\u043e\u0437\u0434\u0430\u0439\u0442\u0435 VM \u0441 OpenWrt\u201d, \u0430 \u0434\u0430\u043b\u044c\u0448\u0435 \u043a\u0430\u0436\u0434\u044b\u0439 \u0441\u0430\u043c \u0434\u043e\u0433\u0430\u0434\u044b\u0432\u0430\u0435\u0442\u0441\u044f, \u043a\u0430\u043a\u043e\u0439 \u043e\u0431\u0440\u0430\u0437 \u0431\u0440\u0430\u0442\u044c, \u043a\u0443\u0434\u0430 \u0435\u0433\u043e \u043a\u043b\u0430\u0441\u0442\u044c \u0438 \u043a\u0430\u043a \u0438\u043c\u043f\u043e\u0440\u0442\u0438\u0440\u043e\u0432\u0430\u0442\u044c \u0434\u0438\u0441\u043a \u0432 Proxmox. \u041f\u043e\u044d\u0442\u043e\u043c\u0443 \u0440\u0430\u0441\u043f\u0438\u0448\u0443 \u044d\u0442\u043e\u0442 \u043a\u0443\u0441\u043e\u043a \u043e\u0442\u0434\u0435\u043b\u044c\u043d\u043e.<\/p>\n<p>\u0414\u043b\u044f Proxmox \u0443\u0434\u043e\u0431\u043d\u0435\u0435 \u0431\u0440\u0430\u0442\u044c x86_64 \u043e\u0431\u0440\u0430\u0437 OpenWrt. \u042f \u0431\u044b \u043d\u0430\u0447\u0438\u043d\u0430\u043b \u0441 ext4 combined EFI \u043e\u0431\u0440\u0430\u0437\u0430. Ext4 \u043f\u0440\u043e\u0449\u0435 \u0440\u0430\u0441\u0448\u0438\u0440\u044f\u0442\u044c \u0438 \u0447\u0438\u043d\u0438\u0442\u044c, \u0430 EFI \u043e\u0431\u044b\u0447\u043d\u043e \u0441\u043f\u043e\u043a\u043e\u0439\u043d\u0435\u0435 \u0433\u0440\u0443\u0437\u0438\u0442\u0441\u044f \u0432 \u043d\u043e\u0432\u044b\u0445 \u0432\u0438\u0440\u0442\u0443\u0430\u043b\u044c\u043d\u044b\u0445 \u043e\u043a\u0440\u0443\u0436\u0435\u043d\u0438\u044f\u0445. \u0415\u0441\u043b\u0438 \u0443 \u0432\u0430\u0441 \u0441\u0442\u0430\u0440\u0430\u044f \u0441\u0445\u0435\u043c\u0430 BIOS\/SeaBIOS, \u043c\u043e\u0436\u043d\u043e \u0432\u0437\u044f\u0442\u044c \u043e\u0431\u044b\u0447\u043d\u044b\u0439 combined \u043e\u0431\u0440\u0430\u0437 \u0431\u0435\u0437 EFI.<\/p>\n<blockquote>\n<p><strong>\u0412\u0430\u0436\u043d\u043e:<\/strong> \u041d\u043e\u043c\u0435\u0440 \u0432\u0435\u0440\u0441\u0438\u0438 \u0432 \u043a\u043e\u043c\u0430\u043d\u0434\u0430\u0445 \u043d\u0438\u0436\u0435 \u043b\u0443\u0447\u0448\u0435 \u0437\u0430\u043c\u0435\u043d\u0438\u0442\u044c \u043d\u0430 \u0430\u043a\u0442\u0443\u0430\u043b\u044c\u043d\u044b\u0439. \u0412 \u0441\u0442\u0430\u0442\u044c\u0435 \u044f \u043e\u0441\u0442\u0430\u0432\u043b\u044f\u044e \u043f\u0435\u0440\u0435\u043c\u0435\u043d\u043d\u0443\u044e OPENWRT_VERSION, \u0447\u0442\u043e\u0431\u044b \u043d\u0435 \u043f\u0440\u0438\u0432\u044f\u0437\u044b\u0432\u0430\u0442\u044c \u0438\u043d\u0441\u0442\u0440\u0443\u043a\u0446\u0438\u044e \u043a \u043a\u043e\u043d\u043a\u0440\u0435\u0442\u043d\u043e\u043c\u0443 \u0440\u0435\u043b\u0438\u0437\u0443.<\/p>\n<\/blockquote>\n<h3>1.1. \u0421\u043a\u0430\u0447\u0430\u0442\u044c \u043e\u0431\u0440\u0430\u0437 \u043d\u0430 Proxmox-\u0445\u043e\u0441\u0442\u0435<\/h3>\n<p>\u041a\u043e\u043c\u0430\u043d\u0434\u044b \u043d\u0438\u0436\u0435 \u0432\u044b\u043f\u043e\u043b\u043d\u044f\u044e\u0442\u0441\u044f \u0438\u043c\u0435\u043d\u043d\u043e \u043d\u0430 Proxmox, \u0442\u043e \u0435\u0441\u0442\u044c \u0432 \u043a\u043e\u043d\u0441\u043e\u043b\u0438 \u0432\u0438\u0434\u0430 root@pve, \u0430 \u043d\u0435 \u0432\u043d\u0443\u0442\u0440\u0438 OpenWrt. \u042d\u0442\u043e \u0432\u0430\u0436\u043d\u044b\u0439 \u043c\u043e\u043c\u0435\u043d\u0442. \u041d\u0430 Proxmox \u043d\u0435\u0442 uci \u0438 \u043d\u0435\u0442 \/etc\/config\/firewall, \u0437\u0430\u0442\u043e \u0438\u043c\u0435\u043d\u043d\u043e \u0442\u0430\u043c \u043c\u044b \u0441\u043e\u0437\u0434\u0430\u0435\u043c VM \u0438 \u0438\u043c\u043f\u043e\u0440\u0442\u0438\u0440\u0443\u0435\u043c \u0434\u0438\u0441\u043a.<\/p>\n<pre><code class=\"bash\">mkdir -p \/var\/lib\/vz\/template\/openwrtcd \/var\/lib\/vz\/template\/openwrtOPENWRT_VERSION=\"24.10.7\"OPENWRT_TARGET=\"x86\/64\"OPENWRT_BASE_URL=\"https:\/\/downloads.openwrt.org\/releases\/${OPENWRT_VERSION}\/targets\/${OPENWRT_TARGET}\"wget \"${OPENWRT_BASE_URL}\/openwrt-${OPENWRT_VERSION}-x86-64-generic-ext4-combined-efi.img.gz\"wget \"${OPENWRT_BASE_URL}\/sha256sums\"<\/code><div class=\"code-explainer\"><a href=\"https:\/\/sourcecraft.dev\/\" class=\"tm-button code-explainer__link\" style=\"visibility: hidden;\"><img style=\"width:14px;height:14px;object-fit:cover;object-position:left;\"\/><\/a><\/div><\/pre>\n<p>\u0415\u0441\u043b\u0438 \u043d\u0443\u0436\u043d\u043e\u0439 \u0432\u0435\u0440\u0441\u0438\u0438 \u0443\u0436\u0435 \u043d\u0435\u0442 \u0438\u043b\u0438 \u0432\u044b\u0448\u043b\u0430 \u043d\u043e\u0432\u0430\u044f, \u043f\u0440\u043e\u0449\u0435 \u043e\u0442\u043a\u0440\u044b\u0442\u044c \u043a\u0430\u0442\u0430\u043b\u043e\u0433 downloads.openwrt.org \u0432 \u0431\u0440\u0430\u0443\u0437\u0435\u0440\u0435 \u0438 \u043f\u043e\u0434\u0441\u0442\u0430\u0432\u0438\u0442\u044c \u0441\u0432\u0435\u0436\u0438\u0439 \u043d\u043e\u043c\u0435\u0440 \u0432\u0435\u0440\u0441\u0438\u0438. \u0414\u043b\u044f \u0441\u0442\u0430\u0442\u044c\u0438 \u0432\u0430\u0436\u0435\u043d \u043d\u0435 \u043a\u043e\u043d\u043a\u0440\u0435\u0442\u043d\u044b\u0439 \u043d\u043e\u043c\u0435\u0440, \u0430 \u043f\u0440\u0438\u043d\u0446\u0438\u043f: \u0431\u0435\u0440\u0435\u043c x86\/64 generic ext4 combined EFI image.<\/p>\n<h3>1.2. \u041f\u0440\u043e\u0432\u0435\u0440\u0438\u0442\u044c checksum<\/h3>\n<p>\u042d\u0442\u043e \u043d\u0435 \u043e\u0431\u044f\u0437\u0430\u0442\u0435\u043b\u044c\u043d\u044b\u0439, \u043d\u043e \u043f\u0440\u0430\u0432\u0438\u043b\u044c\u043d\u044b\u0439 \u0448\u0430\u0433. \u041e\u0431\u0440\u0430\u0437 \u0431\u0443\u0434\u0435\u0442 \u0438\u0441\u043f\u043e\u043b\u044c\u0437\u043e\u0432\u0430\u0442\u044c\u0441\u044f \u043a\u0430\u043a \u0434\u0438\u0441\u043a \u0440\u043e\u0443\u0442\u0435\u0440\u0430, \u043f\u043e\u044d\u0442\u043e\u043c\u0443 \u043b\u0443\u0447\u0448\u0435 \u0443\u0431\u0435\u0434\u0438\u0442\u044c\u0441\u044f, \u0447\u0442\u043e \u043e\u043d \u0441\u043a\u0430\u0447\u0430\u043b\u0441\u044f \u0431\u0435\u0437 \u043f\u043e\u0432\u0440\u0435\u0436\u0434\u0435\u043d\u0438\u0439.<\/p>\n<pre><code class=\"bash\">sha256sum -c --ignore-missing sha256sums<\/code><div class=\"code-explainer\"><a href=\"https:\/\/sourcecraft.dev\/\" class=\"tm-button code-explainer__link\" style=\"visibility: hidden;\"><img style=\"width:14px;height:14px;object-fit:cover;object-position:left;\"\/><\/a><\/div><\/pre>\n<p>\u0415\u0441\u043b\u0438 \u043f\u0440\u043e\u0432\u0435\u0440\u043a\u0430 \u043f\u0438\u0448\u0435\u0442 OK, \u043c\u043e\u0436\u043d\u043e \u0440\u0430\u0441\u043f\u0430\u043a\u043e\u0432\u044b\u0432\u0430\u0442\u044c \u043e\u0431\u0440\u0430\u0437. \u0415\u0441\u043b\u0438 \u0444\u0430\u0439\u043b \u043d\u0435 \u043d\u0430\u0439\u0434\u0435\u043d \u0432 sha256sums, \u0437\u043d\u0430\u0447\u0438\u0442 \u0438\u043c\u044f \u043e\u0431\u0440\u0430\u0437\u0430 \u043e\u0442\u043b\u0438\u0447\u0430\u0435\u0442\u0441\u044f \u043e\u0442 \u043e\u0436\u0438\u0434\u0430\u0435\u043c\u043e\u0433\u043e. \u0422\u043e\u0433\u0434\u0430 \u043d\u0430\u0434\u043e \u0441\u0432\u0435\u0440\u0438\u0442\u044c \u043d\u0430\u0437\u0432\u0430\u043d\u0438\u0435 \u0444\u0430\u0439\u043b\u0430 \u0432 \u043a\u0430\u0442\u0430\u043b\u043e\u0433\u0435 \u0440\u0435\u043b\u0438\u0437\u0430.<\/p>\n<h3>1.3. \u0420\u0430\u0441\u043f\u0430\u043a\u043e\u0432\u0430\u0442\u044c \u0438 \u043a\u043e\u043d\u0432\u0435\u0440\u0442\u0438\u0440\u043e\u0432\u0430\u0442\u044c \u043e\u0431\u0440\u0430\u0437<\/h3>\n<p>OpenWrt \u043e\u0431\u0440\u0430\u0437 \u043f\u0440\u0438\u0445\u043e\u0434\u0438\u0442 \u043a\u0430\u043a gzip-\u0430\u0440\u0445\u0438\u0432 \u0441 raw-\u0434\u0438\u0441\u043a\u043e\u043c \u0432\u043d\u0443\u0442\u0440\u0438. Proxmox \u0443\u043c\u0435\u0435\u0442 \u0438\u043c\u043f\u043e\u0440\u0442\u0438\u0440\u043e\u0432\u0430\u0442\u044c raw, \u043d\u043e \u043c\u043d\u0435 \u0443\u0434\u043e\u0431\u043d\u0435\u0435 \u0441\u043d\u0430\u0447\u0430\u043b\u0430 \u043a\u043e\u043d\u0432\u0435\u0440\u0442\u0438\u0440\u043e\u0432\u0430\u0442\u044c \u0435\u0433\u043e \u0432 qcow2.<\/p>\n<pre><code class=\"bash\">gzip -dk openwrt-${OPENWRT_VERSION}-x86-64-generic-ext4-combined-efi.img.gzqemu-img convert -f raw -O qcow2   openwrt-${OPENWRT_VERSION}-x86-64-generic-ext4-combined-efi.img   openwrt-${OPENWRT_VERSION}-x86-64-generic-ext4-combined-efi.qcow2qemu-img info openwrt-${OPENWRT_VERSION}-x86-64-generic-ext4-combined-efi.qcow2<\/code><div class=\"code-explainer\"><a href=\"https:\/\/sourcecraft.dev\/\" class=\"tm-button code-explainer__link\" style=\"visibility: hidden;\"><img style=\"width:14px;height:14px;object-fit:cover;object-position:left;\"\/><\/a><\/div><\/pre>\n<p>\u0415\u0441\u043b\u0438 qemu-img \u043d\u0435 \u043d\u0430\u0439\u0434\u0435\u043d, \u043d\u0430 Proxmox \u043e\u0431\u044b\u0447\u043d\u043e \u044d\u0442\u043e \u0441\u0442\u0440\u0430\u043d\u043d\u043e, \u043d\u043e \u043c\u043e\u0436\u043d\u043e \u043f\u043e\u0441\u0442\u0430\u0432\u0438\u0442\u044c qemu-utils. \u041d\u0430 \u043e\u0431\u044b\u0447\u043d\u043e\u043c Debian \u044d\u0442\u043e \u0434\u0435\u043b\u0430\u0435\u0442\u0441\u044f \u0447\u0435\u0440\u0435\u0437 apt install qemu-utils.<\/p>\n<h3>1.4. \u0421\u043e\u0437\u0434\u0430\u0442\u044c VM \u0432 Proxmox<\/h3>\n<p>\u0414\u0430\u043b\u044c\u0448\u0435 \u0441\u043e\u0437\u0434\u0430\u0435\u043c VM. \u041d\u043e\u043c\u0435\u0440 VMID \u043c\u043e\u0436\u043d\u043e \u0432\u044b\u0431\u0440\u0430\u0442\u044c \u043b\u044e\u0431\u043e\u0439 \u0441\u0432\u043e\u0431\u043e\u0434\u043d\u044b\u0439. \u0412 \u043f\u0440\u0438\u043c\u0435\u0440\u0435 \u044f \u0438\u0441\u043f\u043e\u043b\u044c\u0437\u0443\u044e 150.<\/p>\n<pre><code class=\"bash\">VMID=150VMNAME=\"openwrt-gateway\"qm create ${VMID}   --name ${VMNAME}   --memory 1024   --cores 2   --cpu host   --ostype l26   --net0 virtio,bridge=vmbr0   --net1 virtio,bridge=vmbr0<\/code><div class=\"code-explainer\"><a href=\"https:\/\/sourcecraft.dev\/\" class=\"tm-button code-explainer__link\" style=\"visibility: hidden;\"><img style=\"width:14px;height:14px;object-fit:cover;object-position:left;\"\/><\/a><\/div><\/pre>\n<p>\u0412 \u043f\u0440\u0438\u043c\u0435\u0440\u0435 \u043e\u0431\u0430 \u0438\u043d\u0442\u0435\u0440\u0444\u0435\u0439\u0441\u0430 \u043f\u043e\u0434\u043a\u043b\u044e\u0447\u0435\u043d\u044b \u043a vmbr0, \u043f\u043e\u0442\u043e\u043c\u0443 \u0447\u0442\u043e \u0443 \u043c\u0435\u043d\u044f \u043e\u0441\u043d\u043e\u0432\u043d\u0430\u044f \u0437\u0430\u0434\u0430\u0447\u0430 \u0431\u044b\u043b\u0430 \u0441\u043d\u0430\u0447\u0430\u043b\u0430 \u0437\u0430\u0432\u0435\u0441\u0442\u0438 OpenWrt \u0432 \u0441\u0443\u0449\u0435\u0441\u0442\u0432\u0443\u044e\u0449\u0435\u0439 \u0441\u0435\u0442\u0438. \u0415\u0441\u043b\u0438 \u0443 \u0432\u0430\u0441 \u0435\u0441\u0442\u044c \u043e\u0442\u0434\u0435\u043b\u044c\u043d\u044b\u0439 bridge \u043f\u043e\u0434 \u0442\u0435\u0441\u0442\u043e\u0432\u0443\u044e LAN, \u043d\u0430\u043f\u0440\u0438\u043c\u0435\u0440 vmbr1, \u0432\u0442\u043e\u0440\u043e\u0439 \u0438\u043d\u0442\u0435\u0440\u0444\u0435\u0439\u0441 \u043c\u043e\u0436\u043d\u043e \u043f\u043e\u0432\u0435\u0441\u0438\u0442\u044c \u0442\u0443\u0434\u0430.<\/p>\n<pre><code># \u0432\u0430\u0440\u0438\u0430\u043d\u0442, \u0435\u0441\u043b\u0438 \u0435\u0441\u0442\u044c \u043e\u0442\u0434\u0435\u043b\u044c\u043d\u044b\u0439 bridge \u043f\u043e\u0434 \u0442\u0435\u0441\u0442\u043e\u0432\u0443\u044e LAN# qm set ${VMID} --net1 virtio,bridge=vmbr1<\/code><div class=\"code-explainer\"><a href=\"https:\/\/sourcecraft.dev\/\" class=\"tm-button code-explainer__link\" style=\"visibility: hidden;\"><img style=\"width:14px;height:14px;object-fit:cover;object-position:left;\"\/><\/a><\/div><\/pre>\n<p>\u041f\u043e\u0447\u0435\u043c\u0443 virtio: \u0434\u043b\u044f \u0432\u0438\u0440\u0442\u0443\u0430\u043b\u044c\u043d\u043e\u0439 \u043c\u0430\u0448\u0438\u043d\u044b \u044d\u0442\u043e \u043d\u043e\u0440\u043c\u0430\u043b\u044c\u043d\u044b\u0439 \u0431\u044b\u0441\u0442\u0440\u044b\u0439 \u0441\u0435\u0442\u0435\u0432\u043e\u0439 \u0434\u0440\u0430\u0439\u0432\u0435\u0440. OpenWrt x86_64 \u0441 \u043d\u0438\u043c \u0440\u0430\u0431\u043e\u0442\u0430\u0435\u0442 \u0431\u0435\u0437 \u043b\u0438\u0448\u043d\u0438\u0445 \u043f\u043b\u044f\u0441\u043e\u043a.<\/p>\n<h3>1.5. \u0418\u043c\u043f\u043e\u0440\u0442\u0438\u0440\u043e\u0432\u0430\u0442\u044c \u0434\u0438\u0441\u043a \u0432 VM<\/h3>\n<p>\u0414\u0430\u043b\u044c\u0448\u0435 \u0438\u043c\u043f\u043e\u0440\u0442\u0438\u0440\u0443\u0435\u043c qcow2-\u0434\u0438\u0441\u043a \u0432 \u0445\u0440\u0430\u043d\u0438\u043b\u0438\u0449\u0435 Proxmox. \u0412 \u043f\u0440\u0438\u043c\u0435\u0440\u0435 \u0438\u0441\u043f\u043e\u043b\u044c\u0437\u0443\u0435\u0442\u0441\u044f local-lvm. \u0415\u0441\u043b\u0438 \u0443 \u0432\u0430\u0441 \u0434\u0440\u0443\u0433\u043e\u0435 \u0445\u0440\u0430\u043d\u0438\u043b\u0438\u0449\u0435, \u043d\u0430\u043f\u0440\u0438\u043c\u0435\u0440 local, zfs, nvme \u0438\u043b\u0438 ceph, \u0437\u0430\u043c\u0435\u043d\u0438\u0442\u0435 \u0438\u043c\u044f storage.<\/p>\n<pre><code class=\"bash\">qm importdisk ${VMID}   openwrt-${OPENWRT_VERSION}-x86-64-generic-ext4-combined-efi.qcow2   local-lvm<\/code><div class=\"code-explainer\"><a href=\"https:\/\/sourcecraft.dev\/\" class=\"tm-button code-explainer__link\" style=\"visibility: hidden;\"><img style=\"width:14px;height:14px;object-fit:cover;object-position:left;\"\/><\/a><\/div><\/pre>\n<p>\u041f\u043e\u0441\u043b\u0435 \u0438\u043c\u043f\u043e\u0440\u0442\u0430 \u0434\u0438\u0441\u043a \u043f\u043e\u044f\u0432\u0438\u0442\u0441\u044f \u043a\u0430\u043a unused disk \u0443 VM. \u0415\u0433\u043e \u043d\u0443\u0436\u043d\u043e \u043f\u043e\u0434\u043a\u043b\u044e\u0447\u0438\u0442\u044c \u043a\u0430\u043a \u043e\u0441\u043d\u043e\u0432\u043d\u043e\u0439 \u0434\u0438\u0441\u043a.<\/p>\n<pre><code class=\"bash\">qm set ${VMID} --scsihw virtio-scsi-pciqm set ${VMID} --scsi0 local-lvm:vm-${VMID}-disk-0qm set ${VMID} --boot order=scsi0<\/code><div class=\"code-explainer\"><a href=\"https:\/\/sourcecraft.dev\/\" class=\"tm-button code-explainer__link\" style=\"visibility: hidden;\"><img style=\"width:14px;height:14px;object-fit:cover;object-position:left;\"\/><\/a><\/div><\/pre>\n<blockquote>\n<p><strong>\u0412\u0430\u0436\u043d\u043e:<\/strong> \u0415\u0441\u043b\u0438 Proxmox \u043d\u0430\u0437\u0432\u0430\u043b \u0438\u043c\u043f\u043e\u0440\u0442\u0438\u0440\u043e\u0432\u0430\u043d\u043d\u044b\u0439 \u0434\u0438\u0441\u043a \u0438\u043d\u0430\u0447\u0435, \u043f\u043e\u0441\u043c\u043e\u0442\u0440\u0438\u0442\u0435 VM \u0432 \u0432\u0435\u0431-\u043c\u043e\u0440\u0434\u0435 \u0438\u043b\u0438 \u0432\u044b\u043f\u043e\u043b\u043d\u0438\u0442\u0435 qm config 150. \u0418\u043d\u043e\u0433\u0434\u0430 \u0438\u043c\u044f \u0434\u0438\u0441\u043a\u0430 \u043e\u0442\u043b\u0438\u0447\u0430\u0435\u0442\u0441\u044f, \u043e\u0441\u043e\u0431\u0435\u043d\u043d\u043e \u0435\u0441\u043b\u0438 VM \u0443\u0436\u0435 \u0441\u043e\u0437\u0434\u0430\u0432\u0430\u043b\u0430\u0441\u044c \u0440\u0430\u043d\u044c\u0448\u0435.<\/p>\n<\/blockquote>\n<h3>1.6. \u041d\u0430\u0441\u0442\u0440\u043e\u0438\u0442\u044c \u043a\u043e\u043d\u0441\u043e\u043b\u044c<\/h3>\n<p>\u0427\u0442\u043e\u0431\u044b \u0431\u044b\u043b\u043e \u0443\u0434\u043e\u0431\u043d\u043e \u0437\u0430\u0445\u043e\u0434\u0438\u0442\u044c \u0432 OpenWrt \u0447\u0435\u0440\u0435\u0437 \u043a\u043e\u043d\u0441\u043e\u043b\u044c Proxmox, \u043c\u043e\u0436\u043d\u043e \u0432\u043a\u043b\u044e\u0447\u0438\u0442\u044c serial console. \u042d\u0442\u043e \u043e\u0441\u043e\u0431\u0435\u043d\u043d\u043e \u043f\u043e\u043b\u0435\u0437\u043d\u043e, \u043a\u043e\u0433\u0434\u0430 \u0441\u0435\u0442\u044c \u0441\u043b\u043e\u043c\u0430\u043b\u0430\u0441\u044c \u0438 SSH \u043d\u0435\u0434\u043e\u0441\u0442\u0443\u043f\u0435\u043d.<\/p>\n<pre><code class=\"bash\">qm set ${VMID} --serial0 socketqm set ${VMID} --vga serial0<\/code><div class=\"code-explainer\"><a href=\"https:\/\/sourcecraft.dev\/\" class=\"tm-button code-explainer__link\" style=\"visibility: hidden;\"><img style=\"width:14px;height:14px;object-fit:cover;object-position:left;\"\/><\/a><\/div><\/pre>\n<p>\u0415\u0441\u043b\u0438 \u0441 serial console \u0447\u0442\u043e-\u0442\u043e \u043d\u0435 \u043d\u0440\u0430\u0432\u0438\u0442\u0441\u044f, \u043c\u043e\u0436\u043d\u043e \u043e\u0441\u0442\u0430\u0432\u0438\u0442\u044c \u043e\u0431\u044b\u0447\u043d\u0443\u044e VGA-\u043a\u043e\u043d\u0441\u043e\u043b\u044c \u0432 \u0432\u0435\u0431-\u0438\u043d\u0442\u0435\u0440\u0444\u0435\u0439\u0441\u0435 Proxmox. \u0413\u043b\u0430\u0432\u043d\u043e\u0435, \u0447\u0442\u043e\u0431\u044b \u0431\u044b\u043b \u0430\u0432\u0430\u0440\u0438\u0439\u043d\u044b\u0439 \u0434\u043e\u0441\u0442\u0443\u043f \u043a VM \u043d\u0435 \u0447\u0435\u0440\u0435\u0437 \u0441\u0435\u0442\u044c.<\/p>\n<h3>1.7. \u0423\u0432\u0435\u043b\u0438\u0447\u0438\u0442\u044c \u0434\u0438\u0441\u043a VM<\/h3>\n<p>\u041e\u0431\u0440\u0430\u0437 OpenWrt \u043e\u0431\u044b\u0447\u043d\u043e \u043c\u0430\u043b\u0435\u043d\u044c\u043a\u0438\u0439. \u0414\u043b\u044f \u0447\u0438\u0441\u0442\u043e\u0433\u043e \u0440\u043e\u0443\u0442\u0435\u0440\u0430 \u044d\u0442\u043e\u0433\u043e \u0445\u0432\u0430\u0442\u0430\u0435\u0442, \u043d\u043e \u043c\u044b \u0431\u0443\u0434\u0435\u043c \u0441\u0442\u0430\u0432\u0438\u0442\u044c sing-box, tcpdump, curl, LuCI, WireGuard \u0438 \u0434\u0440\u0443\u0433\u0438\u0435 \u043f\u0430\u043a\u0435\u0442\u044b. \u041f\u043e\u044d\u0442\u043e\u043c\u0443 \u043b\u0443\u0447\u0448\u0435 \u0441\u0440\u0430\u0437\u0443 \u0443\u0432\u0435\u043b\u0438\u0447\u0438\u0442\u044c \u0434\u0438\u0441\u043a.<\/p>\n<pre><code class=\"bash\">qm resize ${VMID} scsi0 +2G<\/code><div class=\"code-explainer\"><a href=\"https:\/\/sourcecraft.dev\/\" class=\"tm-button code-explainer__link\" style=\"visibility: hidden;\"><img style=\"width:14px;height:14px;object-fit:cover;object-position:left;\"\/><\/a><\/div><\/pre>\n<p>\u042d\u0442\u043e \u0443\u0432\u0435\u043b\u0438\u0447\u0438\u0432\u0430\u0435\u0442 \u0432\u0438\u0440\u0442\u0443\u0430\u043b\u044c\u043d\u044b\u0439 \u0434\u0438\u0441\u043a \u0432 Proxmox, \u043d\u043e \u0432\u043d\u0443\u0442\u0440\u0438 OpenWrt \u0440\u0430\u0437\u0434\u0435\u043b \u0438 \u0444\u0430\u0439\u043b\u043e\u0432\u0443\u044e \u0441\u0438\u0441\u0442\u0435\u043c\u0443 \u0442\u043e\u0436\u0435 \u043d\u0430\u0434\u043e \u0440\u0430\u0441\u0448\u0438\u0440\u0438\u0442\u044c. \u042d\u0442\u043e \u043c\u043e\u0436\u043d\u043e \u0441\u0434\u0435\u043b\u0430\u0442\u044c \u043f\u043e\u0441\u043b\u0435 \u043f\u0435\u0440\u0432\u043e\u0433\u043e \u0437\u0430\u043f\u0443\u0441\u043a\u0430.<\/p>\n<h3>1.8. \u041f\u0435\u0440\u0432\u044b\u0439 \u0437\u0430\u043f\u0443\u0441\u043a VM<\/h3>\n<pre><code class=\"bash\">qm start ${VMID}qm status ${VMID}qm terminal ${VMID}<\/code><div class=\"code-explainer\"><a href=\"https:\/\/sourcecraft.dev\/\" class=\"tm-button code-explainer__link\" style=\"visibility: hidden;\"><img style=\"width:14px;height:14px;object-fit:cover;object-position:left;\"\/><\/a><\/div><\/pre>\n<p>\u0415\u0441\u043b\u0438 qm terminal \u043d\u0435 \u0438\u0441\u043f\u043e\u043b\u044c\u0437\u0443\u0435\u0442\u0441\u044f, \u043f\u0440\u043e\u0441\u0442\u043e \u043e\u0442\u043a\u0440\u043e\u0439\u0442\u0435 VM \u0432 \u0432\u0435\u0431-\u043c\u043e\u0440\u0434\u0435 Proxmox: VM -&gt; Console. \u041f\u043e\u0441\u043b\u0435 \u0437\u0430\u0433\u0440\u0443\u0437\u043a\u0438 \u0432\u044b \u0434\u043e\u043b\u0436\u043d\u044b \u043f\u043e\u043f\u0430\u0441\u0442\u044c \u0432 \u043a\u043e\u043d\u0441\u043e\u043b\u044c OpenWrt.<\/p>\n<h3>1.9. \u041f\u0435\u0440\u0432\u044b\u0439 \u0432\u0445\u043e\u0434 \u0432 OpenWrt<\/h3>\n<p>\u0412\u043d\u0443\u0442\u0440\u0438 OpenWrt \u0437\u0430\u0434\u0430\u0435\u043c \u043f\u0430\u0440\u043e\u043b\u044c root:<\/p>\n<pre><code class=\"bash\">passwd<\/code><div class=\"code-explainer\"><a href=\"https:\/\/sourcecraft.dev\/\" class=\"tm-button code-explainer__link\" style=\"visibility: hidden;\"><img style=\"width:14px;height:14px;object-fit:cover;object-position:left;\"\/><\/a><\/div><\/pre>\n<p>\u041f\u0440\u043e\u0432\u0435\u0440\u044f\u0435\u043c \u0438\u043d\u0442\u0435\u0440\u0444\u0435\u0439\u0441\u044b:<\/p>\n<pre><code class=\"bash\">ip aifconfig<\/code><div class=\"code-explainer\"><a href=\"https:\/\/sourcecraft.dev\/\" class=\"tm-button code-explainer__link\" style=\"visibility: hidden;\"><img style=\"width:14px;height:14px;object-fit:cover;object-position:left;\"\/><\/a><\/div><\/pre>\n<p>\u041d\u0430 \u044d\u0442\u043e\u043c \u044d\u0442\u0430\u043f\u0435 \u0432\u0430\u0436\u043d\u043e \u043f\u043e\u043d\u044f\u0442\u044c, \u043a\u0430\u043a\u043e\u0439 \u0438\u043d\u0442\u0435\u0440\u0444\u0435\u0439\u0441 \u0441\u0442\u0430\u043b eth0, \u0430 \u043a\u0430\u043a\u043e\u0439 eth1. \u0412 \u0441\u0442\u0430\u0442\u044c\u0435 \u0434\u0430\u043b\u044c\u0448\u0435 \u0441\u0447\u0438\u0442\u0430\u0435\u043c, \u0447\u0442\u043e eth0 \u0441\u043c\u043e\u0442\u0440\u0438\u0442 \u0432 \u043e\u0441\u043d\u043e\u0432\u043d\u0443\u044e \u0441\u0435\u0442\u044c 192.168.0.0\/24, \u0430 eth1 \u0438\u0441\u043f\u043e\u043b\u044c\u0437\u0443\u0435\u0442\u0441\u044f \u0434\u043b\u044f \u0442\u0435\u0441\u0442\u043e\u0432\u043e\u0439 LAN.<\/p>\n<h3>1.10. \u0420\u0430\u0441\u0448\u0438\u0440\u0438\u0442\u044c root-\u0440\u0430\u0437\u0434\u0435\u043b OpenWrt<\/h3>\n<p>\u042d\u0442\u043e\u0442 \u0448\u0430\u0433 \u043e\u043f\u0446\u0438\u043e\u043d\u0430\u043b\u044c\u043d\u044b\u0439, \u043d\u043e \u044f \u0431\u044b \u0435\u0433\u043e \u0441\u0434\u0435\u043b\u0430\u043b \u0441\u0440\u0430\u0437\u0443. \u0418\u043d\u0430\u0447\u0435 \u043f\u043e\u0441\u043b\u0435 \u0443\u0441\u0442\u0430\u043d\u043e\u0432\u043a\u0438 \u043f\u0430\u043a\u0435\u0442\u043e\u0432 \u043c\u043e\u0436\u043d\u043e \u0431\u044b\u0441\u0442\u0440\u043e \u0443\u043f\u0435\u0440\u0435\u0442\u044c\u0441\u044f \u0432 \u043c\u0435\u0441\u0442\u043e. \u0421\u043d\u0430\u0447\u0430\u043b\u0430 \u0441\u043c\u043e\u0442\u0440\u0438\u043c \u0440\u0430\u0437\u043c\u0435\u0442\u043a\u0443 \u0434\u0438\u0441\u043a\u0430:<\/p>\n<pre><code class=\"bash\">df -hlsblk 2&gt;\/dev\/null || block info<\/code><div class=\"code-explainer\"><a href=\"https:\/\/sourcecraft.dev\/\" class=\"tm-button code-explainer__link\" style=\"visibility: hidden;\"><img style=\"width:14px;height:14px;object-fit:cover;object-position:left;\"\/><\/a><\/div><\/pre>\n<p>\u0415\u0441\u043b\u0438 lsblk \u043d\u0435 \u0443\u0441\u0442\u0430\u043d\u043e\u0432\u043b\u0435\u043d, \u043c\u043e\u0436\u043d\u043e \u043f\u043e\u0441\u0442\u0430\u0432\u0438\u0442\u044c \u0443\u0442\u0438\u043b\u0438\u0442\u044b \u0438 \u0440\u0430\u0441\u0448\u0438\u0440\u0438\u0442\u044c \u0440\u0430\u0437\u0434\u0435\u043b. \u041d\u0430 x86 ext4 combined \u0447\u0430\u0449\u0435 \u0432\u0441\u0435\u0433\u043e root-\u0440\u0430\u0437\u0434\u0435\u043b \u044d\u0442\u043e \/dev\/sda2, \u043d\u043e \u043b\u0443\u0447\u0448\u0435 \u043f\u0440\u043e\u0432\u0435\u0440\u0438\u0442\u044c \u0433\u043b\u0430\u0437\u0430\u043c\u0438.<\/p>\n<pre><code class=\"bash\">opkg updateopkg install parted e2fsprogs resize2fs lsblkparted -s \/dev\/sda printparted -s \/dev\/sda resizepart 2 100%reboot<\/code><div class=\"code-explainer\"><a href=\"https:\/\/sourcecraft.dev\/\" class=\"tm-button code-explainer__link\" style=\"visibility: hidden;\"><img style=\"width:14px;height:14px;object-fit:cover;object-position:left;\"\/><\/a><\/div><\/pre>\n<p>\u041f\u043e\u0441\u043b\u0435 \u043f\u0435\u0440\u0435\u0437\u0430\u0433\u0440\u0443\u0437\u043a\u0438 \u0440\u0430\u0441\u0448\u0438\u0440\u044f\u0435\u043c \u0444\u0430\u0439\u043b\u043e\u0432\u0443\u044e \u0441\u0438\u0441\u0442\u0435\u043c\u0443:<\/p>\n<pre><code class=\"bash\">resize2fs \/dev\/sda2df -h<\/code><div class=\"code-explainer\"><a href=\"https:\/\/sourcecraft.dev\/\" class=\"tm-button code-explainer__link\" style=\"visibility: hidden;\"><img style=\"width:14px;height:14px;object-fit:cover;object-position:left;\"\/><\/a><\/div><\/pre>\n<blockquote>\n<p><strong>\u0412\u0430\u0436\u043d\u043e:<\/strong> \u0415\u0441\u043b\u0438 \u0443 \u0432\u0430\u0441 \u0434\u0438\u0441\u043a \u043d\u0430\u0437\u044b\u0432\u0430\u0435\u0442\u0441\u044f \u043d\u0435 \/dev\/sda \u0438\u043b\u0438 root-\u0440\u0430\u0437\u0434\u0435\u043b \u043d\u0435 \/dev\/sda2, \u043a\u043e\u043c\u0430\u043d\u0434\u044b \u043d\u0430\u0434\u043e \u0430\u0434\u0430\u043f\u0442\u0438\u0440\u043e\u0432\u0430\u0442\u044c. \u041d\u0435 \u0432\u044b\u043f\u043e\u043b\u043d\u044f\u0439\u0442\u0435 resizepart \u0432\u0441\u043b\u0435\u043f\u0443\u044e \u043d\u0430 \u043d\u0435\u0437\u043d\u0430\u043a\u043e\u043c\u043e\u0439 \u0440\u0430\u0437\u043c\u0435\u0442\u043a\u0435.<\/p>\n<\/blockquote>\n<h2>\u0428\u0430\u0433 2. \u041d\u0430\u0441\u0442\u0440\u043e\u0438\u0442\u044c \u0441\u0435\u0442\u044c OpenWrt<\/h2>\n<p>\u0422\u0435\u043f\u0435\u0440\u044c \u043d\u0443\u0436\u043d\u043e \u0441\u0434\u0435\u043b\u0430\u0442\u044c \u0442\u0430\u043a, \u0447\u0442\u043e\u0431\u044b OpenWrt \u0438\u043c\u0435\u043b \u043f\u043e\u0441\u0442\u043e\u044f\u043d\u043d\u044b\u0439 \u0430\u0434\u0440\u0435\u0441 192.168.0.2 \u0432 \u043e\u0441\u043d\u043e\u0432\u043d\u043e\u0439 \u0441\u0435\u0442\u0438 \u0438 \u0437\u043d\u0430\u043b, \u0447\u0442\u043e \u043e\u0441\u043d\u043e\u0432\u043d\u043e\u0439 \u0440\u043e\u0443\u0442\u0435\u0440 \u043d\u0430\u0445\u043e\u0434\u0438\u0442\u0441\u044f \u043d\u0430 192.168.0.1.<\/p>\n<h3>2.1. \u041d\u0430\u0441\u0442\u0440\u043e\u0439\u043a\u0430 WAN \u043a\u0430\u043a \u0441\u0442\u0430\u0442\u0438\u0447\u0435\u0441\u043a\u043e\u0433\u043e \u0430\u0434\u0440\u0435\u0441\u0430 \u0432 \u043e\u0441\u043d\u043e\u0432\u043d\u043e\u0439 \u0441\u0435\u0442\u0438<\/h3>\n<pre><code class=\"bash\">uci set network.wan=interfaceuci set network.wan.device='eth0'uci set network.wan.proto='static'uci set network.wan.ipaddr='192.168.0.2'uci set network.wan.netmask='255.255.255.0'uci set network.wan.gateway='192.168.0.1'uci delete network.wan.dns 2&gt;\/dev\/nulluci add_list network.wan.dns='192.168.0.1'uci add_list network.wan.dns='1.1.1.1'uci commit network\/etc\/init.d\/network restart<\/code><div class=\"code-explainer\"><a href=\"https:\/\/sourcecraft.dev\/\" class=\"tm-button code-explainer__link\" style=\"visibility: hidden;\"><img style=\"width:14px;height:14px;object-fit:cover;object-position:left;\"\/><\/a><\/div><\/pre>\n<p>\u0414\u0430, \u0437\u0434\u0435\u0441\u044c \u0438\u043d\u0442\u0435\u0440\u0444\u0435\u0439\u0441 \u043d\u0430\u0437\u044b\u0432\u0430\u0435\u0442\u0441\u044f wan, \u0445\u043e\u0442\u044f \u043e\u043d \u043d\u0430\u0445\u043e\u0434\u0438\u0442\u0441\u044f \u0432 \u0434\u043e\u043c\u0430\u0448\u043d\u0435\u0439 \u0441\u0435\u0442\u0438. \u042d\u0442\u043e \u043e\u0441\u043e\u0431\u0435\u043d\u043d\u043e\u0441\u0442\u044c \u043d\u0430\u0448\u0435\u0439 \u0441\u0445\u0435\u043c\u044b. \u0424\u0438\u0437\u0438\u0447\u0435\u0441\u043a\u0438 eth0 \u043f\u043e\u0434\u043a\u043b\u044e\u0447\u0435\u043d \u0432 \u043e\u0441\u043d\u043e\u0432\u043d\u0443\u044e \u0441\u0435\u0442\u044c, \u0430 \u043b\u043e\u0433\u0438\u0447\u0435\u0441\u043a\u0438 OpenWrt \u0432\u0441\u0435 \u0435\u0449\u0435 \u0441\u0447\u0438\u0442\u0430\u0435\u0442 \u0435\u0433\u043e wan-\u0437\u043e\u043d\u043e\u0439.<\/p>\n<h3>2.2. \u041d\u0430\u0441\u0442\u0440\u043e\u0439\u043a\u0430 \u0442\u0435\u0441\u0442\u043e\u0432\u043e\u0439 LAN<\/h3>\n<p>\u0415\u0441\u043b\u0438 \u0435\u0441\u0442\u044c \u0432\u0442\u043e\u0440\u043e\u0439 \u0438\u043d\u0442\u0435\u0440\u0444\u0435\u0439\u0441 eth1, \u043c\u043e\u0436\u043d\u043e \u043e\u0441\u0442\u0430\u0432\u0438\u0442\u044c \u043d\u0430 \u043d\u0435\u043c \u043e\u0442\u0434\u0435\u043b\u044c\u043d\u0443\u044e LAN-\u0441\u0435\u0442\u044c:<\/p>\n<pre><code class=\"bash\">uci set network.lan=interfaceuci set network.lan.device='eth1'uci set network.lan.proto='static'uci set network.lan.ipaddr='192.168.50.1'uci set network.lan.netmask='255.255.255.0'uci commit network\/etc\/init.d\/network restart<\/code><div class=\"code-explainer\"><a href=\"https:\/\/sourcecraft.dev\/\" class=\"tm-button code-explainer__link\" style=\"visibility: hidden;\"><img style=\"width:14px;height:14px;object-fit:cover;object-position:left;\"\/><\/a><\/div><\/pre>\n<p>\u041f\u043e\u0441\u043b\u0435 \u044d\u0442\u043e\u0433\u043e OpenWrt \u0434\u043e\u043b\u0436\u0435\u043d \u043e\u0442\u043a\u0440\u044b\u0432\u0430\u0442\u044c\u0441\u044f \u043f\u043e \u0430\u0434\u0440\u0435\u0441\u0443 192.168.0.2 \u0438\u0437 \u043e\u0441\u043d\u043e\u0432\u043d\u043e\u0439 \u0441\u0435\u0442\u0438 \u0438 \u043f\u043e 192.168.50.1 \u0438\u0437 \u0442\u0435\u0441\u0442\u043e\u0432\u043e\u0439 LAN, \u0435\u0441\u043b\u0438 \u043e\u043d\u0430 \u043f\u043e\u0434\u043a\u043b\u044e\u0447\u0435\u043d\u0430.<\/p>\n<h2>\u0428\u0430\u0433 3. \u0411\u0430\u0437\u043e\u0432\u044b\u0439 firewall OpenWrt<\/h2>\n<p>\u0422\u0430\u043a \u043a\u0430\u043a \u043a\u043b\u0438\u0435\u043d\u0442\u044b \u043f\u0440\u0438\u0445\u043e\u0434\u044f\u0442 \u043d\u0430 OpenWrt \u0441\u043e \u0441\u0442\u043e\u0440\u043e\u043d\u044b wan-\u0437\u043e\u043d\u044b, \u043d\u0443\u0436\u043d\u043e \u0430\u043a\u043a\u0443\u0440\u0430\u0442\u043d\u043e \u0440\u0430\u0437\u0440\u0435\u0448\u0438\u0442\u044c \u0442\u043e, \u0447\u0442\u043e \u0434\u043b\u044f \u043e\u0431\u044b\u0447\u043d\u043e\u0433\u043e WAN \u043e\u0431\u044b\u0447\u043d\u043e \u0437\u0430\u043f\u0440\u0435\u0449\u0435\u043d\u043e: DHCP, DNS, LuCI\/SSH \u0438\u0437 \u043b\u043e\u043a\u0430\u043b\u044c\u043d\u043e\u0439 \u0441\u0435\u0442\u0438 \u0438 \u043f\u043e\u0437\u0436\u0435 \u043f\u043e\u0440\u0442 7892 \u0434\u043b\u044f sing-box redirect.<\/p>\n<h3>3.1. \u041d\u0430\u0439\u0442\u0438 wan-\u0437\u043e\u043d\u0443 \u0438 \u0432\u043a\u043b\u044e\u0447\u0438\u0442\u044c forward\/NAT<\/h3>\n<pre><code class=\"bash\">WAN_ZONE=\"$(uci show firewall | sed -n \"s\/^\\(firewall\\.@zone\\[[0-9]\\+\\]\\)\\.name='wan'$\/\\1\/p\" | head -n1)\"echo \"$WAN_ZONE\"uci set ${WAN_ZONE}.forward='ACCEPT'uci set ${WAN_ZONE}.masq='1'uci set ${WAN_ZONE}.mtu_fix='1'uci commit firewall\/etc\/init.d\/firewall restart<\/code><div class=\"code-explainer\"><a href=\"https:\/\/sourcecraft.dev\/\" class=\"tm-button code-explainer__link\" style=\"visibility: hidden;\"><img style=\"width:14px;height:14px;object-fit:cover;object-position:left;\"\/><\/a><\/div><\/pre>\n<p>masq \u043d\u0443\u0436\u0435\u043d, \u0447\u0442\u043e\u0431\u044b OpenWrt \u043c\u043e\u0433 \u043d\u043e\u0440\u043c\u0430\u043b\u044c\u043d\u043e \u0432\u044b\u043f\u0443\u0441\u043a\u0430\u0442\u044c \u043a\u043b\u0438\u0435\u043d\u0442\u043e\u0432 \u0434\u0430\u043b\u044c\u0448\u0435 \u0447\u0435\u0440\u0435\u0437 \u043e\u0441\u043d\u043e\u0432\u043d\u043e\u0439 \u0440\u043e\u0443\u0442\u0435\u0440. \u0412 \u043a\u043b\u0430\u0441\u0441\u0438\u0447\u0435\u0441\u043a\u043e\u0439 \u0441\u0445\u0435\u043c\u0435 \u044d\u0442\u043e \u0432\u044b\u0433\u043b\u044f\u0434\u0435\u043b\u043e \u0431\u044b \u043f\u0440\u0438\u0432\u044b\u0447\u043d\u0435\u0435, \u043d\u043e \u0443 \u043d\u0430\u0441 gateway-on-a-stick, \u043f\u043e\u044d\u0442\u043e\u043c\u0443 \u043b\u0443\u0447\u0448\u0435 \u044f\u0432\u043d\u043e \u0437\u0430\u0444\u0438\u043a\u0441\u0438\u0440\u043e\u0432\u0430\u0442\u044c \u043f\u043e\u0432\u0435\u0434\u0435\u043d\u0438\u0435.<\/p>\n<h3>3.2. \u0420\u0430\u0437\u0440\u0435\u0448\u0438\u0442\u044c DHCP \u0438 DNS \u0434\u043b\u044f \u043a\u043b\u0438\u0435\u043d\u0442\u043e\u0432<\/h3>\n<pre><code class=\"bash\">uci add firewall ruleuci set firewall.@rule[-1].name='Allow-DHCP-WAN-Clients'uci set firewall.@rule[-1].src='wan'uci set firewall.@rule[-1].proto='udp'uci set firewall.@rule[-1].src_port='68'uci set firewall.@rule[-1].dest_port='67'uci set firewall.@rule[-1].target='ACCEPT'uci add firewall ruleuci set firewall.@rule[-1].name='Allow-DNS-WAN-Clients'uci set firewall.@rule[-1].src='wan'uci set firewall.@rule[-1].proto='tcp udp'uci set firewall.@rule[-1].dest_port='53'uci set firewall.@rule[-1].target='ACCEPT'uci commit firewall\/etc\/init.d\/firewall restart<\/code><div class=\"code-explainer\"><a href=\"https:\/\/sourcecraft.dev\/\" class=\"tm-button code-explainer__link\" style=\"visibility: hidden;\"><img style=\"width:14px;height:14px;object-fit:cover;object-position:left;\"\/><\/a><\/div><\/pre>\n<h3>3.3. \u0420\u0430\u0437\u0440\u0435\u0448\u0438\u0442\u044c LuCI \u0438 SSH \u0438\u0437 \u043b\u043e\u043a\u0430\u043b\u044c\u043d\u043e\u0439 \u0441\u0435\u0442\u0438<\/h3>\n<pre><code class=\"bash\">uci add firewall ruleuci set firewall.@rule[-1].name='Allow-LuCI-SSH-from-main-LAN'uci set firewall.@rule[-1].src='wan'uci set firewall.@rule[-1].src_ip='192.168.0.0\/24'uci set firewall.@rule[-1].proto='tcp'uci set firewall.@rule[-1].dest_port='22 80 443'uci set firewall.@rule[-1].target='ACCEPT'uci commit firewall\/etc\/init.d\/firewall restart<\/code><div class=\"code-explainer\"><a href=\"https:\/\/sourcecraft.dev\/\" class=\"tm-button code-explainer__link\" style=\"visibility: hidden;\"><img style=\"width:14px;height:14px;object-fit:cover;object-position:left;\"\/><\/a><\/div><\/pre>\n<blockquote>\n<p><strong>\u0412\u0430\u0436\u043d\u043e:<\/strong> \u041d\u0435 \u043e\u0442\u043a\u0440\u044b\u0432\u0430\u0439\u0442\u0435 LuCI \u0438 SSH \u043d\u0430\u0440\u0443\u0436\u0443 \u0432 \u0438\u043d\u0442\u0435\u0440\u043d\u0435\u0442. \u0417\u0434\u0435\u0441\u044c \u043f\u0440\u0430\u0432\u0438\u043b\u043e \u0440\u0430\u0437\u0440\u0435\u0448\u0430\u0435\u0442 \u0434\u043e\u0441\u0442\u0443\u043f \u0442\u043e\u043b\u044c\u043a\u043e \u0438\u0437 192.168.0.0\/24.<\/p>\n<\/blockquote>\n<h3>3.4. \u041e\u0442\u043a\u043b\u044e\u0447\u0438\u0442\u044c flow offloading<\/h3>\n<p>\u041f\u043e\u0437\u0436\u0435 \u043c\u044b \u0431\u0443\u0434\u0435\u043c \u043f\u0435\u0440\u0435\u0445\u0432\u0430\u0442\u044b\u0432\u0430\u0442\u044c \u0442\u0440\u0430\u0444\u0438\u043a \u0447\u0435\u0440\u0435\u0437 nftables. Flow offloading \u043c\u043e\u0436\u0435\u0442 \u043c\u0435\u0448\u0430\u0442\u044c \u043e\u0442\u043b\u0430\u0434\u043a\u0435, \u043f\u043e\u0442\u043e\u043c\u0443 \u0447\u0442\u043e \u0447\u0430\u0441\u0442\u044c \u0442\u0440\u0430\u0444\u0438\u043a\u0430 \u043f\u0440\u043e\u0445\u043e\u0434\u0438\u0442 \u0443\u0441\u043a\u043e\u0440\u0435\u043d\u043d\u044b\u043c \u043f\u0443\u0442\u0435\u043c. \u041d\u0430 \u0432\u0440\u0435\u043c\u044f \u0442\u0430\u043a\u043e\u0439 \u0441\u0445\u0435\u043c\u044b \u044f \u0435\u0433\u043e \u043e\u0442\u043a\u043b\u044e\u0447\u0438\u043b.<\/p>\n<pre><code class=\"bash\">uci set firewall.@defaults[0].flow_offloading='0'uci set firewall.@defaults[0].flow_offloading_hw='0'uci commit firewall\/etc\/init.d\/firewall restart<\/code><div class=\"code-explainer\"><a href=\"https:\/\/sourcecraft.dev\/\" class=\"tm-button code-explainer__link\" style=\"visibility: hidden;\"><img style=\"width:14px;height:14px;object-fit:cover;object-position:left;\"\/><\/a><\/div><\/pre>\n<h2>\u0428\u0430\u0433 4. \u041f\u0435\u0440\u0435\u043d\u0435\u0441\u0442\u0438 DHCP \u043d\u0430 OpenWrt<\/h2>\n<figure class=\"\"><img decoding=\"async\" src=\"https:\/\/habrastorage.org\/r\/w1560\/webt\/70\/90\/ae\/7090ae4dbc3b9e0d55f1ca822c0b0744.png\" sizes=\"(max-width: 780px) 100vw, 50vw\" srcset=\"https:\/\/habrastorage.org\/r\/w780\/webt\/70\/90\/ae\/7090ae4dbc3b9e0d55f1ca822c0b0744.png 780w,&#10;       https:\/\/habrastorage.org\/r\/w1560\/webt\/70\/90\/ae\/7090ae4dbc3b9e0d55f1ca822c0b0744.png 781w\" loading=\"lazy\" decode=\"async\"\/><\/figure>\n<p><em>\u0420\u0438\u0441\u0443\u043d\u043e\u043a 2. OpenWrt \u0441\u0442\u0430\u043b \u0434\u043b\u044f \u043a\u043b\u0438\u0435\u043d\u0442\u043e\u0432 DHCP-\u0441\u0435\u0440\u0432\u0435\u0440\u043e\u043c, DNS-\u0441\u0435\u0440\u0432\u0435\u0440\u043e\u043c \u0438 \u0448\u043b\u044e\u0437\u043e\u043c.<\/em> <\/p>\n<p>\u0422\u0435\u043f\u0435\u0440\u044c \u0433\u043b\u0430\u0432\u043d\u044b\u0439 \u043c\u043e\u043c\u0435\u043d\u0442: \u043a\u043b\u0438\u0435\u043d\u0442\u044b \u0434\u043e\u043b\u0436\u043d\u044b \u043f\u043e\u043b\u0443\u0447\u0430\u0442\u044c \u043e\u0442 OpenWrt \u043d\u0435 \u0442\u043e\u043b\u044c\u043a\u043e IP-\u0430\u0434\u0440\u0435\u0441, \u043d\u043e \u0438 gateway\/DNS. \u0418\u043d\u0430\u0447\u0435 \u043e\u043d\u0438 \u0431\u0443\u0434\u0443\u0442 \u043e\u0431\u0445\u043e\u0434\u0438\u0442\u044c OpenWrt, \u0430 sing-box \u0432\u043e\u043e\u0431\u0449\u0435 \u043d\u0435 \u0443\u0432\u0438\u0434\u0438\u0442 \u0438\u0445 \u0442\u0440\u0430\u0444\u0438\u043a.<\/p>\n<h3>4.1. \u041e\u0442\u043a\u043b\u044e\u0447\u0438\u0442\u044c DHCP \u043d\u0430 \u043e\u0441\u043d\u043e\u0432\u043d\u043e\u043c \u0440\u043e\u0443\u0442\u0435\u0440\u0435<\/h3>\n<p>\u041d\u0430 \u043e\u0441\u043d\u043e\u0432\u043d\u043e\u043c \u0440\u043e\u0443\u0442\u0435\u0440\u0435 192.168.0.1 \u043d\u0443\u0436\u043d\u043e \u0432\u044b\u043a\u043b\u044e\u0447\u0438\u0442\u044c DHCP-\u0441\u0435\u0440\u0432\u0435\u0440. \u042d\u0442\u043e \u0434\u0435\u043b\u0430\u0435\u0442\u0441\u044f \u0432 \u0435\u0433\u043e \u0432\u0435\u0431-\u043c\u043e\u0440\u0434\u0435. \u0415\u0441\u043b\u0438 \u043e\u0441\u0442\u0430\u0432\u0438\u0442\u044c \u0434\u0432\u0430 DHCP-\u0441\u0435\u0440\u0432\u0435\u0440\u0430, \u043d\u0430\u0447\u043d\u0435\u0442\u0441\u044f \u043b\u043e\u0442\u0435\u0440\u0435\u044f: \u043e\u0434\u0438\u043d \u043a\u043b\u0438\u0435\u043d\u0442 \u043f\u043e\u043b\u0443\u0447\u0438\u0442 gateway 192.168.0.1, \u0434\u0440\u0443\u0433\u043e\u0439 192.168.0.2.<\/p>\n<blockquote>\n<p><strong>\u0412\u0430\u0436\u043d\u043e:<\/strong> \u041f\u0435\u0440\u0435\u0434 \u043e\u0442\u043a\u043b\u044e\u0447\u0435\u043d\u0438\u0435\u043c DHCP \u0443\u0431\u0435\u0434\u0438\u0442\u0435\u0441\u044c, \u0447\u0442\u043e \u0443 \u0432\u0430\u0441 \u0435\u0441\u0442\u044c \u0434\u043e\u0441\u0442\u0443\u043f \u043a OpenWrt \u0447\u0435\u0440\u0435\u0437 \u043a\u043e\u043d\u0441\u043e\u043b\u044c Proxmox. \u0415\u0441\u043b\u0438 DHCP \u0441\u043b\u043e\u043c\u0430\u0435\u0442\u0441\u044f, \u0432\u044b \u0441\u043c\u043e\u0436\u0435\u0442\u0435 \u0437\u0430\u0439\u0442\u0438 \u0432 VM \u0438 \u043f\u043e\u043f\u0440\u0430\u0432\u0438\u0442\u044c \u043d\u0430\u0441\u0442\u0440\u043e\u0439\u043a\u0438.<\/p>\n<\/blockquote>\n<h3>4.2. \u0412\u043a\u043b\u044e\u0447\u0438\u0442\u044c DHCP \u043d\u0430 wan-\u0438\u043d\u0442\u0435\u0440\u0444\u0435\u0439\u0441\u0435 OpenWrt<\/h3>\n<pre><code class=\"bash\">uci delete dhcp.wan 2&gt;\/dev\/nulluci set dhcp.wan=dhcpuci set dhcp.wan.interface='wan'uci set dhcp.wan.ignore='0'uci set dhcp.wan.start='100'uci set dhcp.wan.limit='100'uci set dhcp.wan.leasetime='12h'uci set dhcp.wan.force='1'uci set dhcp.wan.dynamicdhcp='1'uci delete dhcp.wan.dhcp_option 2&gt;\/dev\/nulluci add_list dhcp.wan.dhcp_option='3,192.168.0.2'uci add_list dhcp.wan.dhcp_option='6,192.168.0.2'uci set dhcp.@dnsmasq[0].authoritative='1'uci set dhcp.@dnsmasq[0].localservice='0'uci set dhcp.@dnsmasq[0].rebind_protection='0'uci commit dhcp\/etc\/init.d\/dnsmasq restart<\/code><div class=\"code-explainer\"><a href=\"https:\/\/sourcecraft.dev\/\" class=\"tm-button code-explainer__link\" style=\"visibility: hidden;\"><img style=\"width:14px;height:14px;object-fit:cover;object-position:left;\"\/><\/a><\/div><\/pre>\n<p>\u041e\u043f\u0446\u0438\u044f 3 \u0432\u044b\u0434\u0430\u0435\u0442 gateway. \u041e\u043f\u0446\u0438\u044f 6 \u0432\u044b\u0434\u0430\u0435\u0442 DNS. \u041f\u043e\u044d\u0442\u043e\u043c\u0443 \u043a\u043b\u0438\u0435\u043d\u0442 \u043f\u043e\u043b\u0443\u0447\u0430\u0435\u0442 \u043d\u0435 \u043f\u0440\u043e\u0441\u0442\u043e \u0430\u0434\u0440\u0435\u0441 \u0438\u0437 \u0434\u0438\u0430\u043f\u0430\u0437\u043e\u043d\u0430, \u0430 \u043f\u043e\u043b\u043d\u043e\u0441\u0442\u044c\u044e \u043f\u0440\u0430\u0432\u0438\u043b\u044c\u043d\u044b\u0439 \u043c\u0430\u0440\u0448\u0440\u0443\u0442 \u0447\u0435\u0440\u0435\u0437 OpenWrt.<\/p>\n<h3>4.3. \u041f\u0440\u043e\u0432\u0435\u0440\u0438\u0442\u044c DHCP<\/h3>\n<pre><code class=\"bash\">logread -e dnsmasqcat \/tmp\/dhcp.leasesnetstat -ulnp | grep ':67'<\/code><div class=\"code-explainer\"><a href=\"https:\/\/sourcecraft.dev\/\" class=\"tm-button code-explainer__link\" style=\"visibility: hidden;\"><img style=\"width:14px;height:14px;object-fit:cover;object-position:left;\"\/><\/a><\/div><\/pre>\n<p>\u041d\u043e\u0440\u043c\u0430\u043b\u044c\u043d\u0430\u044f \u043f\u043e\u0441\u043b\u0435\u0434\u043e\u0432\u0430\u0442\u0435\u043b\u044c\u043d\u043e\u0441\u0442\u044c \u0432\u044b\u0433\u043b\u044f\u0434\u0438\u0442 \u0442\u0430\u043a:<\/p>\n<pre><code class=\"bash\">DHCPDISCOVER(eth0)DHCPOFFER(eth0) 192.168.0.181DHCPREQUEST(eth0)DHCPACK(eth0) 192.168.0.181<\/code><div class=\"code-explainer\"><a href=\"https:\/\/sourcecraft.dev\/\" class=\"tm-button code-explainer__link\" style=\"visibility: hidden;\"><img style=\"width:14px;height:14px;object-fit:cover;object-position:left;\"\/><\/a><\/div><\/pre>\n<p>\u0415\u0441\u043b\u0438 \u0435\u0441\u0442\u044c DISCOVER \u0438 OFFER, \u043d\u043e \u043d\u0435\u0442 REQUEST \u0438 ACK, \u0437\u043d\u0430\u0447\u0438\u0442 OpenWrt \u043e\u0442\u0432\u0435\u0447\u0430\u0435\u0442, \u043d\u043e \u043a\u043b\u0438\u0435\u043d\u0442 \u043d\u0435 \u043f\u0440\u0438\u043d\u0438\u043c\u0430\u0435\u0442 \u043e\u0442\u0432\u0435\u0442. \u0423 \u043c\u0435\u043d\u044f \u0442\u0430\u043a\u043e\u0435 \u0431\u044b\u043b\u043e \u0441 Wi-Fi \u0442\u043e\u0447\u043a\u043e\u0439 \u0434\u043e\u0441\u0442\u0443\u043f\u0430, \u043a\u043e\u0433\u0434\u0430 \u043e\u043d\u0430 \u0431\u044b\u043b\u0430 \u043d\u0435 \u0432 \u0442\u043e\u043c \u0440\u0435\u0436\u0438\u043c\u0435.<\/p>\n<h2>\u0428\u0430\u0433 5. \u041f\u0440\u0438\u0432\u0435\u0441\u0442\u0438 Wi-Fi \u043a \u0440\u0435\u0436\u0438\u043c\u0443 \u0442\u043e\u0447\u043a\u0438 \u0434\u043e\u0441\u0442\u0443\u043f\u0430<\/h2>\n<p>Wi-Fi-\u0440\u043e\u0443\u0442\u0435\u0440 \u0432 \u044d\u0442\u043e\u0439 \u0441\u0445\u0435\u043c\u0435 \u043d\u0435 \u0434\u043e\u043b\u0436\u0435\u043d \u0431\u044b\u0442\u044c \u043e\u0442\u0434\u0435\u043b\u044c\u043d\u044b\u043c \u043c\u0430\u0440\u0448\u0440\u0443\u0442\u0438\u0437\u0430\u0442\u043e\u0440\u043e\u043c. \u041e\u043d \u0434\u043e\u043b\u0436\u0435\u043d \u0431\u044b\u0442\u044c \u043f\u0440\u043e\u0441\u0442\u043e\u0439 \u0442\u043e\u0447\u043a\u043e\u0439 \u0434\u043e\u0441\u0442\u0443\u043f\u0430 \u0432 \u0442\u043e\u0439 \u0436\u0435 \u0441\u0435\u0442\u0438 192.168.0.0\/24.<\/p>\n<ul>\n<li>\n<p>DHCP \u043d\u0430 Wi-Fi-\u0440\u043e\u0443\u0442\u0435\u0440\u0435 \u0432\u044b\u043a\u043b\u044e\u0447\u0435\u043d;<\/p>\n<\/li>\n<li>\n<p>\u043a\u0430\u0431\u0435\u043b\u044c \u0438\u0437 \u043e\u0441\u043d\u043e\u0432\u043d\u043e\u0439 \u0441\u0435\u0442\u0438 \u043f\u043e\u0434\u043a\u043b\u044e\u0447\u0435\u043d \u0432 LAN-\u043f\u043e\u0440\u0442, \u043d\u0435 \u0432 WAN;<\/p>\n<\/li>\n<li>\n<p>Wi-Fi \u0432\u043a\u043b\u044e\u0447\u0435\u043d;<\/p>\n<\/li>\n<li>\n<p>\u043a\u043b\u0438\u0435\u043d\u0442\u044b Wi-Fi \u043f\u043e\u043b\u0443\u0447\u0430\u044e\u0442 IP \u043e\u0442 OpenWrt;<\/p>\n<\/li>\n<li>\n<p>guest network \u0438 client isolation \u043b\u0443\u0447\u0448\u0435 \u0432\u044b\u043a\u043b\u044e\u0447\u0438\u0442\u044c \u043d\u0430 \u0432\u0440\u0435\u043c\u044f \u043f\u0440\u043e\u0432\u0435\u0440\u043a\u0438. \u0415\u0441\u043b\u0438 \u0432\u043e\u0442\u043a\u043d\u0443\u0442\u044c \u043a\u0430\u0431\u0435\u043b\u044c \u0432 WAN-\u043f\u043e\u0440\u0442, Wi-Fi-\u0440\u043e\u0443\u0442\u0435\u0440 \u043c\u043e\u0436\u0435\u0442 \u0441\u043e\u0437\u0434\u0430\u0442\u044c \u043e\u0442\u0434\u0435\u043b\u044c\u043d\u0443\u044e \u043f\u043e\u0434\u0441\u0435\u0442\u044c \u0438 NAT. \u0422\u043e\u0433\u0434\u0430 DHCP-\u0437\u0430\u043f\u0440\u043e\u0441\u044b \u043b\u0438\u0431\u043e \u043d\u0435 \u0434\u043e\u0439\u0434\u0443\u0442 \u0434\u043e OpenWrt, \u043b\u0438\u0431\u043e \u043e\u0442\u0432\u0435\u0442\u044b \u043d\u0435 \u0432\u0435\u0440\u043d\u0443\u0442\u0441\u044f \u043a\u043b\u0438\u0435\u043d\u0442\u0430\u043c. \u0421\u043d\u0430\u0440\u0443\u0436\u0438 \u044d\u0442\u043e \u0432\u044b\u0433\u043b\u044f\u0434\u0438\u0442 \u043a\u0430\u043a \u0431\u0435\u0441\u043a\u043e\u043d\u0435\u0447\u043d\u043e\u0435 \u201c\u041f\u043e\u043b\u0443\u0447\u0435\u043d\u0438\u0435 IP-\u0430\u0434\u0440\u0435\u0441\u0430\u201d.<\/p>\n<\/li>\n<\/ul>\n<h2>\u0428\u0430\u0433 6. \u041f\u0440\u043e\u0432\u0435\u0440\u0438\u0442\u044c, \u0447\u0442\u043e \u043a\u043b\u0438\u0435\u043d\u0442\u044b \u0440\u0435\u0430\u043b\u044c\u043d\u043e \u0438\u0434\u0443\u0442 \u0447\u0435\u0440\u0435\u0437 OpenWrt<\/h2>\n<p>\u041f\u043e\u0441\u043b\u0435 DHCP \u043d\u0430\u0434\u043e \u043f\u0440\u043e\u0432\u0435\u0440\u0438\u0442\u044c \u043c\u0430\u0440\u0448\u0440\u0443\u0442. \u041d\u0430 Windows \u044d\u0442\u043e \u0434\u0435\u043b\u0430\u0435\u0442\u0441\u044f \u0442\u0430\u043a:<\/p>\n<pre><code>tracert 1.1.1.1<\/code><div class=\"code-explainer\"><a href=\"https:\/\/sourcecraft.dev\/\" class=\"tm-button code-explainer__link\" style=\"visibility: hidden;\"><img style=\"width:14px;height:14px;object-fit:cover;object-position:left;\"\/><\/a><\/div><\/pre>\n<p>\u041f\u0435\u0440\u0432\u044b\u043c \u0443\u0437\u043b\u043e\u043c \u0434\u043e\u043b\u0436\u0435\u043d \u0431\u044b\u0442\u044c OpenWrt:<\/p>\n<pre><code class=\"bash\">1  &lt;1 ms  OpenWrt.lan [192.168.0.2]2   1 ms  192.168.0.1<\/code><div class=\"code-explainer\"><a href=\"https:\/\/sourcecraft.dev\/\" class=\"tm-button code-explainer__link\" style=\"visibility: hidden;\"><img style=\"width:14px;height:14px;object-fit:cover;object-position:left;\"\/><\/a><\/div><\/pre>\n<p>\u0415\u0441\u043b\u0438 \u043f\u0435\u0440\u0432\u044b\u043c \u0443\u0437\u043b\u043e\u043c \u0438\u0434\u0435\u0442 \u043e\u0441\u043d\u043e\u0432\u043d\u043e\u0439 \u0440\u043e\u0443\u0442\u0435\u0440 192.168.0.1, \u0434\u0430\u043b\u044c\u0448\u0435 \u043c\u043e\u0436\u043d\u043e \u043d\u0435 \u043f\u0440\u043e\u0434\u043e\u043b\u0436\u0430\u0442\u044c. \u041a\u043b\u0438\u0435\u043d\u0442 \u043e\u0431\u0445\u043e\u0434\u0438\u0442 OpenWrt, \u0437\u043d\u0430\u0447\u0438\u0442 sing-box \u043d\u0438\u0447\u0435\u0433\u043e \u043d\u0435 \u043f\u0435\u0440\u0435\u0445\u0432\u0430\u0442\u0438\u0442.<\/p>\n<p>\u0415\u0449\u0435 \u043f\u043e\u043b\u0435\u0437\u043d\u044b\u0435 \u043f\u0440\u043e\u0432\u0435\u0440\u043a\u0438 \u0441 \u043a\u043b\u0438\u0435\u043d\u0442\u0430:<\/p>\n<pre><code>ping 1.1.1.1nslookup ya.ru 192.168.0.2curl -4 https:\/\/api.ipify.org<\/code><div class=\"code-explainer\"><a href=\"https:\/\/sourcecraft.dev\/\" class=\"tm-button code-explainer__link\" style=\"visibility: hidden;\"><img style=\"width:14px;height:14px;object-fit:cover;object-position:left;\"\/><\/a><\/div><\/pre>\n<p>\u041d\u0430 \u044d\u0442\u043e\u043c \u044d\u0442\u0430\u043f\u0435 \u0438\u043d\u0442\u0435\u0440\u043d\u0435\u0442 \u0434\u043e\u043b\u0436\u0435\u043d \u0440\u0430\u0431\u043e\u0442\u0430\u0442\u044c \u043d\u0430\u043f\u0440\u044f\u043c\u0443\u044e, \u0431\u0435\u0437 sing-box. \u0421\u043d\u0430\u0447\u0430\u043b\u0430 \u0434\u043e\u0431\u0438\u0432\u0430\u0435\u043c\u0441\u044f \u0441\u0442\u0430\u0431\u0438\u043b\u044c\u043d\u043e\u0439 \u0431\u0430\u0437\u044b, \u043f\u043e\u0442\u043e\u043c \u0434\u043e\u0431\u0430\u0432\u043b\u044f\u0435\u043c \u0442\u0443\u043d\u043d\u0435\u043b\u044c.<\/p>\n<h2>\u0428\u0430\u0433 7. \u0423\u0441\u0442\u0430\u043d\u043e\u0432\u0438\u0442\u044c \u043f\u0430\u043a\u0435\u0442\u044b \u0438 \u043f\u043e\u0434\u0433\u043e\u0442\u043e\u0432\u0438\u0442\u044c OpenWrt \u043a \u0440\u0430\u0431\u043e\u0442\u0435<\/h2>\n<p>\u0422\u0435\u043f\u0435\u0440\u044c \u043f\u0435\u0440\u0435\u0445\u043e\u0434\u0438\u043c \u043a \u043f\u0430\u043a\u0435\u0442\u0430\u043c. \u041d\u0430 \u044d\u0442\u043e\u043c \u044d\u0442\u0430\u043f\u0435 \u0431\u0430\u0437\u043e\u0432\u0430\u044f \u0441\u0435\u0442\u044c \u0443\u0436\u0435 \u0434\u043e\u043b\u0436\u043d\u0430 \u0440\u0430\u0431\u043e\u0442\u0430\u0442\u044c: OpenWrt \u0434\u043e\u043b\u0436\u0435\u043d \u043f\u0438\u043d\u0433\u043e\u0432\u0430\u0442\u044c \u0438\u043d\u0442\u0435\u0440\u043d\u0435\u0442, \u0440\u0435\u0437\u043e\u043b\u0432\u0438\u0442\u044c \u0434\u043e\u043c\u0435\u043d\u044b \u0438 \u043e\u0442\u043a\u0440\u044b\u0432\u0430\u0442\u044c\u0441\u044f \u043f\u043e SSH \u0438\u043b\u0438 \u0447\u0435\u0440\u0435\u0437 \u043a\u043e\u043d\u0441\u043e\u043b\u044c Proxmox.<\/p>\n<h3>7.1. \u041f\u0440\u043e\u0432\u0435\u0440\u0438\u0442\u044c \u0438\u043d\u0442\u0435\u0440\u043d\u0435\u0442 \u0438 DNS \u043d\u0430 \u0441\u0430\u043c\u043e\u043c OpenWrt<\/h3>\n<pre><code>ping -c 3 1.1.1.1nslookup downloads.openwrt.orgopkg update<\/code><div class=\"code-explainer\"><a href=\"https:\/\/sourcecraft.dev\/\" class=\"tm-button code-explainer__link\" style=\"visibility: hidden;\"><img style=\"width:14px;height:14px;object-fit:cover;object-position:left;\"\/><\/a><\/div><\/pre>\n<p>\u0415\u0441\u043b\u0438 ping \u043f\u043e IP \u0440\u0430\u0431\u043e\u0442\u0430\u0435\u0442, \u0430 nslookup \u043d\u0435\u0442, \u0441\u043d\u0430\u0447\u0430\u043b\u0430 \u0447\u0438\u043d\u0438\u0442\u0435 DNS. \u0415\u0441\u043b\u0438 opkg update \u043d\u0435 \u0440\u0430\u0431\u043e\u0442\u0430\u0435\u0442, \u043f\u0430\u043a\u0435\u0442\u044b \u0434\u0430\u043b\u044c\u0448\u0435 \u043d\u0435 \u0443\u0441\u0442\u0430\u043d\u043e\u0432\u044f\u0442\u0441\u044f. \u0412 \u0442\u0430\u043a\u043e\u0439 \u0441\u0438\u0442\u0443\u0430\u0446\u0438\u0438 \u043d\u0435\u0442 \u0441\u043c\u044b\u0441\u043b\u0430 \u043f\u0435\u0440\u0435\u0445\u043e\u0434\u0438\u0442\u044c \u043a sing-box.<\/p>\n<h3>7.2. \u041f\u043e\u0441\u0442\u0430\u0432\u0438\u0442\u044c LuCI \u0438 \u0432\u0435\u0431-\u043c\u043e\u0440\u0434\u0443<\/h3>\n<p>\u0412 \u043d\u0435\u043a\u043e\u0442\u043e\u0440\u044b\u0445 \u043e\u0431\u0440\u0430\u0437\u0430\u0445 LuCI \u0443\u0436\u0435 \u0435\u0441\u0442\u044c, \u0432 \u043d\u0435\u043a\u043e\u0442\u043e\u0440\u044b\u0445 \u043d\u0435\u0442. \u042f \u043f\u0440\u0435\u0434\u043f\u043e\u0447\u0438\u0442\u0430\u044e \u044f\u0432\u043d\u043e \u043f\u043e\u0441\u0442\u0430\u0432\u0438\u0442\u044c \u0432\u0435\u0431-\u043c\u043e\u0440\u0434\u0443 \u0438 uhttpd, \u0447\u0442\u043e\u0431\u044b \u043f\u043e\u0442\u043e\u043c \u0443\u043f\u0440\u0430\u0432\u043b\u044f\u0442\u044c OpenWrt \u0447\u0435\u0440\u0435\u0437 \u0431\u0440\u0430\u0443\u0437\u0435\u0440.<\/p>\n<pre><code class=\"bash\">opkg updateopkg install luci luci-ssl uhttpd uhttpd-mod-ubus\/etc\/init.d\/uhttpd enable\/etc\/init.d\/uhttpd restart<\/code><div class=\"code-explainer\"><a href=\"https:\/\/sourcecraft.dev\/\" class=\"tm-button code-explainer__link\" style=\"visibility: hidden;\"><img style=\"width:14px;height:14px;object-fit:cover;object-position:left;\"\/><\/a><\/div><\/pre>\n<p>\u041f\u043e\u0441\u043b\u0435 \u044d\u0442\u043e\u0433\u043e LuCI \u0434\u043e\u043b\u0436\u043d\u0430 \u043e\u0442\u043a\u0440\u044b\u0432\u0430\u0442\u044c\u0441\u044f \u043f\u043e \u0430\u0434\u0440\u0435\u0441\u0443:<\/p>\n<pre><code class=\"bash\">http:\/\/192.168.0.2\/https:\/\/192.168.0.2\/<\/code><div class=\"code-explainer\"><a href=\"https:\/\/sourcecraft.dev\/\" class=\"tm-button code-explainer__link\" style=\"visibility: hidden;\"><img style=\"width:14px;height:14px;object-fit:cover;object-position:left;\"\/><\/a><\/div><\/pre>\n<p>\u0415\u0441\u043b\u0438 \u0432\u0435\u0431-\u043c\u043e\u0440\u0434\u0430 \u043d\u0435 \u043e\u0442\u043a\u0440\u044b\u0432\u0430\u0435\u0442\u0441\u044f, \u043f\u0440\u043e\u0432\u0435\u0440\u044c\u0442\u0435 firewall-\u043f\u0440\u0430\u0432\u0438\u043b\u043e \u0434\u043b\u044f \u043f\u043e\u0440\u0442\u043e\u0432 80\/443 \u0438\u0437 \u0441\u0435\u0442\u0438 192.168.0.0\/24 \u0438 \u0447\u0442\u043e uhttpd \u0434\u0435\u0439\u0441\u0442\u0432\u0438\u0442\u0435\u043b\u044c\u043d\u043e \u0441\u043b\u0443\u0448\u0430\u0435\u0442 \u043f\u043e\u0440\u0442\u044b:<\/p>\n<pre><code class=\"bash\">netstat -lntp | grep -E ':80|:443'\/etc\/init.d\/uhttpd status<\/code><div class=\"code-explainer\"><a href=\"https:\/\/sourcecraft.dev\/\" class=\"tm-button code-explainer__link\" style=\"visibility: hidden;\"><img style=\"width:14px;height:14px;object-fit:cover;object-position:left;\"\/><\/a><\/div><\/pre>\n<h3>7.3. \u0420\u0443\u0441\u0441\u043a\u0438\u0439 \u044f\u0437\u044b\u043a \u0434\u043b\u044f LuCI<\/h3>\n<p>\u0420\u0443\u0441\u0438\u0444\u0438\u043a\u0430\u0446\u0438\u044f \u043d\u0435 \u043e\u0431\u044f\u0437\u0430\u0442\u0435\u043b\u044c\u043d\u0430, \u043d\u043e \u0435\u0441\u043b\u0438 \u0443\u0434\u043e\u0431\u043d\u0435\u0435 \u0440\u0430\u0431\u043e\u0442\u0430\u0442\u044c \u0432 \u0440\u0443\u0441\u0441\u043a\u043e\u0439 \u0432\u0435\u0431-\u043c\u043e\u0440\u0434\u0435, \u043c\u043e\u0436\u043d\u043e \u043f\u043e\u0441\u0442\u0430\u0432\u0438\u0442\u044c \u044f\u0437\u044b\u043a\u043e\u0432\u044b\u0435 \u043f\u0430\u043a\u0435\u0442\u044b. \u041d\u0435 \u0432\u0441\u0435 \u043f\u0430\u043a\u0435\u0442\u044b \u043b\u043e\u043a\u0430\u043b\u0438\u0437\u0430\u0446\u0438\u0438 \u0441\u0443\u0449\u0435\u0441\u0442\u0432\u0443\u044e\u0442 \u0434\u043b\u044f \u043a\u0430\u0436\u0434\u043e\u0439 \u0432\u0435\u0440\u0441\u0438\u0438, \u043f\u043e\u044d\u0442\u043e\u043c\u0443 \u043e\u0448\u0438\u0431\u043a\u0438 \u0432\u0438\u0434\u0430 Unknown package \u0434\u043b\u044f \u043e\u0442\u0434\u0435\u043b\u044c\u043d\u044b\u0445 luci-i18n-* \u043d\u0435 \u0432\u0441\u0435\u0433\u0434\u0430 \u043a\u0440\u0438\u0442\u0438\u0447\u043d\u044b.<\/p>\n<pre><code class=\"bash\">opkg install luci-i18n-base-ru luci-i18n-firewall-ru luci-i18n-uhttpd-ru# \u042d\u0442\u0438 \u043f\u0430\u043a\u0435\u0442\u044b \u0441\u0442\u0430\u0432\u044c\u0442\u0435 \u0442\u043e\u043b\u044c\u043a\u043e \u0435\u0441\u043b\u0438 \u043e\u043d\u0438 \u0435\u0441\u0442\u044c \u0432 \u0432\u0430\u0448\u0435\u0439 \u0432\u0435\u0440\u0441\u0438\u0438 OpenWrt:opkg install luci-i18n-mwan3-ru luci-i18n-pbr-ru 2&gt;\/dev\/null || true<\/code><div class=\"code-explainer\"><a href=\"https:\/\/sourcecraft.dev\/\" class=\"tm-button code-explainer__link\" style=\"visibility: hidden;\"><img style=\"width:14px;height:14px;object-fit:cover;object-position:left;\"\/><\/a><\/div><\/pre>\n<p>\u041f\u043e\u0441\u043b\u0435 \u0443\u0441\u0442\u0430\u043d\u043e\u0432\u043a\u0438 \u044f\u0437\u044b\u043a \u043c\u043e\u0436\u043d\u043e \u0432\u044b\u0431\u0440\u0430\u0442\u044c \u0432 LuCI: System -&gt; System -&gt; Language and Style. \u0415\u0441\u043b\u0438 \u0447\u0430\u0441\u0442\u044c \u043f\u0443\u043d\u043a\u0442\u043e\u0432 \u043e\u0441\u0442\u0430\u043b\u0430\u0441\u044c \u043d\u0430 \u0430\u043d\u0433\u043b\u0438\u0439\u0441\u043a\u043e\u043c, \u0437\u043d\u0430\u0447\u0438\u0442 \u0434\u043b\u044f \u043a\u043e\u043d\u043a\u0440\u0435\u0442\u043d\u043e\u0433\u043e \u043f\u0440\u0438\u043b\u043e\u0436\u0435\u043d\u0438\u044f \u043d\u0435\u0442 ru-\u043f\u0430\u043a\u0435\u0442\u0430 \u0438\u043b\u0438 \u043e\u043d \u043d\u0435 \u0443\u0441\u0442\u0430\u043d\u043e\u0432\u043b\u0435\u043d.<\/p>\n<h3>7.4. \u041f\u043e\u0441\u0442\u0430\u0432\u0438\u0442\u044c \u0431\u0430\u0437\u043e\u0432\u044b\u0435 \u0434\u0438\u0430\u0433\u043d\u043e\u0441\u0442\u0438\u0447\u0435\u0441\u043a\u0438\u0435 \u0443\u0442\u0438\u043b\u0438\u0442\u044b<\/h3>\n<p>\u0411\u0435\u0437 \u0434\u0438\u0430\u0433\u043d\u043e\u0441\u0442\u0438\u0447\u0435\u0441\u043a\u0438\u0445 \u0443\u0442\u0438\u043b\u0438\u0442 \u043e\u0442\u043b\u0430\u0434\u043a\u0430 \u0441\u0435\u0442\u0438 \u043f\u0440\u0435\u0432\u0440\u0430\u0449\u0430\u0435\u0442\u0441\u044f \u0432 \u0433\u0430\u0434\u0430\u043d\u0438\u0435. \u041c\u0438\u043d\u0438\u043c\u0430\u043b\u044c\u043d\u044b\u0439 \u043d\u0430\u0431\u043e\u0440: curl, tcpdump, ip-full, nano \u0438 \u0441\u0435\u0440\u0442\u0438\u0444\u0438\u043a\u0430\u0442\u044b.<\/p>\n<pre><code class=\"bash\">opkg install curl wget nano tcpdump ca-bundle ca-certificatesopkg install ip-full jq htop bind-digopkg install nftables-json 2&gt;\/dev\/null || true<\/code><div class=\"code-explainer\"><a href=\"https:\/\/sourcecraft.dev\/\" class=\"tm-button code-explainer__link\" style=\"visibility: hidden;\"><img style=\"width:14px;height:14px;object-fit:cover;object-position:left;\"\/><\/a><\/div><\/pre>\n<p>\u0414\u043b\u044f \u043f\u0440\u043e\u0432\u0435\u0440\u043a\u0438 DNS \u043c\u043e\u0436\u043d\u043e \u0438\u0441\u043f\u043e\u043b\u044c\u0437\u043e\u0432\u0430\u0442\u044c nslookup \u0438\u043b\u0438 dig. \u0414\u043b\u044f \u043f\u0440\u043e\u0432\u0435\u0440\u043a\u0438 \u0442\u0440\u0430\u0444\u0438\u043a\u0430 DHCP \u0438 TCP \u043e\u0447\u0435\u043d\u044c \u043f\u0440\u0438\u0433\u043e\u0434\u0438\u043b\u0441\u044f tcpdump.<\/p>\n<pre><code class=\"bash\">tcpdump -ni eth0 'port 67 or port 68'tcpdump -ni eth0 'tcp port 443'<\/code><div class=\"code-explainer\"><a href=\"https:\/\/sourcecraft.dev\/\" class=\"tm-button code-explainer__link\" style=\"visibility: hidden;\"><img style=\"width:14px;height:14px;object-fit:cover;object-position:left;\"\/><\/a><\/div><\/pre>\n<h3>7.5. \u041f\u043e\u0441\u0442\u0430\u0432\u0438\u0442\u044c sing-box<\/h3>\n<p>\u0413\u043b\u0430\u0432\u043d\u044b\u0439 \u043f\u0430\u043a\u0435\u0442 \u0434\u043b\u044f \u044d\u0442\u043e\u0439 \u0441\u0445\u0435\u043c\u044b &#8212; sing-box. \u0412 \u043c\u043e\u0435\u043c \u0441\u043b\u0443\u0447\u0430\u0435 \u043e\u043d \u0441\u0442\u0430\u0432\u0438\u043b\u0441\u044f \u0438\u0437 opkg.<\/p>\n<pre><code class=\"bash\">opkg install sing-boxwhich sing-boxsing-box version<\/code><div class=\"code-explainer\"><a href=\"https:\/\/sourcecraft.dev\/\" class=\"tm-button code-explainer__link\" style=\"visibility: hidden;\"><img style=\"width:14px;height:14px;object-fit:cover;object-position:left;\"\/><\/a><\/div><\/pre>\n<p>\u0415\u0441\u043b\u0438 \u043f\u0430\u043a\u0435\u0442 sing-box \u043d\u0435 \u043d\u0430\u0439\u0434\u0435\u043d, \u0437\u043d\u0430\u0447\u0438\u0442 \u0432 \u0432\u0430\u0448\u0435\u0439 \u0441\u0431\u043e\u0440\u043a\u0435\/\u0440\u0435\u043f\u043e\u0437\u0438\u0442\u043e\u0440\u0438\u044f\u0445 \u0435\u0433\u043e \u043d\u0435\u0442. \u0422\u043e\u0433\u0434\u0430 \u0432\u0430\u0440\u0438\u0430\u043d\u0442\u044b \u0442\u0430\u043a\u0438\u0435: \u043f\u043e\u0434\u043a\u043b\u044e\u0447\u0438\u0442\u044c \u043f\u043e\u0434\u0445\u043e\u0434\u044f\u0449\u0438\u0439 feed, \u0438\u0441\u043f\u043e\u043b\u044c\u0437\u043e\u0432\u0430\u0442\u044c \u043f\u0430\u043a\u0435\u0442 \u0438\u0437 \u0441\u0442\u043e\u0440\u043e\u043d\u043d\u0435\u0433\u043e \u0440\u0435\u043f\u043e\u0437\u0438\u0442\u043e\u0440\u0438\u044f \u043f\u043e\u0434 \u0432\u0430\u0448\u0443 \u0432\u0435\u0440\u0441\u0438\u044e OpenWrt \u0438\u043b\u0438 \u0441\u043e\u0431\u0440\u0430\u0442\u044c \u043e\u0431\u0440\u0430\u0437 \u0441 sing-box \u0437\u0430\u0440\u0430\u043d\u0435\u0435. \u041d\u043e \u0432 \u0441\u0442\u0430\u0442\u044c\u0435 \u0434\u0430\u043b\u044c\u0448\u0435 \u0441\u0447\u0438\u0442\u0430\u0435\u043c, \u0447\u0442\u043e \u043a\u043e\u043c\u0430\u043d\u0434\u0430 sing-box version \u0443\u0436\u0435 \u0440\u0430\u0431\u043e\u0442\u0430\u0435\u0442.<\/p>\n<blockquote>\n<p><strong>\u0412\u0430\u0436\u043d\u043e:<\/strong> \u041d\u0435 \u0441\u043c\u0435\u0448\u0438\u0432\u0430\u0439\u0442\u0435 \u0431\u0435\u0437 \u043d\u0435\u043e\u0431\u0445\u043e\u0434\u0438\u043c\u043e\u0441\u0442\u0438 \u043d\u0435\u0441\u043a\u043e\u043b\u044c\u043a\u043e \u0431\u043e\u043b\u044c\u0448\u0438\u0445 LuCI-\u043d\u0430\u0434\u0441\u0442\u0440\u043e\u0435\u043a \u0432\u0440\u043e\u0434\u0435 PassWall\/HomeProxy\/Momo \u0441 \u0443\u0436\u0435 \u0441\u043e\u0431\u0440\u0430\u043d\u043d\u043e\u0439 \u0432\u0440\u0443\u0447\u043d\u0443\u044e \u0441\u0445\u0435\u043c\u043e\u0439. \u041e\u043d\u0438 \u043c\u043e\u0433\u0443\u0442 \u0441\u043e\u0437\u0434\u0430\u0442\u044c \u0441\u0432\u043e\u0438 firewall\/nft-\u043f\u0440\u0430\u0432\u0438\u043b\u0430 \u0438 \u0437\u0430\u0442\u0435\u0440\u0435\u0442\u044c \u043d\u0430\u0448\u0443 \u043b\u043e\u0433\u0438\u043a\u0443 redirect.<\/p>\n<\/blockquote>\n<h3>7.6. \u041f\u043e\u0441\u0442\u0430\u0432\u0438\u0442\u044c WireGuard \u043d\u0430 \u0431\u0443\u0434\u0443\u0449\u0435\u0435<\/h3>\n<p>WireGuard \u043d\u0435 \u043d\u0443\u0436\u0435\u043d \u0434\u043b\u044f \u0431\u0430\u0437\u043e\u0432\u043e\u0433\u043e \u0437\u0430\u0432\u043e\u0440\u043e\u0442\u0430 \u043b\u043e\u043a\u0430\u043b\u044c\u043d\u044b\u0445 \u043a\u043b\u0438\u0435\u043d\u0442\u043e\u0432 \u0447\u0435\u0440\u0435\u0437 sing-box, \u043d\u043e \u043f\u0440\u0438\u0433\u043e\u0434\u0438\u0442\u0441\u044f \u0434\u043b\u044f \u0441\u043b\u0435\u0434\u0443\u044e\u0449\u0435\u0433\u043e \u044d\u0442\u0430\u043f\u0430: \u043f\u043e\u0434\u043a\u043b\u044e\u0447\u0430\u0442\u044c \u0432\u043d\u0435\u0448\u043d\u0438\u0435 \u0441\u0435\u0442\u0438 \u0438\u043b\u0438 MikroTik \u0447\u0435\u0440\u0435\u0437 \u0438\u043d\u0442\u0435\u0440\u043d\u0435\u0442.<\/p>\n<pre><code class=\"bash\">opkg install kmod-wireguard wireguard-tools luci-proto-wireguard<\/code><div class=\"code-explainer\"><a href=\"https:\/\/sourcecraft.dev\/\" class=\"tm-button code-explainer__link\" style=\"visibility: hidden;\"><img style=\"width:14px;height:14px;object-fit:cover;object-position:left;\"\/><\/a><\/div><\/pre>\n<p>\u041f\u0440\u043e\u0432\u0435\u0440\u043a\u0430:<\/p>\n<pre><code class=\"bash\">wg --versionmodinfo wireguard 2&gt;\/dev\/null | head || true<\/code><div class=\"code-explainer\"><a href=\"https:\/\/sourcecraft.dev\/\" class=\"tm-button code-explainer__link\" style=\"visibility: hidden;\"><img style=\"width:14px;height:14px;object-fit:cover;object-position:left;\"\/><\/a><\/div><\/pre>\n<h3>7.7. \u041f\u043e\u0441\u0442\u0430\u0432\u0438\u0442\u044c mwan3\/pbr \u0442\u043e\u043b\u044c\u043a\u043e \u0435\u0441\u043b\u0438 \u043f\u043b\u0430\u043d\u0438\u0440\u0443\u0435\u0442\u0435 \u043d\u0435\u0441\u043a\u043e\u043b\u044c\u043a\u043e WAN<\/h3>\n<p>\u0418\u0437\u043d\u0430\u0447\u0430\u043b\u044c\u043d\u043e \u0445\u043e\u0442\u0435\u043b\u043e\u0441\u044c \u043f\u043e\u043f\u0440\u043e\u0431\u043e\u0432\u0430\u0442\u044c mwan3 \u0438 pbr \u0434\u043b\u044f \u043d\u0435\u0441\u043a\u043e\u043b\u044c\u043a\u0438\u0445 \u0442\u0443\u043d\u043d\u0435\u043b\u0435\u0439 \u0438 policy routing. \u0412 \u0444\u0438\u043d\u0430\u043b\u044c\u043d\u043e\u0439 \u0440\u0430\u0431\u043e\u0447\u0435\u0439 \u0441\u0445\u0435\u043c\u0435 \u0434\u043b\u044f TCP redirect \u043e\u043d\u0438 \u043d\u0435 \u043e\u0431\u044f\u0437\u0430\u0442\u0435\u043b\u044c\u043d\u044b. \u041d\u043e \u0435\u0441\u043b\u0438 \u0434\u0430\u043b\u044c\u0448\u0435 \u0431\u0443\u0434\u0435\u0442\u0435 \u0431\u0430\u043b\u0430\u043d\u0441\u0438\u0440\u043e\u0432\u0430\u0442\u044c \u043d\u0435\u0441\u043a\u043e\u043b\u044c\u043a\u043e WAN \u0438\u043b\u0438 VPN, \u0438\u0445 \u043c\u043e\u0436\u043d\u043e \u043f\u043e\u0441\u0442\u0430\u0432\u0438\u0442\u044c \u043e\u0442\u0434\u0435\u043b\u044c\u043d\u043e.<\/p>\n<pre><code class=\"bash\">opkg install mwan3 luci-app-mwan3 pbr luci-app-pbr<\/code><div class=\"code-explainer\"><a href=\"https:\/\/sourcecraft.dev\/\" class=\"tm-button code-explainer__link\" style=\"visibility: hidden;\"><img style=\"width:14px;height:14px;object-fit:cover;object-position:left;\"\/><\/a><\/div><\/pre>\n<p>\u0415\u0441\u043b\u0438 pbr \u043f\u043e\u0441\u043b\u0435 \u0443\u0441\u0442\u0430\u043d\u043e\u0432\u043a\u0438 \u043f\u0438\u0448\u0435\u0442, \u0447\u0442\u043e \u0441\u0435\u0440\u0432\u0438\u0441 disabled \u0438\u043b\u0438 \u043d\u0435 \u0441\u0442\u0430\u0440\u0442\u0443\u0435\u0442, \u044d\u0442\u043e \u043d\u0435 \u0441\u0442\u0440\u0430\u0448\u043d\u043e \u0434\u043b\u044f \u0442\u0435\u043a\u0443\u0449\u0435\u0439 \u0441\u0442\u0430\u0442\u044c\u0438. \u041c\u044b \u0432 \u0444\u0438\u043d\u0430\u043b\u044c\u043d\u043e\u0439 \u0441\u0445\u0435\u043c\u0435 \u043d\u0435 \u043e\u043f\u0438\u0440\u0430\u0435\u043c\u0441\u044f \u043d\u0430 pbr. \u0412\u0430\u0436\u043d\u043e \u043d\u0435 \u043f\u044b\u0442\u0430\u0442\u044c\u0441\u044f \u0447\u0438\u043d\u0438\u0442\u044c \u0441\u0440\u0430\u0437\u0443 \u0432\u0441\u0435 \u043f\u043e\u0434\u0440\u044f\u0434: \u0441\u043d\u0430\u0447\u0430\u043b\u0430 \u0431\u0430\u0437\u043e\u0432\u044b\u0439 gateway, \u043f\u043e\u0442\u043e\u043c DHCP, \u043f\u043e\u0442\u043e\u043c sing-box redirect.<\/p>\n<h3>7.8. \u0417\u0430\u0444\u0438\u043a\u0441\u0438\u0440\u043e\u0432\u0430\u0442\u044c \u0441\u043e\u0441\u0442\u043e\u044f\u043d\u0438\u0435 \u043f\u0435\u0440\u0435\u0434 sing-box<\/h3>\n<p>\u041f\u0435\u0440\u0435\u0434 \u043f\u0435\u0440\u0435\u0445\u043e\u0434\u043e\u043c \u043a Xray \u0438 \u043f\u0440\u043e\u0437\u0440\u0430\u0447\u043d\u043e\u043c\u0443 redirect \u043f\u043e\u043b\u0435\u0437\u043d\u043e \u0441\u043e\u0445\u0440\u0430\u043d\u0438\u0442\u044c \u0442\u0435\u043a\u0443\u0449\u0435\u0435 \u0441\u043e\u0441\u0442\u043e\u044f\u043d\u0438\u0435. \u041d\u0430 Proxmox \u043c\u043e\u0436\u043d\u043e \u0441\u0434\u0435\u043b\u0430\u0442\u044c snapshot VM. \u041d\u0430 \u0441\u0430\u043c\u043e\u043c OpenWrt \u043c\u043e\u0436\u043d\u043e \u0441\u043e\u0445\u0440\u0430\u043d\u0438\u0442\u044c \u043a\u043e\u043d\u0444\u0438\u0433\u0438 \u0432 \u043e\u0442\u0434\u0435\u043b\u044c\u043d\u044b\u0439 \u043a\u0430\u0442\u0430\u043b\u043e\u0433.<\/p>\n<pre><code class=\"bash\">mkdir -p \/root\/backup-before-singboxcp \/etc\/config\/network \/root\/backup-before-singbox\/networkcp \/etc\/config\/firewall \/root\/backup-before-singbox\/firewallcp \/etc\/config\/dhcp \/root\/backup-before-singbox\/dhcpuci show network &gt; \/root\/backup-before-singbox\/network.uci.txtuci show firewall &gt; \/root\/backup-before-singbox\/firewall.uci.txtuci show dhcp &gt; \/root\/backup-before-singbox\/dhcp.uci.txt<\/code><div class=\"code-explainer\"><a href=\"https:\/\/sourcecraft.dev\/\" class=\"tm-button code-explainer__link\" style=\"visibility: hidden;\"><img style=\"width:14px;height:14px;object-fit:cover;object-position:left;\"\/><\/a><\/div><\/pre>\n<p>\u042d\u0442\u043e \u043d\u0435 \u0437\u0430\u043c\u0435\u043d\u044f\u0435\u0442 snapshot, \u043d\u043e \u043f\u043e\u043c\u043e\u0433\u0430\u0435\u0442 \u0431\u044b\u0441\u0442\u0440\u043e \u0441\u0440\u0430\u0432\u043d\u0438\u0442\u044c, \u0447\u0442\u043e \u043f\u043e\u043c\u0435\u043d\u044f\u043b\u043e\u0441\u044c \u043f\u043e\u0441\u043b\u0435 \u0441\u0435\u0440\u0438\u0438 \u043a\u043e\u043c\u0430\u043d\u0434.<\/p>\n<h2>\u0428\u0430\u0433 8. \u0421\u043d\u0430\u0447\u0430\u043b\u0430 \u043f\u0440\u043e\u0432\u0435\u0440\u0438\u0442\u044c Xray\/VLESS \u043e\u0442\u0434\u0435\u043b\u044c\u043d\u043e<\/h2>\n<p>\u0421\u0430\u043c\u0430\u044f \u0431\u043e\u043b\u044c\u0448\u0430\u044f \u043e\u0448\u0438\u0431\u043a\u0430 \u0432 \u0442\u0430\u043a\u0438\u0445 \u0441\u0445\u0435\u043c\u0430\u0445: \u0441\u0440\u0430\u0437\u0443 \u0432\u043a\u043b\u044e\u0447\u0438\u0442\u044c \u043f\u0440\u043e\u0437\u0440\u0430\u0447\u043d\u044b\u0439 \u0440\u0435\u0436\u0438\u043c \u0438 \u043f\u043e\u0442\u043e\u043c \u0433\u0430\u0434\u0430\u0442\u044c, \u0447\u0442\u043e \u0438\u043c\u0435\u043d\u043d\u043e \u0441\u043b\u043e\u043c\u0430\u043b\u043e\u0441\u044c. \u041f\u043e\u044d\u0442\u043e\u043c\u0443 \u0441\u043d\u0430\u0447\u0430\u043b\u0430 \u043f\u0440\u043e\u0432\u0435\u0440\u044f\u0435\u043c \u0441\u0430\u043c outbound \u0447\u0435\u0440\u0435\u0437 \u043b\u043e\u043a\u0430\u043b\u044c\u043d\u044b\u0439 SOCKS\/mixed proxy.<\/p>\n<p>\u0412\u0440\u0435\u043c\u0435\u043d\u043d\u044b\u0439 \u043a\u043e\u043d\u0444\u0438\u0433 \u0434\u043b\u044f \u043f\u0440\u043e\u0432\u0435\u0440\u043a\u0438 \u043c\u043e\u0436\u043d\u043e \u0441\u0434\u0435\u043b\u0430\u0442\u044c \u0442\u0430\u043a:<\/p>\n<pre><code class=\"bash\">cat &gt; \/etc\/sing-box\/config-test-mixed.json &lt;&lt;'EOF'{  \"log\": {    \"level\": \"info\",    \"timestamp\": true  },  \"inbounds\": [    {      \"type\": \"mixed\",      \"tag\": \"mixed-in\",      \"listen\": \"127.0.0.1\",      \"listen_port\": 2080    }  ],  \"outbounds\": [    {      \"type\": \"direct\",      \"tag\": \"direct\"    },    {      \"type\": \"vless\",      \"tag\": \"amnezia-xray\",      \"server\": \"&lt;XRAY_SERVER_IP&gt;\",      \"server_port\": 443,      \"uuid\": \"&lt;UUID&gt;\",      \"flow\": \"xtls-rprx-vision\",      \"tls\": {        \"enabled\": true,        \"server_name\": \"www.googletagmanager.com\",        \"utls\": {          \"enabled\": true,          \"fingerprint\": \"chrome\"        },        \"reality\": {          \"enabled\": true,          \"public_key\": \"&lt;REALITY_PUBLIC_KEY&gt;\",          \"short_id\": \"&lt;REALITY_SHORT_ID&gt;\"        }      },      \"packet_encoding\": \"xudp\"    }  ],  \"route\": {    \"final\": \"amnezia-xray\"  }}EOFsing-box check -c \/etc\/sing-box\/config-test-mixed.jsonsing-box run -c \/etc\/sing-box\/config-test-mixed.json<\/code><div class=\"code-explainer\"><a href=\"https:\/\/sourcecraft.dev\/\" class=\"tm-button code-explainer__link\" style=\"visibility: hidden;\"><img style=\"width:14px;height:14px;object-fit:cover;object-position:left;\"\/><\/a><\/div><\/pre>\n<p>\u0412 \u0434\u0440\u0443\u0433\u043e\u043c \u043e\u043a\u043d\u0435 \u043f\u0440\u043e\u0432\u0435\u0440\u044f\u0435\u043c:<\/p>\n<pre><code class=\"bash\">curl -4 https:\/\/ifconfig.mecurl -4 -x socks5h:\/\/127.0.0.1:2080 https:\/\/ifconfig.me<\/code><div class=\"code-explainer\"><a href=\"https:\/\/sourcecraft.dev\/\" class=\"tm-button code-explainer__link\" style=\"visibility: hidden;\"><img style=\"width:14px;height:14px;object-fit:cover;object-position:left;\"\/><\/a><\/div><\/pre>\n<p>\u041f\u0435\u0440\u0432\u044b\u0439 \u0437\u0430\u043f\u0440\u043e\u0441 \u0434\u043e\u043b\u0436\u0435\u043d \u043f\u043e\u043a\u0430\u0437\u0430\u0442\u044c \u043f\u0440\u044f\u043c\u043e\u0439 IP \u043f\u0440\u043e\u0432\u0430\u0439\u0434\u0435\u0440\u0430. \u0412\u0442\u043e\u0440\u043e\u0439 \u0434\u043e\u043b\u0436\u0435\u043d \u043f\u043e\u043a\u0430\u0437\u0430\u0442\u044c IP \u0442\u0443\u043d\u043d\u0435\u043b\u044f. \u0415\u0441\u043b\u0438 \u0442\u0430\u043a \u0438 \u0435\u0441\u0442\u044c, Xray\/VLESS \u0436\u0438\u0432\u043e\u0439. \u0414\u0430\u043b\u044c\u0448\u0435 \u043f\u0440\u043e\u0431\u043b\u0435\u043c\u044b \u0431\u0443\u0434\u0443\u0442 \u0443\u0436\u0435 \u0432 DNS, firewall, nftables \u0438\u043b\u0438 \u043f\u0440\u0430\u0432\u0438\u043b\u0430\u0445 \u043c\u0430\u0440\u0448\u0440\u0443\u0442\u0438\u0437\u0430\u0446\u0438\u0438.<\/p>\n<h2>\u0428\u0430\u0433 9. \u041f\u043e\u0447\u0435\u043c\u0443 \u044f \u043d\u0435 \u043e\u0441\u0442\u0430\u0432\u0438\u043b TUN<\/h2>\n<p>\u041f\u0435\u0440\u0432\u043e\u0439 \u043f\u043e\u043f\u044b\u0442\u043a\u043e\u0439 \u0431\u044b\u043b TUN-\u0440\u0435\u0436\u0438\u043c sing-box. \u041e\u043d \u0432\u044b\u0433\u043b\u044f\u0434\u0438\u0442 \u0437\u0430\u043c\u0430\u043d\u0447\u0438\u0432\u043e: \u0432\u043a\u043b\u044e\u0447\u0430\u0435\u0448\u044c auto_route \u0438 auto_redirect, \u0430 sing-box \u0441\u0430\u043c \u0441\u043e\u0437\u0434\u0430\u0435\u0442 \u0438\u043d\u0442\u0435\u0440\u0444\u0435\u0439\u0441 \u0438 \u043f\u0440\u0430\u0432\u0438\u043b\u0430.<\/p>\n<pre><code class=\"json\">{  \"type\": \"tun\",  \"auto_route\": true,  \"auto_redirect\": true}<\/code><div class=\"code-explainer\"><a href=\"https:\/\/sourcecraft.dev\/\" class=\"tm-button code-explainer__link\" style=\"visibility: hidden;\"><img style=\"width:14px;height:14px;object-fit:cover;object-position:left;\"\/><\/a><\/div><\/pre>\n<p>\u041d\u043e \u0432 \u043c\u043e\u0435\u0439 \u0441\u0445\u0435\u043c\u0435 \u044d\u0442\u043e \u043d\u0430\u0447\u0430\u043b\u043e \u043b\u043e\u043c\u0430\u0442\u044c DNS \u0438 \u043b\u043e\u0432\u0438\u0442\u044c \u0442\u0440\u0430\u0444\u0438\u043a \u0441\u0430\u043c\u043e\u0433\u043e OpenWrt. \u0412 \u043b\u043e\u0433\u0430\u0445 \u043f\u043e\u044f\u0432\u043b\u044f\u043b\u0438\u0441\u044c \u043f\u043e\u0434\u043a\u043b\u044e\u0447\u0435\u043d\u0438\u044f \u043e\u0442 192.168.0.2. \u042d\u0442\u043e \u0430\u0434\u0440\u0435\u0441 \u0441\u0430\u043c\u043e\u0433\u043e OpenWrt, \u0430 \u043d\u0435 \u043a\u043b\u0438\u0435\u043d\u0442\u0430.<\/p>\n<pre><code class=\"bash\">inbound\/tun[tun-in]: inbound packet connection from 192.168.0.2<\/code><div class=\"code-explainer\"><a href=\"https:\/\/sourcecraft.dev\/\" class=\"tm-button code-explainer__link\" style=\"visibility: hidden;\"><img style=\"width:14px;height:14px;object-fit:cover;object-position:left;\"\/><\/a><\/div><\/pre>\n<p>\u0421\u043d\u0430\u0440\u0443\u0436\u0438 \u044d\u0442\u043e \u0432\u044b\u0433\u043b\u044f\u0434\u0435\u043b\u043e \u043a\u0430\u043a \u043a\u043b\u0430\u0441\u0441\u0438\u0447\u0435\u0441\u043a\u0438\u0439 \u0441\u0435\u0442\u0435\u0432\u043e\u0439 \u0430\u0434: \u0443 \u043a\u043b\u0438\u0435\u043d\u0442\u043e\u0432 DNS_PROBE_FINISHED_NO_INTERNET, \u0433\u0434\u0435-\u0442\u043e ERR_CONNECTION_REFUSED, \u0433\u0434\u0435-\u0442\u043e \u0434\u043e\u043c\u0435\u043d \u0440\u0435\u0437\u043e\u043b\u0432\u0438\u0442\u0441\u044f, \u043d\u043e \u043d\u0435 \u043e\u0442\u043a\u0440\u044b\u0432\u0430\u0435\u0442\u0441\u044f. \u041f\u0440\u0438 \u044d\u0442\u043e\u043c SOCKS-\u043f\u0440\u043e\u0432\u0435\u0440\u043a\u0430 \u043f\u043e\u043a\u0430\u0437\u044b\u0432\u0430\u043b\u0430, \u0447\u0442\u043e \u0441\u0430\u043c Xray \u0440\u0430\u0431\u043e\u0442\u0430\u0435\u0442.<\/p>\n<p>\u041f\u043e\u0441\u043b\u0435 \u044d\u0442\u043e\u0433\u043e \u044f \u0443\u043f\u0440\u043e\u0441\u0442\u0438\u043b \u0441\u0445\u0435\u043c\u0443: \u043d\u0435 \u043f\u044b\u0442\u0430\u0442\u044c\u0441\u044f \u043f\u0435\u0440\u0435\u0445\u0432\u0430\u0442\u044b\u0432\u0430\u0442\u044c \u0432\u0441\u0435 \u0447\u0435\u0440\u0435\u0437 TUN, \u0430 \u044f\u0432\u043d\u043e \u043f\u0435\u0440\u0435\u043d\u0430\u043f\u0440\u0430\u0432\u043b\u044f\u0442\u044c TCP-\u0442\u0440\u0430\u0444\u0438\u043a \u043a\u043b\u0438\u0435\u043d\u0442\u043e\u0432 \u043d\u0430 \u043b\u043e\u043a\u0430\u043b\u044c\u043d\u044b\u0439 \u043f\u043e\u0440\u0442 sing-box.<\/p>\n<h2>\u0428\u0430\u0433 10. \u0420\u0430\u0431\u043e\u0447\u0438\u0439 \u0432\u0430\u0440\u0438\u0430\u043d\u0442: TCP redirect<\/h2>\n<figure class=\"\"><img decoding=\"async\" src=\"https:\/\/habrastorage.org\/r\/w1560\/webt\/15\/98\/21\/159821938176a6722023316cfd8083d6.png\" sizes=\"(max-width: 780px) 100vw, 50vw\" srcset=\"https:\/\/habrastorage.org\/r\/w780\/webt\/15\/98\/21\/159821938176a6722023316cfd8083d6.png 780w,&#10;       https:\/\/habrastorage.org\/r\/w1560\/webt\/15\/98\/21\/159821938176a6722023316cfd8083d6.png 781w\" loading=\"lazy\" decode=\"async\"\/><\/figure>\n<p><em>\u0420\u0438\u0441\u0443\u043d\u043e\u043a 3. \u0420\u0430\u0431\u043e\u0447\u0438\u0439 \u0437\u0430\u0432\u043e\u0440\u043e\u0442: nftables \u043f\u0435\u0440\u0435\u043d\u0430\u043f\u0440\u0430\u0432\u043b\u044f\u0435\u0442 TCP \u043d\u0430 sing-box, \u0430 sing-box \u0432\u044b\u0431\u0438\u0440\u0430\u0435\u0442 direct \u0438\u043b\u0438 \u0442\u0443\u043d\u043d\u0435\u043b\u044c.<\/em> <\/p>\n<p>\u0420\u0430\u0431\u043e\u0447\u0430\u044f \u043b\u043e\u0433\u0438\u043a\u0430 \u0442\u0430\u043a\u0430\u044f: \u043a\u043b\u0438\u0435\u043d\u0442 \u0434\u0435\u043b\u0430\u0435\u0442 TCP-\u0437\u0430\u043f\u0440\u043e\u0441, nftables \u043d\u0430 OpenWrt \u043f\u0435\u0440\u0435\u043d\u0430\u043f\u0440\u0430\u0432\u043b\u044f\u0435\u0442 \u0435\u0433\u043e \u043d\u0430 \u043b\u043e\u043a\u0430\u043b\u044c\u043d\u044b\u0439 \u043f\u043e\u0440\u0442 7892, sing-box \u043f\u0440\u0438\u043d\u0438\u043c\u0430\u0435\u0442 \u0441\u043e\u0435\u0434\u0438\u043d\u0435\u043d\u0438\u0435 \u0447\u0435\u0440\u0435\u0437 redirect inbound, \u0447\u0435\u0440\u0435\u0437 sniff \u043e\u043f\u0440\u0435\u0434\u0435\u043b\u044f\u0435\u0442 \u0434\u043e\u043c\u0435\u043d \u0438 \u043f\u0440\u0438\u043c\u0435\u043d\u044f\u0435\u0442 route rules.<\/p>\n<h3>10.1. \u0424\u0438\u043d\u0430\u043b\u044c\u043d\u044b\u0439 inbound sing-box<\/h3>\n<p>\u0412\u043d\u0443\u0442\u0440\u0438 sing-box \u043d\u0443\u0436\u0435\u043d redirect inbound:<\/p>\n<pre><code class=\"json\">\"inbounds\": [  {    \"type\": \"redirect\",    \"tag\": \"redirect-in\",    \"listen\": \"0.0.0.0\",    \"listen_port\": 7892,    \"sniff\": true,    \"sniff_override_destination\": true  }]<\/code><div class=\"code-explainer\"><a href=\"https:\/\/sourcecraft.dev\/\" class=\"tm-button code-explainer__link\" style=\"visibility: hidden;\"><img style=\"width:14px;height:14px;object-fit:cover;object-position:left;\"\/><\/a><\/div><\/pre>\n<p>sniff \u043d\u0443\u0436\u0435\u043d, \u0447\u0442\u043e\u0431\u044b sing-box \u043c\u043e\u0433 \u043f\u043e\u043d\u044f\u0442\u044c \u0434\u043e\u043c\u0435\u043d \u0438\u0437 TLS\/SNI. \u0411\u0435\u0437 \u044d\u0442\u043e\u0433\u043e \u0434\u043e\u043c\u0435\u043d\u043d\u044b\u0435 \u043f\u0440\u0430\u0432\u0438\u043b\u0430 \u0431\u0443\u0434\u0443\u0442 \u0440\u0430\u0431\u043e\u0442\u0430\u0442\u044c \u0445\u0443\u0436\u0435, \u043f\u043e\u0442\u043e\u043c\u0443 \u0447\u0442\u043e \u043f\u043e\u0441\u043b\u0435 redirect \u0441\u043e\u0435\u0434\u0438\u043d\u0435\u043d\u0438\u0435 \u043f\u0440\u0438\u0445\u043e\u0434\u0438\u0442 \u043a\u0430\u043a TCP-\u0441\u043e\u0435\u0434\u0438\u043d\u0435\u043d\u0438\u0435 \u043d\u0430 IP.<\/p>\n<h2>\u0428\u0430\u0433 11. \u0421\u043e\u0431\u0440\u0430\u0442\u044c \u043e\u0441\u043d\u043e\u0432\u043d\u043e\u0439 config.json \u0434\u043b\u044f sing-box<\/h2>\n<p>\u041d\u0438\u0436\u0435 \u043f\u0440\u0438\u043c\u0435\u0440 \u043f\u043e\u043b\u043d\u043e\u0433\u043e \u043a\u043e\u043d\u0444\u0438\u0433\u0430. \u041e\u043d \u0441\u043f\u0435\u0446\u0438\u0430\u043b\u044c\u043d\u043e \u0441\u043e\u0434\u0435\u0440\u0436\u0438\u0442 \u043f\u043b\u0435\u0439\u0441\u0445\u043e\u043b\u0434\u0435\u0440\u044b. \u0412 \u0440\u0435\u0430\u043b\u044c\u043d\u043e\u043c \u0444\u0430\u0439\u043b\u0435 \u043d\u0443\u0436\u043d\u043e \u0437\u0430\u043c\u0435\u043d\u0438\u0442\u044c &lt;XRAY_SERVER_IP&gt;, , &lt;REALITY_PUBLIC_KEY&gt; \u0438 &lt;REALITY_SHORT_ID&gt; \u043d\u0430 \u0441\u0432\u043e\u0438 \u0437\u043d\u0430\u0447\u0435\u043d\u0438\u044f.<\/p>\n<pre><code class=\"bash\">cat &gt; \/etc\/sing-box\/config.json &lt;&lt;'EOF'{  \"log\": {    \"level\": \"info\",    \"timestamp\": true  },  \"inbounds\": [    {      \"type\": \"redirect\",      \"tag\": \"redirect-in\",      \"listen\": \"0.0.0.0\",      \"listen_port\": 7892,      \"sniff\": true,      \"sniff_override_destination\": true    }  ],  \"outbounds\": [    {      \"type\": \"direct\",      \"tag\": \"direct\",      \"bind_interface\": \"eth0\"    },    {      \"type\": \"vless\",      \"tag\": \"amnezia-xray\",      \"server\": \"&lt;XRAY_SERVER_IP&gt;\",      \"server_port\": 443,      \"uuid\": \"&lt;UUID&gt;\",      \"flow\": \"xtls-rprx-vision\",      \"bind_interface\": \"eth0\",      \"tls\": {        \"enabled\": true,        \"server_name\": \"www.googletagmanager.com\",        \"utls\": {          \"enabled\": true,          \"fingerprint\": \"chrome\"        },        \"reality\": {          \"enabled\": true,          \"public_key\": \"&lt;REALITY_PUBLIC_KEY&gt;\",          \"short_id\": \"&lt;REALITY_SHORT_ID&gt;\"        }      },      \"packet_encoding\": \"xudp\"    }  ],  \"route\": {    \"rules\": [      {        \"ip_is_private\": true,        \"outbound\": \"direct\"      },      {        \"ip_cidr\": [          \"&lt;XRAY_SERVER_IP&gt;\/32\",          \"192.168.0.1\/32\",          \"192.168.0.2\/32\"        ],        \"outbound\": \"direct\"      },      {        \"ip_cidr\": [          \"91.108.4.0\/22\",          \"91.108.8.0\/22\",          \"91.108.12.0\/22\",          \"91.108.16.0\/22\",          \"91.108.20.0\/22\",          \"91.108.56.0\/22\",          \"91.105.192.0\/23\",          \"149.154.160.0\/20\",          \"185.76.151.0\/24\"        ],        \"outbound\": \"amnezia-xray\"      },      {        \"domain_suffix\": [          \"ifconfig.me\",          \"ipinfo.io\",          \"2ip.ru\",          \"telegram.org\",          \"telegram.me\",          \"telegram.dog\",          \"telegram.space\",          \"telegram-cdn.org\",          \"cdn-telegram.org\",          \"t.me\",          \"tdesktop.com\",          \"telegra.ph\",          \"telesco.pe\",          \"whatsapp.com\",          \"whatsapp.net\",          \"wa.me\",          \"web.whatsapp.com\",          \"chat.whatsapp.com\",          \"static.whatsapp.net\",          \"scontent.whatsapp.net\",          \"cdn.whatsapp.net\",          \"fbsbx.com\",          \"fbcdn.net\",          \"facebook.com\",          \"facebook.net\",          \"youtube.com\",          \"youtu.be\",          \"googlevideo.com\",          \"ytimg.com\",          \"discord.com\",          \"discordapp.com\",          \"discord.gg\",          \"openai.com\",          \"chatgpt.com\",          \"oaistatic.com\",          \"oaiusercontent.com\"        ],        \"outbound\": \"amnezia-xray\"      },      {        \"domain_keyword\": [          \"telegram\",          \"telegra\",          \"telesco\",          \"whatsapp\",          \"fbcdn\",          \"facebook\",          \"fbsbx\",          \"youtube\",          \"googlevideo\",          \"discord\",          \"openai\",          \"chatgpt\"        ],        \"outbound\": \"amnezia-xray\"      }    ],    \"final\": \"direct\"  }}EOFsing-box check -c \/etc\/sing-box\/config.json<\/code><div class=\"code-explainer\"><a href=\"https:\/\/sourcecraft.dev\/\" class=\"tm-button code-explainer__link\" style=\"visibility: hidden;\"><img style=\"width:14px;height:14px;object-fit:cover;object-position:left;\"\/><\/a><\/div><\/pre>\n<blockquote>\n<p><strong>\u0412\u0430\u0436\u043d\u043e:<\/strong> \u0412 JSON \u043d\u0435\u043b\u044c\u0437\u044f \u043e\u0441\u0442\u0430\u0432\u043b\u044f\u0442\u044c \u043b\u0438\u0448\u043d\u0438\u0435 \u0437\u0430\u043f\u044f\u0442\u044b\u0435 \u043f\u043e\u0441\u043b\u0435 \u043f\u043e\u0441\u043b\u0435\u0434\u043d\u0435\u0433\u043e \u044d\u043b\u0435\u043c\u0435\u043d\u0442\u0430 \u043c\u0430\u0441\u0441\u0438\u0432\u0430. \u041e\u0434\u043d\u0430 \u0442\u0430\u043a\u0430\u044f \u0437\u0430\u043f\u044f\u0442\u0430\u044f, \u0438 sing-box \u043d\u0435 \u0441\u0442\u0430\u0440\u0442\u0443\u0435\u0442.<\/p>\n<\/blockquote>\n<h2>\u0428\u0430\u0433 12. \u041d\u0430\u0441\u0442\u0440\u043e\u0438\u0442\u044c nftables redirect<\/h2>\n<p>\u0422\u0435\u043f\u0435\u0440\u044c \u043d\u0443\u0436\u043d\u043e \u043e\u0442\u043f\u0440\u0430\u0432\u0438\u0442\u044c TCP-\u0442\u0440\u0430\u0444\u0438\u043a \u043a\u043b\u0438\u0435\u043d\u0442\u043e\u0432 \u043d\u0430 \u043f\u043e\u0440\u0442 7892. \u0414\u043b\u044f \u044d\u0442\u043e\u0433\u043e \u0441\u043e\u0437\u0434\u0430\u0435\u043c \u043e\u0442\u0434\u0435\u043b\u044c\u043d\u044b\u0439 nft table. \u042f \u0432\u044b\u043d\u0435\u0441 \u043f\u0440\u0430\u0432\u0438\u043b\u0430 \u0432 \u0441\u043a\u0440\u0438\u043f\u0442, \u0447\u0442\u043e\u0431\u044b \u0438\u0445 \u043c\u043e\u0436\u043d\u043e \u0431\u044b\u043b\u043e \u0431\u044b\u0441\u0442\u0440\u043e \u043f\u0440\u0438\u043c\u0435\u043d\u0438\u0442\u044c \u0438 \u0431\u044b\u0441\u0442\u0440\u043e \u0443\u0434\u0430\u043b\u0438\u0442\u044c.<\/p>\n<pre><code class=\"bash\">cat &gt; \/root\/singbox-redirect.sh &lt;&lt;'EOF'#!\/bin\/shnft delete table ip sbxredir 2&gt;\/dev\/nullnft -f - &lt;&lt;'NFT'table ip sbxredir {  chain prerouting {    type nat hook prerouting priority dstnat; policy accept;    ip daddr 10.0.0.0\/8 return    ip daddr 172.16.0.0\/12 return    ip daddr 192.168.0.0\/16 return    ip daddr &lt;XRAY_SERVER_IP&gt; return    udp dport { 53, 67, 68, 123 } return    tcp dport 53 return    ip saddr 192.168.0.0\/24 tcp dport != 7892 counter redirect to :7892  }  chain forward {    type filter hook forward priority filter; policy accept;    ip saddr 192.168.0.0\/24 udp dport 443 counter reject  }}NFTEOFchmod +x \/root\/singbox-redirect.sh\/root\/singbox-redirect.shnft list table ip sbxredir<\/code><div class=\"code-explainer\"><a href=\"https:\/\/sourcecraft.dev\/\" class=\"tm-button code-explainer__link\" style=\"visibility: hidden;\"><img style=\"width:14px;height:14px;object-fit:cover;object-position:left;\"\/><\/a><\/div><\/pre>\n<p>\u0417\u0434\u0435\u0441\u044c \u0435\u0441\u0442\u044c \u043d\u0435\u0441\u043a\u043e\u043b\u044c\u043a\u043e \u0432\u0430\u0436\u043d\u044b\u0445 \u0438\u0441\u043a\u043b\u044e\u0447\u0435\u043d\u0438\u0439:<\/p>\n<ul>\n<li>\n<p>\u043b\u043e\u043a\u0430\u043b\u044c\u043d\u044b\u0435 \u0441\u0435\u0442\u0438 \u043d\u0435 \u0442\u0440\u043e\u0433\u0430\u0435\u043c, \u0438\u043d\u0430\u0447\u0435 \u043c\u043e\u0436\u043d\u043e \u0441\u043b\u043e\u043c\u0430\u0442\u044c \u0434\u043e\u0441\u0442\u0443\u043f \u043a \u0440\u043e\u0443\u0442\u0435\u0440\u0443, Proxmox, OpenWrt \u0438 NAS;<\/p>\n<\/li>\n<li>\n<p>IP Xray-\u0441\u0435\u0440\u0432\u0435\u0440\u0430 \u043d\u0435 \u0442\u0440\u043e\u0433\u0430\u0435\u043c, \u0438\u043d\u0430\u0447\u0435 sing-box \u043c\u043e\u0436\u0435\u0442 \u0437\u0430\u0432\u0435\u0440\u043d\u0443\u0442\u044c \u0441\u043e\u0431\u0441\u0442\u0432\u0435\u043d\u043d\u043e\u0435 \u0441\u043e\u0435\u0434\u0438\u043d\u0435\u043d\u0438\u0435 \u043a \u0441\u0435\u0440\u0432\u0435\u0440\u0443 \u043e\u0431\u0440\u0430\u0442\u043d\u043e \u0432 \u0441\u0435\u0431\u044f;<\/p>\n<\/li>\n<li>\n<p>DNS, DHCP \u0438 NTP \u043d\u0435 \u0442\u0440\u043e\u0433\u0430\u0435\u043c, \u0447\u0442\u043e\u0431\u044b \u0431\u0430\u0437\u043e\u0432\u0430\u044f \u0441\u0435\u0442\u044c \u043e\u0441\u0442\u0430\u0432\u0430\u043b\u0430\u0441\u044c \u0441\u0442\u0430\u0431\u0438\u043b\u044c\u043d\u043e\u0439;<\/p>\n<\/li>\n<li>\n<p>UDP\/443 \u0431\u043b\u043e\u043a\u0438\u0440\u0443\u0435\u043c, \u0447\u0442\u043e\u0431\u044b \u0431\u0440\u0430\u0443\u0437\u0435\u0440\u044b \u0447\u0430\u0449\u0435 \u043e\u0442\u043a\u0430\u0442\u044b\u0432\u0430\u043b\u0438\u0441\u044c \u0441 QUIC \u043d\u0430 TCP.<\/p>\n<\/li>\n<\/ul>\n<h2>\u0428\u0430\u0433 13. \u0420\u0430\u0437\u0440\u0435\u0448\u0438\u0442\u044c \u043f\u043e\u0440\u0442 7892 \u0432 firewall<\/h2>\n<p>\u042d\u0442\u043e \u0431\u044b\u043b\u0430 \u043e\u0434\u043d\u0430 \u0438\u0437 \u0441\u0430\u043c\u044b\u0445 \u043d\u0435\u043f\u0440\u0438\u044f\u0442\u043d\u044b\u0445 \u0433\u0440\u0430\u0431\u043b\u0435\u0439. nft-\u0441\u0447\u0435\u0442\u0447\u0438\u043a\u0438 \u0443\u0436\u0435 \u0440\u043e\u0441\u043b\u0438, \u0437\u043d\u0430\u0447\u0438\u0442 \u043f\u0430\u043a\u0435\u0442\u044b \u043a\u043b\u0438\u0435\u043d\u0442\u043e\u0432 \u0434\u0435\u0439\u0441\u0442\u0432\u0438\u0442\u0435\u043b\u044c\u043d\u043e \u043f\u043e\u043f\u0430\u0434\u0430\u043b\u0438 \u0432 redirect. \u041d\u043e \u0431\u0440\u0430\u0443\u0437\u0435\u0440 \u0432\u0441\u0435 \u0440\u0430\u0432\u043d\u043e \u043f\u043e\u043b\u0443\u0447\u0430\u043b ERR_CONNECTION_REFUSED.<\/p>\n<p>\u041f\u0440\u0438\u0447\u0438\u043d\u0430 \u043e\u043a\u0430\u0437\u0430\u043b\u0430\u0441\u044c \u043f\u0440\u043e\u0441\u0442\u043e\u0439: \u0432 \u043c\u043e\u0435\u0439 \u0441\u0445\u0435\u043c\u0435 \u043a\u043b\u0438\u0435\u043d\u0442\u044b \u043f\u0440\u0438\u0445\u043e\u0434\u044f\u0442 \u043d\u0430 OpenWrt \u0441\u043e \u0441\u0442\u043e\u0440\u043e\u043d\u044b \u0437\u043e\u043d\u044b wan, \u0430 \u0443 wan \u043f\u043e \u0443\u043c\u043e\u043b\u0447\u0430\u043d\u0438\u044e input = REJECT. \u0417\u043d\u0430\u0447\u0438\u0442 OpenWrt \u0441\u0430\u043c \u0436\u0435 \u0440\u0435\u0437\u0430\u043b \u0432\u0445\u043e\u0434 \u043d\u0430 \u043b\u043e\u043a\u0430\u043b\u044c\u043d\u044b\u0439 \u043f\u043e\u0440\u0442 7892.<\/p>\n<pre><code class=\"bash\">uci add firewall ruleuci set firewall.@rule[-1].name='Allow-SingBox-Redirect-7892'uci set firewall.@rule[-1].src='wan'uci set firewall.@rule[-1].src_ip='192.168.0.0\/24'uci set firewall.@rule[-1].proto='tcp'uci set firewall.@rule[-1].dest_port='7892'uci set firewall.@rule[-1].target='ACCEPT'uci commit firewall\/etc\/init.d\/firewall restart<\/code><div class=\"code-explainer\"><a href=\"https:\/\/sourcecraft.dev\/\" class=\"tm-button code-explainer__link\" style=\"visibility: hidden;\"><img style=\"width:14px;height:14px;object-fit:cover;object-position:left;\"\/><\/a><\/div><\/pre>\n<p>\u041f\u043e\u0441\u043b\u0435 \u043f\u0435\u0440\u0435\u0437\u0430\u043f\u0443\u0441\u043a\u0430 firewall \u043f\u0440\u043e\u0432\u0435\u0440\u044c\u0442\u0435, \u0447\u0442\u043e nft-\u0442\u0430\u0431\u043b\u0438\u0446\u0430 \u043d\u0435 \u043f\u0440\u043e\u043f\u0430\u043b\u0430. \u0415\u0441\u043b\u0438 \u043f\u0440\u043e\u043f\u0430\u043b\u0430, \u043f\u0440\u043e\u0441\u0442\u043e \u043f\u0440\u0438\u043c\u0435\u043d\u0438\u0442\u0435 \u0441\u043a\u0440\u0438\u043f\u0442 \u0437\u0430\u043d\u043e\u0432\u043e:<\/p>\n<pre><code class=\"bash\">\/root\/singbox-redirect.shnft list table ip sbxredir<\/code><div class=\"code-explainer\"><a href=\"https:\/\/sourcecraft.dev\/\" class=\"tm-button code-explainer__link\" style=\"visibility: hidden;\"><img style=\"width:14px;height:14px;object-fit:cover;object-position:left;\"\/><\/a><\/div><\/pre>\n<h2>\u0428\u0430\u0433 14. \u0417\u0430\u043f\u0443\u0441\u0442\u0438\u0442\u044c sing-box \u0438 \u043f\u0440\u043e\u0432\u0435\u0440\u0438\u0442\u044c, \u0447\u0442\u043e \u0442\u0440\u0430\u0444\u0438\u043a \u043f\u043e\u043f\u0430\u0434\u0430\u0435\u0442 \u0432\u043d\u0443\u0442\u0440\u044c<\/h2>\n<p>\u041d\u0430 \u044d\u0442\u0430\u043f\u0435 \u043e\u0442\u043b\u0430\u0434\u043a\u0438 \u043b\u0443\u0447\u0448\u0435 \u0437\u0430\u043f\u0443\u0441\u043a\u0430\u0442\u044c sing-box \u0432\u0440\u0443\u0447\u043d\u0443\u044e, \u0447\u0442\u043e\u0431\u044b \u0432\u0438\u0434\u0435\u0442\u044c \u043b\u043e\u0433 \u043f\u0440\u044f\u043c\u043e \u0432 \u043a\u043e\u043d\u0441\u043e\u043b\u0438:<\/p>\n<pre><code class=\"bash\">killall sing-box 2&gt;\/dev\/nullsing-box run -c \/etc\/sing-box\/config.json<\/code><div class=\"code-explainer\"><a href=\"https:\/\/sourcecraft.dev\/\" class=\"tm-button code-explainer__link\" style=\"visibility: hidden;\"><img style=\"width:14px;height:14px;object-fit:cover;object-position:left;\"\/><\/a><\/div><\/pre>\n<p>\u0412 \u0434\u0440\u0443\u0433\u043e\u043c \u043e\u043a\u043d\u0435 \u043f\u0440\u043e\u0432\u0435\u0440\u044f\u0435\u043c, \u0447\u0442\u043e \u043f\u043e\u0440\u0442 \u0441\u043b\u0443\u0448\u0430\u0435\u0442\u0441\u044f:<\/p>\n<pre><code class=\"bash\">netstat -lntp | grep 7892nft list table ip sbxredir<\/code><div class=\"code-explainer\"><a href=\"https:\/\/sourcecraft.dev\/\" class=\"tm-button code-explainer__link\" style=\"visibility: hidden;\"><img style=\"width:14px;height:14px;object-fit:cover;object-position:left;\"\/><\/a><\/div><\/pre>\n<p>\u0421 \u043a\u043b\u0438\u0435\u043d\u0442\u0430 \u0432\u044b\u043f\u043e\u043b\u043d\u044f\u0435\u043c:<\/p>\n<pre><code class=\"bash\">curl -4 https:\/\/ifconfig.mecurl -4 https:\/\/api.ipify.org<\/code><div class=\"code-explainer\"><a href=\"https:\/\/sourcecraft.dev\/\" class=\"tm-button code-explainer__link\" style=\"visibility: hidden;\"><img style=\"width:14px;height:14px;object-fit:cover;object-position:left;\"\/><\/a><\/div><\/pre>\n<p>\u0415\u0441\u043b\u0438 ifconfig.me \u0434\u043e\u0431\u0430\u0432\u043b\u0435\u043d \u0432 \u0441\u043f\u0438\u0441\u043e\u043a \u0434\u043e\u043c\u0435\u043d\u043e\u0432 \u0434\u043b\u044f \u0442\u0443\u043d\u043d\u0435\u043b\u044f, \u043e\u043d \u0434\u043e\u043b\u0436\u0435\u043d \u043f\u043e\u043a\u0430\u0437\u0430\u0442\u044c IP \u0442\u0443\u043d\u043d\u0435\u043b\u044f. \u0415\u0441\u043b\u0438 api.ipify.org \u043d\u0435 \u0434\u043e\u0431\u0430\u0432\u043b\u0435\u043d, \u043e\u043d \u0434\u043e\u043b\u0436\u0435\u043d \u043f\u043e\u043a\u0430\u0437\u0430\u0442\u044c \u043f\u0440\u044f\u043c\u043e\u0439 IP \u043f\u0440\u043e\u0432\u0430\u0439\u0434\u0435\u0440\u0430.<\/p>\n<p>\u042d\u0442\u043e \u043b\u0443\u0447\u0448\u0438\u0439 \u043f\u0440\u043e\u0441\u0442\u043e\u0439 \u0442\u0435\u0441\u0442, \u043f\u043e\u0442\u043e\u043c\u0443 \u0447\u0442\u043e \u043e\u043d \u043f\u043e\u043a\u0430\u0437\u044b\u0432\u0430\u0435\u0442 \u0438\u043c\u0435\u043d\u043d\u043e \u0432\u044b\u0431\u043e\u0440\u043e\u0447\u043d\u0443\u044e \u043c\u0430\u0440\u0448\u0440\u0443\u0442\u0438\u0437\u0430\u0446\u0438\u044e, \u0430 \u043d\u0435 \u0440\u0435\u0436\u0438\u043c \u201c\u0432\u0441\u0435 \u0447\u0435\u0440\u0435\u0437 \u0442\u0443\u043d\u043d\u0435\u043b\u044c\u201d.<\/p>\n<h2>\u0428\u0430\u0433 15. \u041f\u043e\u043d\u044f\u0442\u044c \u043f\u043e\u0440\u044f\u0434\u043e\u043a \u043f\u0440\u0430\u0432\u0438\u043b sing-box<\/h2>\n<figure class=\"\"><img decoding=\"async\" src=\"https:\/\/habrastorage.org\/r\/w1560\/webt\/37\/a1\/9d\/37a19d550ff685ec20674ff3464cbbda.png\" sizes=\"(max-width: 780px) 100vw, 50vw\" srcset=\"https:\/\/habrastorage.org\/r\/w780\/webt\/37\/a1\/9d\/37a19d550ff685ec20674ff3464cbbda.png 780w,&#10;       https:\/\/habrastorage.org\/r\/w1560\/webt\/37\/a1\/9d\/37a19d550ff685ec20674ff3464cbbda.png 781w\" loading=\"lazy\" decode=\"async\"\/><\/figure>\n<p><em>\u0420\u0438\u0441\u0443\u043d\u043e\u043a 4. \u041f\u0440\u0430\u0432\u0438\u043b\u0430 sing-box \u0447\u0438\u0442\u0430\u044e\u0442\u0441\u044f \u0441\u0432\u0435\u0440\u0445\u0443 \u0432\u043d\u0438\u0437. \u041f\u0435\u0440\u0432\u043e\u0435 \u0441\u043e\u0432\u043f\u0430\u0434\u0435\u043d\u0438\u0435 \u043f\u043e\u0431\u0435\u0436\u0434\u0430\u0435\u0442.<\/em> <\/p>\n<p>\u0412 sing-box \u043f\u043e\u0440\u044f\u0434\u043e\u043a \u043f\u0440\u0430\u0432\u0438\u043b \u043a\u0440\u0438\u0442\u0438\u0447\u0435\u043d. \u041f\u0435\u0440\u0432\u043e\u0435 \u0441\u043e\u0432\u043f\u0430\u0434\u0435\u043d\u0438\u0435 \u043f\u043e\u0431\u0435\u0436\u0434\u0430\u0435\u0442. \u0418\u043c\u0435\u043d\u043d\u043e \u043f\u043e\u044d\u0442\u043e\u043c\u0443 \u0441\u043b\u0443\u0436\u0435\u0431\u043d\u044b\u0435 \u0430\u0434\u0440\u0435\u0441\u0430 \u0434\u043e\u043b\u0436\u043d\u044b \u0438\u0434\u0442\u0438 \u0432\u044b\u0448\u0435, \u0447\u0435\u043c \u0448\u0438\u0440\u043e\u043a\u0438\u0435 \u043f\u0440\u0430\u0432\u0438\u043b\u0430 \u043d\u0430 \u0442\u0443\u043d\u043d\u0435\u043b\u044c.<\/p>\n<p>\u041c\u043e\u044f \u043b\u043e\u0433\u0438\u043a\u0430 \u043f\u043e\u043b\u0443\u0447\u0438\u043b\u0430\u0441\u044c \u0442\u0430\u043a\u043e\u0439:<\/p>\n<ol>\n<li>\n<p>\u041b\u043e\u043a\u0430\u043b\u044c\u043d\u044b\u0435 \u0438 \u0441\u043b\u0443\u0436\u0435\u0431\u043d\u044b\u0435 \u0430\u0434\u0440\u0435\u0441\u0430 \u0438\u0434\u0443\u0442 \u043d\u0430\u043f\u0440\u044f\u043c\u0443\u044e.<\/p>\n<\/li>\n<li>\n<p>IP \u0441\u0430\u043c\u043e\u0433\u043e Xray-\u0441\u0435\u0440\u0432\u0435\u0440\u0430 \u0438\u0434\u0435\u0442 \u043d\u0430\u043f\u0440\u044f\u043c\u0443\u044e, \u0447\u0442\u043e\u0431\u044b \u043d\u0435 \u043f\u043e\u043b\u0443\u0447\u0438\u0442\u044c \u043f\u0435\u0442\u043b\u044e.<\/p>\n<\/li>\n<li>\n<p>Telegram IP \u0438\u0434\u0443\u0442 \u0447\u0435\u0440\u0435\u0437 amnezia-xray.<\/p>\n<\/li>\n<li>\n<p>\u0414\u043e\u043c\u0435\u043d\u044b \u0438\u0437 \u0441\u043f\u0438\u0441\u043a\u0430 \u0438\u0434\u0443\u0442 \u0447\u0435\u0440\u0435\u0437 amnezia-xray.<\/p>\n<\/li>\n<li>\n<p>\u0415\u0441\u043b\u0438 \u043d\u0438\u0447\u0435\u0433\u043e \u043d\u0435 \u0441\u043e\u0432\u043f\u0430\u043b\u043e, final: direct.<\/p>\n<\/li>\n<\/ol>\n<p>\u041d\u0430 \u044d\u0442\u043e\u043c \u044f \u043e\u0448\u0438\u0431\u0441\u044f \u043e\u0434\u0438\u043d \u0440\u0430\u0437: \u043f\u043e\u043b\u043e\u0436\u0438\u043b Telegram IP \u0432 direct-\u043f\u0440\u0430\u0432\u0438\u043b\u043e. \u0412 \u0438\u0442\u043e\u0433\u0435 Telegram \u0448\u0435\u043b \u043d\u0430\u043f\u0440\u044f\u043c\u0443\u044e, \u0445\u043e\u0442\u044f \u043d\u0438\u0436\u0435 \u0431\u044b\u043b\u0438 \u043f\u0440\u0430\u0432\u0438\u043b\u044c\u043d\u044b\u0435 \u0434\u043e\u043c\u0435\u043d\u043d\u044b\u0435 \u043f\u0440\u0430\u0432\u0438\u043b\u0430. \u042d\u0442\u043e \u0445\u043e\u0440\u043e\u0448\u0438\u0439 \u043f\u0440\u0438\u043c\u0435\u0440, \u043f\u043e\u0447\u0435\u043c\u0443 \u043f\u043e\u0440\u044f\u0434\u043e\u043a \u043f\u0440\u0430\u0432\u0438\u043b \u043d\u0443\u0436\u043d\u043e \u043f\u0440\u043e\u0432\u0435\u0440\u044f\u0442\u044c \u0433\u043b\u0430\u0437\u0430\u043c\u0438.<\/p>\n<h2>\u0428\u0430\u0433 16. \u041e\u0444\u043e\u0440\u043c\u0438\u0442\u044c \u0430\u0432\u0442\u043e\u0437\u0430\u043f\u0443\u0441\u043a<\/h2>\n<p>\u041a\u043e\u0433\u0434\u0430 \u0432\u0441\u0435 \u0437\u0430\u0440\u0430\u0431\u043e\u0442\u0430\u043b\u043e \u0440\u0443\u043a\u0430\u043c\u0438, \u043c\u043e\u0436\u043d\u043e \u0434\u0435\u043b\u0430\u0442\u044c \u0441\u0435\u0440\u0432\u0438\u0441\u044b. \u0421\u043d\u0430\u0447\u0430\u043b\u0430 init-\u0441\u043a\u0440\u0438\u043f\u0442 \u0434\u043b\u044f sing-box:<\/p>\n<pre><code class=\"bash\">cat &gt; \/etc\/init.d\/sing-box &lt;&lt;'EOF'#!\/bin\/sh \/etc\/rc.commonSTART=99STOP=10USE_PROCD=1PROG=\/usr\/bin\/sing-boxCONF=\/etc\/sing-box\/config.jsonstart_service() {    procd_open_instance    procd_set_param command \"$PROG\" run -c \"$CONF\"    procd_set_param respawn    procd_set_param stdout 1    procd_set_param stderr 1    procd_close_instance}EOFchmod +x \/etc\/init.d\/sing-box\/etc\/init.d\/sing-box enable\/etc\/init.d\/sing-box restart<\/code><div class=\"code-explainer\"><a href=\"https:\/\/sourcecraft.dev\/\" class=\"tm-button code-explainer__link\" style=\"visibility: hidden;\"><img style=\"width:14px;height:14px;object-fit:cover;object-position:left;\"\/><\/a><\/div><\/pre>\n<p>\u041f\u043e\u0442\u043e\u043c \u043e\u0442\u0434\u0435\u043b\u044c\u043d\u044b\u0439 init-\u0441\u043a\u0440\u0438\u043f\u0442 \u0434\u043b\u044f nft-\u043f\u0440\u0430\u0432\u0438\u043b:<\/p>\n<pre><code class=\"bash\">cat &gt; \/etc\/init.d\/singbox-redirect &lt;&lt;'EOF'#!\/bin\/sh \/etc\/rc.commonSTART=98STOP=10start() {    \/root\/singbox-redirect.sh}stop() {    nft delete table ip sbxredir 2&gt;\/dev\/null}restart() {    stop    start}EOFchmod +x \/etc\/init.d\/singbox-redirect\/etc\/init.d\/singbox-redirect enable\/etc\/init.d\/singbox-redirect start<\/code><div class=\"code-explainer\"><a href=\"https:\/\/sourcecraft.dev\/\" class=\"tm-button code-explainer__link\" style=\"visibility: hidden;\"><img style=\"width:14px;height:14px;object-fit:cover;object-position:left;\"\/><\/a><\/div><\/pre>\n<p>\u041f\u043e\u0440\u044f\u0434\u043e\u043a \u0441\u0442\u0430\u0440\u0442\u0430 \u0432\u0430\u0436\u0435\u043d: \u0441\u043d\u0430\u0447\u0430\u043b\u0430 nft-\u043f\u0440\u0430\u0432\u0438\u043b\u0430, \u043f\u043e\u0442\u043e\u043c sing-box. \u0412 \u043c\u043e\u0435\u043c \u0432\u0430\u0440\u0438\u0430\u043d\u0442\u0435 redirect \u0441\u0442\u0430\u0440\u0442\u0443\u0435\u0442 \u0441 START=98, \u0430 sing-box \u0441 START=99.<\/p>\n<h2>\u0428\u0430\u0433 17. \u041f\u0440\u043e\u0432\u0435\u0440\u043a\u0438 \u043f\u043e\u0441\u043b\u0435 \u043f\u0435\u0440\u0435\u0437\u0430\u0433\u0440\u0443\u0437\u043a\u0438<\/h2>\n<p>\u041f\u043e\u0441\u043b\u0435 reboot \u043d\u0430\u0434\u043e \u043f\u0440\u043e\u0432\u0435\u0440\u0438\u0442\u044c \u0432\u0441\u044e \u0446\u0435\u043f\u043e\u0447\u043a\u0443, \u0430 \u043d\u0435 \u0442\u043e\u043b\u044c\u043a\u043e \u043e\u0434\u0438\u043d \u0441\u0435\u0440\u0432\u0438\u0441.<\/p>\n<pre><code class=\"bash\">reboot<\/code><div class=\"code-explainer\"><a href=\"https:\/\/sourcecraft.dev\/\" class=\"tm-button code-explainer__link\" style=\"visibility: hidden;\"><img style=\"width:14px;height:14px;object-fit:cover;object-position:left;\"\/><\/a><\/div><\/pre>\n<p>\u041f\u043e\u0441\u043b\u0435 \u0437\u0430\u0433\u0440\u0443\u0437\u043a\u0438:<\/p>\n<pre><code class=\"bash\">ps | grep sing-box | grep -v grepnetstat -lntp | grep 7892nft list table ip sbxredir\/etc\/init.d\/dnsmasq statusip routelogread -e sing<\/code><div class=\"code-explainer\"><a href=\"https:\/\/sourcecraft.dev\/\" class=\"tm-button code-explainer__link\" style=\"visibility: hidden;\"><img style=\"width:14px;height:14px;object-fit:cover;object-position:left;\"\/><\/a><\/div><\/pre>\n<p>\u0421 \u043a\u043b\u0438\u0435\u043d\u0442\u0430:<\/p>\n<pre><code>ipconfig \/alltracert 1.1.1.1nslookup ya.ru 192.168.0.2curl -4 https:\/\/ifconfig.mecurl -4 https:\/\/api.ipify.org<\/code><div class=\"code-explainer\"><a href=\"https:\/\/sourcecraft.dev\/\" class=\"tm-button code-explainer__link\" style=\"visibility: hidden;\"><img style=\"width:14px;height:14px;object-fit:cover;object-position:left;\"\/><\/a><\/div><\/pre>\n<p>\u041d\u043e\u0440\u043c\u0430\u043b\u044c\u043d\u044b\u0439 \u0440\u0435\u0437\u0443\u043b\u044c\u0442\u0430\u0442: \u043f\u0435\u0440\u0432\u044b\u0439 hop \u0432 tracert \u044d\u0442\u043e 192.168.0.2, DNS \u043e\u0442\u0432\u0435\u0447\u0430\u0435\u0442 \u0447\u0435\u0440\u0435\u0437 OpenWrt, ifconfig.me \u043f\u043e\u043a\u0430\u0437\u044b\u0432\u0430\u0435\u0442 IP \u0442\u0443\u043d\u043d\u0435\u043b\u044f, \u0430 api.ipify.org \u043f\u043e\u043a\u0430\u0437\u044b\u0432\u0430\u0435\u0442 \u043f\u0440\u044f\u043c\u043e\u0439 IP \u043f\u0440\u043e\u0432\u0430\u0439\u0434\u0435\u0440\u0430.<\/p>\n<h2>\u0428\u0430\u0433 18. \u0427\u0442\u043e \u0434\u0435\u043b\u0430\u0442\u044c, \u0435\u0441\u043b\u0438 \u0441\u043b\u043e\u043c\u0430\u043b\u043e\u0441\u044c<\/h2>\n<h3>18.1. \u041a\u043b\u0438\u0435\u043d\u0442 \u043d\u0435 \u043f\u043e\u043b\u0443\u0447\u0430\u0435\u0442 IP<\/h3>\n<p>\u0421\u043d\u0430\u0447\u0430\u043b\u0430 \u0441\u043c\u043e\u0442\u0440\u0438\u043c DHCP:<\/p>\n<pre><code class=\"bash\">logread -e dnsmasqcat \/tmp\/dhcp.leasestcpdump -ni eth0 'port 67 or port 68'<\/code><div class=\"code-explainer\"><a href=\"https:\/\/sourcecraft.dev\/\" class=\"tm-button code-explainer__link\" style=\"visibility: hidden;\"><img style=\"width:14px;height:14px;object-fit:cover;object-position:left;\"\/><\/a><\/div><\/pre>\n<p>\u0415\u0441\u043b\u0438 \u0432 tcpdump \u043d\u0435\u0442 DHCPDISCOVER, \u0437\u0430\u043f\u0440\u043e\u0441\u044b \u043e\u0442 \u043a\u043b\u0438\u0435\u043d\u0442\u0430 \u0432\u043e\u043e\u0431\u0449\u0435 \u043d\u0435 \u0434\u043e\u0445\u043e\u0434\u044f\u0442 \u0434\u043e OpenWrt. \u0427\u0430\u0441\u0442\u043e \u043f\u0440\u043e\u0431\u043b\u0435\u043c\u0430 \u0432 Wi-Fi \u0442\u043e\u0447\u043a\u0435 \u0434\u043e\u0441\u0442\u0443\u043f\u0430, WAN-\u043f\u043e\u0440\u0442\u0435 \u0438\u043b\u0438 client isolation. \u0415\u0441\u043b\u0438 DISCOVER \u0435\u0441\u0442\u044c, OFFER \u0435\u0441\u0442\u044c, \u043d\u043e REQUEST \u043d\u0435\u0442, \u043a\u043b\u0438\u0435\u043d\u0442 \u043d\u0435 \u043f\u0440\u0438\u043d\u0438\u043c\u0430\u0435\u0442 \u043e\u0442\u0432\u0435\u0442.<\/p>\n<h3>18.2. IP \u0435\u0441\u0442\u044c, \u043d\u043e \u0438\u043d\u0442\u0435\u0440\u043d\u0435\u0442\u0430 \u043d\u0435\u0442<\/h3>\n<pre><code>ping 1.1.1.1nslookup ya.ru 192.168.0.2tracert 1.1.1.1<\/code><div class=\"code-explainer\"><a href=\"https:\/\/sourcecraft.dev\/\" class=\"tm-button code-explainer__link\" style=\"visibility: hidden;\"><img style=\"width:14px;height:14px;object-fit:cover;object-position:left;\"\/><\/a><\/div><\/pre>\n<p>\u0415\u0441\u043b\u0438 ping 1.1.1.1 \u0440\u0430\u0431\u043e\u0442\u0430\u0435\u0442, \u0430 DNS \u043d\u0435\u0442, \u043f\u0440\u043e\u0431\u043b\u0435\u043c\u0430 \u0432 dnsmasq \u0438\u043b\u0438 upstream DNS. \u0415\u0441\u043b\u0438 \u043f\u0435\u0440\u0432\u044b\u0439 hop \u043d\u0435 OpenWrt, \u043a\u043b\u0438\u0435\u043d\u0442 \u043f\u043e\u043b\u0443\u0447\u0430\u0435\u0442 \u043d\u0435 \u0442\u043e\u0442 gateway.<\/p>\n<h3>18.3. nft counter \u043d\u0435 \u0440\u0430\u0441\u0442\u0435\u0442<\/h3>\n<pre><code class=\"bash\">nft list table ip sbxredir<\/code><div class=\"code-explainer\"><a href=\"https:\/\/sourcecraft.dev\/\" class=\"tm-button code-explainer__link\" style=\"visibility: hidden;\"><img style=\"width:14px;height:14px;object-fit:cover;object-position:left;\"\/><\/a><\/div><\/pre>\n<p>\u0415\u0441\u043b\u0438 \u0441\u0447\u0435\u0442\u0447\u0438\u043a redirect \u043d\u0435 \u0440\u0430\u0441\u0442\u0435\u0442 \u043f\u0440\u0438 curl \u0441 \u043a\u043b\u0438\u0435\u043d\u0442\u0430, \u0437\u043d\u0430\u0447\u0438\u0442 \u0442\u0440\u0430\u0444\u0438\u043a \u043d\u0435 \u043f\u043e\u043f\u0430\u0434\u0430\u0435\u0442 \u043f\u043e\u0434 \u043f\u0440\u0430\u0432\u0438\u043b\u043e. \u041f\u0440\u043e\u0432\u0435\u0440\u044f\u0435\u043c source IP \u043a\u043b\u0438\u0435\u043d\u0442\u0430, gateway, flow offloading \u0438 \u0441\u0430\u043c\u0443 \u0442\u0430\u0431\u043b\u0438\u0446\u0443 nft.<\/p>\n<h3>18.4. counter \u0440\u0430\u0441\u0442\u0435\u0442, \u043d\u043e \u0431\u0440\u0430\u0443\u0437\u0435\u0440 \u043f\u0438\u0448\u0435\u0442 ERR_CONNECTION_REFUSED<\/h3>\n<p>\u042d\u0442\u043e \u043f\u043e\u0447\u0442\u0438 \u0442\u043e\u0447\u043d\u043e firewall. \u0422\u0440\u0430\u0444\u0438\u043a \u0440\u0435\u0434\u0438\u0440\u0435\u043a\u0442\u0438\u0442\u0441\u044f \u043d\u0430 7892, \u043d\u043e OpenWrt \u043d\u0435 \u0440\u0430\u0437\u0440\u0435\u0448\u0430\u0435\u0442 \u0432\u0445\u043e\u0434 \u043d\u0430 \u044d\u0442\u043e\u0442 \u043b\u043e\u043a\u0430\u043b\u044c\u043d\u044b\u0439 \u043f\u043e\u0440\u0442 \u0441\u043e \u0441\u0442\u043e\u0440\u043e\u043d\u044b wan-\u0437\u043e\u043d\u044b. \u041f\u0440\u043e\u0432\u0435\u0440\u044f\u0435\u043c \u043f\u0440\u0430\u0432\u0438\u043b\u043e Allow-SingBox-Redirect-7892.<\/p>\n<h3>18.5. \u0412\u0441\u0435 \u0438\u0434\u0435\u0442 \u043d\u0430\u043f\u0440\u044f\u043c\u0443\u044e, \u0445\u043e\u0442\u044f \u0434\u043e\u043c\u0435\u043d \u0435\u0441\u0442\u044c \u0432 \u0441\u043f\u0438\u0441\u043a\u0435<\/h3>\n<p>\u041f\u0440\u043e\u0432\u0435\u0440\u044f\u0435\u043c \u043f\u043e\u0440\u044f\u0434\u043e\u043a route rules \u0432 sing-box. \u0415\u0441\u043b\u0438 \u0432\u044b\u0448\u0435 \u0441\u0442\u043e\u0438\u0442 \u0431\u043e\u043b\u0435\u0435 \u0448\u0438\u0440\u043e\u043a\u043e\u0435 direct-\u043f\u0440\u0430\u0432\u0438\u043b\u043e, \u043e\u043d\u043e \u043f\u043e\u0431\u0435\u0434\u0438\u0442. \u0422\u0430\u043a \u044f \u0441\u043b\u0443\u0447\u0430\u0439\u043d\u043e \u043e\u0442\u043f\u0440\u0430\u0432\u0438\u043b Telegram IP \u043d\u0430\u043f\u0440\u044f\u043c\u0443\u044e.<\/p>\n<h3>18.6. \u0412\u0441\u0435 \u043b\u0435\u0433\u043b\u043e \u043f\u043e\u0441\u043b\u0435 \u044d\u043a\u0441\u043f\u0435\u0440\u0438\u043c\u0435\u043d\u0442\u043e\u0432<\/h3>\n<p>\u041d\u0430 \u044d\u0442\u043e\u0442 \u0441\u043b\u0443\u0447\u0430\u0439 \u0434\u043e\u043b\u0436\u0435\u043d \u0431\u044b\u0442\u044c \u0431\u044b\u0441\u0442\u0440\u044b\u0439 \u043e\u0442\u043a\u0430\u0442.<\/p>\n<h2>\u0411\u044b\u0441\u0442\u0440\u044b\u0439 \u043e\u0442\u043a\u0430\u0442<\/h2>\n<pre><code class=\"bash\">\/etc\/init.d\/sing-box stop\/etc\/init.d\/singbox-redirect stop\/etc\/init.d\/firewall restart\/etc\/init.d\/dnsmasq restart<\/code><div class=\"code-explainer\"><a href=\"https:\/\/sourcecraft.dev\/\" class=\"tm-button code-explainer__link\" style=\"visibility: hidden;\"><img style=\"width:14px;height:14px;object-fit:cover;object-position:left;\"\/><\/a><\/div><\/pre>\n<p>\u0418\u043b\u0438 \u0432\u0440\u0443\u0447\u043d\u0443\u044e:<\/p>\n<pre><code class=\"bash\">killall sing-box 2&gt;\/dev\/nullnft delete table ip sbxredir 2&gt;\/dev\/null\/etc\/init.d\/firewall restart\/etc\/init.d\/dnsmasq restart<\/code><div class=\"code-explainer\"><a href=\"https:\/\/sourcecraft.dev\/\" class=\"tm-button code-explainer__link\" style=\"visibility: hidden;\"><img style=\"width:14px;height:14px;object-fit:cover;object-position:left;\"\/><\/a><\/div><\/pre>\n<p>\u041f\u043e\u0441\u043b\u0435 \u044d\u0442\u043e\u0433\u043e \u043a\u043b\u0438\u0435\u043d\u0442\u044b \u0441\u043d\u043e\u0432\u0430 \u0438\u0434\u0443\u0442 \u043d\u0430\u043f\u0440\u044f\u043c\u0443\u044e \u0447\u0435\u0440\u0435\u0437 OpenWrt. \u042d\u0442\u043e \u043d\u0435 \u043e\u0442\u043a\u0430\u0442\u044b\u0432\u0430\u0435\u0442 DHCP, \u043d\u043e \u0443\u0431\u0438\u0440\u0430\u0435\u0442 transparent proxy \u0438 redirect.<\/p>\n<h2>\u0427\u0442\u043e \u043f\u043e\u043b\u0443\u0447\u0438\u043b\u043e\u0441\u044c<\/h2>\n<p>\u0412 \u0444\u0438\u043d\u0430\u043b\u0435 \u043f\u043e\u043b\u0443\u0447\u0438\u043b\u0430\u0441\u044c \u0434\u043e\u0441\u0442\u0430\u0442\u043e\u0447\u043d\u043e \u043f\u043e\u043d\u044f\u0442\u043d\u0430\u044f \u0441\u0445\u0435\u043c\u0430. OpenWrt \u0440\u0430\u0437\u0434\u0430\u0435\u0442 DHCP, \u044f\u0432\u043b\u044f\u0435\u0442\u0441\u044f DNS \u0438 gateway \u0434\u043b\u044f \u043a\u043b\u0438\u0435\u043d\u0442\u043e\u0432. nftables \u043f\u0435\u0440\u0435\u043d\u0430\u043f\u0440\u0430\u0432\u043b\u044f\u0435\u0442 TCP-\u0442\u0440\u0430\u0444\u0438\u043a \u043a\u043b\u0438\u0435\u043d\u0442\u043e\u0432 \u043d\u0430 sing-box. sing-box \u043e\u043f\u0440\u0435\u0434\u0435\u043b\u044f\u0435\u0442 \u0434\u043e\u043c\u0435\u043d \u0438\u043b\u0438 IP \u0438 \u0440\u0435\u0448\u0430\u0435\u0442, \u043e\u0442\u043f\u0440\u0430\u0432\u0438\u0442\u044c \u0441\u043e\u0435\u0434\u0438\u043d\u0435\u043d\u0438\u0435 \u043d\u0430\u043f\u0440\u044f\u043c\u0443\u044e \u0438\u043b\u0438 \u0447\u0435\u0440\u0435\u0437 amnezia-xray.<\/p>\n<p>\u0413\u043b\u0430\u0432\u043d\u044b\u0439 \u043f\u043b\u044e\u0441: VPN \u0431\u043e\u043b\u044c\u0448\u0435 \u043d\u0435 \u043d\u0443\u0436\u043d\u043e \u043d\u0430\u0441\u0442\u0440\u0430\u0438\u0432\u0430\u0442\u044c \u043d\u0430 \u043a\u0430\u0436\u0434\u043e\u043c \u0443\u0441\u0442\u0440\u043e\u0439\u0441\u0442\u0432\u0435. \u0422\u0435\u043b\u0435\u0444\u043e\u043d, \u043d\u043e\u0443\u0442\u0431\u0443\u043a, \u0442\u0435\u043b\u0435\u0432\u0438\u0437\u043e\u0440 \u0438\u043b\u0438 \u0433\u043e\u0441\u0442\u0435\u0432\u043e\u0439 \u043a\u043b\u0438\u0435\u043d\u0442 \u043f\u0440\u043e\u0441\u0442\u043e \u043f\u043e\u0434\u043a\u043b\u044e\u0447\u0430\u044e\u0442\u0441\u044f \u043a \u0441\u0435\u0442\u0438. \u0415\u0441\u043b\u0438 \u0438\u0445 \u0442\u0440\u0430\u0444\u0438\u043a \u043f\u043e\u043f\u0430\u0434\u0430\u0435\u0442 \u043f\u043e\u0434 \u043f\u0440\u0430\u0432\u0438\u043b\u0430, \u043e\u043d \u0438\u0434\u0435\u0442 \u0447\u0435\u0440\u0435\u0437 \u0442\u0443\u043d\u043d\u0435\u043b\u044c. \u0415\u0441\u043b\u0438 \u043d\u0435 \u043f\u043e\u043f\u0430\u0434\u0430\u0435\u0442, \u043e\u043d \u0438\u0434\u0435\u0442 \u043d\u0430\u043f\u0440\u044f\u043c\u0443\u044e.<\/p>\n<p>\u0412\u0442\u043e\u0440\u043e\u0439 \u043f\u043b\u044e\u0441: \u043e\u0431\u044b\u0447\u043d\u044b\u0439 \u0442\u0440\u0430\u0444\u0438\u043a \u043d\u0435 \u0433\u043e\u043d\u044f\u0435\u0442\u0441\u044f \u0447\u0435\u0440\u0435\u0437 \u0443\u0434\u0430\u043b\u0435\u043d\u043d\u044b\u0439 \u0441\u0435\u0440\u0432\u0435\u0440. \u042d\u0442\u043e \u044d\u043a\u043e\u043d\u043e\u043c\u0438\u0442 \u0440\u0435\u0441\u0443\u0440\u0441 \u0442\u0443\u043d\u043d\u0435\u043b\u044f \u0438 \u0441\u043d\u0438\u0436\u0430\u0435\u0442 \u0437\u0430\u0434\u0435\u0440\u0436\u043a\u0438 \u0434\u043b\u044f \u0432\u0441\u0435\u0433\u043e, \u0447\u0442\u043e \u043d\u0435 \u0442\u0440\u0435\u0431\u0443\u0435\u0442 \u043e\u0431\u0445\u043e\u0434\u043d\u043e\u0433\u043e \u043c\u0430\u0440\u0448\u0440\u0443\u0442\u0430.<\/p>\n<p>\u0422\u0440\u0435\u0442\u0438\u0439 \u043f\u043b\u044e\u0441: \u043f\u0440\u0430\u0432\u0438\u043b\u0430 \u0446\u0435\u043d\u0442\u0440\u0430\u043b\u0438\u0437\u043e\u0432\u0430\u043d\u044b. \u0414\u043e\u0431\u0430\u0432\u0438\u0442\u044c \u0434\u043e\u043c\u0435\u043d \u0438\u043b\u0438 IP \u043c\u043e\u0436\u043d\u043e \u0432 \u043e\u0434\u043d\u043e\u043c \u043c\u0435\u0441\u0442\u0435, \u043d\u0430 OpenWrt, \u0430 \u043d\u0435 \u0431\u0435\u0433\u0430\u0442\u044c \u043f\u043e \u0432\u0441\u0435\u043c \u0443\u0441\u0442\u0440\u043e\u0439\u0441\u0442\u0432\u0430\u043c.<\/p>\n<h2>\u0427\u0442\u043e \u043e\u0441\u0442\u0430\u043b\u043e\u0441\u044c \u043d\u0435\u0438\u0434\u0435\u0430\u043b\u044c\u043d\u044b\u043c<\/h2>\n<p>\u0422\u0435\u043a\u0443\u0449\u0430\u044f \u0441\u0445\u0435\u043c\u0430 \u0445\u043e\u0440\u043e\u0448\u043e \u0440\u0430\u0431\u043e\u0442\u0430\u0435\u0442 \u0434\u043b\u044f TCP: \u0431\u0440\u0430\u0443\u0437\u0435\u0440, Telegram Web, WhatsApp Web, Discord, YouTube, OpenAI \u0438 \u0447\u0430\u0441\u0442\u044c desktop-\u043f\u0440\u0438\u043b\u043e\u0436\u0435\u043d\u0438\u0439.<\/p>\n<p>\u041d\u043e \u043c\u043e\u0431\u0438\u043b\u044c\u043d\u044b\u0435 \u043f\u0440\u0438\u043b\u043e\u0436\u0435\u043d\u0438\u044f \u0438 \u0437\u0432\u043e\u043d\u043a\u0438 \u043c\u043e\u0433\u0443\u0442 \u0438\u0441\u043f\u043e\u043b\u044c\u0437\u043e\u0432\u0430\u0442\u044c UDP: Telegram calls, WhatsApp calls, QUIC, STUN\/TURN. \u0427\u0430\u0441\u0442\u0438\u0447\u043d\u043e \u043f\u043e\u043c\u043e\u0433\u0430\u0435\u0442 \u0431\u043b\u043e\u043a\u0438\u0440\u043e\u0432\u043a\u0430 UDP\/443, \u043f\u043e\u0442\u043e\u043c\u0443 \u0447\u0442\u043e \u043a\u043b\u0438\u0435\u043d\u0442\u044b \u043e\u0442\u043a\u0430\u0442\u044b\u0432\u0430\u044e\u0442\u0441\u044f \u043d\u0430 TCP. \u041d\u043e \u0434\u043b\u044f \u043f\u043e\u043b\u043d\u043e\u0446\u0435\u043d\u043d\u043e\u0439 \u043f\u043e\u0434\u0434\u0435\u0440\u0436\u043a\u0438 UDP \u043d\u0443\u0436\u0435\u043d \u0441\u043b\u0435\u0434\u0443\u044e\u0449\u0438\u0439 \u044d\u0442\u0430\u043f: UDP TProxy \u0438\u043b\u0438 \u0437\u0430\u0432\u043e\u0440\u043e\u0442 \u0432\u0441\u0435\u0433\u043e \u0442\u0440\u0430\u0444\u0438\u043a\u0430 \u043a\u043e\u043d\u043a\u0440\u0435\u0442\u043d\u043e\u0433\u043e \u0443\u0441\u0442\u0440\u043e\u0439\u0441\u0442\u0432\u0430 \u0447\u0435\u0440\u0435\u0437 \u0442\u0443\u043d\u043d\u0435\u043b\u044c.<\/p>\n<p>\u0415\u0449\u0435 \u043e\u0434\u0438\u043d \u043a\u043e\u043c\u043f\u0440\u043e\u043c\u0438\u0441\u0441 \u0441\u0432\u044f\u0437\u0430\u043d \u0441 WhatsApp. Telegram \u0438\u043c\u0435\u0435\u0442 \u0431\u043e\u043b\u0435\u0435 \u043f\u043e\u043d\u044f\u0442\u043d\u044b\u0435 IP-\u0434\u0438\u0430\u043f\u0430\u0437\u043e\u043d\u044b, \u0430 WhatsApp \u0430\u043a\u0442\u0438\u0432\u043d\u043e \u0438\u0441\u043f\u043e\u043b\u044c\u0437\u0443\u0435\u0442 \u0438\u043d\u0444\u0440\u0430\u0441\u0442\u0440\u0443\u043a\u0442\u0443\u0440\u0443 Meta \u0438 CDN. \u0427\u0435\u043c \u0448\u0438\u0440\u0435 \u0441\u043f\u0438\u0441\u043e\u043a \u0434\u043e\u043c\u0435\u043d\u043e\u0432 Meta, \u0442\u0435\u043c \u0431\u043e\u043b\u044c\u0448\u0435 \u0448\u0430\u043d\u0441\u043e\u0432 \u043f\u043e\u0439\u043c\u0430\u0442\u044c \u0432\u0435\u0441\u044c WhatsApp, \u043d\u043e \u0442\u0435\u043c \u0431\u043e\u043b\u044c\u0448\u0435 \u0441\u043e\u0441\u0435\u0434\u043d\u0435\u0433\u043e \u0442\u0440\u0430\u0444\u0438\u043a\u0430 \u0442\u043e\u0436\u0435 \u0443\u0439\u0434\u0435\u0442 \u0447\u0435\u0440\u0435\u0437 \u0442\u0443\u043d\u043d\u0435\u043b\u044c.<\/p>\n<p>\u041e\u0442\u0434\u0435\u043b\u044c\u043d\u044b\u0439 \u0441\u043b\u0435\u0434\u0443\u044e\u0449\u0438\u0439 \u044d\u0442\u0430\u043f: \u043f\u043e\u0434\u043a\u043b\u044e\u0447\u0435\u043d\u0438\u0435 \u0432\u043d\u0435\u0448\u043d\u0435\u0433\u043e MikroTik \u0447\u0435\u0440\u0435\u0437 WireGuard site-to-site, \u0447\u0442\u043e\u0431\u044b \u0443\u0434\u0430\u043b\u0435\u043d\u043d\u0430\u044f \u0441\u0435\u0442\u044c \u0442\u043e\u0436\u0435 \u0445\u043e\u0434\u0438\u043b\u0430 \u0447\u0435\u0440\u0435\u0437 \u044d\u0442\u043e\u0442 \u0434\u043e\u043c\u0430\u0448\u043d\u0438\u0439 \u0448\u043b\u044e\u0437. \u041d\u043e \u044d\u0442\u043e \u0443\u0436\u0435 \u043e\u0442\u0434\u0435\u043b\u044c\u043d\u0430\u044f \u0438\u0441\u0442\u043e\u0440\u0438\u044f, \u043f\u043e\u0442\u043e\u043c\u0443 \u0447\u0442\u043e \u0442\u0430\u043c \u0434\u043e\u0431\u0430\u0432\u043b\u044f\u044e\u0442\u0441\u044f peer keys, allowed IP, \u043c\u0430\u0440\u0448\u0440\u0443\u0442\u044b \u0438 \u043f\u0440\u043e\u0431\u0440\u043e\u0441 UDP-\u043f\u043e\u0440\u0442\u0430 \u0434\u043e OpenWrt.<\/p>\n<h2>\u0412\u044b\u0432\u043e\u0434\u044b<\/h2>\n<ol>\n<li>\n<p>\u0421\u043d\u0430\u0447\u0430\u043b\u0430 \u043d\u0430\u0434\u043e \u0443\u0431\u0435\u0434\u0438\u0442\u044c\u0441\u044f, \u0447\u0442\u043e \u043a\u043b\u0438\u0435\u043d\u0442\u044b \u0434\u0435\u0439\u0441\u0442\u0432\u0438\u0442\u0435\u043b\u044c\u043d\u043e \u0445\u043e\u0434\u044f\u0442 \u0447\u0435\u0440\u0435\u0437 OpenWrt. \u0415\u0441\u043b\u0438 \u043f\u0435\u0440\u0432\u044b\u0439 hop \u043d\u0435 192.168.0.2, \u0434\u0430\u043b\u044c\u0448\u0435 \u043c\u043e\u0436\u043d\u043e \u043d\u0435 \u043f\u0440\u043e\u0434\u043e\u043b\u0436\u0430\u0442\u044c.<\/p>\n<\/li>\n<li>\n<p>Outbound \u043d\u0430\u0434\u043e \u043f\u0440\u043e\u0432\u0435\u0440\u044f\u0442\u044c \u043e\u0442\u0434\u0435\u043b\u044c\u043d\u043e. SOCKS-\u0442\u0435\u0441\u0442 \u0447\u0435\u0440\u0435\u0437 curl \u0431\u044b\u0441\u0442\u0440\u043e \u043f\u043e\u043a\u0430\u0437\u044b\u0432\u0430\u0435\u0442, \u0440\u0430\u0431\u043e\u0442\u0430\u0435\u0442 \u043b\u0438 Xray\/VLESS Reality \u0441\u0430\u043c \u043f\u043e \u0441\u0435\u0431\u0435.<\/p>\n<\/li>\n<li>\n<p>TUN \u043d\u0435 \u0432\u0441\u0435\u0433\u0434\u0430 \u043b\u0443\u0447\u0448\u0438\u0439 \u0432\u0430\u0440\u0438\u0430\u043d\u0442. \u0412 \u043c\u043e\u0435\u0439 \u0441\u0445\u0435\u043c\u0435 \u043e\u043d \u043b\u043e\u0432\u0438\u043b \u0442\u0440\u0430\u0444\u0438\u043a \u0441\u0430\u043c\u043e\u0433\u043e OpenWrt \u0438 \u043b\u043e\u043c\u0430\u043b DNS. TCP redirect \u043e\u043a\u0430\u0437\u0430\u043b\u0441\u044f \u043f\u0440\u043e\u0449\u0435 \u0438 \u0441\u0442\u0430\u0431\u0438\u043b\u044c\u043d\u0435\u0435.<\/p>\n<\/li>\n<li>\n<p>Firewall \u043c\u043e\u0436\u0435\u0442 \u0441\u043b\u043e\u043c\u0430\u0442\u044c \u0432\u0441\u0435 \u0434\u0430\u0436\u0435 \u0442\u043e\u0433\u0434\u0430, \u043a\u043e\u0433\u0434\u0430 nft-\u0441\u0447\u0435\u0442\u0447\u0438\u043a\u0438 \u0440\u0430\u0441\u0442\u0443\u0442. \u0415\u0441\u043b\u0438 redirect \u0432\u0435\u0434\u0435\u0442 \u043d\u0430 \u043b\u043e\u043a\u0430\u043b\u044c\u043d\u044b\u0439 \u043f\u043e\u0440\u0442, \u044d\u0442\u043e\u0442 \u043f\u043e\u0440\u0442 \u0434\u043e\u043b\u0436\u0435\u043d \u0431\u044b\u0442\u044c \u0440\u0430\u0437\u0440\u0435\u0448\u0435\u043d \u0434\u043b\u044f \u043d\u0443\u0436\u043d\u043e\u0439 \u0437\u043e\u043d\u044b.<\/p>\n<\/li>\n<li>\n<p>\u041f\u043e\u0440\u044f\u0434\u043e\u043a \u043f\u0440\u0430\u0432\u0438\u043b \u0432 sing-box \u043a\u0440\u0438\u0442\u0438\u0447\u0435\u043d. \u041f\u0435\u0440\u0432\u043e\u0435 \u0441\u043e\u0432\u043f\u0430\u0434\u0435\u043d\u0438\u0435 \u043f\u043e\u0431\u0435\u0436\u0434\u0430\u0435\u0442.<\/p>\n<\/li>\n<li>\n<p>\u041b\u044e\u0431\u044b\u0435 \u0441\u0435\u0442\u0435\u0432\u044b\u0435 \u044d\u043a\u0441\u043f\u0435\u0440\u0438\u043c\u0435\u043d\u0442\u044b \u043d\u0430\u0434\u043e \u0434\u0435\u043b\u0430\u0442\u044c \u0441 \u043f\u043b\u0430\u043d\u043e\u043c \u043e\u0442\u043a\u0430\u0442\u0430. Snapshot \u0432 Proxmox \u0438 \u043a\u043e\u043c\u0430\u043d\u0434\u0430 \u0443\u0434\u0430\u043b\u0435\u043d\u0438\u044f nft-\u0442\u0430\u0431\u043b\u0438\u0446\u044b \u0441\u043f\u0430\u0441\u0430\u044e\u0442 \u0432\u0440\u0435\u043c\u044f.<\/p>\n<\/li>\n<\/ol>\n<h2>\u0418\u0442\u043e\u0433<\/h2>\n<p>\u041d\u0430\u0447\u0430\u043b\u043e\u0441\u044c \u0432\u0441\u0435 \u0441 \u0431\u044b\u0442\u043e\u0432\u043e\u0439 \u043f\u043e\u0442\u0440\u0435\u0431\u043d\u043e\u0441\u0442\u0438: \u043d\u0430\u0434\u043e\u0435\u043b\u043e \u0434\u0435\u0440\u0436\u0430\u0442\u044c VPN-\u043a\u043b\u0438\u0435\u043d\u0442\u044b \u043d\u0430 \u043a\u0430\u0436\u0434\u043e\u043c \u0443\u0441\u0442\u0440\u043e\u0439\u0441\u0442\u0432\u0435. \u0425\u043e\u0442\u0435\u043b\u043e\u0441\u044c, \u0447\u0442\u043e\u0431\u044b \u0441\u0435\u0442\u044c \u0441\u0430\u043c\u0430 \u043f\u043e\u043d\u0438\u043c\u0430\u043b\u0430, \u0447\u0442\u043e \u043a\u0443\u0434\u0430 \u043e\u0442\u043f\u0440\u0430\u0432\u043b\u044f\u0442\u044c. \u0414\u043e\u043c\u0430 \u0443\u0436\u0435 \u0431\u044b\u043b Proxmox, \u043f\u043e\u044d\u0442\u043e\u043c\u0443 OpenWrt \u0432 \u0432\u0438\u0440\u0442\u0443\u0430\u043b\u043a\u0435 \u043e\u043a\u0430\u0437\u0430\u043b\u0441\u044f \u0443\u0434\u043e\u0431\u043d\u043e\u0439 \u0442\u043e\u0447\u043a\u043e\u0439 \u0434\u043b\u044f \u044d\u043a\u0441\u043f\u0435\u0440\u0438\u043c\u0435\u043d\u0442\u0430.<\/p>\n<p>\u041f\u043e \u043f\u0443\u0442\u0438 \u043f\u0440\u0438\u0448\u043b\u043e\u0441\u044c \u043f\u0440\u043e\u0439\u0442\u0438 \u0447\u0435\u0440\u0435\u0437 DHCP, DNS, firewall, nftables, sing-box, Xray\/VLESS Reality, \u043d\u0435\u0443\u0434\u0430\u0447\u043d\u044b\u0439 TUN, \u043d\u0435\u0443\u0434\u0430\u0447\u043d\u044b\u0439 TProxy, ERR_CONNECTION_REFUSED \u0438 DNS_PROBE_FINISHED_NO_INTERNET. \u041d\u043e \u0444\u0438\u043d\u0430\u043b\u044c\u043d\u0430\u044f \u0441\u0445\u0435\u043c\u0430 \u043e\u043a\u0430\u0437\u0430\u043b\u0430\u0441\u044c \u0434\u043e\u0441\u0442\u0430\u0442\u043e\u0447\u043d\u043e \u043f\u0440\u043e\u0441\u0442\u043e\u0439: OpenWrt \u043a\u0430\u043a \u0448\u043b\u044e\u0437, nftables redirect, sing-box \u043d\u0430 7892, \u043d\u0443\u0436\u043d\u044b\u0435 \u0434\u043e\u043c\u0435\u043d\u044b \u0447\u0435\u0440\u0435\u0437 \u0442\u0443\u043d\u043d\u0435\u043b\u044c, \u0432\u0441\u0435 \u043e\u0441\u0442\u0430\u043b\u044c\u043d\u043e\u0435 \u043d\u0430\u043f\u0440\u044f\u043c\u0443\u044e.<\/p>\n<p>\u041a\u043e\u0433\u0434\u0430 \u043f\u043e\u0441\u043b\u0435 \u0432\u0441\u0435\u0445 \u044d\u0442\u0438\u0445 \u043f\u0440\u043e\u0432\u0435\u0440\u043e\u043a ifconfig.me \u043f\u043e\u043a\u0430\u0437\u044b\u0432\u0430\u0435\u0442 IP \u0442\u0443\u043d\u043d\u0435\u043b\u044f, \u0430 api.ipify.org \u043f\u043e\u043a\u0430\u0437\u044b\u0432\u0430\u0435\u0442 \u043f\u0440\u044f\u043c\u043e\u0439 IP \u043f\u0440\u043e\u0432\u0430\u0439\u0434\u0435\u0440\u0430, \u044d\u0442\u043e \u0434\u0435\u0439\u0441\u0442\u0432\u0438\u0442\u0435\u043b\u044c\u043d\u043e \u043f\u0440\u0438\u044f\u0442\u043d\u044b\u0439 \u043c\u043e\u043c\u0435\u043d\u0442. \u041f\u043e\u0442\u043e\u043c\u0443 \u0447\u0442\u043e \u0442\u0435\u043f\u0435\u0440\u044c VPN \u0436\u0438\u0432\u0435\u0442 \u043d\u0435 \u043d\u0430 \u043a\u0430\u0436\u0434\u043e\u043c \u0443\u0441\u0442\u0440\u043e\u0439\u0441\u0442\u0432\u0435 \u043e\u0442\u0434\u0435\u043b\u044c\u043d\u043e, \u0430 \u0432 \u043e\u0434\u043d\u043e\u043c \u043f\u043e\u043d\u044f\u0442\u043d\u043e\u043c \u043c\u0435\u0441\u0442\u0435: \u043d\u0430 \u0434\u043e\u043c\u0430\u0448\u043d\u0435\u043c \u0448\u043b\u044e\u0437\u0435.<\/p>\n<\/div>\n<p>\u0441\u0441\u044b\u043b\u043a\u0430 \u043d\u0430 \u043e\u0440\u0438\u0433\u0438\u043d\u0430\u043b \u0441\u0442\u0430\u0442\u044c\u0438 <a href=\"https:\/\/habr.com\/ru\/articles\/1046960\/\">https:\/\/habr.com\/ru\/articles\/1046960\/<\/a><\/p>\n","protected":false},"excerpt":{"rendered":"<p>\u0417\u0430\u0447\u0435\u043c \u044f \u0432\u043e\u043e\u0431\u0449\u0435 \u0432 \u044d\u0442\u043e \u043f\u043e\u043b\u0435\u0437\u0412 \u043a\u0430\u043a\u043e\u0439-\u0442\u043e \u043c\u043e\u043c\u0435\u043d\u0442 \u044f \u043f\u043e\u0439\u043c\u0430\u043b \u0441\u0435\u0431\u044f \u043d\u0430 \u0441\u0442\u0440\u0430\u043d\u043d\u043e\u0439 \u043c\u044b\u0441\u043b\u0438: \u0434\u043e\u043c\u0430 \u0435\u0441\u0442\u044c \u0441\u0435\u0440\u0432\u0435\u0440 \u043f\u043e\u0434 Proxmox, \u043d\u043e\u0440\u043c\u0430\u043b\u044c\u043d\u0430\u044f \u043b\u043e\u043a\u0430\u043b\u044c\u043d\u0430\u044f \u0441\u0435\u0442\u044c, \u043d\u0435\u0441\u043a\u043e\u043b\u044c\u043a\u043e \u043f\u043e\u0441\u0442\u043e\u044f\u043d\u043d\u044b\u0445 \u0443\u0441\u0442\u0440\u043e\u0439\u0441\u0442\u0432, \u0430 VPN \u0432\u0441\u0435 \u0440\u0430\u0432\u043d\u043e \u0436\u0438\u0432\u0435\u0442 \u043d\u0430 \u043a\u0430\u0436\u0434\u043e\u043c \u043a\u043b\u0438\u0435\u043d\u0442\u0435 \u043e\u0442\u0434\u0435\u043b\u044c\u043d\u043e. \u041d\u0430 \u043d\u043e\u0443\u0442\u0431\u0443\u043a\u0435 \u043e\u0434\u0438\u043d \u043a\u043b\u0438\u0435\u043d\u0442, \u043d\u0430 \u0442\u0435\u043b\u0435\u0444\u043e\u043d\u0435 \u0434\u0440\u0443\u0433\u043e\u0439, \u043d\u0430 \u0440\u0430\u0431\u043e\u0447\u0435\u0439 \u043c\u0430\u0448\u0438\u043d\u0435 \u043b\u0443\u0447\u0448\u0435 \u0432\u043e\u043e\u0431\u0449\u0435 \u043d\u0438\u0447\u0435\u0433\u043e \u043b\u0438\u0448\u043d\u0435\u0433\u043e \u043d\u0435 \u0442\u0440\u043e\u0433\u0430\u0442\u044c, \u043d\u0430 \u0442\u0435\u043b\u0435\u0432\u0438\u0437\u043e\u0440\u0435 \u043f\u043e\u0441\u0442\u0430\u0432\u0438\u0442\u044c \u043d\u043e\u0440\u043c\u0430\u043b\u044c\u043d\u044b\u0439 \u043a\u043b\u0438\u0435\u043d\u0442 \u043f\u043e\u0447\u0442\u0438 \u043d\u0435\u0432\u043e\u0437\u043c\u043e\u0436\u043d\u043e.\u0421\u043d\u0430\u0447\u0430\u043b\u0430 \u044d\u0442\u043e \u043d\u0435 \u0432\u044b\u0433\u043b\u044f\u0434\u0438\u0442 \u043f\u0440\u043e\u0431\u043b\u0435\u043c\u043e\u0439. \u041d\u0443 \u043f\u043e\u0441\u0442\u0430\u0432\u0438\u043b VPN \u043d\u0430 \u043d\u043e\u0443\u0442\u0431\u0443\u043a. \u041f\u043e\u0442\u043e\u043c \u043d\u0430 \u0442\u0435\u043b\u0435\u0444\u043e\u043d. \u041f\u043e\u0442\u043e\u043c \u0435\u0449\u0435 \u0440\u0430\u0437 \u043d\u0430 \u0432\u0442\u043e\u0440\u043e\u0439 \u043d\u043e\u0443\u0442\u0431\u0443\u043a. \u041d\u043e \u0434\u0430\u043b\u044c\u0448\u0435 \u043d\u0430\u0447\u0438\u043d\u0430\u0435\u0442\u0441\u044f \u043e\u0431\u044b\u0447\u043d\u044b\u0439 \u0431\u044b\u0442\u043e\u0432\u043e\u0439 \u0445\u0430\u043e\u0441: \u0433\u0434\u0435-\u0442\u043e VPN \u0437\u0430\u0431\u044b\u043b\u0438 \u0432\u043a\u043b\u044e\u0447\u0438\u0442\u044c, \u0433\u0434\u0435-\u0442\u043e \u043e\u043d \u043c\u0435\u0448\u0430\u0435\u0442 \u043b\u043e\u043a\u0430\u043b\u043a\u0435, \u0433\u0434\u0435-\u0442\u043e \u043b\u043e\u043c\u0430\u0435\u0442 \u0431\u0430\u043d\u043a\u043e\u0432\u0441\u043a\u043e\u0435 \u043f\u0440\u0438\u043b\u043e\u0436\u0435\u043d\u0438\u0435, \u0433\u0434\u0435-\u0442\u043e \u0442\u044f\u043d\u0435\u0442 \u0432\u0435\u0441\u044c \u0442\u0440\u0430\u0444\u0438\u043a \u0447\u0435\u0440\u0435\u0437 \u0443\u0434\u0430\u043b\u0435\u043d\u043d\u044b\u0439 \u0441\u0435\u0440\u0432\u0435\u0440 \u0431\u0435\u0437 \u043d\u0435\u043e\u0431\u0445\u043e\u0434\u0438\u043c\u043e\u0441\u0442\u0438.\u041e\u0442\u0434\u0435\u043b\u044c\u043d\u0430\u044f \u0431\u043e\u043b\u044c: \u0443\u0441\u0442\u0440\u043e\u0439\u0441\u0442\u0432\u0430, \u043d\u0430 \u043a\u043e\u0442\u043e\u0440\u044b\u0435 VPN-\u043a\u043b\u0438\u0435\u043d\u0442 \u043d\u043e\u0440\u043c\u0430\u043b\u044c\u043d\u043e \u043d\u0435 \u043f\u043e\u0441\u0442\u0430\u0432\u0438\u0442\u044c. \u0422\u0435\u043b\u0435\u0432\u0438\u0437\u043e\u0440\u044b, \u043f\u0440\u0438\u0441\u0442\u0430\u0432\u043a\u0438, \u0443\u043c\u043d\u044b\u0435 \u043a\u043e\u043b\u043e\u043d\u043a\u0438, IoT, \u0433\u043e\u0441\u0442\u0435\u0432\u044b\u0435 \u0442\u0435\u043b\u0435\u0444\u043e\u043d\u044b. \u0414\u0430 \u0438 \u043e\u0431\u044a\u044f\u0441\u043d\u044f\u0442\u044c \u043a\u0430\u0436\u0434\u043e\u043c\u0443 \u0434\u043e\u043c\u0430\u0448\u043d\u0435\u043c\u0443 \u043f\u043e\u043b\u044c\u0437\u043e\u0432\u0430\u0442\u0435\u043b\u044e, \u043a\u043e\u0433\u0434\u0430 \u0432\u043a\u043b\u044e\u0447\u0430\u0442\u044c VPN, \u0430 \u043a\u043e\u0433\u0434\u0430 \u0432\u044b\u043a\u043b\u044e\u0447\u0430\u0442\u044c, \u0442\u043e\u0436\u0435 \u043d\u0435 \u0445\u043e\u0447\u0435\u0442\u0441\u044f.\u0422\u0430\u043a \u043f\u043e\u044f\u0432\u0438\u043b\u0430\u0441\u044c \u0438\u0434\u0435\u044f \u0432\u044b\u043d\u0435\u0441\u0442\u0438 \u043b\u043e\u0433\u0438\u043a\u0443 \u043d\u0430 \u0448\u043b\u044e\u0437. \u041f\u0443\u0441\u0442\u044c \u043a\u043b\u0438\u0435\u043d\u0442 \u043f\u0440\u043e\u0441\u0442\u043e \u043f\u043e\u0434\u043a\u043b\u044e\u0447\u0430\u0435\u0442\u0441\u044f \u043a Wi-Fi \u0438\u043b\u0438 \u043a\u0430\u0431\u0435\u043b\u044e \u0438 \u043f\u043e\u043b\u0443\u0447\u0430\u0435\u0442 \u0438\u043d\u0442\u0435\u0440\u043d\u0435\u0442. \u0410 \u0434\u0430\u043b\u044c\u0448\u0435 \u0443\u0436\u0435 \u0434\u043e\u043c\u0430\u0448\u043d\u0438\u0439 \u0448\u043b\u044e\u0437 \u0441\u0430\u043c \u0440\u0435\u0448\u0430\u0435\u0442, \u0447\u0442\u043e \u043e\u0442\u043f\u0440\u0430\u0432\u0438\u0442\u044c \u043d\u0430\u043f\u0440\u044f\u043c\u0443\u044e, \u0430 \u0447\u0442\u043e \u0437\u0430\u0432\u0435\u0440\u043d\u0443\u0442\u044c \u0447\u0435\u0440\u0435\u0437 \u0442\u0443\u043d\u043d\u0435\u043b\u044c.\u0413\u043b\u0430\u0432\u043d\u0430\u044f \u0446\u0435\u043b\u044c \u0431\u044b\u043b\u0430 \u043d\u0435 \u0441\u0434\u0435\u043b\u0430\u0442\u044c \u201c\u0432\u0435\u0441\u044c \u0438\u043d\u0442\u0435\u0440\u043d\u0435\u0442 \u0447\u0435\u0440\u0435\u0437 VPN\u201d. \u041d\u0430\u043e\u0431\u043e\u0440\u043e\u0442, \u0445\u043e\u0442\u0435\u043b\u043e\u0441\u044c \u043d\u043e\u0440\u043c\u0430\u043b\u044c\u043d\u044b\u0439 split routing \u043d\u0430 \u0443\u0440\u043e\u0432\u043d\u0435 \u0441\u0435\u0442\u0438. \u041e\u0431\u044b\u0447\u043d\u044b\u0435 \u0441\u0430\u0439\u0442\u044b, \u043e\u0431\u043d\u043e\u0432\u043b\u0435\u043d\u0438\u044f, \u043b\u043e\u043a\u0430\u043b\u044c\u043d\u044b\u0435 \u0441\u0435\u0440\u0432\u0438\u0441\u044b \u0438 \u0442\u044f\u0436\u0435\u043b\u044b\u0435 \u0437\u0430\u0433\u0440\u0443\u0437\u043a\u0438 \u043f\u0443\u0441\u0442\u044c \u0438\u0434\u0443\u0442 \u043d\u0430\u043f\u0440\u044f\u043c\u0443\u044e. \u0427\u0435\u0440\u0435\u0437 \u0442\u0443\u043d\u043d\u0435\u043b\u044c \u043d\u0443\u0436\u043d\u044b \u0442\u043e\u043b\u044c\u043a\u043e \u043a\u043e\u043d\u043a\u0440\u0435\u0442\u043d\u044b\u0435 \u0434\u043e\u043c\u0435\u043d\u044b \u0438 IP: YouTube, Telegram, WhatsApp, Discord, OpenAI \u0438 \u043f\u043e\u0445\u043e\u0436\u0438\u0435 \u0441\u0435\u0440\u0432\u0438\u0441\u044b.\u0427\u0442\u043e \u0432 \u0438\u0442\u043e\u0433\u0435 \u0441\u043e\u0431\u0438\u0440\u0430\u0435\u043c\u0412 \u0444\u0438\u043d\u0430\u043b\u0435 \u0441\u0445\u0435\u043c\u0430 \u0432\u044b\u0433\u043b\u044f\u0434\u0438\u0442 \u0442\u0430\u043a: OpenWrt \u0437\u0430\u043f\u0443\u0449\u0435\u043d \u0432\u0438\u0440\u0442\u0443\u0430\u043b\u044c\u043d\u043e\u0439 \u043c\u0430\u0448\u0438\u043d\u043e\u0439 \u0432 Proxmox, \u0440\u0430\u0437\u0434\u0430\u0435\u0442 DHCP, \u043e\u0431\u0441\u043b\u0443\u0436\u0438\u0432\u0430\u0435\u0442 DNS \u0438 \u0441\u0442\u0430\u043d\u043e\u0432\u0438\u0442\u0441\u044f \u043e\u0441\u043d\u043e\u0432\u043d\u044b\u043c gateway \u0434\u043b\u044f \u043a\u043b\u0438\u0435\u043d\u0442\u043e\u0432. TCP-\u0442\u0440\u0430\u0444\u0438\u043a \u043a\u043b\u0438\u0435\u043d\u0442\u043e\u0432 \u0447\u0435\u0440\u0435\u0437 nftables \u043f\u0435\u0440\u0435\u043d\u0430\u043f\u0440\u0430\u0432\u043b\u044f\u0435\u0442\u0441\u044f \u043d\u0430 \u043b\u043e\u043a\u0430\u043b\u044c\u043d\u044b\u0439 \u043f\u043e\u0440\u0442 sing-box. \u0410 sing-box \u0443\u0436\u0435 \u0440\u0435\u0448\u0430\u0435\u0442, \u043a\u0443\u0434\u0430 \u043e\u0442\u043f\u0440\u0430\u0432\u0438\u0442\u044c \u0441\u043e\u0435\u0434\u0438\u043d\u0435\u043d\u0438\u0435: direct \u0438\u043b\u0438 \u0447\u0435\u0440\u0435\u0437 Xray\/VLESS Reality \u0438\u0437 Amnezia.\u0420\u0438\u0441\u0443\u043d\u043e\u043a 1. \u0418\u0441\u0445\u043e\u0434\u043d\u0430\u044f \u0441\u0445\u0435\u043c\u0430: OpenWrt \u0437\u0430\u043f\u0443\u0449\u0435\u043d \u0432 Proxmox \u0438 \u043d\u0430\u0445\u043e\u0434\u0438\u0442\u0441\u044f \u0432 \u0442\u043e\u0439 \u0436\u0435 \u043f\u043e\u0434\u0441\u0435\u0442\u0438, \u0447\u0442\u043e \u0438 \u043a\u043b\u0438\u0435\u043d\u0442\u044b. \u0421\u0430\u043c\u044b\u0439 \u0432\u0430\u0436\u043d\u044b\u0439 \u043c\u043e\u043c\u0435\u043d\u0442: OpenWrt \u043d\u0430\u0445\u043e\u0434\u0438\u0442\u0441\u044f \u0432 \u0442\u043e\u0439 \u0436\u0435 \u043f\u043e\u0434\u0441\u0435\u0442\u0438, \u0447\u0442\u043e \u0438 \u043a\u043b\u0438\u0435\u043d\u0442\u044b. \u042d\u0442\u043e \u043d\u0435 \u043a\u043b\u0430\u0441\u0441\u0438\u0447\u0435\u0441\u043a\u0430\u044f \u0441\u0445\u0435\u043c\u0430 \u0441 \u043e\u0442\u0434\u0435\u043b\u044c\u043d\u044b\u043c LAN \u0438 \u043e\u0442\u0434\u0435\u043b\u044c\u043d\u044b\u043c WAN. \u041a\u043b\u0438\u0435\u043d\u0442 \u043f\u043e\u043b\u0443\u0447\u0430\u0435\u0442 gateway 192.168.0.2, \u0441\u0430\u043c OpenWrt \u0434\u0430\u043b\u044c\u0448\u0435 \u043e\u0442\u043f\u0440\u0430\u0432\u043b\u044f\u0435\u0442 \u043e\u0431\u044b\u0447\u043d\u044b\u0439 \u0442\u0440\u0430\u0444\u0438\u043a \u043d\u0430 \u043e\u0441\u043d\u043e\u0432\u043d\u043e\u0439 \u0440\u043e\u0443\u0442\u0435\u0440 192.168.0.1.\u0418\u0437-\u0437\u0430 \u044d\u0442\u043e\u0433\u043e \u043d\u0435\u043a\u043e\u0442\u043e\u0440\u044b\u0435 \u0441\u0442\u0430\u043d\u0434\u0430\u0440\u0442\u043d\u044b\u0435 \u043a\u0440\u0430\u0441\u0438\u0432\u044b\u0435 \u0432\u0430\u0440\u0438\u0430\u043d\u0442\u044b, \u043d\u0430\u043f\u0440\u0438\u043c\u0435\u0440 TUN \u0441 auto_route \u0438 auto_redirect, \u043f\u043e\u0432\u0435\u043b\u0438 \u0441\u0435\u0431\u044f \u043d\u0435 \u0442\u0430\u043a, \u043a\u0430\u043a \u0445\u043e\u0442\u0435\u043b\u043e\u0441\u044c. \u041e\u043d\u0438 \u0445\u043e\u0440\u043e\u0448\u043e \u0441\u043c\u043e\u0442\u0440\u044f\u0442\u0441\u044f \u0432 \u043f\u0440\u0438\u043c\u0435\u0440\u0430\u0445, \u043d\u043e \u0432 \u043c\u043e\u0435\u0439 \u0441\u0445\u0435\u043c\u0435 \u043d\u0430\u0447\u0430\u043b\u0438 \u043b\u043e\u0432\u0438\u0442\u044c \u0442\u0440\u0430\u0444\u0438\u043a \u0441\u0430\u043c\u043e\u0433\u043e OpenWrt \u0438 \u043b\u043e\u043c\u0430\u0442\u044c DNS.\u041f\u043b\u0430\u043d \u0430\u0434\u0440\u0435\u0441\u0430\u0446\u0438\u0438\u0427\u0442\u043e\u0431\u044b \u0434\u0430\u043b\u044c\u0448\u0435 \u043a\u043e\u043c\u0430\u043d\u0434\u044b \u0447\u0438\u0442\u0430\u043b\u0438\u0441\u044c \u043d\u043e\u0440\u043c\u0430\u043b\u044c\u043d\u043e, \u0437\u0430\u0444\u0438\u043a\u0441\u0438\u0440\u0443\u0435\u043c \u0443\u0441\u043b\u043e\u0432\u043d\u044b\u0435 \u0430\u0434\u0440\u0435\u0441\u0430. \u0415\u0441\u043b\u0438 \u0443 \u0432\u0430\u0441 \u0434\u0440\u0443\u0433\u0430\u044f \u0441\u0435\u0442\u044c, \u043c\u0435\u043d\u044f\u0439\u0442\u0435 \u0438\u0445 \u043f\u043e\u0434 \u0441\u0435\u0431\u044f.\u041e\u0441\u043d\u043e\u0432\u043d\u0430\u044f \u0441\u0435\u0442\u044c:        192.168.0.0\/24\u041e\u0441\u043d\u043e\u0432\u043d\u043e\u0439 \u0440\u043e\u0443\u0442\u0435\u0440:      192.168.0.1OpenWrt VM:           192.168.0.2DHCP-\u0434\u0438\u0430\u043f\u0430\u0437\u043e\u043d:        192.168.0.100-192.168.0.199\u0422\u0435\u0441\u0442\u043e\u0432\u0430\u044f LAN OpenWrt: 192.168.50.0\/24OpenWrt LAN IP:       192.168.50.1sing-box redirect:    7892\/tcpXray\/VLESS server:    &lt;XRAY_SERVER_IP&gt;:443\u0427\u0442\u043e \u043f\u043e\u043d\u0430\u0434\u043e\u0431\u0438\u0442\u0441\u044f\u0441\u0435\u0440\u0432\u0435\u0440 \u0441 Proxmox, \u043a\u043e\u0442\u043e\u0440\u044b\u0439 \u043f\u043e\u0441\u0442\u043e\u044f\u043d\u043d\u043e \u0432\u043a\u043b\u044e\u0447\u0435\u043d;\u0432\u0438\u0440\u0442\u0443\u0430\u043b\u044c\u043d\u0430\u044f \u043c\u0430\u0448\u0438\u043d\u0430 OpenWrt x86_64;\u0434\u043e\u0441\u0442\u0443\u043f \u043a \u043a\u043e\u043d\u0441\u043e\u043b\u0438 OpenWrt \u0447\u0435\u0440\u0435\u0437 Proxmox, \u0447\u0442\u043e\u0431\u044b \u043d\u0435 \u043f\u043e\u0442\u0435\u0440\u044f\u0442\u044c\u0441\u044f \u043f\u0440\u0438 \u043e\u0448\u0438\u0431\u043a\u0430\u0445 \u0441 \u0441\u0435\u0442\u044c\u044e;\u043e\u0441\u043d\u043e\u0432\u043d\u043e\u0439 \u0440\u043e\u0443\u0442\u0435\u0440 192.168.0.1;\u0432\u043e\u0437\u043c\u043e\u0436\u043d\u043e\u0441\u0442\u044c \u0432\u044b\u043a\u043b\u044e\u0447\u0438\u0442\u044c DHCP \u043d\u0430 \u043e\u0441\u043d\u043e\u0432\u043d\u043e\u043c \u0440\u043e\u0443\u0442\u0435\u0440\u0435;\u0433\u043e\u0442\u043e\u0432\u044b\u0439 \u0440\u0430\u0431\u043e\u0447\u0438\u0439 \u043a\u043e\u043d\u0444\u0438\u0433 Xray\/VLESS Reality, \u043d\u0430\u043f\u0440\u0438\u043c\u0435\u0440 \u044d\u043a\u0441\u043f\u043e\u0440\u0442\u0438\u0440\u043e\u0432\u0430\u043d\u043d\u044b\u0439 \u0438\u0437 Amnezia;\u043d\u0435\u043c\u043d\u043e\u0433\u043e \u0442\u0435\u0440\u043f\u0435\u043d\u0438\u044f, \u043f\u043e\u0442\u043e\u043c\u0443 \u0447\u0442\u043e \u0441\u0435\u0442\u044c \u043b\u043e\u043c\u0430\u0435\u0442\u0441\u044f \u0431\u044b\u0441\u0442\u0440\u043e, \u0430 \u0447\u0438\u043d\u0438\u0442\u0441\u044f \u0432\u043d\u0438\u043c\u0430\u0442\u0435\u043b\u044c\u043d\u043e\u0439 \u043f\u0440\u043e\u0432\u0435\u0440\u043a\u043e\u0439 \u043f\u043e \u0441\u043b\u043e\u044f\u043c.\u0412\u0430\u0436\u043d\u043e: \u041f\u0435\u0440\u0435\u0434 \u0438\u0437\u043c\u0435\u043d\u0435\u043d\u0438\u044f\u043c\u0438 \u043b\u0443\u0447\u0448\u0435 \u0441\u0434\u0435\u043b\u0430\u0442\u044c snapshot VM \u0432 Proxmox. \u0415\u0441\u043b\u0438 \u0441\u043b\u043e\u043c\u0430\u0435\u0442\u0441\u044f DHCP, firewall \u0438\u043b\u0438 \u043c\u0430\u0440\u0448\u0440\u0443\u0442\u044b, \u043e\u0442\u043a\u0430\u0442 snapshot \u044d\u043a\u043e\u043d\u043e\u043c\u0438\u0442 \u043c\u043d\u043e\u0433\u043e \u043d\u0435\u0440\u0432\u043e\u0432.\u0428\u0430\u0433 1. \u0421\u043a\u0430\u0447\u0430\u0442\u044c \u043e\u0431\u0440\u0430\u0437 OpenWrt \u0438 \u043f\u043e\u0434\u0433\u043e\u0442\u043e\u0432\u0438\u0442\u044c VM \u0432 Proxmox\u0412\u043e\u0442 \u044d\u0442\u043e\u0433\u043e \u0434\u0435\u0439\u0441\u0442\u0432\u0438\u0442\u0435\u043b\u044c\u043d\u043e \u0447\u0430\u0441\u0442\u043e \u043d\u0435 \u0445\u0432\u0430\u0442\u0430\u0435\u0442 \u0432 \u0438\u043d\u0441\u0442\u0440\u0443\u043a\u0446\u0438\u044f\u0445. \u041e\u0431\u044b\u0447\u043d\u043e \u043f\u0438\u0448\u0443\u0442 \u201c\u0441\u043e\u0437\u0434\u0430\u0439\u0442\u0435 VM \u0441 OpenWrt\u201d, \u0430 \u0434\u0430\u043b\u044c\u0448\u0435 \u043a\u0430\u0436\u0434\u044b\u0439 \u0441\u0430\u043c \u0434\u043e\u0433\u0430\u0434\u044b\u0432\u0430\u0435\u0442\u0441\u044f, \u043a\u0430\u043a\u043e\u0439 \u043e\u0431\u0440\u0430\u0437 \u0431\u0440\u0430\u0442\u044c, \u043a\u0443\u0434\u0430 \u0435\u0433\u043e \u043a\u043b\u0430\u0441\u0442\u044c \u0438 \u043a\u0430\u043a \u0438\u043c\u043f\u043e\u0440\u0442\u0438\u0440\u043e\u0432\u0430\u0442\u044c \u0434\u0438\u0441\u043a \u0432 Proxmox. \u041f\u043e\u044d\u0442\u043e\u043c\u0443 \u0440\u0430\u0441\u043f\u0438\u0448\u0443 \u044d\u0442\u043e\u0442 \u043a\u0443\u0441\u043e\u043a \u043e\u0442\u0434\u0435\u043b\u044c\u043d\u043e.\u0414\u043b\u044f Proxmox \u0443\u0434\u043e\u0431\u043d\u0435\u0435 \u0431\u0440\u0430\u0442\u044c x86_64 \u043e\u0431\u0440\u0430\u0437 OpenWrt. \u042f \u0431\u044b \u043d\u0430\u0447\u0438\u043d\u0430\u043b \u0441 ext4 combined EFI \u043e\u0431\u0440\u0430\u0437\u0430. Ext4 \u043f\u0440\u043e\u0449\u0435 \u0440\u0430\u0441\u0448\u0438\u0440\u044f\u0442\u044c \u0438 \u0447\u0438\u043d\u0438\u0442\u044c, \u0430 EFI \u043e\u0431\u044b\u0447\u043d\u043e \u0441\u043f\u043e\u043a\u043e\u0439\u043d\u0435\u0435 \u0433\u0440\u0443\u0437\u0438\u0442\u0441\u044f \u0432 \u043d\u043e\u0432\u044b\u0445 \u0432\u0438\u0440\u0442\u0443\u0430\u043b\u044c\u043d\u044b\u0445 \u043e\u043a\u0440\u0443\u0436\u0435\u043d\u0438\u044f\u0445. \u0415\u0441\u043b\u0438 \u0443 \u0432\u0430\u0441 \u0441\u0442\u0430\u0440\u0430\u044f \u0441\u0445\u0435\u043c\u0430 BIOS\/SeaBIOS, \u043c\u043e\u0436\u043d\u043e \u0432\u0437\u044f\u0442\u044c \u043e\u0431\u044b\u0447\u043d\u044b\u0439 combined \u043e\u0431\u0440\u0430\u0437 \u0431\u0435\u0437 EFI.\u0412\u0430\u0436\u043d\u043e: \u041d\u043e\u043c\u0435\u0440 \u0432\u0435\u0440\u0441\u0438\u0438 \u0432 \u043a\u043e\u043c\u0430\u043d\u0434\u0430\u0445 \u043d\u0438\u0436\u0435 \u043b\u0443\u0447\u0448\u0435 \u0437\u0430\u043c\u0435\u043d\u0438\u0442\u044c \u043d\u0430 \u0430\u043a\u0442\u0443\u0430\u043b\u044c\u043d\u044b\u0439. \u0412 \u0441\u0442\u0430\u0442\u044c\u0435 \u044f \u043e\u0441\u0442\u0430\u0432\u043b\u044f\u044e \u043f\u0435\u0440\u0435\u043c\u0435\u043d\u043d\u0443\u044e OPENWRT_VERSION, \u0447\u0442\u043e\u0431\u044b \u043d\u0435 \u043f\u0440\u0438\u0432\u044f\u0437\u044b\u0432\u0430\u0442\u044c \u0438\u043d\u0441\u0442\u0440\u0443\u043a\u0446\u0438\u044e \u043a \u043a\u043e\u043d\u043a\u0440\u0435\u0442\u043d\u043e\u043c\u0443 \u0440\u0435\u043b\u0438\u0437\u0443.1.1. \u0421\u043a\u0430\u0447\u0430\u0442\u044c \u043e\u0431\u0440\u0430\u0437 \u043d\u0430 Proxmox-\u0445\u043e\u0441\u0442\u0435\u041a\u043e\u043c\u0430\u043d\u0434\u044b \u043d\u0438\u0436\u0435 \u0432\u044b\u043f\u043e\u043b\u043d\u044f\u044e\u0442\u0441\u044f \u0438\u043c\u0435\u043d\u043d\u043e \u043d\u0430 Proxmox, \u0442\u043e \u0435\u0441\u0442\u044c \u0432 \u043a\u043e\u043d\u0441\u043e\u043b\u0438 \u0432\u0438\u0434\u0430 root@pve, \u0430 \u043d\u0435 \u0432\u043d\u0443\u0442\u0440\u0438 OpenWrt. \u042d\u0442\u043e \u0432\u0430\u0436\u043d\u044b\u0439 \u043c\u043e\u043c\u0435\u043d\u0442. \u041d\u0430 Proxmox \u043d\u0435\u0442 uci \u0438 \u043d\u0435\u0442 \/etc\/config\/firewall, \u0437\u0430\u0442\u043e \u0438\u043c\u0435\u043d\u043d\u043e \u0442\u0430\u043c \u043c\u044b \u0441\u043e\u0437\u0434\u0430\u0435\u043c VM \u0438 \u0438\u043c\u043f\u043e\u0440\u0442\u0438\u0440\u0443\u0435\u043c \u0434\u0438\u0441\u043a.mkdir -p \/var\/lib\/vz\/template\/openwrtcd \/var\/lib\/vz\/template\/openwrtOPENWRT_VERSION=&#187;24.10.7&#8243;OPENWRT_TARGET=&#187;x86\/64&#8243;OPENWRT_BASE_URL=&#187;https:\/\/downloads.openwrt.org\/releases\/${OPENWRT_VERSION}\/targets\/${OPENWRT_TARGET}&#187;wget &#171;${OPENWRT_BASE_URL}\/openwrt-${OPENWRT_VERSION}-x86-64-generic-ext4-combined-efi.img.gz&#187;wget &#171;${OPENWRT_BASE_URL}\/sha256sums&#187;\u0415\u0441\u043b\u0438 \u043d\u0443\u0436\u043d\u043e\u0439 \u0432\u0435\u0440\u0441\u0438\u0438 \u0443\u0436\u0435 \u043d\u0435\u0442 \u0438\u043b\u0438 \u0432\u044b\u0448\u043b\u0430 \u043d\u043e\u0432\u0430\u044f, \u043f\u0440\u043e\u0449\u0435 \u043e\u0442\u043a\u0440\u044b\u0442\u044c \u043a\u0430\u0442\u0430\u043b\u043e\u0433 downloads.openwrt.org \u0432 \u0431\u0440\u0430\u0443\u0437\u0435\u0440\u0435 \u0438 \u043f\u043e\u0434\u0441\u0442\u0430\u0432\u0438\u0442\u044c \u0441\u0432\u0435\u0436\u0438\u0439 \u043d\u043e\u043c\u0435\u0440 \u0432\u0435\u0440\u0441\u0438\u0438. \u0414\u043b\u044f \u0441\u0442\u0430\u0442\u044c\u0438 \u0432\u0430\u0436\u0435\u043d \u043d\u0435 \u043a\u043e\u043d\u043a\u0440\u0435\u0442\u043d\u044b\u0439 \u043d\u043e\u043c\u0435\u0440, \u0430 \u043f\u0440\u0438\u043d\u0446\u0438\u043f: \u0431\u0435\u0440\u0435\u043c x86\/64 generic ext4 combined EFI image.1.2. \u041f\u0440\u043e\u0432\u0435\u0440\u0438\u0442\u044c checksum\u042d\u0442\u043e \u043d\u0435 \u043e\u0431\u044f\u0437\u0430\u0442\u0435\u043b\u044c\u043d\u044b\u0439, \u043d\u043e \u043f\u0440\u0430\u0432\u0438\u043b\u044c\u043d\u044b\u0439 \u0448\u0430\u0433. \u041e\u0431\u0440\u0430\u0437 \u0431\u0443\u0434\u0435\u0442 \u0438\u0441\u043f\u043e\u043b\u044c\u0437\u043e\u0432\u0430\u0442\u044c\u0441\u044f \u043a\u0430\u043a \u0434\u0438\u0441\u043a \u0440\u043e\u0443\u0442\u0435\u0440\u0430, \u043f\u043e\u044d\u0442\u043e\u043c\u0443 \u043b\u0443\u0447\u0448\u0435 \u0443\u0431\u0435\u0434\u0438\u0442\u044c\u0441\u044f, \u0447\u0442\u043e \u043e\u043d \u0441\u043a\u0430\u0447\u0430\u043b\u0441\u044f \u0431\u0435\u0437 \u043f\u043e\u0432\u0440\u0435\u0436\u0434\u0435\u043d\u0438\u0439.sha256sum -c &#8212;ignore-missing sha256sums\u0415\u0441\u043b\u0438 \u043f\u0440\u043e\u0432\u0435\u0440\u043a\u0430 \u043f\u0438\u0448\u0435\u0442 OK, \u043c\u043e\u0436\u043d\u043e \u0440\u0430\u0441\u043f\u0430\u043a\u043e\u0432\u044b\u0432\u0430\u0442\u044c \u043e\u0431\u0440\u0430\u0437. \u0415\u0441\u043b\u0438 \u0444\u0430\u0439\u043b \u043d\u0435 \u043d\u0430\u0439\u0434\u0435\u043d \u0432 sha256sums, \u0437\u043d\u0430\u0447\u0438\u0442 \u0438\u043c\u044f \u043e\u0431\u0440\u0430\u0437\u0430 \u043e\u0442\u043b\u0438\u0447\u0430\u0435\u0442\u0441\u044f \u043e\u0442 \u043e\u0436\u0438\u0434\u0430\u0435\u043c\u043e\u0433\u043e. \u0422\u043e\u0433\u0434\u0430 \u043d\u0430\u0434\u043e \u0441\u0432\u0435\u0440\u0438\u0442\u044c \u043d\u0430\u0437\u0432\u0430\u043d\u0438\u0435 \u0444\u0430\u0439\u043b\u0430 \u0432 \u043a\u0430\u0442\u0430\u043b\u043e\u0433\u0435 \u0440\u0435\u043b\u0438\u0437\u0430.1.3. \u0420\u0430\u0441\u043f\u0430\u043a\u043e\u0432\u0430\u0442\u044c \u0438 \u043a\u043e\u043d\u0432\u0435\u0440\u0442\u0438\u0440\u043e\u0432\u0430\u0442\u044c \u043e\u0431\u0440\u0430\u0437OpenWrt \u043e\u0431\u0440\u0430\u0437 \u043f\u0440\u0438\u0445\u043e\u0434\u0438\u0442 \u043a\u0430\u043a gzip-\u0430\u0440\u0445\u0438\u0432 \u0441 raw-\u0434\u0438\u0441\u043a\u043e\u043c \u0432\u043d\u0443\u0442\u0440\u0438. Proxmox \u0443\u043c\u0435\u0435\u0442 \u0438\u043c\u043f\u043e\u0440\u0442\u0438\u0440\u043e\u0432\u0430\u0442\u044c raw, \u043d\u043e \u043c\u043d\u0435 \u0443\u0434\u043e\u0431\u043d\u0435\u0435 \u0441\u043d\u0430\u0447\u0430\u043b\u0430 \u043a\u043e\u043d\u0432\u0435\u0440\u0442\u0438\u0440\u043e\u0432\u0430\u0442\u044c \u0435\u0433\u043e \u0432 qcow2.gzip -dk openwrt-${OPENWRT_VERSION}-x86-64-generic-ext4-combined-efi.img.gzqemu-img convert -f raw -O qcow2   openwrt-${OPENWRT_VERSION}-x86-64-generic-ext4-combined-efi.img   openwrt-${OPENWRT_VERSION}-x86-64-generic-ext4-combined-efi.qcow2qemu-img info openwrt-${OPENWRT_VERSION}-x86-64-generic-ext4-combined-efi.qcow2\u0415\u0441\u043b\u0438 qemu-img \u043d\u0435 \u043d\u0430\u0439\u0434\u0435\u043d, \u043d\u0430 Proxmox \u043e\u0431\u044b\u0447\u043d\u043e \u044d\u0442\u043e \u0441\u0442\u0440\u0430\u043d\u043d\u043e, \u043d\u043e \u043c\u043e\u0436\u043d\u043e \u043f\u043e\u0441\u0442\u0430\u0432\u0438\u0442\u044c qemu-utils. \u041d\u0430 \u043e\u0431\u044b\u0447\u043d\u043e\u043c Debian \u044d\u0442\u043e \u0434\u0435\u043b\u0430\u0435\u0442\u0441\u044f \u0447\u0435\u0440\u0435\u0437 apt install qemu-utils.1.4. \u0421\u043e\u0437\u0434\u0430\u0442\u044c VM \u0432 Proxmox\u0414\u0430\u043b\u044c\u0448\u0435 \u0441\u043e\u0437\u0434\u0430\u0435\u043c VM. \u041d\u043e\u043c\u0435\u0440 VMID \u043c\u043e\u0436\u043d\u043e \u0432\u044b\u0431\u0440\u0430\u0442\u044c \u043b\u044e\u0431\u043e\u0439 \u0441\u0432\u043e\u0431\u043e\u0434\u043d\u044b\u0439. \u0412 \u043f\u0440\u0438\u043c\u0435\u0440\u0435 \u044f \u0438\u0441\u043f\u043e\u043b\u044c\u0437\u0443\u044e 150.VMID=150VMNAME=&#187;openwrt-gateway&#187;qm create ${VMID}   &#8212;name ${VMNAME}   &#8212;memory 1024   &#8212;cores 2   &#8212;cpu host   &#8212;ostype l26   &#8212;net0 virtio,bridge=vmbr0   &#8212;net1 virtio,bridge=vmbr0\u0412 \u043f\u0440\u0438\u043c\u0435\u0440\u0435 \u043e\u0431\u0430 \u0438\u043d\u0442\u0435\u0440\u0444\u0435\u0439\u0441\u0430 \u043f\u043e\u0434\u043a\u043b\u044e\u0447\u0435\u043d\u044b \u043a vmbr0, \u043f\u043e\u0442\u043e\u043c\u0443 \u0447\u0442\u043e \u0443 \u043c\u0435\u043d\u044f \u043e\u0441\u043d\u043e\u0432\u043d\u0430\u044f \u0437\u0430\u0434\u0430\u0447\u0430 \u0431\u044b\u043b\u0430 \u0441\u043d\u0430\u0447\u0430\u043b\u0430 \u0437\u0430\u0432\u0435\u0441\u0442\u0438 OpenWrt \u0432 \u0441\u0443\u0449\u0435\u0441\u0442\u0432\u0443\u044e\u0449\u0435\u0439 \u0441\u0435\u0442\u0438. \u0415\u0441\u043b\u0438 \u0443 \u0432\u0430\u0441 \u0435\u0441\u0442\u044c \u043e\u0442\u0434\u0435\u043b\u044c\u043d\u044b\u0439 bridge \u043f\u043e\u0434 \u0442\u0435\u0441\u0442\u043e\u0432\u0443\u044e LAN, \u043d\u0430\u043f\u0440\u0438\u043c\u0435\u0440 vmbr1, \u0432\u0442\u043e\u0440\u043e\u0439 \u0438\u043d\u0442\u0435\u0440\u0444\u0435\u0439\u0441 \u043c\u043e\u0436\u043d\u043e \u043f\u043e\u0432\u0435\u0441\u0438\u0442\u044c \u0442\u0443\u0434\u0430.# \u0432\u0430\u0440\u0438\u0430\u043d\u0442, \u0435\u0441\u043b\u0438 \u0435\u0441\u0442\u044c \u043e\u0442\u0434\u0435\u043b\u044c\u043d\u044b\u0439 bridge \u043f\u043e\u0434 \u0442\u0435\u0441\u0442\u043e\u0432\u0443\u044e LAN# qm set ${VMID} &#8212;net1 virtio,bridge=vmbr1\u041f\u043e\u0447\u0435\u043c\u0443 virtio: \u0434\u043b\u044f \u0432\u0438\u0440\u0442\u0443\u0430\u043b\u044c\u043d\u043e\u0439 \u043c\u0430\u0448\u0438\u043d\u044b \u044d\u0442\u043e \u043d\u043e\u0440\u043c\u0430\u043b\u044c\u043d\u044b\u0439 \u0431\u044b\u0441\u0442\u0440\u044b\u0439 \u0441\u0435\u0442\u0435\u0432\u043e\u0439 \u0434\u0440\u0430\u0439\u0432\u0435\u0440. OpenWrt x86_64 \u0441 \u043d\u0438\u043c \u0440\u0430\u0431\u043e\u0442\u0430\u0435\u0442 \u0431\u0435\u0437 \u043b\u0438\u0448\u043d\u0438\u0445 \u043f\u043b\u044f\u0441\u043e\u043a.1.5. \u0418\u043c\u043f\u043e\u0440\u0442\u0438\u0440\u043e\u0432\u0430\u0442\u044c \u0434\u0438\u0441\u043a \u0432 VM\u0414\u0430\u043b\u044c\u0448\u0435 \u0438\u043c\u043f\u043e\u0440\u0442\u0438\u0440\u0443\u0435\u043c qcow2-\u0434\u0438\u0441\u043a \u0432 \u0445\u0440\u0430\u043d\u0438\u043b\u0438\u0449\u0435 Proxmox. \u0412 \u043f\u0440\u0438\u043c\u0435\u0440\u0435 \u0438\u0441\u043f\u043e\u043b\u044c\u0437\u0443\u0435\u0442\u0441\u044f local-lvm. \u0415\u0441\u043b\u0438 \u0443 \u0432\u0430\u0441 \u0434\u0440\u0443\u0433\u043e\u0435 \u0445\u0440\u0430\u043d\u0438\u043b\u0438\u0449\u0435, \u043d\u0430\u043f\u0440\u0438\u043c\u0435\u0440 local, zfs, nvme \u0438\u043b\u0438 ceph, \u0437\u0430\u043c\u0435\u043d\u0438\u0442\u0435 \u0438\u043c\u044f storage.qm importdisk ${VMID}   openwrt-${OPENWRT_VERSION}-x86-64-generic-ext4-combined-efi.qcow2   local-lvm\u041f\u043e\u0441\u043b\u0435 \u0438\u043c\u043f\u043e\u0440\u0442\u0430 \u0434\u0438\u0441\u043a \u043f\u043e\u044f\u0432\u0438\u0442\u0441\u044f \u043a\u0430\u043a unused disk \u0443 VM. \u0415\u0433\u043e \u043d\u0443\u0436\u043d\u043e \u043f\u043e\u0434\u043a\u043b\u044e\u0447\u0438\u0442\u044c \u043a\u0430\u043a \u043e\u0441\u043d\u043e\u0432\u043d\u043e\u0439 \u0434\u0438\u0441\u043a.qm set ${VMID} &#8212;scsihw virtio-scsi-pciqm set ${VMID} &#8212;scsi0 local-lvm:vm-${VMID}-disk-0qm set ${VMID} &#8212;boot order=scsi0\u0412\u0430\u0436\u043d\u043e: \u0415\u0441\u043b\u0438 Proxmox \u043d\u0430\u0437\u0432\u0430\u043b \u0438\u043c\u043f\u043e\u0440\u0442\u0438\u0440\u043e\u0432\u0430\u043d\u043d\u044b\u0439 \u0434\u0438\u0441\u043a \u0438\u043d\u0430\u0447\u0435, \u043f\u043e\u0441\u043c\u043e\u0442\u0440\u0438\u0442\u0435 VM \u0432 \u0432\u0435\u0431-\u043c\u043e\u0440\u0434\u0435 \u0438\u043b\u0438 \u0432\u044b\u043f\u043e\u043b\u043d\u0438\u0442\u0435 qm config 150. \u0418\u043d\u043e\u0433\u0434\u0430 \u0438\u043c\u044f \u0434\u0438\u0441\u043a\u0430 \u043e\u0442\u043b\u0438\u0447\u0430\u0435\u0442\u0441\u044f, \u043e\u0441\u043e\u0431\u0435\u043d\u043d\u043e \u0435\u0441\u043b\u0438 VM \u0443\u0436\u0435 \u0441\u043e\u0437\u0434\u0430\u0432\u0430\u043b\u0430\u0441\u044c \u0440\u0430\u043d\u044c\u0448\u0435.1.6. \u041d\u0430\u0441\u0442\u0440\u043e\u0438\u0442\u044c \u043a\u043e\u043d\u0441\u043e\u043b\u044c\u0427\u0442\u043e\u0431\u044b \u0431\u044b\u043b\u043e \u0443\u0434\u043e\u0431\u043d\u043e \u0437\u0430\u0445\u043e\u0434\u0438\u0442\u044c \u0432 OpenWrt \u0447\u0435\u0440\u0435\u0437 \u043a\u043e\u043d\u0441\u043e\u043b\u044c Proxmox, \u043c\u043e\u0436\u043d\u043e \u0432\u043a\u043b\u044e\u0447\u0438\u0442\u044c serial console. \u042d\u0442\u043e \u043e\u0441\u043e\u0431\u0435\u043d\u043d\u043e \u043f\u043e\u043b\u0435\u0437\u043d\u043e, \u043a\u043e\u0433\u0434\u0430 \u0441\u0435\u0442\u044c \u0441\u043b\u043e\u043c\u0430\u043b\u0430\u0441\u044c \u0438 SSH \u043d\u0435\u0434\u043e\u0441\u0442\u0443\u043f\u0435\u043d.qm set ${VMID} &#8212;serial0 socketqm set ${VMID} &#8212;vga serial0\u0415\u0441\u043b\u0438 \u0441 serial console \u0447\u0442\u043e-\u0442\u043e \u043d\u0435 \u043d\u0440\u0430\u0432\u0438\u0442\u0441\u044f, \u043c\u043e\u0436\u043d\u043e \u043e\u0441\u0442\u0430\u0432\u0438\u0442\u044c \u043e\u0431\u044b\u0447\u043d\u0443\u044e VGA-\u043a\u043e\u043d\u0441\u043e\u043b\u044c \u0432 \u0432\u0435\u0431-\u0438\u043d\u0442\u0435\u0440\u0444\u0435\u0439\u0441\u0435 Proxmox. \u0413\u043b\u0430\u0432\u043d\u043e\u0435, \u0447\u0442\u043e\u0431\u044b \u0431\u044b\u043b \u0430\u0432\u0430\u0440\u0438\u0439\u043d\u044b\u0439 \u0434\u043e\u0441\u0442\u0443\u043f \u043a VM \u043d\u0435 \u0447\u0435\u0440\u0435\u0437 \u0441\u0435\u0442\u044c.1.7. \u0423\u0432\u0435\u043b\u0438\u0447\u0438\u0442\u044c \u0434\u0438\u0441\u043a VM\u041e\u0431\u0440\u0430\u0437 OpenWrt \u043e\u0431\u044b\u0447\u043d\u043e \u043c\u0430\u043b\u0435\u043d\u044c\u043a\u0438\u0439. \u0414\u043b\u044f \u0447\u0438\u0441\u0442\u043e\u0433\u043e \u0440\u043e\u0443\u0442\u0435\u0440\u0430 \u044d\u0442\u043e\u0433\u043e \u0445\u0432\u0430\u0442\u0430\u0435\u0442, \u043d\u043e \u043c\u044b \u0431\u0443\u0434\u0435\u043c \u0441\u0442\u0430\u0432\u0438\u0442\u044c sing-box, tcpdump, curl, LuCI, WireGuard \u0438 \u0434\u0440\u0443\u0433\u0438\u0435 \u043f\u0430\u043a\u0435\u0442\u044b. \u041f\u043e\u044d\u0442\u043e\u043c\u0443 \u043b\u0443\u0447\u0448\u0435 \u0441\u0440\u0430\u0437\u0443 \u0443\u0432\u0435\u043b\u0438\u0447\u0438\u0442\u044c \u0434\u0438\u0441\u043a.qm resize ${VMID} scsi0 +2G\u042d\u0442\u043e \u0443\u0432\u0435\u043b\u0438\u0447\u0438\u0432\u0430\u0435\u0442 \u0432\u0438\u0440\u0442\u0443\u0430\u043b\u044c\u043d\u044b\u0439 \u0434\u0438\u0441\u043a \u0432 Proxmox, \u043d\u043e \u0432\u043d\u0443\u0442\u0440\u0438 OpenWrt \u0440\u0430\u0437\u0434\u0435\u043b \u0438 \u0444\u0430\u0439\u043b\u043e\u0432\u0443\u044e \u0441\u0438\u0441\u0442\u0435\u043c\u0443 \u0442\u043e\u0436\u0435 \u043d\u0430\u0434\u043e \u0440\u0430\u0441\u0448\u0438\u0440\u0438\u0442\u044c. \u042d\u0442\u043e \u043c\u043e\u0436\u043d\u043e \u0441\u0434\u0435\u043b\u0430\u0442\u044c \u043f\u043e\u0441\u043b\u0435 \u043f\u0435\u0440\u0432\u043e\u0433\u043e \u0437\u0430\u043f\u0443\u0441\u043a\u0430.1.8. \u041f\u0435\u0440\u0432\u044b\u0439 \u0437\u0430\u043f\u0443\u0441\u043a VMqm start ${VMID}qm status ${VMID}qm terminal ${VMID}\u0415\u0441\u043b\u0438 qm terminal \u043d\u0435 \u0438\u0441\u043f\u043e\u043b\u044c\u0437\u0443\u0435\u0442\u0441\u044f, \u043f\u0440\u043e\u0441\u0442\u043e \u043e\u0442\u043a\u0440\u043e\u0439\u0442\u0435 VM \u0432 \u0432\u0435\u0431-\u043c\u043e\u0440\u0434\u0435 Proxmox: VM -&gt; Console. \u041f\u043e\u0441\u043b\u0435 \u0437\u0430\u0433\u0440\u0443\u0437\u043a\u0438 \u0432\u044b \u0434\u043e\u043b\u0436\u043d\u044b \u043f\u043e\u043f\u0430\u0441\u0442\u044c \u0432 \u043a\u043e\u043d\u0441\u043e\u043b\u044c OpenWrt.1.9. \u041f\u0435\u0440\u0432\u044b\u0439 \u0432\u0445\u043e\u0434 \u0432 OpenWrt\u0412\u043d\u0443\u0442\u0440\u0438 OpenWrt \u0437\u0430\u0434\u0430\u0435\u043c \u043f\u0430\u0440\u043e\u043b\u044c root:passwd\u041f\u0440\u043e\u0432\u0435\u0440\u044f\u0435\u043c \u0438\u043d\u0442\u0435\u0440\u0444\u0435\u0439\u0441\u044b:ip aifconfig\u041d\u0430 \u044d\u0442\u043e\u043c \u044d\u0442\u0430\u043f\u0435 \u0432\u0430\u0436\u043d\u043e \u043f\u043e\u043d\u044f\u0442\u044c, \u043a\u0430\u043a\u043e\u0439 \u0438\u043d\u0442\u0435\u0440\u0444\u0435\u0439\u0441 \u0441\u0442\u0430\u043b eth0, \u0430 \u043a\u0430\u043a\u043e\u0439 eth1. \u0412 \u0441\u0442\u0430\u0442\u044c\u0435 \u0434\u0430\u043b\u044c\u0448\u0435 \u0441\u0447\u0438\u0442\u0430\u0435\u043c, \u0447\u0442\u043e eth0 \u0441\u043c\u043e\u0442\u0440\u0438\u0442 \u0432 \u043e\u0441\u043d\u043e\u0432\u043d\u0443\u044e \u0441\u0435\u0442\u044c 192.168.0.0\/24, \u0430 eth1 \u0438\u0441\u043f\u043e\u043b\u044c\u0437\u0443\u0435\u0442\u0441\u044f \u0434\u043b\u044f \u0442\u0435\u0441\u0442\u043e\u0432\u043e\u0439 LAN.1.10. \u0420\u0430\u0441\u0448\u0438\u0440\u0438\u0442\u044c root-\u0440\u0430\u0437\u0434\u0435\u043b OpenWrt\u042d\u0442\u043e\u0442 \u0448\u0430\u0433 \u043e\u043f\u0446\u0438\u043e\u043d\u0430\u043b\u044c\u043d\u044b\u0439, \u043d\u043e \u044f \u0431\u044b \u0435\u0433\u043e \u0441\u0434\u0435\u043b\u0430\u043b \u0441\u0440\u0430\u0437\u0443. \u0418\u043d\u0430\u0447\u0435 \u043f\u043e\u0441\u043b\u0435 \u0443\u0441\u0442\u0430\u043d\u043e\u0432\u043a\u0438 \u043f\u0430\u043a\u0435\u0442\u043e\u0432 \u043c\u043e\u0436\u043d\u043e \u0431\u044b\u0441\u0442\u0440\u043e \u0443\u043f\u0435\u0440\u0435\u0442\u044c\u0441\u044f \u0432 \u043c\u0435\u0441\u0442\u043e. \u0421\u043d\u0430\u0447\u0430\u043b\u0430 \u0441\u043c\u043e\u0442\u0440\u0438\u043c \u0440\u0430\u0437\u043c\u0435\u0442\u043a\u0443 \u0434\u0438\u0441\u043a\u0430:df -hlsblk 2&gt;\/dev\/null || block info\u0415\u0441\u043b\u0438 lsblk \u043d\u0435 \u0443\u0441\u0442\u0430\u043d\u043e\u0432\u043b\u0435\u043d, \u043c\u043e\u0436\u043d\u043e \u043f\u043e\u0441\u0442\u0430\u0432\u0438\u0442\u044c \u0443\u0442\u0438\u043b\u0438\u0442\u044b \u0438 \u0440\u0430\u0441\u0448\u0438\u0440\u0438\u0442\u044c \u0440\u0430\u0437\u0434\u0435\u043b. \u041d\u0430 x86 ext4 combined \u0447\u0430\u0449\u0435 \u0432\u0441\u0435\u0433\u043e root-\u0440\u0430\u0437\u0434\u0435\u043b \u044d\u0442\u043e \/dev\/sda2, \u043d\u043e \u043b\u0443\u0447\u0448\u0435 \u043f\u0440\u043e\u0432\u0435\u0440\u0438\u0442\u044c \u0433\u043b\u0430\u0437\u0430\u043c\u0438.opkg updateopkg install parted e2fsprogs resize2fs lsblkparted -s \/dev\/sda printparted -s \/dev\/sda resizepart 2 100%reboot\u041f\u043e\u0441\u043b\u0435 \u043f\u0435\u0440\u0435\u0437\u0430\u0433\u0440\u0443\u0437\u043a\u0438 \u0440\u0430\u0441\u0448\u0438\u0440\u044f\u0435\u043c \u0444\u0430\u0439\u043b\u043e\u0432\u0443\u044e \u0441\u0438\u0441\u0442\u0435\u043c\u0443:resize2fs \/dev\/sda2df -h\u0412\u0430\u0436\u043d\u043e: \u0415\u0441\u043b\u0438 \u0443 \u0432\u0430\u0441 \u0434\u0438\u0441\u043a \u043d\u0430\u0437\u044b\u0432\u0430\u0435\u0442\u0441\u044f \u043d\u0435 \/dev\/sda \u0438\u043b\u0438 root-\u0440\u0430\u0437\u0434\u0435\u043b \u043d\u0435 \/dev\/sda2, \u043a\u043e\u043c\u0430\u043d\u0434\u044b \u043d\u0430\u0434\u043e \u0430\u0434\u0430\u043f\u0442\u0438\u0440\u043e\u0432\u0430\u0442\u044c. \u041d\u0435 \u0432\u044b\u043f\u043e\u043b\u043d\u044f\u0439\u0442\u0435 resizepart \u0432\u0441\u043b\u0435\u043f\u0443\u044e \u043d\u0430 \u043d\u0435\u0437\u043d\u0430\u043a\u043e\u043c\u043e\u0439 \u0440\u0430\u0437\u043c\u0435\u0442\u043a\u0435.\u0428\u0430\u0433 2. \u041d\u0430\u0441\u0442\u0440\u043e\u0438\u0442\u044c \u0441\u0435\u0442\u044c OpenWrt\u0422\u0435\u043f\u0435\u0440\u044c \u043d\u0443\u0436\u043d\u043e \u0441\u0434\u0435\u043b\u0430\u0442\u044c \u0442\u0430\u043a, \u0447\u0442\u043e\u0431\u044b OpenWrt \u0438\u043c\u0435\u043b \u043f\u043e\u0441\u0442\u043e\u044f\u043d\u043d\u044b\u0439 \u0430\u0434\u0440\u0435\u0441 192.168.0.2 \u0432 \u043e\u0441\u043d\u043e\u0432\u043d\u043e\u0439 \u0441\u0435\u0442\u0438 \u0438 \u0437\u043d\u0430\u043b, \u0447\u0442\u043e \u043e\u0441\u043d\u043e\u0432\u043d\u043e\u0439 \u0440\u043e\u0443\u0442\u0435\u0440 \u043d\u0430\u0445\u043e\u0434\u0438\u0442\u0441\u044f \u043d\u0430 192.168.0.1.2.1. \u041d\u0430\u0441\u0442\u0440\u043e\u0439\u043a\u0430 WAN \u043a\u0430\u043a \u0441\u0442\u0430\u0442\u0438\u0447\u0435\u0441\u043a\u043e\u0433\u043e \u0430\u0434\u0440\u0435\u0441\u0430 \u0432 \u043e\u0441\u043d\u043e\u0432\u043d\u043e\u0439 \u0441\u0435\u0442\u0438uci set network.wan=interfaceuci set network.wan.device=&#8217;eth0&#8217;uci set network.wan.proto=&#8217;static&#8217;uci set network.wan.ipaddr=&#8217;192.168.0.2&#8217;uci set network.wan.netmask=&#8217;255.255.255.0&#8217;uci set network.wan.gateway=&#8217;192.168.0.1&#8217;uci delete network.wan.dns 2&gt;\/dev\/nulluci add_list network.wan.dns=&#8217;192.168.0.1&#8217;uci add_list network.wan.dns=&#8217;1.1.1.1&#8217;uci commit network\/etc\/init.d\/network restart\u0414\u0430, \u0437\u0434\u0435\u0441\u044c&#8230;<\/p>\n","protected":false},"author":1,"featured_media":0,"comment_status":"closed","ping_status":"closed","sticky":false,"template":"","format":"standard","meta":{"footnotes":""},"categories":[],"tags":[],"class_list":["post-483455","post","type-post","status-publish","format-standard","hentry"],"_links":{"self":[{"href":"https:\/\/savepearlharbor.com\/index.php?rest_route=\/wp\/v2\/posts\/483455","targetHints":{"allow":["GET"]}}],"collection":[{"href":"https:\/\/savepearlharbor.com\/index.php?rest_route=\/wp\/v2\/posts"}],"about":[{"href":"https:\/\/savepearlharbor.com\/index.php?rest_route=\/wp\/v2\/types\/post"}],"author":[{"embeddable":true,"href":"https:\/\/savepearlharbor.com\/index.php?rest_route=\/wp\/v2\/users\/1"}],"replies":[{"embeddable":true,"href":"https:\/\/savepearlharbor.com\/index.php?rest_route=%2Fwp%2Fv2%2Fcomments&post=483455"}],"version-history":[{"count":0,"href":"https:\/\/savepearlharbor.com\/index.php?rest_route=\/wp\/v2\/posts\/483455\/revisions"}],"wp:attachment":[{"href":"https:\/\/savepearlharbor.com\/index.php?rest_route=%2Fwp%2Fv2%2Fmedia&parent=483455"}],"wp:term":[{"taxonomy":"category","embeddable":true,"href":"https:\/\/savepearlharbor.com\/index.php?rest_route=%2Fwp%2Fv2%2Fcategories&post=483455"},{"taxonomy":"post_tag","embeddable":true,"href":"https:\/\/savepearlharbor.com\/index.php?rest_route=%2Fwp%2Fv2%2Ftags&post=483455"}],"curies":[{"name":"wp","href":"https:\/\/api.w.org\/{rel}","templated":true}]}}