0% found this document useful (0 votes)
6 views

System_Optimization_Tweaks

Ubuntu command and tricks to boost performance

Uploaded by

Esaro Logics
Copyright
© © All Rights Reserved
Available Formats
Download as PDF, TXT or read online on Scribd
0% found this document useful (0 votes)
6 views

System_Optimization_Tweaks

Ubuntu command and tricks to boost performance

Uploaded by

Esaro Logics
Copyright
© © All Rights Reserved
Available Formats
Download as PDF, TXT or read online on Scribd
You are on page 1/ 2

System Optimization Tweaks

Below are the consolidated tweaks for system performance optimization, including detailed steps:

1. Update Kernel Parameters

----------------------------

sysctl -w vm.swappiness=10

sysctl -w vm.dirty_ratio=15

sysctl -w vm.dirty_background_ratio=5

sysctl -p

2. Adjust I/O Scheduler

------------------------

for disk in /sys/block/nvme*; do

echo "none" > "$disk/queue/scheduler"

done

3. Optimize CPU Frequency Scaling

----------------------------------

for cpu in /sys/devices/system/cpu/cpu*/cpufreq/scaling_governor; do

echo "performance" > "$cpu"

done

4. Disable Unnecessary Services

--------------------------------

systemctl disable apt-daily.service apt-daily-upgrade.service


systemctl disable cups.service

5. Mount Options Optimization

------------------------------

mount -o remount,noatime /

6. Clear Cached Memory (Optional)

----------------------------------

sync; echo 3 > /proc/sys/vm/drop_caches

7. Benchmarking (Optional)

---------------------------

fio --name=write_test --rw=write --bs=64k --size=1G --numjobs=4 --iodepth=1

fio --name=read_test --rw=read --bs=64k --size=1G --numjobs=4 --iodepth=1

Usage Instructions

------------------

1. Save the tweaks in a shell script (e.g., system_tweaks.sh).

2. Make the script executable using: chmod +x system_tweaks.sh

3. Run the script with: sudo ./system_tweaks.sh

You might also like