Configuring ZRAM in ubuntu

As mentioned by @Mr_McBride. In the previous topic. See instructions below to configure ZRAM, to replace your swapfile. Recommend for machines with >8GB of internal RAM.

# More info: https://teejeetech.com/2022/04/23/ubuntu-22-04-tips-tricks/
# Disable and remove swap file
wget -O - https://teejeetech.com/scripts/jammy/disable_swapfile | bash

# ZRAM creates a compressed swap disk that is located in RAM. The ZRAM disk is used when the system is low on memory.
# Since it is compressed, it increases the amount of available memory at the cost of slightly higher CPU cycles.
sudo apt install -y zram-config

# Reboot and run zramctl in a terminal to check the swap usage.