Friday, January 14, 2022

To clear the package cache in Arch Linux

 To clear the package cache in Arch Linux

  • Check how many cached packages are available in your cache folder and the occupied size:
$ sudo ls /var/cache/pacman/pkg/ | wc -l
$ du -sh /var/cache/pacman/pkg/ 
  •  Use the pacman command to remove all uninstalled packages that are still in cache:
$ sudo pacman -Sc
  • To completely remove all packages (whether they are installed or uninstalled) from the cache:
$ sudo pacman -Scc
 
Font: OSTechNix

No comments:

Post a Comment