• sales

    +86-0755-88291180

Milk-V Duo Tutorial【Enable virtual RAM memory】

Virtual memory is a technology in the operating system that is used to expand the capacity of a computer's physical memory (RAM). It works by storing some data on the disk and loading active data from the disk into memory to meet the memory requirements of processes.


1】Virtual memory has the following advantages:

Expanded memory capacity: 

Virtual memory allows the operating system to expand the available memory capacity when physical memory is insufficient. It moves less frequently used data to a swap file on the disk to free up memory for other processes.

Running more programs: 

Virtual memory makes it possible to run multiple programs simultaneously. Each program is allocated a portion of virtual memory, so even if physical memory cannot accommodate all the data of all programs at the same time, memory usage can be switched by swapping data to the disk.

Larger address space: 

Virtual memory allows each process to access a larger address space beyond the limitations of physical memory. Processes can perceive a contiguous block of memory space, even though their data is actually scattered across physical memory and the disk.

Better memory management: 

Virtual memory can automatically manage memory paging (dividing memory into fixed-sized pages), provide memory protection (preventing processes from accessing memory beyond their boundaries), and implement mechanisms such as memory sharing and memory mapping.


Virtual memory offers significant advantages in terms of memory expansion and multitasking, but it also introduces performance overhead and additional complexity. In modern computer systems, virtual memory is an essential component and is widely used in various operating systems.


2】Enabling virtual memory in milkv-Duo:

Before using, make sure that milkv-Duo is using the system image Duo-V1.0.4 or above.

Enter the following commands in the terminal:

mkswap /dev/mmcblk0p3

swapon /dev/mmcblk0p3

Enter 'free -h' to check if virtual memory is enabled.


TAG: Raspberry Pi LCD Display Screen 1.3inch LCD with Game Button AND Audio Buzzer For Zero 2W / 3B / 4B / PI5 / RP2040-PiZero UART 2.8inch Capacitive TouchScreen LCD Display ST7789 CST328 240x320 For Arduino/Raspberry Pi/ESP32/Pico GPS LCD Driver Board Raspberry Pi Pi5 Raspberry Pi Pico 2 RP2350B 1.46 inch Round LCD Touch Display 412x412 HMI LVGL QMI8658 6-axis 65K Colors LoRa32-Heltec V4 ESP32-S3 LoRa SX1262 Development Board 863-928MHz Meshtastic For Arduino Raspberry Pi Transparent LCD USB camera 5MP IMX335 No Distortion DeepSeek AI Voice Chat ESP32 C6 Development Board 1.69 inch LCD Display 240x280 1.69inch TouchScreen Programmable Watch Raspberry Pi 5 inch LCD 720x1280 Capacitive TouchScreen Display HDMI For Jetson Nano/mini Computer PC 14 inch Dual LCD Computer PC Monitor Display Double Secondary Screen Type C Mini HDMI 1080P For Windows/MacOS JETSON-NANO-MINI Jetson Nano PoE-M.2-HAT+B User Guide LCD Screen 1.28inch Round LCD Jetson Nano Development Kit JETSON-NANO-DEV-KIT Replace For Jetson-Nano-Developer-Kit-B01 and Audio Speaker