PROMOX - mit eigenem integriertem OpenWRT Router

jan-t

Well-Known Member
May 13, 2020
176
11
58
Hallo Forum,

kann ich auf Proxmox PVE ein OpenWRT System als VM installieren?

https://www.bachmann-lan.de/openwrt-unter-proxmox-installieren/

https://openwrt.org/docs/guide-user/virtualization/start
lxc
https://openwrt.org/docs/guide-user/virtualization/lxc

Dann brauche ich keinen "echten" Router mehr um auf die auf Proxmox installierten Systeme zugreifen zu können?
Den Zugriff stelle ich mir über einen WiFi USB Stick bzw. ein durchgereichte WiFi Device vor.

Ist mein Vorhaben möglich?

MfG
jan-t
 
Last edited:
Ich verstehe noch nicht deinen gedanken was du genau umsetzen willst.
Ich nutze bei mir Proxmox als Test umgebung, habe mehrere virtuelle Netze die ich entsprechend mit pfSense, OPNsense, OpenWRT trenne oder sogar VPNs mache. Also ja du kannst eine Firewall als VM laufen lassen
Was hat der Zugriff und einen Firewall VM miteinander zu tun, du kannst doch auch einen Baremetal Firewall betreiben und Trotzdem auf die VM in Proxmox zugreifen mache ich ja auch schon, hier mein Netzwerk
Code:
                                            ┌──────────────────────────┐                                     
                                            │                          │                                     
                                            │  WAN / Internet (PPPoE)  │                                     
                                            │        Willy.tel         │                                     
                                            │ 1000/250Mbit/s Glasfaser │                                     
                                            │                          │                                     
                                            └─────────────┬────────────┘                                     
─ ─ ─ ─ ─ ─ ─ ─WAN─ ─ ─ ─ ─ ─ ─ ─ ─ ─ ─ ─ ─ ─ ─ ─ ─ ─ ─ ─ ┼ ─ ─ ─ ─ ─ ─ ─ ─ ─ ─ ─ WAN ─ ─ ─ ─ ─ ─ ─ ─ ─ ─ ─ ─
                                                          │                                                 
 ┌────────────────┐   ┌────────────────┐    ╔═════════════╩═════════ pfSense+ ════════╗                     
 │                │   │     Switch     │    ║                             Netgate 6100║    Stand: ─ ─ ┐     
 │ TrueNAS SCALE  ├───┤  USW-Flex-XG   ├────╣                      LAN: 192.168.3.0/24║  │                   
 │                │   │                │    ║   Gäste (W)LAN (VLAN33): 192.168.33.0/24║    18.05.2025 │     
 └────────────────┘   └───┬─┬──┬───────┘    ║       IoT WLAN (VLAN34): 192.168.34.0/24║  │                   
 ┌────────────────┐       │ │  │            ║  DynDNS über deSEC.io mit eigener Domain║   ─ ─ ─ ─ ─ ─ ┘     
 │      UBNT      │       │ │  │            ║                                   VPN's:║                     
 │UniFI AP AC Pro ├───────┘ │  │            ║                 1 x Fritzbox 7490) IPSec║                     
 │                │         │  │            ║             1 x S2S WireGuard Fritz 6591║                     
 └────────────────┘         │  │            ║     1 x pfSense S2S (Netgate 6100) IPSec║                     
 ┌────────────────┐         │  │            ║             1 x OpenVPN Road Warrior DCO║                     
 │                │         │  │            ║                          (172.16.3.0/24)║                     
 │    proxmox     ├─────────┘  │            ║               1 x WireGuard Road Warrior║                     
 │                │            │            ║                         (172.16.33.0/24)║                     
 └────────────────┘            │            ║                                         ║                     
                               │            ╚═════════════════════════════════════════╝                     
                               │                                                                             
 ┌────────────────┐   ┌────────┴───────┐ ┌────────────────────┐ ┌────────────────┐                           
 │ Fritzbox 7490  │   │     Switch     │ │        UBNT        │ │    1 x UBNT    │                           
 │    IPClient    ├───┤  USW-Flex-XG   ├─┤USW-ENTERPRISE-8-POE├─┤UniFi AP-Flex-HD│                           
 │   (Nur VoIP)   │   │                │ │                    │ │                │                           
 └────────────────┘   └────┬───────────┘ └──────┬─────────────┘ └────────────────┘                           
 ┌────────────────┐        │                    │    ┌───────────┐                                           
 │      UBNT      │        │                    │    │           │                                           
 │UniFI AP AC Pro ├────────┘                    └────┤  Clients  │                                           
 │                │                                  │           │                                           
 └────────────────┘                                  └───────────┘
 
Last edited:
Beispiel:
Auf meinem Notebook habe ich Proxmox installiert.

Auf diesem Proxmox sind als VM Ubuntu-Nextcloud und OperWRT installiert.
OpenWRT erstellt ein WiFi-Netzwerk.

Du kannst dich mit dem Handy in die WiFi-Netzwerk einloggen und die VM Ubuntu-Nextcloud nutzen.

Jetzt klar?
 
  • dein Notebook mit Proxmox läuft in deinem LAN, warum dann mit WLAN Verbinden, gerade VM Profitieren von schnellen Verbindungen, warum kein Ethernet?
  • Wie kommst du ins Internet mit deinem LAN?
  • Was für eine Firewall setzt du in deinem LAN ein, hängt dein Proxmox mit in deinem LAN oder einem Separaten VLAN?
 
Last edited:
Weil es an dem Ort kein Internet gibt.
Das Promox-Notebookt hat kein Internet.
Es ist nur ein lokales Netzwerk.
Keine Firewall wird eingesetzt.

Es soll ein vom Internet unabhängiges System werden.
OpenWRT-VM soll ein Ersatz für eine mitgeführte Fritz!Box sein.
Fritz!Box-en können auch ohne Internet genutzt werden.
 
Last edited:
? ist es dann nur ein Testnetzwerk oder wie soll ich das Verstehen, sonst frage ich mich, wozu eine Nextcloud ohne Internet, nur fürs LAN?

Ok, ich denke ich bin raus, meine Netzwerks Kills sind für das Thema zu schlecht
Wenn es KEIN Internet gibt, wozu brauchst du dann OpenWRT nur als DHCP Server?
 
Ein Testnetzwerk.
Anstelle der Nextcloud, kann es auch eine Wordpress Website sein.


OpenWRT nur als DHCP Server?
Genau, jetzt haben wir es.

OpenWRT-VM soll eine mitgeführte Fritz!Box ersetzen.
 
Last edited:
Klar, kannst du OpenWRT als DHCP Server einrichten, wie man OpenWRT konfiguriert kannst du ja in der Offiziellen Dokumentation zu OpenWRT nachlesen, ich gehe davon aus das die aber immer von dem Setup ausgehen das es einen Internetzugang gibt.
 
https://downloads.openwrt.org/releases/24.10.1/targets/x86/64/

https://openwrt.org/docs/guide-user/installation/openwrt_x86
https://openwrt.org/docs/guide-user/virtualization/qemu

https://gist.github.com/ryuheechul/e829b7846a965638deeb122bdd0b403c
https://github.com/ryuheechul/reflect/blob/main/org/tool/proxmox.org#openwrt

Eine Top Dokumentation
https://www.bachmann-lan.de/openwrt-unter-proxmox-installieren/
Auf dem Proxmox Host lade ich das aktuelle x64 generic OpenWrt Image herunter, entpacke es und importiere das Festplattenimage in die VM.
(Nur mit dem combined.img.gz ist es später möglich die Partition zu vergrößern und den gesamten Speicherplatz zu nutzen!)

Meine Wahl
https://downloads.openwrt.org/relea...t-24.10.1-x86-64-generic-ext4-combined.img.gz

Nur zur Info:
Code:
https://community-scripts.github.io/ProxmoxVE/scripts?id=openwrt
https://raw.githubusercontent.com/community-scripts/ProxmoxVE/main/vm/openwrt.sh
https://i12bretro.github.io/tutorials/
https://i12bretro.github.io/tutorials/0405.html
https://www.youtube.com/watch?v=_fh7tnQW034

i
Code:
--------------------------------------------------------------------
Setting Up the OpenWRT Disk
--------------------------------------------------------------------
   01. Select the Proxmox node name in the left navigation menu
   02. Click Shell in the left sub-navigation
   03. Run the following commands in the terminal
         lookup the latest stable version number
         regex='≪strong≫Current Stable Release - OpenWrt ([^/]*)≪\/strong≫' && response=$(curl -s https://openwrt.org) && [[ $response =~ $regex ]] && stableVersion="${BASH_REMATCH[1]}"
         download openwrt image
         wget -O openwrt.img.gz https://downloads.openwrt.org/release...
         extract the openwrt img
         gunzip ./openwrt.img.gz
         rename the extracted img
         mv ./openwrt*.img ./openwrt.raw
         increase the raw disk to 512 MB
         qemu-img resize -f raw ./openwrt.raw 512M
         import the disk to the openwrt vm
         update the vm id and storage device as needed
         usage: qm importdisk
         qm importdisk 123 openwrt.raw HDD_500GB     
   04. Once the disk import completes, select the OpenWRT VM from the left navigation menu ≫ Hardware
   05. Double click the Unused Disk ≫ Click the Add button
   06. Select Options from the left sub-navigation menu
   07. Double click Boot Order
   08. Check the Enabled box next to the hard disk
   09. Drag the Hard disk up in the boot order as needed, typically below the CD-ROM device
   10. Click OK
   11. Double click Use tablet pointer ≫ Uncheck the Enabled box ≫ Click OK
   12. Click the Start button in the top right of the screen
   13. Click the Console link to watch the boot process
   14. Wait for the text to stop scrolling and press Enter
   15. Run the following command to change/set the root password
         passwd     
   16. Type a new root password twice to set it
   17. Continue the configuration by running the following commands
         set the lan ip address, use something in the same subnet as your LAN
         uci set network.lan.ipaddr='10.10.27.151'
         restart network services
         service network restart
         update openwrt packages
         opkg update
         install the luci web ui
         opkg install luci     
   18. Open a new browser tab and navigate to http://IPofVM, http://10.10.27.151 in the example
   19. At the login screen, enter the username root and the password set above ≫ Click the Login button
   20. Enjoy OpenWRT running in Proxmox
 
Last edited:
  • Like
Reactions: micneu