OpenWrt Soft Router Series: Detailed Tutorial on Deploying OpenWrt (23.05.2) on PVE
本文最后更新于 934 天前,其中的信息可能已经有所发展或是发生改变,如有失效可到评论区留言。
Article Abstract
To address the need for IPv6 traffic optimization in home network architectures, the author deploys an OpenWrt software router solution based on the PVE environment, detailing the complete process from image download and virtual machine creation to network configuration. By setting up a dual-network-card mode to implement a bypass router deployment, it can serve as a bypass gateway for the main router's proxy traffic while avoiding single points of failure affecting the entire network. This practically validates the feasibility of OpenWrt on the PVE platform, providing infrastructure support for subsequent scenarios such as IPv6 address management and traffic policy formulation. Meanwhile, adding a Chinese language pack enhances the user experience, demonstrating the flexibility and scalability of software router solutions in home data center construction.
Qwen3-14B · 2026-06-18

Preface

Actually, I used lede a long time ago, but the main purpose back then was for multi-dialing. Later, after using iKuai, I found that iKuai was unbeatable in terms of multi-dialing, so I abandoned lede (partly because I didn't really like the lede interface). Now my home internet setup is a physical iKuai + ac86u Merlin system. iKuai has 3 wan ports: wan port 1 has single-line 3-dialing; wan port 2 connects to the lan port of the ac86u (the wan port of the ac86u connects back to the lan port of iKuai); wan port 3 connects to the itv port of the optical modem to achieve multi-terminal use of IPTV. Using it this way works flawlessly and is stable, so I haven't had much motivation to research openwrt.

However, recently, because I have been researching inbound and outbound traffic optimization and security solutions around IPv6 public IP addresses for future home data centers (see:Home Data Center Series: Home Data Center v4/v6 Dual-Stack Network Architecture and Application Access Flow Optimization), I have been investigating related technologies in various aspects, including v6-to-v4 technologies like lucky and socat, which can run directly as software packages on OpenWrt. In addition, I always feel that nowadays, with virtualization technology available, using a standalone AC86U as a proxy gateway is a bit low-end (and what if it breaks and I have to buy a new one??), so I also wanted to prepare a backup plan. This gave me the motivation to specifically study OpenWrt.

Note: This article is just a record of the installation process, with not much technical depth.

Install OpenWrt

Download the image and decompress it

Note: The official OpenWrt is a clean version with nothing but basic functions. All needed software must be installed by yourself (I prefer this kind, just like I always download official Windows images to install myself and refuse to use other modified versions). If you prefer pre-customized, full-featured versions, you will need to find those images yourself.

Download the latest img version suitable for PVE. At the time of writing this article, the latest version is 23.05.2. The official download link is as follows:
OpenWrt 23.05.2 official download link。
Download the .gz package directly to the /root folder on PVE:

wget https://downloads.openwrt.org/releases/23.05.2/targets/x86/64/openwrt-23.05.2-x86-64-generic-squashfs-combined-efi.img.gz

Decompress the package with the .gz extension. You can use gzip. If it is not installed, use apt to install it first, as follows:

apt install gzip #安装gzip
cd /root  #进入下载目录
gunzip openwrt-23.05.2-x86-64-generic-squashfs-combined-efi.img.gz #进行解压缩,得到扩展名为.img的文件

Create a new virtual machine in PVE

cd /root #Enter download directory

image.png

image.png

image.png

image.png

image.png

image.png

image.png

image.png

image.png

gunzip openwrt-23.05.2-x86-64-generic-squashfs-combined-efi.img.gz #Decompress to get the file with .img extension

cd /root #进入下载文件夹
qm  importdisk 107 openwrt-23.05.2-x86-64-generic-squashfs-combined-efi.img local-lvm #将.img文件作为硬盘导入VM id为107的虚拟机

Import the previously decompressed .img file directly as a disk into the virtual machine with VM ID 107:

image.png

cd /root #Enter download folder
image.png

image.png

qm importdisk 107 openwrt-23.05.2-x86-64-generic-squashfs-combined-efi.img local-lvm #Import the .img file as a hard disk into the virtual machine with VM ID 107
image.png

image.png

Imported successfully:
image.png

Initialize OpenWrt

An unused disk 0 will appear in the hardware settings of VM 107:

image.png

image.png

Modify boot order:

ip address

image.png

After entering the system, the first step is to use the "passwd" command to set a password for the root user:http://192.168.1.1Use the command to view the default interface IP address of OpenWrt:
image.png

image.png

Basic configuration of OpenWrt

Configure IP address

ip address

image.png

The default address is 192.168.1.1, and SSH is also enabled. If you need to change the IP address, you can actually SSH into OpenWrt now and modify the IP address via the command line, but it's not really necessary as it can also be changed in the web interface. Simply change your computer's IP to the 192.168.1.0 subnet, and then log in directly using a browser
image.png

, username "root", and the password is the one set earlier using the passwd command:
image.png

image.png

image.png

Go to "Network" - "Interfaces":
image.png

image.png

Click "Edit" in the red box:


Modify the IP information of OpenWrt according to your actual environment. Generally speaking, installing OpenWrt with PVE is highly likely for a bypass router setup, so you need to configure OpenWrt based on the main router's configuration. Assuming the LAN port IP address of the main router is 192.168.100.254, then the OpenWrt interface also needs to be configured in the 192.168.100.x subnet (assuming 192.168.100.1), and the gateway needs to point to 192.168.100.254:

Finally, return to the interfaces page and click "Save & Apply" to take effect:


Add Chinese language pack

Log in again using the newly configured IP address.

image.png

Note: I am only using the simplest OpenWrt single-network-card deployment method to demonstrate the installation and configuration, which is generally sufficient for a bypass router. Afterwards, you only need to have all clients point their default gateway to the bypass router via DHCP allocation (or just have the clients that need proxy access point their default gateway directly to the bypass router). However, in reality, this method is actually quite troublesome and inefficient, and carries a very large risk (for example, if the bypass router crashes, all clients pointing their default gateway to it will lose internet access).
image.png

Actually, the most scientific and efficient way is for OpenWrt to use a dual virtual network card setup (one LAN port and one WAN port), with all clients' default gateways pointing to the main router. The main router, through multi-WAN policy routing, sends requests destined for target domains requiring proxy access or requests from specified source IP addresses to the LAN port of the bypass router via a separate WAN port. Then, the WAN port of the bypass router points back to the LAN port of the main router for normal internet access. Using this method, first, if the bypass router crashes, it won't affect most normal clients; second, the flexibility is high: if configured based on target domains, it can achieve the effect of accessing special domains without affecting the normal internet access of all clients on the network, which is truly the best solution... I will write a dedicated article about this in the future.
image.png

First, you need to update the OpenWrt package list:

luci-i18n-base-zh-cn

image.png

image.png

Updated successfully (may require proxy or magic):
image.png

Search for the Chinese language pack name and install it:
image.png

luci-i18n-base-zh-cn
image.png

Afterword

Installed successfully:

📌 Content Structure Prompt:
This content belongs to the "Blog Knowledge Map" part, you can view the complete content path from here: Blog Knowledge Map 。
View Related Categories · 3 Matches
📎 Related Articles
Share this article
The blog content is original, please indicate the source when reposting! The RSS address of the blog is:https://blog.tangwudi.com/feed, welcome to subscribe; if needed, you can join theTelegram Groupto discuss questions together.
No Comments

Send Comment Edit Comment


				
|´・ω・)ノ
ヾ(≧∇≦*)ゝ
(☆ω☆)
(╯‵□′)╯︵┴─┴
 ̄﹃ ̄
(/ω\)
∠( ᐛ 」∠)_
(๑•̀ㅁ•́ฅ)
→_→
୧(๑•̀⌄•́๑)૭
٩(ˊᗜˋ*)و
(ノ°ο°)ノ
(´இ皿இ`)
⌇●﹏●⌇
(ฅ´ω`ฅ)
(╯°A°)╯︵○○○
φ( ̄∇ ̄o)
ヾ(´・ ・`。)ノ"
( ง ᵒ̌皿ᵒ̌)ง⁼³₌₃
(ó﹏ò。)
Σ(っ °Д °;)っ
( ,,´・ω・)ノ"(´っω・`。)
╮(╯▽╰)╭
o(*////▽////*)q
>﹏<
( ๑´•ω•) "(ㆆᴗ
😂
😀
😅
😊
🙂
🙃
😌
😍
😘
😜
😝
😏
😒
🙄
😳
😡
😔
😫
😱
😭
💩
👻
🙌
🖕
👍
👫
👬
👭
🌚
🌝
🙈
💊
😶
🙏
🍦
🍉
😣
Source: github.com/k4yt3x/flowerhd
Kaomoji
Emoji
Little Dinosaur
Flower!
Previous
Next
       

👋 Welcome to “Wudi's Personal Blog”

Here, long-term exploration is mainly carried out around the following directions:

🧱 Personal Digital Infrastructure and Blog System Construction
☁️ Cloudflare and Network Architecture Practice
🧠 AI and Knowledge System Exploration
🛡️ Network Security and Access Optimization
🎵 Music and Sound Cognition
👁️ Cognitive Perspectives and Worldviews