Skip to content

modtherhub/Ubuntu-System-Maintenance

Folders and files

NameName
Last commit message
Last commit date

Latest commit

Β 

History

6 Commits
Β 
Β 

Repository files navigation

πŸ› οΈ Ubuntu System Maintenance Guide

A practical guide for checking and maintaining your Ubuntu system.
Includes disk health checks, file system verification, cache/RAM cleaning, and performance optimization.

πŸ”Ž 1. Check Hard Disk (SMART Test)

Install smartmontools and check disk health:


sudo apt update && sudo apt install smartmontools -y
sudo smartctl -a /dev/sda
sudo smartctl -t long /dev/sda

πŸ”§ 2. Check File System

Run fsck on the root partition (replace sda1 with your actual partition):

sudo fsck -f /dev/sda1

🧹 3. Clean the System

Remove unnecessary packages and clean cache:

sudo apt autoremove -y
sudo apt autoclean
sudo apt clean

Clean system logs older than 7 days:

sudo journalctl --vacuum-time=7d

🧠 4. Free RAM

Clear memory cache without removing files:

sudo sync; sudo sysctl -w vm.drop_caches=3

πŸš€ 5. Improve Performance

Update the system:

sudo apt update && sudo apt upgrade -y

Monitor resource usage:

htop

Disable an unnecessary service:

sudo systemctl disable service_name

About

Repository provides a step-by-step guide for maintaining and optimizing Ubuntu systems.

Topics

Resources

Stars

Watchers

Forks

Releases

No releases published

Packages

No packages published