Openwrt installation on VirtualBox
Openwrt installation on VirtualBox
We will be installing the latest version of OpenWRT 64 bit in VirtualBox.
In this tutorial, we will be guiding you to install and configure OpenWRT in the Virtualbox machine.
Also guiding you to configure networks for OpenWRT machine.
Prerequisites
Before installing OpenWRT, install the VirtualBox machine.
Download and Install OpenWRT in VirtualBox
Download OpenWRT .img from the below link. (I suggest to download the latest one)
[Index of /snapshots/targets/x86/64/]
Now open the terminal and go to the directory where it is downloaded and extract using gunzip command
cd /home/viking/Downloads/ gunzip openwrt-x86-64-generic-ext4-combined-efi.img.gz
After extracting, use below command to convert .img to .vdi format
VBoxManage convertfromraw --format VDI openwrt-*x86-64-combined*.img openwrt.vdi
Now open VirtualBox and start installing OpenWrt.
Now Configuring Network settings.
Change network from NAT to Bridged Adapter
Start OpenWRT virtual machine
Now we also need to make changes in OpenWRT network settings as default IP value is defineĀ – 192.168.1.1 and DNS, gateway are also not defined.
Step 1 – first check the ping
ping google.com
Step 2 – cat /etc/config/network
Change IP and add DNS, Gateway.
Step 3 – Edit – vi /etc/config/network
option ipaddr '192.168.1.101' option gateway '192.168.1.1' option dns '1.1.1.1'
change IP and add DNS, Gateway.
Now restart network service
service restart network
ping google.com
How to access Web
opkg update opkg install luci
http://192.168.1.1