At least as far back as Linux Mint 21.x, the command is:
resolvectl flush-caches
To flush the local DNS cache on earlier versions of Linux Mint/Ubuntu (say around 16.04 or later):
sudo systemd-resolve --flush-caches
A Geek and his Blog
At least as far back as Linux Mint 21.x, the command is:
resolvectl flush-caches
To flush the local DNS cache on earlier versions of Linux Mint/Ubuntu (say around 16.04 or later):
sudo systemd-resolve --flush-caches