Elementary, my dear watson

I’m not sure if RPi5 can use tow-boot as a pre-bootloader but on Pinebook Pro I use tow-boot to boot grub to boot Linux. Pine is also ARM64.

Edit: my Pinebook Pro has EFI as partition#1 and there’s config, grub.cfg, initramfs, system map, vmlinuz etc

Hi Rosika,
Yes , the VM memory is released, but there is still the Virt-manager GUI running. You need to shut that down too.

Thank you for showing us smem.

Regards
Neville

Hi Rosika,

Yes, you are right and my thoughts too. I started Vbox up again today to do a little more testing. I want to know how to load a snapshot of the OS into the VM.

After shutting down the VM and issuing Top, I saw that swap usage was still very high. I wait a couple minutes to see if swap would clear but swap usage was still high. So I had a little talk with Co-Pilot.

A summary of what I found out.

vmstat 1
Will show the actual swap rate. Pages In / Pages out.

sudo swapoff -a
sudo swapon -a
Will turn off / on swap but also force all the pages back into Ram.

Note;
Swap used is not the same as swap rate.

After loading a large program like VM into memory it force a lot of pages to swap. When VM was closed, swap still had the pages that were not needed by the system. Having Ram sitting in swap is not necessary a bad thing.

Turning swap off / on reset swap usage to zero.

Kind Regards,
Howard

Only if your host OS was very busy and using a lot of pages.
With 8Gb there should be room for both the host and the VM without swapping… not a lot to spare, but it should fit without swapping if the host is not busy.

I agree. 8 GB of Ram. Gave 4 GB to Vbox VM, so that would leave 4 GB left over for Mint and what ever storage Vbox software took up. But I don’t know what else to blame the high swap usage on nor do I know how to find out what was being swaped.

I’ve found that too… Xubuntu ships with a more up to date XFCE than you get from the stock debian repos, and is better “integrated”…

Last time I tried Manjaro - on a laptop - XFCE was fully configured without stuff missing…

The defaults probably vary distro to distro, but the OS doesn’t wait until you are out of RAM before swapping. There is a setting that tells the OS when to swap. I saw it somewhere but don’t remember off the top of my head. Swapping itself isn’t a super bad thing. Swapping all the time to a slow HDD is a bad thing.

I asked Copilot where the setting was for Ubuntu. Here’s the response:

The setting that controls how aggressively Ubuntu swaps to disk is the kernel parameter vm.swappiness. Ubuntu doesn’t expose this in a GUI — it’s configured through sysctl.

:puzzle_piece: The setting you’re looking for

vm.swappiness

  • Range: 0–100

  • Lower = avoid swap unless absolutely necessary

  • Higher = push inactive memory to swap more aggressively

Ubuntu defaults to 60, which is far more aggressive than most people want on modern systems.


:wrench: Where to change it (Ubuntu 24.04 / 26.04)

1. Check the current value

cat /proc/sys/vm/swappiness

2. Make a permanent change

Create or edit a sysctl config file:

sudo nano /etc/sysctl.d/99-swappiness.conf

Add:

vm.swappiness=10

Save, then apply immediately:

sudo sysctl --system

This reloads all sysctl settings — no reboot needed.


:brain: Why this is the correct place

Ubuntu (and all systemd-based distros) read kernel tunables from:

  • /etc/sysctl.conf

  • /etc/sysctl.d/*.conf

  • /usr/lib/sysctl.d/*.conf

  • /run/sysctl.d/*.conf

Your custom file in /etc/sysctl.d/ overrides the defaults and persists across reboots.


:+1: Recommended values

  • 10 → Ideal for systems with plenty of RAM (your 30 GiB fits this perfectly)

  • 1 → Almost never swap

  • 60 → Ubuntu default

  • 100 → Swap aggressively (not recommended)


If you want, I can also show you how to tune vm.vfs_cache_pressure or check actual swap usage over time so you can see whether the new setting behaves the way you expect.

Thanks @pdecker.
I made the change to 10 and I will see how the swap usage is tomorrow when I test Vbox again.

It swaps memory pages… the algorithm is quite complicated.

Hi Neville,

And thanks for your suggestion. Learning the concept of swap management would be too complex for me. I confused swap usage with the active rate of swaping.

Swaping is the rate of page in and pages out. We called it thrashing when the CPU was spending too much time reading pages in and writing pages out. It would be a sign that the system is running too many tasks or a program was using a lot of memory.

For some reason - I thought Zorin O/S was exclusively XFCE - but just realised this morning - Zorin “Core” and “Pro” default to Gnome…

If you want Zorin with XFCE you have to get Zorin Lite… Which I’m doing now and about to give a test drive (in Virt-Manager).

And it looks like they’re discontinuing Zorin Lite after 18.1…

And yeh, nah…

All Zorin seems to offer for $80 in the pro version is more themes (there’s a Pro version of Lite too)… Sure it does most of the configuration - but I can mostly get Ubuntu LTS version with Gnome to look like I want and it’s free…


Can’t see a compelling reason to run Zorin over Mint anyway…

My best xfce is MX, closely followed by Devuan.

I prefer mint xfce but only on older underpowered computers as a last hope.

But don’t they all look and feel the same as xfce is controlling the desktop ?

Underneath it’s still (debian) linux, or am I missing something

It all depends how well integrated the desktop is with things like BlueTooth, WiFi, networking, power savings, volume control etc…

It was my experience with Pi4 5+ years ago - installing Raspbian “Lite” (i.e. TTY / ssh / headless) then installing XFCE (e.g. “apt install tasksel-xfce” or “apt install xfce-desktop”) didn’t have features for WiFi connection - they were there - but didn’t work with the underlying hardware…

Sort of … some distros configure xfce better than others.

Surprised by that thought they would all be alike

Every day I learn more