# Hyper-V

Special thanks to our community contributor [@Jordanwise](https://forum.ewelink.cc/u/jordanwise) for creating and sharing this helpful tutorial video:

{% embed url="<https://www.youtube.com/watch?v=StVw-60Piuk>" %}

### 1. Preparation <a href="#id-1.-prerequisites" id="id-1.-prerequisites"></a>

{% stepper %}
{% step %}
**Download the** CUBE OS **image**

Visit this [repo](https://github.com/eWeLinkCUBE/CUBE-OS/releases/latest) to download the latest `.vmdk` image. Please extract the image after downloading.
{% endstep %}

{% step %}
**Install Hyper-V**

Windows 10 / 11 Pro, Enterprise, or Education (Hyper-V required)

Hyper-V enabled on your system: Before using Hyper-V, make sure it is enabled in Windows. Open **Control Panel → Programs → Turn Windows features on or off**,&#x20;

<div align="left"><figure><img src="https://67406449-files.gitbook.io/~/files/v0/b/gitbook-x-prod.appspot.com/o/spaces%2FCnF8kmk9yw3yiy2mRerq%2Fuploads%2FWDcT9mnUIFijGtyKD6cm%2Fimage.png?alt=media&#x26;token=e436eae3-61cb-4e08-a3e0-612f0b37960b" alt="" width="310"><figcaption></figcaption></figure></div>

enable **Hyper-V** (including *Hyper-V Management Tools* and *Hyper-V Platform*), **Virtual Machine Platform**, **Windows Hypervisor Platform**, then click **OK** and restart your computer.

<div align="left"><figure><img src="https://67406449-files.gitbook.io/~/files/v0/b/gitbook-x-prod.appspot.com/o/spaces%2FCnF8kmk9yw3yiy2mRerq%2Fuploads%2FULGXxO2KkrnniwM6CQvr%2Fimage.png?alt=media&#x26;token=0ce61757-dbf8-4ba5-9ab9-b8d635250028" alt="" width="332"><figcaption></figcaption></figure></div>
{% endstep %}

{% step %}
**Zigbee Adapter (Optional)**

If you need to add USB Zigbee devices, please note that Hyper-V does not support native USB passthrough for hardware devices such as Zigbee dongles. If USB access is required, consider using a **USB-over-IP solution** or a **network-based Zigbee coordinator** instead.
{% endstep %}
{% endstepper %}

### 2. Convert the CUBE OS Image to VHDX <a href="#id-2.-convert-the-cube-os-image-to-vhdx" id="id-2.-convert-the-cube-os-image-to-vhdx"></a>

Before creating the virtual machine, convert the CUBE OS disk image to a Hyper-V **VHDX** compatible format.

{% stepper %}
{% step %}
Download and install a VM image conversion tool, such as **VM Image Converter** (recommended on Windows)&#x20;

<div align="left"><figure><img src="https://67406449-files.gitbook.io/~/files/v0/b/gitbook-x-prod.appspot.com/o/spaces%2FCnF8kmk9yw3yiy2mRerq%2Fuploads%2FClQstydrldjmcLuKnY6J%2Fimage.png?alt=media&#x26;token=82d68ed0-cbdb-40ab-a655-43355f62d0d9" alt="" width="375"><figcaption></figcaption></figure></div>
{% endstep %}

{% step %}
Launch the converter and select:

* Source format: **VMDK**
* Target format: **VHDX**

<div align="left"><figure><img src="https://67406449-files.gitbook.io/~/files/v0/b/gitbook-x-prod.appspot.com/o/spaces%2FCnF8kmk9yw3yiy2mRerq%2Fuploads%2F7iCfbFg9ACqHTf4qWAMQ%2Fimage.png?alt=media&#x26;token=9cdf81ab-e4b2-4cd9-a75f-f6a265b57973" alt="" width="360"><figcaption></figcaption></figure></div>
{% endstep %}

{% step %}
Complete the conversion and note the location of the generated `.vhdx` file.

<div align="left"><figure><img src="https://67406449-files.gitbook.io/~/files/v0/b/gitbook-x-prod.appspot.com/o/spaces%2FCnF8kmk9yw3yiy2mRerq%2Fuploads%2FQKS70hxaW1oTz6RCwmic%2Fimage.png?alt=media&#x26;token=eeffdb9e-2408-46aa-926e-a1be47ad6bb2" alt="" width="375"><figcaption></figcaption></figure></div>
{% endstep %}
{% endstepper %}

### 3. Create the Virtual Machine <a href="#id-3.-create-the-virtual-machine" id="id-3.-create-the-virtual-machine"></a>

{% stepper %}
{% step %}
Launch **Hyper-V Manager**.

<div align="left"><figure><img src="https://67406449-files.gitbook.io/~/files/v0/b/gitbook-x-prod.appspot.com/o/spaces%2FCnF8kmk9yw3yiy2mRerq%2Fuploads%2FKLGnYhpnW4TUgAiSVzta%2Fimage.png?alt=media&#x26;token=27dfe2ee-cefa-473b-a5eb-397ecf905871" alt="" width="375"><figcaption></figcaption></figure></div>
{% endstep %}

{% step %}
Click **Quick Create** → Select![](https://67406449-files.gitbook.io/~/files/v0/b/gitbook-x-prod.appspot.com/o/spaces%2FCnF8kmk9yw3yiy2mRerq%2Fuploads%2F8yCryNG9EQ2ZML71mllN%2Fimage.png?alt=media\&token=d005ecdb-686a-4373-bf54-14a94a273d1f)**Local installation source**.

<div align="left"><figure><img src="https://67406449-files.gitbook.io/~/files/v0/b/gitbook-x-prod.appspot.com/o/spaces%2FCnF8kmk9yw3yiy2mRerq%2Fuploads%2Ff5qgA3WXeEw1KlNAQehR%2Fimage.png?alt=media&#x26;token=6f4f67dc-11c5-4f87-b794-26cb34e01b97" alt="" width="375"><figcaption></figcaption></figure></div>
{% endstep %}

{% step %}
Select **Change installation source**, select the converted **CUBE OS `.vhdx`** file and disable **Windows Secure Boot**.

<div align="left"><figure><img src="https://67406449-files.gitbook.io/~/files/v0/b/gitbook-x-prod.appspot.com/o/spaces%2FCnF8kmk9yw3yiy2mRerq%2Fuploads%2FLekBkkamd2Hydx4xsEYv%2Fimage.png?alt=media&#x26;token=0ed27f1f-3756-4fdf-8dab-d3491a5ca132" alt="" width="375"><figcaption></figcaption></figure></div>
{% endstep %}

{% step %}
Enter a name for the VM (for example, `CUBE OS`), and then **Create Virtual Machine**.
{% endstep %}
{% endstepper %}

### 4. Configure Virtual Machine Settings <a href="#id-4.-configure-virtual-machine-settings" id="id-4.-configure-virtual-machine-settings"></a>

{% stepper %}
{% step %}
Click **Settings** for the newly created virtual machine.

<div align="left"><figure><img src="https://67406449-files.gitbook.io/~/files/v0/b/gitbook-x-prod.appspot.com/o/spaces%2FCnF8kmk9yw3yiy2mRerq%2Fuploads%2FlyxZ9KvMx4bpzL0cQEes%2Fimage.png?alt=media&#x26;token=e6cbd439-042d-4cef-821a-7d86bf1558bc" alt="" width="375"><figcaption></figcaption></figure></div>

{% endstep %}

{% step %}
Assign System Resources:

* Minimum: **4096 MB (4 GB)**
* Disable Dynamic Memory (recommended).
* **Processor**: 2 virtual processors

<div align="left"><figure><img src="https://67406449-files.gitbook.io/~/files/v0/b/gitbook-x-prod.appspot.com/o/spaces%2FCnF8kmk9yw3yiy2mRerq%2Fuploads%2FZdfwbJkXE2NyfMI6Wcsb%2Fimage.png?alt=media&#x26;token=c941758a-e5b1-44ad-91e9-03f757a6434f" alt="" width="375"><figcaption></figcaption></figure></div>
{% endstep %}

{% step %}
Click **Apply** and **OK** to Save the settings.
{% endstep %}
{% endstepper %}

### 5. Boot CUBE OS

{% stepper %}
{% step %}
Click **Connect** and **Start** the created virtual machine.

<div align="left"><figure><img src="https://67406449-files.gitbook.io/~/files/v0/b/gitbook-x-prod.appspot.com/o/spaces%2FCnF8kmk9yw3yiy2mRerq%2Fuploads%2FafxqxaM2WCQFAmiBM1PL%2Fimage.png?alt=media&#x26;token=78525be1-b531-4151-af31-c4a3952da45e" alt="" width="375"><figcaption></figcaption></figure></div>
{% endstep %}

{% step %}
Wait a few moments for CUBE OS to initialize. Monitor the boot screen until the boot is complete.

<div align="left"><figure><img src="https://67406449-files.gitbook.io/~/files/v0/b/gitbook-x-prod.appspot.com/o/spaces%2FCnF8kmk9yw3yiy2mRerq%2Fuploads%2FmsvbU2r30xq0WmtqjTLP%2Fimage.png?alt=media&#x26;token=bbe50140-3a33-4d18-92cf-43df705b49b1" alt="" width="375"><figcaption></figcaption></figure></div>
{% endstep %}

{% step %}
Once completed, you will see the CUBE OS' IP displayed on the screen. Use this IP address or [cube.local](http://cube.local/) to access the CUBE OS Web management page.

<div align="left"><figure><img src="https://67406449-files.gitbook.io/~/files/v0/b/gitbook-x-prod.appspot.com/o/spaces%2FCnF8kmk9yw3yiy2mRerq%2Fuploads%2F6T5sTzxEzfPdiYX1nH0t%2Fimage.png?alt=media&#x26;token=bc18e466-130b-42c2-9f1f-70e704895398" alt="" width="375"><figcaption></figcaption></figure></div>
{% endstep %}

{% step %}
Upon successful access, a short ID can be viewed on the settings page. Subsequently, access the CUBE OS Web management page using `cube-{short id}.local`, which is useful for differentiating multiple CUBE OS instances on the same local network.

<div align="left"><figure><img src="https://67406449-files.gitbook.io/~/files/v0/b/gitbook-x-prod.appspot.com/o/spaces%2FCnF8kmk9yw3yiy2mRerq%2Fuploads%2FtKCHG1Z8FMgijVHgUxdU%2Fimage.png?alt=media&#x26;token=d0f0bc2f-9599-4b45-9c7c-61eb7af32ab4" alt="" width="375"><figcaption></figcaption></figure></div>
{% endstep %}
{% endstepper %}
