├── README.md ├── Manual Install - MacOS - FreshJR QOS.command ├── Manual Install - Windows - FreshJR QOS.bat ├── FreshJR_QoS_Stats.asp └── FreshJR_QOS.sh /README.md: -------------------------------------------------------------------------------- 1 | # FreshJR QOS - Modification Script for AdaptiveQOS on Asus Routers 2 | 3 | This script has been tested on ASUS AC-68U, running RMerlin FW 384.4, using Adaptive QOS with Manual Bandwidth Settings 4 | 5 | ## Quick Overview: 6 | 7 | -- Script Changes Unidentified Packet QOS destination from "Default" Traffic Container (Category7) into user definable (in WebUI) "Others" Traffic Container 8 | 9 | -- Script Changes Minimum Guaranteed Bandwidth per QOS category from 128Kbit into user defined percentages upload and download. 10 | 11 | -- Script allows for custom QOS rules 12 | 13 | -- Script allows for redirection of existing identified traffic 14 | 15 | ## Full Overview: 16 | 17 | See SmallNetBuilder for more information & discussion 18 | 19 | ## Installation: 20 | 21 | In your SSH Client: 22 | 23 | ``` curl "https://raw.githubusercontent.com/FreshPr/FreshJR_QOS/master/FreshJR_QOS.sh" -o /jffs/scripts/FreshJR_QOS --create-dirs && sh /jffs/scripts/FreshJR_QOS -install ``` 24 | 25 | ## Uninstall: 26 | 27 | In your SSH Client: 28 | 29 | ``` /jffs/scripts/FreshJR_QOS -uninstall ``` 30 | -------------------------------------------------------------------------------- /Manual Install - MacOS - FreshJR QOS.command: -------------------------------------------------------------------------------- 1 | #!/bin/sh 2 | cd "$(dirname "${0}")" 3 | clear && printf '\e[3J' 4 | echo "-------------------------------------------------" 5 | echo "---- Ctrl + C to quit installer at any time ----" 6 | echo "-------------------------------------------------" 7 | echo "" 8 | 9 | echo "Detecting if files are present in current folder" 10 | echo "" 11 | file=1 12 | if [ -e "./FreshJR_QOS.sh" ] ; then 13 | echo " [x] FreshJR_QOS.sh" 14 | else 15 | echo " [ ] FreshJR_QOS.sh" 16 | file=0 17 | fi 18 | 19 | if [ -e "./FreshJR_QoS_Stats.asp" ] ; then 20 | echo " [x] FreshJR_QoS_Stats" 21 | else 22 | echo " [ ] FreshJR_QoS_Stats" 23 | file=0 24 | fi 25 | 26 | echo "" 27 | 28 | if [ "${file}" -eq 0 ] ; then 29 | echo "Not all files detected" 30 | echo "--CANNOT CONTINUE!!--" 31 | echo "" 32 | read -n 1 -s -r -p "(Press any key to Exit)" 33 | echo "" 34 | echo "" 35 | exit 36 | fi 37 | 38 | echo "Getting router login information" 39 | echo"" 40 | read -p " Router ipaddress: " ip 41 | read -p " Router username: " user 42 | echo " Router password: " 43 | echo " (entry will appear blank - required twice)" 44 | echo "" 45 | 46 | echo "Transferring files onto router " 47 | scp "./FreshJR_QOS.sh" "./FreshJR_QoS_Stats.asp" "${user}"@"${ip}":/jffs/ 48 | echo "" 49 | 50 | echo "Starting script installer" 51 | ssh -t -o LogLevel=quiet -o UserKnownHostsFile=/dev/null -o StrictHostKeyChecking=no "${user}"@"${ip}" ' 52 | mkdir /jffs/scripts/ 2> /dev/null; 53 | mv /jffs/FreshJR_QOS.sh /jffs/scripts/FreshJR_QOS; 54 | cat /jffs/FreshJR_QoS_Stats.asp > /jffs/scripts/www_FreshJR_QoS_Stats.asp; 55 | rm /jffs/FreshJR_QoS_Stats.asp 56 | dos2unix /jffs/scripts/FreshJR_QOS 57 | sh /jffs/scripts/FreshJR_QOS -install;' 58 | 59 | read -n 1 -s -r -p "(Press any key to Exit)" 60 | echo "" 61 | echo "" 62 | exit -------------------------------------------------------------------------------- /Manual Install - Windows - FreshJR QOS.bat: -------------------------------------------------------------------------------- 1 | @echo off 2 | setlocal EnableDelayedExpansion 3 | 4 | REM --------DETECT FILES------------ 5 | 6 | set putty=0 7 | set pscp=0 8 | set script=0 9 | set webpage=0 10 | 11 | set "putty_path=-" 12 | set "pscp_path=-" 13 | set "script_path=-" 14 | set "webpage_path=-" 15 | 16 | if exist "!cd!\putty.exe" ( 17 | set putty=1 18 | set "putty_path=!cd!\putty.exe" 19 | ) 20 | if exist "!cd!\pscp.exe" ( 21 | set pscp=1 22 | set "pscp_path=!cd!\pscp.exe" 23 | ) 24 | if exist "!cd!\FreshJR_QOS.sh" ( 25 | set script=1 26 | set "script_path=!cd!\FreshJR_QOS.sh" 27 | echo !script_path! 28 | ) 29 | if exist "!cd!\FreshJR_QoS_Stats.asp" ( 30 | set webpage=1 31 | set "webpage_path=!cd!\FreshJR_QoS_Stats.asp" 32 | ) 33 | 34 | set /a "files=!putty!+!pscp!+!script!+!webpage!" 35 | set /a "exectuables=!putty!+!pscp!" 36 | 37 | REM --------OUTPUT FILE DETECTION------------ 38 | 39 | cls 40 | echo Detecting if files are present in current folder 41 | echo: 42 | if !script!==1 ( 43 | echo [x] FreshJR_QOS.sh !script_path! 44 | ) else ( 45 | echo [ ] FreshJR_QOS.sh !cd!\FreshJR_QOS.sh NOT detected 46 | ) 47 | if !webpage!==1 ( 48 | echo [x] FreshJR_QoS_Stats.asp !webpage_path! 49 | ) else ( 50 | echo [ ] FreshJR_QoS_Stats.asp !cd!\FreshJR_QoS_Stats.asp NOT detected 51 | ) 52 | if !putty!==1 ( 53 | echo [x] putty.exe !putty_path! 54 | ) else ( 55 | echo [ ] putty.exe !cd!\putty.exe NOT detected 56 | ) 57 | 58 | if !pscp!==1 ( 59 | echo [x] pscp.exe !pscp_path! 60 | ) else ( 61 | echo [ ] pscp.exe !cd!\pscp.exe NOT detected 62 | ) 63 | 64 | echo: 65 | 66 | if not !files!==4 ( 67 | echo Not all files detected 68 | echo --CANNOT CONTINUE^!^!-- 69 | echo: 70 | if not !exectuables!==2 ( 71 | echo -------------------------------------------------------------------------- 72 | echo Putty / Pscp portable BINARY FILES are located at the following link: 73 | echo: 74 | echo https://www.chiark.greenend.org.uk/~sgtatham/putty/latest.html 75 | echo --------------------------------------------------------------------------- 76 | echo: 77 | ) 78 | pause 79 | exit 80 | ) 81 | 82 | if exist "!cd!\scripts\" ( 83 | echo Remove the folder "scripts" in current directory 84 | echo --CANNOT CONTINUE^!^!-- 85 | echo: 86 | pause 87 | exit 88 | ) 89 | 90 | if exist "!cd!\ssh_command" ( 91 | echo Remove the file "ssh_command" in current directory 92 | echo --CANNOT CONTINUE^!^!-- 93 | echo: 94 | pause 95 | exit 96 | ) 97 | 98 | REM --------PROMPT USER INPUT------------ 99 | 100 | echo Getting router login information 101 | echo: 102 | set /p "user=. Router username: " 103 | set /p "pass=. Router password: " 104 | set /p " ip=. Router ipaddress: " 105 | echo: 106 | 107 | echo Transferring files onto the router 108 | echo: 109 | mkdir "!cd!\scripts\" 110 | pscp -r -pw !pass! -scp "!cd!\scripts" !user!@!ip!:/jffs/ 111 | rmdir "!cd!\scripts\" 112 | pscp -pw !pass! -scp "!webpage_path!" !user!@!ip!:/jffs/scripts/www_FreshJR_QoS_Stats.asp 113 | pscp -pw !pass! -scp "!script_path!" !user!@!ip!:/jffs/scripts/FreshJR_QOS 114 | echo: 115 | echo Starting script installer 116 | echo: 117 | echo dos2unix /jffs/scripts/FreshJR_QOS ^&^& sh /jffs/scripts/FreshJR_QOS -install ^&^& read -n 1 -s -r -p "(Press any key to Exit)" > ssh_command 118 | putty.exe -ssh !user!@!ip! -pw !pass! -m "!cd!\ssh_command" -t 119 | del "!cd!\ssh_command" 120 | 121 | pause 122 | -------------------------------------------------------------------------------- /FreshJR_QoS_Stats.asp: -------------------------------------------------------------------------------- 1 | 2 | 6 | 7 | 8 |
9 | 10 | 11 | 12 | 13 | 14 | 15 |