跳到內容

清出磁碟空間

如果您的磁碟滿了,有許多方式可以清出一些可用空間:

1. 清空垃圾桶

垃圾桶裡的檔案可能會累積起來。把它清空來釋放空間:

  1. 啟動 Dolphin。
  2. 點擊左方側邊欄的「垃圾桶」。
  3. 點擊工具列的「清空垃圾桶」。

2. 解除安裝不需要的應用程式

某些應用程式會佔用很多空間。解除安裝您不需要的應用程式:

  1. 啟動 Discover
  2. 點擊左邊側邊欄裡的「已安裝」項目。
  3. 在工具列裡點擊「排序方式:」然後選擇「大小」。
  4. 如果有不需要的應用程式佔用很多空間的話,點擊它。
  5. 點擊「移除」。

3. 刪除未使用的 Flatpak 執行環境

已經不再有任何應用程式使用的 Flatpak 執行環境有的時候會沒有緣由地殘留在系統上。

要將它們移除,請開啟終端機視窗然後執行 flatpak uninstall --unused。

4. 刪除未使用的檔案

  1. 先安裝 Filelight。
  2. 啟動 Filelight。
  3. 點擊「選擇資料夾…」。
  4. 在左邊的側邊欄點擊「家目錄」,然後點擊「開啟」。
  5. 用 Filelight 的清單或地圖檢視來發現不需要的大檔案或資料夾。如果找到想刪除的資料,請對它按右鍵然後選取「刪除」。

Disk Usage Analyzer and KDiskFree can also be used for this purpose.

5. Prune uneeded snapshots

Snapshots of older versions of files can consume a significant amount of space. If you have a recent off-device backup, these snapshots are safe to prune. Learn how here.

6. Clear caches

Cache files speed up apps, but can consume a significant amount of space. They are safe to remove, but will cause some apps to perform more slowly until they are regenerated.

To remove miscellaneous cache files, use a terminal window to run rm -r ~/.cache/*.

7. Clear logs and crash debugging data

Log files logs and crash dump debugging data is cleaned up automatically, but can still pile up in the interim. If you don’t need them for system troubleshooting purposes, they are safe to remove.

To do so, use a terminal window to run the following commands:

  1. Remove older log files: run0 journalctl --vacuum-time=2d
  2. Remove crash dump debugging data: run0 systemd-tmpfiles --clean

由 以 CC-BY-4.0 授權條款所貢獻的文章。