### Install spdMerlin via SSH Source: https://github.com/amtm-osr/spdmerlin/blob/master/README.md Execute this command in an SSH terminal to download and install the spdMerlin script. ```sh /usr/sbin/curl -fsL --retry 3 "https://raw.githubusercontent.com/AMTM-OSR/spdMerlin/master/spdmerlin.sh" -o /jffs/scripts/spdmerlin && chmod 0755 /jffs/scripts/spdmerlin && /jffs/scripts/spdmerlin install ``` -------------------------------- ### Access spdMerlin WebUI Source: https://context7.com/amtm-osr/spdmerlin/llms.txt The WebUI is automatically mounted upon installation. Access it via your router's web interface under Addons > spdMerlin. The URL can be found programmatically by running the spdMerlin menu. ```bash # WebUI is automatically mounted at installation # Access via: Router WebUI > Addons > spdMerlin # WebUI features: # - Real-time speedtest execution with progress display # - Interactive bandwidth and quality charts (daily/weekly/monthly) # - Sortable results table with last X test results # - Interface selection for speedtests # - Configuration settings panel # - Server preference management # WebUI files location: # /www/user/spdmerlin/ # Symlinks to data files # /jffs/addons/spdmerlin.d/spdstats_www.asp # Main WebUI page # Get WebUI URL programmatically: # The URL is displayed when running the menu: # "WebUI for spdMerlin is available at: https://router.local/user1.asp" ``` -------------------------------- ### Configure Per-Interface Preferred Server Settings Source: https://context7.com/amtm-osr/spdmerlin/llms.txt Set preferred server options for specific network interfaces like WAN or VPN connections. Configure USEPREFERRED and PREFERREDSERVER for each interface. ```bash # Per-interface preferred server settings: USEPREFERRED_WAN=false PREFERREDSERVER_WAN=0|None configured USEPREFERRED_VPNC1=false PREFERREDSERVER_VPNC1=0|None configured # ... (similar for VPNC2-5, WGVPN1-5) ``` -------------------------------- ### Show spdMerlin Help and About Information Source: https://context7.com/amtm-osr/spdmerlin/llms.txt Display available commands and general information about spdMerlin using the 'help' and 'about' commands. ```bash # Show available commands /jffs/scripts/spdmerlin help # Show about information /jffs/scripts/spdmerlin about ``` -------------------------------- ### Launch spdMerlin Menu Source: https://github.com/amtm-osr/spdmerlin/blob/master/README.md Commands to open the spdMerlin management menu from the command line. ```sh spdmerlin ``` ```sh /jffs/scripts/spdmerlin ``` -------------------------------- ### Startup and Service Management Source: https://context7.com/amtm-osr/spdmerlin/llms.txt Manages spdMerlin's startup behavior and service integration. 'startup force' remounts the WebUI and recreates symlinks. 'reset_interfaces force' resets network interface status. ```bash /jffs/scripts/spdmerlin startup force ``` ```bash /jffs/scripts/spdmerlin reset_interfaces force ``` -------------------------------- ### Configure AutoBW (Automatic QoS Bandwidth) Settings Source: https://context7.com/amtm-osr/spdmerlin/llms.txt Adjust Automatic QoS Bandwidth settings including scale factors, upper/lower limits, change thresholds, and averaging for upload and download. ```bash # AutoBW (Automatic QoS Bandwidth) settings: AUTOBW_ENABLED=false AUTOBW_SF_UP=95 # Scale factor upload (%) AUTOBW_SF_DOWN=95 # Scale factor download (%) AUTOBW_ULIMIT_UP=0 # Upper limit upload (Mbps, 0=unlimited) AUTOBW_ULIMIT_DOWN=0 # Upper limit download (Mbps) AUTOBW_LLIMIT_UP=0 # Lower limit upload (Mbps) AUTOBW_LLIMIT_DOWN=0 # Lower limit download (Mbps) AUTOBW_THRESHOLD_UP=10 # Change threshold upload (%) AUTOBW_THRESHOLD_DOWN=10 # Change threshold download (%) AUTOBW_AVERAGE_CALC=10 # Number of tests for averaging ``` -------------------------------- ### Configure spdMerlin Settings Source: https://context7.com/amtm-osr/spdmerlin/llms.txt These are key configuration options for spdMerlin. Adjust AUTOMATICMODE, SCHDAYS, SCHHOURS, SCHMINS for scheduling, DAYSTOKEEP for data retention, LASTXRESULTS for WebUI display, STORAGELOCATION, SPEEDTESTBINARY, EXCLUDEFROMQOS, STORERESULTURL, and OUTPUTTIMEMODE. ```bash AUTOMATICMODE=true # Enable/disable scheduled tests SCHDAYS=* # Days to run (* = every day) SCHHOURS=* # Hours to run (* = every hour) SCHMINS=12,42 # Minutes to run (runs at :12 and :42) DAYSTOKEEP=30 # Days of data retention (15-365) LASTXRESULTS=10 # Results shown in WebUI table (5-100) STORAGELOCATION=jffs # Storage: jffs or usb SPEEDTESTBINARY=builtin # Binary: builtin or external EXCLUDEFROMQOS=true # Exclude tests from QoS STORERESULTURL=true # Store Ookla result URLs OUTPUTTIMEMODE=unix # CSV time format: unix or non-unix ``` -------------------------------- ### Run Manual Speedtest Source: https://context7.com/amtm-osr/spdmerlin/llms.txt Executes a speedtest immediately. Supports auto-selected server, preferred server, or one-time manual server selection. The 'generate' command runs tests for all enabled interfaces. ```bash /jffs/scripts/spdmerlin generate ``` -------------------------------- ### Switch Development Branches Source: https://context7.com/amtm-osr/spdmerlin/llms.txt Allows switching between the stable and development branches of spdMerlin. Use 'develop' for the development branch and 'stable' to return to the main release. ```bash /jffs/scripts/spdmerlin develop ``` ```bash /jffs/scripts/spdmerlin stable ``` -------------------------------- ### Enable/Disable Automatic Speedtests Source: https://context7.com/amtm-osr/spdmerlin/llms.txt Toggles the scheduling of automatic speedtests. Use 'enable' to turn them on and 'disable' to turn them off. ```bash /jffs/scripts/spdmerlin enable ``` ```bash /jffs/scripts/spdmerlin disable ``` -------------------------------- ### Uninstall spdMerlin Source: https://context7.com/amtm-osr/spdmerlin/llms.txt Completely remove spdMerlin from the router using the uninstall command. This process stops tests, removes hooks and cron jobs, unmounts the WebUI, and prompts for data deletion. ```bash # Uninstall spdMerlin /jffs/scripts/spdmerlin uninstall # The uninstall process: # 1. Stops any running speedtests # 2. Removes startup hooks from post-mount, service-event, openvpn-event # 3. Removes cron jobs # 4. Unmounts WebUI tab # 5. Prompts to delete or keep database and config # 6. Removes script files and shortcuts ``` -------------------------------- ### spdMerlin Database Schema Source: https://context7.com/amtm-osr/spdmerlin/llms.txt The SQLite database stores speedtest results. The table structure includes StatID, Timestamp, Download, Upload, Latency, Jitter, PktLoss, ResultURL, DataDownload, DataUpload, ServerID, and ServerName. Indexes are created for optimized queries. ```sql -- Database location: -- JFFS: /jffs/addons/spdmerlin.d/spdstats.db -- USB: /opt/share/spdmerlin.d/spdstats.db -- Table structure (one per interface: spdstats_WAN, spdstats_VPNC1, etc.) CREATE TABLE [spdstats_WAN] ( [StatID] INTEGER PRIMARY KEY NOT NULL, [Timestamp] NUMERIC NOT NULL, -- Unix timestamp [Download] REAL NOT NULL, -- Mbps [Upload] REAL NOT NULL, -- Mbps [Latency] REAL, [Jitter] REAL, -- ms [PktLoss] REAL, -- Percentage [ResultURL] TEXT, -- Ookla result URL [DataDownload] REAL NOT NULL, -- MB transferred [DataUpload] REAL NOT NULL, -- MB transferred [ServerID] TEXT, -- Ookla server ID [ServerName] TEXT -- Server name and location ); -- Indexes are created for optimized queries: -- idx_WAN_download, idx_WAN_upload, idx_WAN_latency, -- idx_WAN_jitter, idx_WAN_pktloss, idx_WAN_resulturl, -- idx_WAN_datadownload, idx_WAN_serverid, idx_WAN_servername ``` -------------------------------- ### Database Maintenance Source: https://context7.com/amtm-osr/spdmerlin/llms.txt Triggers manual database trimming and optimization. This removes old records and optimizes tables. It also runs automatically daily. ```bash /jffs/scripts/spdmerlin trimdb ``` -------------------------------- ### Update spdMerlin Source: https://context7.com/amtm-osr/spdmerlin/llms.txt Manages spdMerlin updates. 'update' checks for and applies updates, 'forceupdate' bypasses confirmation, and 'checkupdate' only checks the status. ```bash /jffs/scripts/spdmerlin update ``` ```bash /jffs/scripts/spdmerlin forceupdate ``` ```bash /jffs/scripts/spdmerlin checkupdate ``` -------------------------------- ### Generate CSV Reports Source: https://context7.com/amtm-osr/spdmerlin/llms.txt Exports speedtest data to CSV files for external analysis. Files are stored in the configured JFFS or USB location. Supports full results, combined chart data, and a ZIP archive. ```bash /jffs/scripts/spdmerlin outputcsv ``` === COMPLETE CONTENT === This response contains all available snippets from this library. No additional content exists. Do not make further requests.