An open API service indexing awesome lists of open source software.

https://github.com/rompelhd/Swap-Disabler

A Magisk module designed to disable swap at system startup. This module is particularly beneficial for devices equipped with a substantial amount of RAM, where the use of swap is unnecessary and may even hinder performance.
https://github.com/rompelhd/Swap-Disabler

android magisk-module swap swap-disabler

Last synced: 4 months ago
JSON representation

A Magisk module designed to disable swap at system startup. This module is particularly beneficial for devices equipped with a substantial amount of RAM, where the use of swap is unnecessary and may even hinder performance.

Awesome Lists containing this project

README

          


Swap-Disabler



License: Apache License


Build Passing


Version




Author: Rompelhd


Magisk v20.4+


Platform: All Android


Swap-Disabler is a Magisk module designed to disable swap at system startup. This module is particularly beneficial for devices with ample RAM, where swap usage is unnecessary and may even hinder performance. By disabling swap, Swap-Disabler offers the following advantages:

- **Extended Flash Memory Lifespan**: Frequent writes to swap partitions can accelerate flash storage wear. Disabling swap significantly reduces this degradation, helping to prolong the lifespan of your device's memory.

- **Eco-Friendly**: By minimizing unnecessary writes to storage, the module contributes to reducing electronic waste, making it a sustainable choice for environmentally conscious users.

- **Performance Improvement**: In certain conditions, particularly for devices with substantial RAM, disabling swap can lead to better overall system performance by avoiding reliance on slower storage-based memory.

- **Flash Memory Durability**: Flash memory typically has between 3,000 and 100,000 write cycles. Disabling swap reduces the number of write cycles used for virtual memory, potentially increasing the lifespan of your device's storage by 20% to 40%, depending on usage.

| Standard | Read (MB/s) | Write (MB/s) | Approx. TBW | Write Cycles | Commonly Used In |
|-------------- |--------------|------------------|------------------|------------------|---------------------------|
| **eMMC 5.0** | ~150 | ~40–60 | 100–200 TBW | ~3,000 cycles | Low-end (2014–2017) |
| **eMMC 5.1** | ~250 | ~100–125 | 200–300 TBW | ~3,000–5,000 | Mid-range |
| **UFS 2.0** | ~350 | ~150–200 | 300–400 TBW | ~5,000 | Mid-range (2016+) |
| **UFS 2.1** | ~800 | ~250–300 | 400–600 TBW | ~10,000 | Upper mid-range |
| **UFS 3.0** | ~1500 | ~400–500 | 600–800 TBW | ~10,000–20,000 | High-end (2019+) |
| **UFS 3.1** | ~2100 | ~700–1200 | 800–1000 TBW | ~20,000 | Premium (2020+) |
| **UFS 4.0** | ~4200 | ~2800 | 1000–2000 TBW | 20,000–30,000 | Flagship (2023+) |

🚨 Disclaimer 🚨

Use at Your Own Risk

I am not responsible for any damage caused by using this module. This includes, but is not limited to:


  • Software malfunctions
  • (Report and I will help you)
  • Hardware brickings
  • (never happened)
  • Explosions

  • Fires

  • Alien invasions

Always ensure you have backups of your important data and use this module responsibly.