KVM installation OpenWRT system, encountered a strange problem。

  • e83a33035cc96ff98b6cee103d74f3d1.png

    My brain really can't solve this problem, please help.

    The network layout is as shown in the figure: after the network cable enters the home, the optical modulation coordinator is set to bridge, and the tp-link router dials up (its LAN address is 192.168.1.1), and the NAS is clean on it.

    Because the tp-link router does not have many functions, I envisage installing an openwrt in the kvm plug-in of the NAS, setting it as a bypass route, and realizing some other functions, but the problem appeared in the process.

    My NAS is installed with omv6 system, and there are three network cards (actually only eth0 is used, and the other two network cards are not used, so don't need to consider it for the time being), I follow the official instructions, in the network management of the omv system, use the eth0 network card to build a bridge br0 , the static ip is set to 192.168.1.11, and other devices on the LAN can access and use the omv function through 192.168.1.11.

    Then, I installed openwrt through the kvm plug-in, used the bridge br0 to establish macvtap, and used it as the lan interface of openwrt. The openwrt static ip was set to 192.168.1.2. At this time, LAN devices can access the openwrt management page through 192.168.1.2.

    I made these changes in openwrt, the ip is set to 192.168.1.2, the subnet mask is set to 255.255.255.0, the gateway is set to 192.168.1.1 (ie tp-link), and the dhcp function and the bridging function of the lan interface are turned off. Openwrt itself can access the Internet, and everything looks fine. But here comes the problem. . .

    1. If other devices on the LAN set the gateway to 192.168.1.2 (openwrt), these intranet devices will not be able to access the Internet normally, and will also cause openwrt to be unable to access the Internet. If openwrt is not used as the gateway, then openwrt will return to normal in an instant.

    2. In this case, if you use "clash, passwall" tools (VPN) in openwrt, the LAN device can use openwrt as a gateway to access the Internet (VPN is also valid), and openwrt itself can also access the Internet normally.

    3. In the above process, omv (that is, the device of 192.168.1.11) cannot be found in openwrt under any circumstances.

    I can't figure out what the problem is right now, hopefully a very low level bug. ;(




  • crashtest

    Approved the thread.
  • I see two possibilities.

    1 - Bridge br0 must not be macvtap. I don't know if it's a typo or a concept error. When you create the VM you must choose in Network, Model->Bridge and in Bridge->br0

    If you didn't do it like that, it could be modified with the created VM. Click add network to VM and enter the same values in Network, Model->bridge and Bridge->br0 and remove the old interface macvtap.

    2 - It is possible that for this network configuration the following will work for you:

    openwrt creates a different network, for example 192.168.2.x

    • The openwrt IP would be 192.168.2.1 and activate DHCP for the network 192.168.2.x
    • The gateway of openwrt will be 192.168.1.1
    • The IP of Router 2 on Router 1's subnet is 192.168.1.2

    For this to work it is necessary to create a static route on router 1 (linksys) to router 2 (openwrt).

    Enter the network configuration of router 1. Set an IP for router 2, for example 192.168.1.2

    Create a static route for the 192.168.2.0/24 network (Destination IP Address) to the IP 192.168.1.2 (Gateway IP Address)

    Then all packets labeled with the IP 192.168.2.x will be directed from router 1 to router 2. Router 2 will be in charge of distributing them within the subnet that it controls.

  • mmmm... For this to work properly you may need to use another network interface for the 192.168.2.x subnet created by openwrt.

    Thank you teacher, I created the bridge through "macvtap", it should be different from the way you showed, I will confirm it when I get home. There is also a funny question. I can't find the description of the kvm plugin I checked before. How did I find that webpage before? XD

    I don't know if I misunderstood it at the time, I hope the problem lies here. If other devices are connected to openwrt according to the second method, it should mean that they cannot directly access tp-link (192.168.1.1)?

  • How did I find that webpage before?

    it should mean that they cannot directly access tp-link (192.168.1.1)?

    Yes. All devices behind openwrt can access the tp-link network. I have two (physical) routers in my house. And I have the network configured in this way. From my PC on subnet 2 I can get into the router on subnet 1 to configure it. I think this should work the same if one of the two routers is a VM.

  • Yes. All devices behind openwrt can access the tp-link network. I have two (physical) routers in my house. And I have the network configured in this way. From my PC on subnet 2 I can get into the router on subnet 1 to configure it. I think this should work the same if one of the two routers is a VM.

    Yes, I refer to the instructions in your post. My English is very poor, I read it through Google Translate, I seem to have misunderstood some places, I will re-study these contents and hope to solve it smoothly.

    I'm a web tech idiot and mostly rely on experience, but your last reply made my understanding of "gateway" a little deeper, thanks~~~

  • So we have a problem, because I don't speak English either, I also translate with google, it's a double translation :)

    If you don't understand anything ask what you want. I will try to make myself understood better.

    Gracias, también estoy explorando constantemente el sistema, omv no es un sistema NAS popular en China, lo que también conduce a menos información a la que se puede hacer referencia. Si vuelvo a tener problemas, volveré en busca de ayuda. ~~XD

    (¿Esto ahorrará un poco de batería para el servidor de Google Translate?)

  • omv no es un sistema NAS popular en China

    omv is not a popular NAS system in China

    What NAS systems are popular in China?

    I appreciate it but better translate into English or they will scold me.

    ___________

    中国流行哪些NAS系统?

    我很欣赏它,但最好把它翻译成英文,否则我会被骂。 :)

  • What NAS systems are popular in China?

    I appreciate it but better translate into English or they will scold me.

    ___________

    中国流行哪些NAS系统?

    我很欣赏它,但最好把它翻译成英文,否则我会被骂。 :)

    English version:

    The most commonly used commercial products by general users are Synology and QNAP. Or install Synology DiskStation Manager on a DIY computer (we call it "Black Synology", which is equivalent to the relationship between Mac OS X and Hackintosh), which is the most popular category. Unraid and truenas (freenas) are more popular among professional users, and unraid is more popular. Many people like the virtual machine function of unraid (I thought that truenas scale would become popular, but it did not). There are very few users of omv, and most problems need to be solved by themselves, and there is not much reference information (I don't know the situation of enterprises).

  • I guess it's not too different from the situation here.

    Synology and QNAP are commercial versions, with their advantages and disadvantages, they play in another league.

    Black Synology here is called xpenology.

    Nowadays with the google translator anyone can access this forum, just like you do. Information should not be missing anywhere.

    __________________________________________________________________

    我想这和这里的情况并没有太大的不同。

    Synology 和 QNAP 是商业版本,各有优缺点,他们在另一个联盟中发挥作用。

    Black Synology 在这里被称为 xpenology。

    现在有了谷歌翻译,任何人都可以访问这个论坛,就像你一样。信息不应在任何地方丢失。

  • Thanksss~

    after I modified the network card settings according to method 1, it was normal. Now I found out that the problem was caused by my laziness, the "3.3 Network Configuration" part of your "Use the Openmediavault-KVM plugin" post, I didn't seem to fully understand it at the time, but I thought I did. Although my question is a bit silly, I'm in a good mood now.

    Next, I will continue to study the port forwarding method of the openwrt bypass route and the slow speed between the 2.5g network cards.

    I hope others don't make the same mistake I did. XD



  • albicocca

    Added the Label resolved
  • I have changed that part of the howto. I hope now it is better understood.

    There is not necessarily a problem with your description, it may be an obstacle to voice communication. Spanish→English→Chinese, some descriptions in this translation chain will inevitably produce ambiguity.

  • TP-link's current new models of routers all use Qualcomm's custom chips, and it is basically impossible to install third-party systems. I use a custom model wta541 (AX5400) from a domestic telecom operator, the price is only about $34, but I can't install a third-party system.

Participate now!

Don’t have an account yet? Register yourself now and be a part of our community!