Integrate Proxmox host optimization into one-button optimizer
Major changes: - Added Proxmox detection with interactive mode selection - Mode 1: Proxmox Host (hypervisor-optimized) - Different kernel parameters (swappiness=10, BBR, FQ) - Minimal tmpfs (2GB APT cache only) - No zram (VMs need direct RAM) - No desktop app configuration - Mode 2: Desktop (original behavior with warnings) - Mode 3: Abort (recommends running in VMs) Technical implementation: - check_proxmox() now offers mode selection - analyze_and_prompt() branches on PROXMOX_MODE - tune_kernel() handles both desktop and proxmox profiles - setup_tmpfs() handles minimal proxmox tmpfs - Updated PROXMOX_COMPATIBILITY.md with new behavior Result: One unified script for both desktop and Proxmox use cases
This commit is contained in:
@@ -1,14 +1,78 @@
|
||||
# Proxmox Host Compatibility Analysis
|
||||
|
||||
## ⚠️ Running on Proxmox Host: Safety Considerations
|
||||
## ✅ **NEW: Integrated Proxmox Support!**
|
||||
|
||||
### 🔴 **NOT RECOMMENDED for Proxmox Host**
|
||||
The one-button optimizer now **automatically detects** Proxmox hosts and offers **two modes**:
|
||||
|
||||
This toolkit is designed for **Linux desktop systems** and **should NOT be used on a Proxmox host** without modifications. Here's why:
|
||||
```bash
|
||||
sudo ./one-button-optimizer.sh
|
||||
```
|
||||
|
||||
### When run on Proxmox host, you'll see:
|
||||
|
||||
```
|
||||
⚠️ Proxmox VE host detected!
|
||||
|
||||
<EFBFBD>️ System: Proxmox VE (5 VMs, 2 containers)
|
||||
|
||||
This tool has TWO modes:
|
||||
|
||||
1️⃣ Proxmox Host Mode (Hypervisor Optimization)
|
||||
• Optimized kernel params for VM workloads
|
||||
• Minimal RAM allocation (2GB for APT cache only)
|
||||
• CPU performance governor
|
||||
• Network optimization (BBR, FQ)
|
||||
• No desktop app configuration
|
||||
|
||||
2️⃣ Desktop Mode (NOT recommended for host)
|
||||
• Heavy RAM usage (zram + tmpfs = 40-50%)
|
||||
• Desktop-focused optimizations
|
||||
• Will reduce memory available for VMs
|
||||
|
||||
3️⃣ Abort (Recommended: Run inside your desktop VMs)
|
||||
|
||||
Choose mode (1=Proxmox/2=Desktop/3=Abort) [1]:
|
||||
```
|
||||
|
||||
---
|
||||
|
||||
## ❌ Potential Issues on Proxmox Host
|
||||
## 🎯 Proxmox Host Mode Optimizations
|
||||
|
||||
When you select **Mode 1 (Proxmox Host Mode)**, you get:
|
||||
|
||||
### 1. **Kernel Parameters**
|
||||
```bash
|
||||
vm.swappiness = 10 # Allow some swap (not aggressive like desktop)
|
||||
vm.dirty_ratio = 10 # Handle VM write bursts
|
||||
vm.dirty_background_ratio = 5 # Start background writes earlier
|
||||
vm.vfs_cache_pressure = 50 # Balance inode/dentry cache
|
||||
vm.min_free_kbytes = 67584 # Keep minimum free RAM
|
||||
|
||||
# Networking (optimized for VM/CT traffic)
|
||||
net.core.default_qdisc = fq # Fair Queue
|
||||
net.ipv4.tcp_congestion_control = bbr # Better bandwidth
|
||||
net.core.netdev_max_backlog = 5000
|
||||
net.ipv4.tcp_max_syn_backlog = 8192
|
||||
```
|
||||
|
||||
### 2. **Minimal tmpfs (Optional)**
|
||||
- Only 2GB for APT package cache
|
||||
- Minimal RAM impact
|
||||
- Speeds up `apt upgrade` operations
|
||||
|
||||
### 3. **No zram**
|
||||
- Skipped entirely in Proxmox mode
|
||||
- VMs need direct RAM access
|
||||
|
||||
### 4. **No Desktop Apps**
|
||||
- Skips browser/IDE configuration
|
||||
- Focus on hypervisor performance
|
||||
|
||||
---
|
||||
|
||||
## ❌ What's NOT Safe (Still Applies if You Choose Mode 2)
|
||||
|
||||
If you mistakenly choose **Desktop Mode** on Proxmox host:
|
||||
|
||||
### 1. **zram Configuration**
|
||||
- **Issue**: Creates compressed swap in RAM
|
||||
|
||||
Reference in New Issue
Block a user