Outils pour utilisateurs

Outils du site


Welcome:Fedora:Clean the OS

Différences

Ci-dessous, les différences entre deux révisions de la page.

Lien vers cette vue comparative

Welcome:Fedora:Clean the OS [2016/12/04 07:57]
arnaud créée
Welcome:Fedora:Clean the OS [2016/12/04 07:57] (Version actuelle)
arnaud
Ligne 1: Ligne 1:
-sdfg+**Clean an installed Fedora OS:** 
 + 
 +====== clean /var/cache ====== 
 + 
 +===== /​var/​cache/​Packagekit ===== 
 +[[http://​unix.stackexchange.com/​questions/​265755/​fedora-23-can-i-safely-delete-files-in-var-cache-packagekit-metadata-updates|Source]] 
 +<​code>​ sudo pkcon refresh force -c -1 </​code>​ 
 +<​code>​ rm -f /​var/​cache/​PackageKit/​metadata/​updates/​packages/​*</​code>​ 
 +Disable the saving of the rpm's: \\  
 +Edit ''/​etc/​PackageKit/​PackageKit.conf''​ and remove the # of ''​KeepCache''​ <​code>​ 
 +# Keep the packages after they have been downloaded 
 +KeepCache=false </​code>​ 
 + 
 +===== dnf ===== 
 +<​code>​dnf clean all --enablerepo=\* </​code>​ 
 + 
 +====== clean /​var/​log/​journal ====== 
 +[[http://​unix.stackexchange.com/​questions/​130786/​can-i-remove-files-in-var-log-journal-and-var-cache-abrt-di-usr|Source]] 
 + 
 +You can delete everything inside of /​var/​log/​journal/​* but do not delete the directory itself. \\  
 +  * You can also query ''​journalctl''​ to find out how much disk space it's consuming: <​code>​ 
 +$ journalctl --disk-usage 
 +Journals take up 3.8G on disk.</​code>​ 
 +  * You can control the size of this directory using this parameter in your ''/​etc/​systemd/​journald.conf'':​ \\ ''​SystemMaxUse=50M''​ 
 +  * You can force a log rotation: <​code>​ 
 +$ sudo systemctl kill --kill-who=main --signal=SIGUSR2 systemd-journald.service </​code>​ 
 +  * You might need to restart the logging service to force a log rotation, if the above signaling method does not do it. \\ You can restart the service like so: <​code>​ 
 +$ sudo systemctl restart systemd-journald.service </​code>​ 
 + 
 + 
 + 
Welcome/Fedora/Clean the OS.txt · Dernière modification: 2016/12/04 07:57 par arnaud