📅  最后修改于: 2023-12-03 15:00:47.511000             🧑  作者: Mango
In Ubuntu 18.04, flushing DNS cache is useful when you encounter DNS issues such as incorrect or outdated DNS records.
Here's how you can flush DNS cache in Ubuntu 18.04 using Shell-Bash:
sudo systemd-resolve --flush-caches
sudo systemd-resolve --statistics
Cache Size (repeated queries): 0
Cache Size (unique domains): 0
That's it! You have successfully flushed DNS cache in Ubuntu 18.04 using Shell-Bash.
Remember to flush DNS cache only when necessary as it can affect the performance of your system.