Run an OpenWRT VM on Proxmox VE

Поділитися
Вставка
  • Опубліковано 12 вер 2024
  • #OpenWRT #Proxmox #VirtualMachine
    Full steps can be found at i12bretro.gith...
    --------------------------------------------------------------------
    What is OpenWRT?
    --------------------------------------------------------------------
    OpenWrt is an open-source project for embedded operating systems based on Linux, primarily used on embedded devices to route network traffic. The main components are Linux, util-linux, musl, and BusyBox. All components have been optimized to be small enough to fit into the limited storage and memory available in home routers. - en.wikipedia.o...
    --------------------------------------------------------------------
    Creating the VM
    --------------------------------------------------------------------
    01. Open a web browser and navigate to the ProxMox web UI ProxMoxDNSorIP:8006/
    02. Click the Create VM button at the top right
    03. On the General tab, name the VM OpenWRT and set a VM ID (123 in this example) ≫ click Next
    04. On the OS tab select Do not use any media and set the Guest OS Type to Linux and Version to 5.x - 2.6 Kernel ≫ click Next
    05. On the System tab click Next
    06. On the Hard Disk tab set the Disk size to 0.001 ≫ click Next
    07. On the CPU tab set the number of CPU cores and the Type to host ≫ click Next
    08. On the Memory tab set the amount of memory to 256 MiB ≫ click Next
    09. On the Network tab set the Model field to VirtIO (paravirtualized), Uncheck the Firewall box ≫ click Next
    10. On the Confirm tab review the settings and click Finish
    11. Select the newly created OpenWRT VM from the left navigation panel
    12. Select Hardware from the left sub-navigation menu
    13. Click the Hard Disk to select it
    14. Click the Detach button at the top of the main content window to detach the hard disk from the VM
    15. Click the Unused disk to select it
    16. Click the Remove button at the top of the main content window to permanently delete it
    17. Click the Add button ≫ Network Device
    18. Set the Model field to VirtIO (paravirtualized), Uncheck the Firewall box ≫ Click Add
    --------------------------------------------------------------------
    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 openwrt.org) && [[ $response =~ $regex ]] && stableVersion="${BASH_REMATCH[1]}"
    download openwrt image
    wget -O openwrt.img.gz downloads.open...
    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 IPofVM, 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
    Connect with me and others ###
    ★ Discord: / discord
    ★ Reddit: / i12bretro
    ★ Twitter: / i12bretro

КОМЕНТАРІ • 34

  • @fizzymint
    @fizzymint Рік тому

    Brilliant - probably the best tutorial Ive ever seen!

    • @i12bretro
      @i12bretro  Рік тому

      Glad it was helpful. Thanks for the comment!

    • @IgnoreMyChan
      @IgnoreMyChan Рік тому +1

      Except for the music, that was very loud and distracting.

    • @i12bretro
      @i12bretro  Рік тому +1

      Thanks for the feedback. I've adjusted the levels in newer videos, but YT doesn't allow modifying existing ones

    • @IgnoreMyChan
      @IgnoreMyChan Рік тому +1

      @@i12bretro I understand. Great work!

  • @GanKsy
    @GanKsy 2 роки тому +4

    This is a fantastic guide! Liked and subscribed.

    • @i12bretro
      @i12bretro  2 роки тому

      Thank you for the comment. Glad it was helpful

  • @drzacks
    @drzacks 2 роки тому +1

    Thank you, really helpful video.

    • @i12bretro
      @i12bretro  2 роки тому

      You're welcome, thanks for the comment

  • @unmesh59
    @unmesh59 Рік тому +1

    Very nice tutorial though you've used the same network bridge for WAN and LAN

  • @BizSchilling
    @BizSchilling Рік тому

    Excellent instructions that worked perfectly for me. Any chance you have something similar for upgrading?

    • @i12bretro
      @i12bretro  Рік тому

      Glad to hear it. I do not, but I will make a note to investigate upgrading

  • @mehdi_fadaei
    @mehdi_fadaei Рік тому

    very nice and working explanation , danke ihn

  • @alabalistic
    @alabalistic Рік тому

    Great video, really good job

  • @stuarttener6194
    @stuarttener6194 5 місяців тому

    I am running ProxMox on an Intel NUC that shows this as part of my lspci output:
    01:00.0 Network controller: Intel Corporation Wireless 8265 / 8275 (rev 78)
    Have you ever experimented with trying to configure a ProxMox VM running OpenWRT to use ProxMox pass-through to deliver a WiFi adapter to OpenWRT whereby OpenWRT could thereafter configure and leverage it?

    • @i12bretro
      @i12bretro  5 місяців тому

      I have but i wasn't successful. I think the hardware has to be capable of AP mode and my pcie wifi card wasn't

  • @Bandicoot803
    @Bandicoot803 2 місяці тому

    Is the music a key requirement for this video!?

  • @thinhnd07
    @thinhnd07 Рік тому

    😃Thanks

    • @i12bretro
      @i12bretro  Рік тому

      Welcome! Thanks for the comment

  • @thyagorodriguesalvarez5264
    @thyagorodriguesalvarez5264 Рік тому

    thanks a lot!!!!!!!!!!!!!!

    • @i12bretro
      @i12bretro  Рік тому

      You're welcome!!!!!!!!!!!!

  • @derrickc7525
    @derrickc7525 3 місяці тому

    hi sorry what is that HDD-500gb, do i need to create one?

    • @i12bretro
      @i12bretro  3 місяці тому

      That's the name of my storage device. You'll replace it with the name of the storage device you want to use for the VM

  • @mehmetcgn8421
    @mehmetcgn8421 9 місяців тому

    How to setup pppoe?

  • @hadikamell6893
    @hadikamell6893 Рік тому

    i like your voice :D

    • @i12bretro
      @i12bretro  Рік тому

      Ha, by far my least favorite part of making videos. Thanks for the comment

  • @ole7492
    @ole7492 Рік тому

    Can I create a real wifi network with it?

    • @i12bretro
      @i12bretro  Рік тому

      You can if you pass real wifi hardware to it that's capable of it

  • @zaqueu6436
    @zaqueu6436 2 роки тому

    Na melhor parte o vídeo acabou... Rs.

  • @MarkConstable
    @MarkConstable 4 місяці тому

    Damn, that background music is sooo annoying!

  • @bankasn8800
    @bankasn8800 2 роки тому

    Ask
    Make free wifi acces with openWrt like as cafe resto and bar
    Without user password and wpa key
    So connect ssid then web portal klick access internet

    • @i12bretro
      @i12bretro  2 роки тому

      I've never tried it, but this should get you started openwrt.org/docs/guide-user/services/captive-portal/start