linux-space-booster
Linux Space Booster is an advanced, secure disk space cleanup utility specifically designed for Linux virtual machines. It intelligently cleans caches, logs, and temporary files to reclaim valuable disk space without risking system stability or user data.
Table of Contents
Loading contents...
README.md
โจ Key Features
- ๐ก๏ธ Safe By Design: Critical system paths protected with multiple safety checks
- ๐ง Intelligent Cleaning: Distribution-specific optimizations for maximum effectiveness
- ๐ Comprehensive Analysis: Visual disk usage summary with cleanup recommendations
- ๐งน Targeted Cleanup: Multiple cleanup modes from basic to advanced
- ๐ Detailed Reporting: Complete cleanup reports with space freed metrics
- โ๏ธ Cross-Distribution Support: Works on Kali, Parrot, Ubuntu, Mint, and Debian-based systems
- ๐ Interactive Interface: User-friendly menu with interactive confirmations
๐ง Installation
Quick Install
# Clone the repository
git clone https://github.com/dr34mhacks/linux-space-booster.git
# Navigate to the directory
cd linux-space-booster
# Make the script executable
chmod +x linux_space_booster.sh
# Run the script
sudo ./linux_space_booster.sh
Optional: Make it available system-wide
sudo cp linux_space_booster.sh /usr/local/bin/linux-space-booster
sudo chmod +x /usr/local/bin/linux-space-booster
๐บ Screenshot
๐ Usage
Interactive Mode (Recommended)
Simply run the script without arguments to access the interactive menu:
sudo ./linux-space-booster
Command Line Options
Option | Description |
---|---|
--quick |
Quick safe cleanup (no confirmations) |
--advanced |
Advanced cleanup with confirmations |
--user-only |
Clean only user cache files (no root required) |
--dry-run |
Preview what would be cleaned without making changes |
--force |
Skip all confirmations (use with caution) |
--help |
Display help information |
Examples
# Quick cleanup
sudo linux-space-booster --quick
# Advanced cleanup
sudo linux-space-booster --advanced
# User-only cleanup (no root required)
linux-space-booster --user-only
# Dry run (preview only)
sudo linux-space-booster --dry-run
๐งน What Gets Cleaned
Category | What’s Cleaned | What’s Preserved |
---|---|---|
APT Cache | Package files (.deb), orphaned packages | Package lists, repository data |
System Logs | Old log files (30+ days), rotated logs | Current active logs |
Temporary Files | Files in /tmp older than 7 days | Recent temp files, active temp files |
User Caches | Browser caches, thumbnail caches | User data, configurations |
PostgreSQL | Old log files (30+ days) | Database data, current logs, configuration |
Metasploit | Old log files (30+ days) | Scan data, loot, exploits, configuration |
Wireshark | Temporary files (.tmp) | Capture files (.pcap), configuration |
Journal | Old journal entries | Recent journal entries |
Snap | Old package versions | Current snap packages, configurations |
Kernels | Old unused kernels | Current kernel, recent kernels |
๐ก๏ธ Safety Features
Linux Space Booster includes multiple layers of protection to ensure your system remains stable and your data safe:
- Critical Path Protection: System directories are explicitly protected
- Active File Detection: Files in use by running processes are never deleted
- User Data Preservation: Personal files and settings are never touched
- Evidence Protection: Forensic data and capture files are preserved
- Configuration Safety: System and tool configurations are protected
- Kernel Safety: Current and recent kernels are always preserved
๐ป Supported Distributions
- Kali Linux: Specialized cleaning for penetration testing tools
- Parrot OS: Optimized for security tools and configurations
- Ubuntu: Enhanced cleaning for desktop environments
- Linux Mint: Tailored for Mint-specific packages and caches
- Debian: Core system optimization for Debian-based distributions
๐ Performance
Average disk space reclaimed on first run:
Distribution | Average Space Freed |
---|---|
Kali Linux | 1.2 - 2.5 GB |
Ubuntu | 0.8 - 1.5 GB |
Linux Mint | 0.9 - 1.7 GB |
Debian | 0.5 - 1.0 GB |
๐ Regular Maintenance Recommendation
For optimal system performance, we recommend running Linux Space Booster:
- Basic Cleanup: Weekly
- Advanced Cleanup: Monthly
- Kernel Cleanup: After system updates that install new kernels
๐ค Contributing
Contributions are welcome! Please feel free to submit a Pull Request.
- Fork the repository
- Create your feature branch (
git checkout -b feature/amazing-feature
) - Commit your changes (
git commit -m 'Add some amazing feature'
) - Push to the branch (
git push origin feature/amazing-feature
) - Open a Pull Request
๐ License
This project is licensed under the MIT License - see the LICENSE file for details.
๐จโ๐ป Author
Sid Joshi - @dr34mhacks
๐ Acknowledgments
- Inspired by various disk cleaning utilities across Linux distributions
- Thanks to all the testers who provided valuable feedback
โญ If you find this tool useful, please consider giving it a star! โญ
๐ง For issues, suggestions, or contributions, please open an issue on GitHub.
Made with โค๏ธ for the Linux communityTool Information
Author
dr34mhacks
Project Added On
June 15, 2025
License
Open Source
Tags
Related Tools
RedTeaming_CheatSheet
Pentesting cheatsheet with all the commands I learned during my learning journey. Will try to to keep it up-to-date.
StableSecPayloads
Sec-Payloads, It's a collection of multiple types of lists used during security assessments & used for bug bounty hunting or penetration testing, collected in one place. List types include xss, sqli, sensitive data patterns, fuzzing payloads, web shells, and many more.
Stable