: Enable ZRAM on the VM-Series Firewall
Focus
Focus

Enable ZRAM on the VM-Series Firewall

Table of Contents
End-of-Life (EoL)

Enable ZRAM on the VM-Series Firewall

If your VM-Series firewall experiences low or out-of memory conditions, you can enable ZRAM to improve memory usage. ZRAM, also called compcache (compressed cache), is a Linux kernel module for creating a compressed block device in RAM. When enabled, ZRAM is used as swap disk and allows for faster I/O of swap because it resides in the RAM.
Complete the following steps to enable ZRAM.
  1. Log in to the VM-Series CLI.
  2. Find the total memory on the VM by using the following CLI command.
    grep pattern “KiB Mem :” mp-log mp-monitor.log
    KiB Mem :  9202656 total,   566504 free,  3475840 used,  5160312 buff/cache
    KiB Mem :  9202656 total,   497112 free,  3481944 used,  5223600 buff/cache
    KiB Mem :  9202656 total,   511744 free,  3466768 used,  5224144 buff/cache
    KiB Mem :  9202656 total,   511668 free,  3466340 used,  5224648 buff/cache
    KiB Mem :  9202656 total,   512124 free,  3465700 used,  5224832 buff/cache
    KiB Mem :  9202656 total,   511436 free,  3465976 used,  5225244 buff/cache
    KiB Mem :  9202656 total,   510984 free,  3465944 used,  5225728 buff/cache
  3. Convert the above total memory from KB to MB. For example:
    9202656 / 1024 = 8987 MB
    Take note of the total memory value in MB. You will need this value in the next step.
  4. Enable ZRAM using the following two CLI commands.
    debug software kernelcfg zram-swap enable
    debug software kernelcfg zram-swap modify host-mem-threshold <total-memory-in-MB>
  5. Reboot the VM-Series firewall.
  6. Verify that ZRAM is enabled.
    debug software kernelcfg zram-swap show config