Skip to content

Latest commit

 

History

History

Folders and files

NameName
Last commit message
Last commit date

parent directory

..
 
 
 
 

README.md

🧠 Enhanced WiFi Analyzer

Advanced WiFi diagnostics and troubleshooting for Linux with WiFi 7, DFS monitoring, and modern VPN support

Shell Script WiFi 7 DFS Monitor

A comprehensive WiFi analysis and troubleshooting tool that diagnoses connectivity issues, optimizes performance, and provides distribution-specific fixes for modern Linux systems. Features DFS radar interference detection, WiFi 7/6E support, and modern VPN integration.

⚠️ Framework Support Disclaimer

Before implementing any power management changes recommended by this tool, please verify with Framework Support first.

While the Enhanced WiFi Analyzer provides valuable diagnostic information and generates safe configuration scripts, power management settings should only be modified when addressing specific connectivity issues. The tool may recommend disabling PCIe ASPM (Active State Power Management) or NetworkManager power saving features, but these changes should only be applied if:

  1. You are experiencing actual WiFi connectivity problems (disconnections, micro-dropouts, poor roaming)
  2. The analysis clearly identifies power management as the root cause
  3. Framework Support has reviewed your specific situation and confirmed the recommendation

Why This Matters

Power management features exist for good reasons - they extend battery life and reduce heat generation. Disabling them unnecessarily can impact your system's efficiency without providing any benefits. The diagnostic tools help identify potential power management conflicts, but not every detection requires action.

Recommended Workflow

  1. Run the analysis to identify potential issues: Run the script per the instructions.
  2. Document your specific symptoms (connection drops, poor performance, etc.)
  3. Contact Framework Support with both your symptoms and the tool's findings
  4. Apply recommended changes only after confirmation from Support
  5. Test thoroughly and revert changes if they don't resolve your specific issues

Contact Framework Support

Contact - Ask to send your findings to the Linux Support Team

Remember: These diagnostic tools are designed to help identify issues, not automatically fix them. Always verify recommendations with Framework Support before making system changes.

πŸ“š Table of Contents

πŸš€ Key Features

πŸ”¬ Advanced Diagnostics

  • Complete WiFi Health Analysis - Full system assessment with scoring
  • Modern Chipset Detection - Supports WiFi 7, 6E, MLO, and new hardware
  • Real-time Connectivity Testing - Tests actual data flow beyond basic connection status
  • Distribution-Aware Analysis - Tailored for Fedora, Ubuntu, Arch (NetworkManager), Debian, openSUSE, and immutable systems

πŸ“‘ DFS Radar Interference Monitoring

  • Radar Event Detection - Identifies DFS channel issues causing sudden disconnections
  • Smart Channel Switching - Automated migration to non-DFS safe channels
  • Environment Analysis - Maps DFS usage patterns in your area
  • 6GHz Migration Path - Recommendations for DFS-free 6GHz operation

πŸ”’ Modern VPN Integration

  • Advanced VPN Detection - Supports Tailscale, ZeroTier, Nebula, WireGuard, commercial VPNs
  • VPN-WiFi Conflict Resolution - Diagnoses and fixes VPN-related connectivity issues
  • Split Tunneling Optimization - Configures optimal routing for modern mesh VPNs
  • MTU Optimization - Automatic sizing for VPN tunnels

🌐 WiFi 6E/7 Optimization

  • 6GHz Band Analysis - Clean spectrum identification and optimization
  • 320MHz Channel Width - Ultra-wide channel support for maximum throughput
  • MLO (Multi-Link Operation) - WiFi 7 multi-band aggregation support
  • Regulatory Domain Optimization - Proper power limits and channel availability

πŸ› οΈ Interactive Troubleshooting

  • Guided Problem Solving - Step-by-step fixes for common issues
  • Emergency Repair Mode - Quick fixes for critical failures
  • Distribution-Specific Commands - Tailored solutions for your Linux distribution
  • Thermal Management - Overheating detection and fixes

⚑ Performance Optimization

  • Band Switching Automation - Intelligent 2.4/5/6GHz selection
  • Signal Strength Analysis - RF environment mapping and optimization
  • Power Management - Battery life vs performance balancing
  • Channel Width Optimization - Maximizes throughput while maintaining stability

🎯 Why Use This Tool?

Solves Real Problems

  • DFS Disconnections: Identifies and fixes mysterious 30+ second WiFi drops caused by radar interference
  • Modern VPN Issues: Resolves connectivity problems with Tailscale, ZeroTier, and other mesh VPNs
  • WiFi 7 Optimization: Optimizes cutting-edge WiFi hardware within driver/firmware limitations
  • Distribution Chaos: Provides correct commands for your specific Linux distribution

Beyond Basic Tools

  • Most WiFi tools only check connection status - this analyzes actual data flow
  • Detects issues that nmcli and GUI tools miss
  • Provides root cause analysis, not just symptoms
  • Includes proactive recommendations to prevent future issues

Expert Knowledge Built-In

  • Incorporates knowledge of MediaTek, Intel, and Qualcomm chipset quirks
  • Understands regulatory domain impacts on performance
  • Knows which channels are safe vs DFS across different regions
  • Includes thermal management strategies for high-performance WiFi cards

πŸ“‹ Quick Start

Prerequisites

# Required tools (install via package manager)
sudo apt install iw curl  # Ubuntu/Debian
sudo dnf install iw curl  # Fedora
sudo pacman -S iw curl    # Arch (NetworkManager required - not iwd compatible)

Installation

curl -s https://raw.githubusercontent.com/FrameworkComputer/linux-docs/refs/heads/main/Enhanced-WiFi-Analyzer/scripts/wifi_diagnostic.sh -o wifi_diagnostic.sh && clear && sudo bash wifi_diagnostic.sh

If already downloaded, just run:

sudo bash wifi_diagnostic.sh

Quick Analysis

Download and run (first time):

curl -s https://raw.githubusercontent.com/FrameworkComputer/linux-docs/refs/heads/main/Enhanced-WiFi-Analyzer/scripts/wifi_diagnostic.sh -o wifi_diagnostic.sh && clear && sudo bash wifi_diagnostic.sh

If already downloaded:

sudo bash wifi_diagnostic.sh

Then choose your option:

  • Option 1: Complete analysis (recommended first run)
  • Option 4: DFS-specific monitoring for radar interference
  • Option 9: Emergency fixes for immediate solutions

πŸŽ›οΈ Main Menu Options

Option Feature Use Case
1 🎯 Complete Analysis Full system health check with all modern features
2 🚨 Error Analysis Deep dive into logs and failure patterns
3 πŸ› οΈ Interactive Troubleshooting Guided problem-solving with custom solutions
4 πŸ“‘ DFS Channel Monitor Dedicated radar interference analysis
5 πŸ§ͺ TX Power Band Test Diagnose power limitations and optimize range
6 πŸ“‘ Manual Band Switching Direct CLI commands for 2.4/5/6GHz control

πŸ”§ Common Use Cases

Scenario 1: Mysterious Disconnections

Symptoms: WiFi drops for 30+ seconds randomly

curl -s https://raw.githubusercontent.com/FrameworkComputer/linux-docs/refs/heads/main/Enhanced-WiFi-Analyzer/scripts/wifi_diagnostic.sh -o wifi_diagnostic.sh && clear && sudo bash wifi_diagnostic.sh

β†’ Choose Option 4 (DFS Monitor) Tool identifies DFS radar interference and provides non-DFS channel solutions

Scenario 2: Slow WiFi 7 Performance

Symptoms: New WiFi 7 card performing poorly

curl -s https://raw.githubusercontent.com/FrameworkComputer/linux-docs/refs/heads/main/Enhanced-WiFi-Analyzer/scripts/wifi_diagnostic.sh -o wifi_diagnostic.sh && clear && sudo bash wifi_diagnostic.sh

β†’ Choose Option 1 (Complete Analysis) Tool detects 6GHz capability and recommends router upgrade/configuration

Scenario 3: VPN Breaks WiFi

Symptoms: WiFi unstable when Tailscale/ZeroTier active

curl -s https://raw.githubusercontent.com/FrameworkComputer/linux-docs/refs/heads/main/Enhanced-WiFi-Analyzer/scripts/wifi_diagnostic.sh -o wifi_diagnostic.sh && clear && sudo bash wifi_diagnostic.sh

β†’ Choose Option 3 β†’ Option 4 (VPN conflicts) Tool provides MTU optimization and split tunneling configuration

Scenario 4: Overheating Laptop

Symptoms: High temperatures, fan noise during WiFi use

curl -s https://raw.githubusercontent.com/FrameworkComputer/linux-docs/refs/heads/main/Enhanced-WiFi-Analyzer/scripts/wifi_diagnostic.sh -o wifi_diagnostic.sh && clear && sudo bash wifi_diagnostic.sh

β†’ Choose Option 3 β†’ Option 5 (thermal issues) Tool provides ASPM fixes and power management optimization

πŸ“Š Example Analysis Output

🧠 === ENHANCED SYSTEM INTELLIGENCE GATHERING ===
🐧 Distribution: Fedora Linux 39
πŸ” WiFi Interface: wlp1s0
πŸ”§ WiFi Functional Status: βœ… WORKING
πŸ”§ Hardware: MediaTek Inc. MT7925 WiFi 7 (802.11be)
πŸ“Š Chip Analysis:
   Vendor: MediaTek
   Model: MT7925
   Generation: WiFi 7 (802.11be) - 160MHz capable
   Known Issues: Excellent Linux support in kernel 6.8+

πŸ“‘ === DFS CHANNEL ANALYSIS ===
πŸ“ Regulatory Domain: US
πŸ” Current Connection DFS Analysis:
   ⚠️ Currently connected to DFS channel: 100 (5500 MHz)
   🎯 DFS Impact: Medium to High risk of disconnections
🚨 Found 3 DFS/radar events in last 24 hours

🎯 === FINAL ANALYSIS SUMMARY ===
πŸ“Š Overall WiFi Health: Fair (DFS risk) (50/100)
πŸ”§ WiFi Status: βœ… Working
πŸ“‘ DFS Status: ⚠️ Connected to DFS channel (radar risk)
🌟 WiFi 7 Features: Standard WiFi 7

⚠️ DFS RECOMMENDATION: Switch to non-DFS channel for stability
πŸ’‘ Suggested channels: 36, 40, 44, 48 (low 5GHz) or 149+ (high 5GHz)

πŸš€ Advanced Features

Advanced Features

  • Automatic Radar Detection: Monitors system logs for DFS events
  • Environmental Mapping: Scans for DFS channel usage in your area
  • Smart Channel Recommendations: Suggests optimal non-DFS alternatives
  • 6GHz Migration Planning: Path to DFS-free operation

Modern VPN Support

  • Mesh VPN Optimization: Tailscale, ZeroTier, Nebula configuration
  • Commercial VPN Fixes: NordVPN, ExpressVPN, Surfshark compatibility
  • Split Tunneling: Optimizes traffic routing for better performance
  • DNS Conflict Resolution: Fixes modern VPN DNS issues

WiFi 7 Optimization

  • 6GHz Band Access: Identifies clean spectrum opportunities
  • 320MHz Channels: Ultra-wide channel detection and recommendations
  • MLO Support: Multi-Link Operation analysis for maximum throughput
  • Advanced Power Management: Thermal optimization for high-performance cards

Distribution Intelligence

  • Immutable Systems: Special handling for Silverblue, Kinoite, Bluefin
  • Package Manager Detection: Uses correct commands for dnf, apt, pacman, zypper
  • Firmware Management: Distribution-specific update procedures
  • Kernel Parameter Handling: Proper GRUB vs rpm-ostree vs bootc configuration

πŸ’‘ Pro Tips

For System Administrators

  • Use Option 1 for baseline health assessment of fleet WiFi systems
  • Option 4 provides regulatory compliance checking for enterprise environments
  • Log outputs to files for trend analysis: ./wifi_diagnostic.sh | tee wifi_analysis.log

For Developers/Power Users

  • Option 6 provides direct CLI commands for automation and scripting
  • All temporary fixes can be converted to permanent configurations
  • Regulatory domain optimization maximizes performance within legal limits

For Gamers/Streamers

  • DFS monitoring eliminates lagspikes from radar interference
  • 6GHz optimization provides lowest latency connections
  • Thermal management prevents throttling during extended use

πŸ” Troubleshooting Matrix

Symptom Likely Cause Tool Solution
Random 30s+ disconnections DFS radar interference Option 4 β†’ Non-DFS channels
WiFi fails after suspend Driver power management Option 3 β†’ Suspend/resume fixes
Slow WiFi 7 speeds Wrong band/channel width Option 1 β†’ 6GHz optimization
VPN breaks WiFi MTU/routing conflicts Option 3 β†’ VPN optimization
Overheating during WiFi ASPM/power management Option 3 β†’ Thermal fixes
Connection fails entirely Driver/firmware issues Option 2 β†’ Distribution fixes

πŸ›‘οΈ Safety & Compatibility

Safe Operation

  • All temporary changes revert on reboot
  • Permanent changes clearly marked and reversible
  • No destructive operations without explicit user confirmation
  • Comprehensive logging for audit trails

Broad Compatibility

  • Distributions: Fedora, Ubuntu, Debian, Arch (NetworkManager only), openSUSE, Pop!_OS, Mint, immutable variants
  • Hardware: Intel, MediaTek, Qualcomm, Broadcom WiFi chipsets
  • Standards: WiFi 4/5/6/6E/7, 2.4/5/6GHz bands
  • VPNs: WireGuard, OpenVPN, modern mesh protocols
  • Network Managers: NetworkManager (iwd support not yet implemented)

πŸ“ˆ Future Development

  • iwd network manager support (currently NetworkManager only)
  • Integration with WiFi 8 (802.11bn) when available
  • Bluetooth coexistence analysis
  • Automated performance benchmarking
  • Web interface for remote diagnostics
  • Integration with network monitoring systems

πŸ”— Related Tools

Specialized WiFi Analysis

When to Use Which Tool

Scenario Enhanced WiFi Analyzer Framework Mesh Analyzer
General WiFi issues βœ… Primary tool βšͺ Not needed
DFS disconnections βœ… Specialized detection βšͺ Limited coverage
VPN conflicts βœ… Modern VPN support βšͺ Not covered
Framework + Mesh βœ… General analysis βœ… Mesh optimization
Thermal/power issues βœ… Comprehensive βšͺ Not covered
Mesh performance tuning βšͺ Basic detection βœ… Specialized analysis

Complementary Workflow

  1. Start here - Run Enhanced WiFi Analyzer for comprehensive system health
  2. Framework + Mesh users - Follow up with Framework's Mesh Analyzer for specialized optimization
  3. Best results - Use both tools for complete coverage of modern WiFi challenges

🀝 Contributing

Contributions welcome! Areas of particular interest:

  • Additional chipset quirks and optimizations
  • Distribution-specific command improvements
  • VPN protocol support expansion
  • Regional regulatory domain data
  • Performance optimization techniques