{"id":21889285,"url":"https://github.com/jacklul/asuswrt-scripts","last_synced_at":"2025-04-07T05:10:04.941Z","repository":{"id":154481728,"uuid":"625923066","full_name":"jacklul/asuswrt-scripts","owner":"jacklul","description":"Collection of scripts that can run on stock Asus routers (also on Merlin's firmware and forks)","archived":false,"fork":false,"pushed_at":"2025-03-21T19:03:58.000Z","size":880,"stargazers_count":82,"open_issues_count":0,"forks_count":17,"subscribers_count":6,"default_branch":"master","last_synced_at":"2025-03-31T04:05:40.099Z","etag":null,"topics":["asus-routers","asuswrt","asuswrt-merlin","router","shell-script"],"latest_commit_sha":null,"homepage":"","language":"Shell","has_issues":true,"has_wiki":null,"has_pages":null,"mirror_url":null,"source_name":null,"license":"mit","status":null,"scm":"git","pull_requests_enabled":true,"icon_url":"https://github.com/jacklul.png","metadata":{"files":{"readme":"README.md","changelog":null,"contributing":null,"funding":null,"license":"LICENSE","code_of_conduct":null,"threat_model":null,"audit":null,"citation":null,"codeowners":null,"security":null,"support":null,"governance":null,"roadmap":null,"authors":null,"dei":null,"publiccode":null,"codemeta":null}},"created_at":"2023-04-10T12:12:02.000Z","updated_at":"2025-03-27T11:42:24.000Z","dependencies_parsed_at":"2023-10-20T17:35:20.762Z","dependency_job_id":"6eb91a87-38e4-4679-940b-b11b089b906e","html_url":"https://github.com/jacklul/asuswrt-scripts","commit_stats":null,"previous_names":[],"tags_count":0,"template":false,"template_full_name":null,"repository_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/jacklul%2Fasuswrt-scripts","tags_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/jacklul%2Fasuswrt-scripts/tags","releases_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/jacklul%2Fasuswrt-scripts/releases","manifests_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/jacklul%2Fasuswrt-scripts/manifests","owner_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/owners/jacklul","download_url":"https://codeload.github.com/jacklul/asuswrt-scripts/tar.gz/refs/heads/master","host":{"name":"GitHub","url":"https://github.com","kind":"github","repositories_count":247595334,"owners_count":20963943,"icon_url":"https://github.com/github.png","version":null,"created_at":"2022-05-30T11:31:42.601Z","updated_at":"2022-07-04T15:15:14.044Z","host_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub","repositories_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories","repository_names_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repository_names","owners_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/owners"}},"keywords":["asus-routers","asuswrt","asuswrt-merlin","router","shell-script"],"created_at":"2024-11-28T11:23:36.128Z","updated_at":"2025-04-07T05:10:04.833Z","avatar_url":"https://github.com/jacklul.png","language":"Shell","funding_links":[],"categories":[],"sub_categories":[],"readme":"# Custom scripts for AsusWRT\n\nThis is a collection of custom scripts for AsusWRT firmware that can be used to enhance your router's functionality.\n\nMost of the scripts were tested on **RT-AX58U v2** running official firmware - there is no guarantee that everything will work on non-AX routers and on older versions of the firmware.\n\nSome informations were pulled from **GPL_RT-AX58U_3.0.0.4.388.22525** sources as well as [RMerl/asuswrt-merlin.ng](https://github.com/RMerl/asuswrt-merlin.ng) repository.\n\n**A lot of scripts here are based on resources from [SNBForums](https://www.snbforums.com) and [asuswrt-merlin.ng wiki](https://github.com/RMerl/asuswrt-merlin.ng/wiki). Scripts that are based on existing resource have the original credited in the header.**\n\n## Installation\n\n\u003e [!IMPORTANT]\n\u003e You need a router with USB port when using official firmware to be able to start the scripts.\n\u003e This is not required on Asuswrt-Merlin as you can use [services-start](https://github.com/RMerl/asuswrt-merlin.ng/wiki/User-scripts#services-start) script.\n\n\u003e [!WARNING]\n\u003e Newer versions of the official firmware have blocked the ability to run scripts using `script_usbmount` NVRAM variable and require a workaround - [look here](/asusware-usbmount).\n\u003e\n\u003e You can check if your router is affected by doing the following:\n\u003e\n\u003e - SSH into the router\n\u003e - Run `set script_usbmount=\"/bin/touch /tmp/yesitworks\" \u0026\u0026 nvram commit`\n\u003e - Wait around 15 seconds then execute `nvram get script_usbmount` - **if there is no output then your router is affected**\n\u003e - Plug in any USB storage - make sure the router mounts it as storage (needs supported filesystem)\n\u003e - Run `cat /tmp/yesitworks` - **if you see `No such file or directory` message then your router is affected**\n\u003e\n\u003e If your router is affected then [apply this workaround](/asusware-usbmount) first.\n\n### Run these commands to install the startup script:\n\n```bash\ncurl -fsSL \"https://raw.githubusercontent.com/jacklul/asuswrt-scripts/master/scripts/scripts-startup.sh\" -o /jffs/scripts/scripts-startup.sh\nchmod +x /jffs/scripts/scripts-startup.sh\nsh /jffs/scripts/scripts-startup.sh install\n# symlink will be created /jffs/scripts-startup.sh -\u003e /jffs/scripts/scripts-startup.sh\n```\n\nThen you can proceed to install scripts that you want to use from the [section below](#available-scripts).\n\n# Available scripts\n\n\u003ctable\u003e\n\u003ctr\u003e\n\u003ctd\u003e\n\u003ca href=\"#user-content-conditional-rebootsh\"\u003econditional-reboot\u003c/a\u003e\u003cbr\u003e\n\u003ca href=\"#user-content-cron-queuesh\"\u003ecron-queue\u003c/a\u003e\u003cbr\u003e\n\u003ca href=\"#user-content-custom-configssh\"\u003ecustom-configs\u003c/a\u003e\u003cbr\u003e\n\u003ca href=\"#user-content-disable-diagsh\"\u003edisable-diag\u003c/a\u003e\u003cbr\u003e\n\u003ca href=\"#user-content-disable-wpssh\"\u003edisable-wps\u003c/a\u003e\u003cbr\u003e\n\u003ca href=\"#user-content-dynamic-dnssh\"\u003edynamic-dns\u003c/a\u003e\u003cbr\u003e\n\u003ca href=\"#user-content-entwaresh\"\u003eentware\u003c/a\u003e\u003cbr\u003e\n\u003ca href=\"#user-content-extra-ipsh\"\u003eextra-ip\u003c/a\u003e\u003cbr\u003e\n\u003ca href=\"#user-content-force-dnssh\"\u003eforce-dns\u003c/a\u003e\u003cbr\u003e\n\u003ca href=\"#user-content-guest-passwordsh\"\u003eguest-password\u003c/a\u003e\u003cbr\u003e\n\u003c/td\u003e\n\u003ctd\u003e\n\u003ca href=\"#user-content-hotplug-eventsh\"\u003ehotplug-event\u003c/a\u003e\u003cbr\u003e\n\u003ca href=\"#user-content-led-controlsh\"\u003eled-control\u003c/a\u003e\u003cbr\u003e\n\u003ca href=\"#user-content-modify-featuressh\"\u003emodify-features\u003c/a\u003e\u003cbr\u003e\n\u003ca href=\"#user-content-modify-webuish\"\u003emodify-webui\u003c/a\u003e\u003cbr\u003e\n\u003ca href=\"#user-content-netboot-downloadsh\"\u003enetboot-download\u003c/a\u003e\u003cbr\u003e\n\u003ca href=\"#user-content-process-affinitysh\"\u003eprocess-affinity\u003c/a\u003e\u003cbr\u003e\n\u003ca href=\"#user-content-process-killersh\"\u003eprocess-killer\u003c/a\u003e\u003cbr\u003e\n\u003ca href=\"#user-content-rclone-backupsh\"\u003erclone-backup\u003c/a\u003e\u003cbr\u003e\n\u003ca href=\"#user-content-samba-masqueradesh\"\u003esamba-masquerade\u003c/a\u003e\u003cbr\u003e\n\u003c/td\u003e\n\u003ctd\u003e\n\u003ca href=\"#user-content-service-eventsh\"\u003eservice-event\u003c/a\u003e\u003cbr\u003e\n\u003ca href=\"#user-content-swapsh\"\u003eswap\u003c/a\u003e\u003cbr\u003e\n\u003ca href=\"#user-content-temperature-warningsh\"\u003etemperature-warning\u003c/a\u003e\u003cbr\u003e\n\u003ca href=\"#user-content-update-notifysh\"\u003eupdate-notify\u003c/a\u003e\u003cbr\u003e\n\u003ca href=\"#user-content-update-scriptssh\"\u003eupdate-scripts\u003c/a\u003e\u003cbr\u003e\n\u003ca href=\"#user-content-usb-mountsh\"\u003eusb-mount\u003c/a\u003e\u003cbr\u003e\n\u003ca href=\"#user-content-usb-networksh\"\u003eusb-network\u003c/a\u003e\u003cbr\u003e\n\u003ca href=\"#user-content-vpn-killswitchsh\"\u003evpn-killswitch\u003c/a\u003e\u003cbr\u003e\n\u003ca href=\"#user-content-wgs-lanonlysh\"\u003ewgs-lanonly\u003c/a\u003e\u003cbr\u003e\n\u003c/td\u003e\n\u003c/tr\u003e\n\u003c/table\u003e\n\n\u003cbr\u003e\n\n\u003e [!IMPORTANT]\n\u003e Remember to mark the scripts as executable after installing, you can use `chmod +x /jffs/scripts/*.sh` to do it in one go.\n\n\u003e [!NOTE]\n\u003e You can override config variables for scripts by creating `.conf` with the same name as the script (for example: `/jffs/scripts/conditional-reboot.conf`).  \n\u003e Configuration variables are defined on top of each script - peek into the script to see what's available to change!\n\n\u003e [!TIP]\n\u003e You can rename the scripts and add prefixes to them (such as `010-force-dns.sh`) to control the order in which they start.  \n\u003e Don't worry about \u003ca href=\"#user-content-update-scriptssh\"\u003eupdate-scripts.sh\u003c/a\u003e as it will still be able to update them!  \n\u003e **Do not rename `cron-queue.sh` as scripts are using it directly!**\n\n\u003e [!TIP]\n\u003e For better organization, you can put the scripts in `/jffs/scripts/jacklul-asuswrt-scripts` directory and set `SCRIPTS_DIR=/jffs/scripts/jacklul-asuswrt-scripts` in `/jffs/scripts-startup.conf`.\n\n---\n\n## [`conditional-reboot.sh`](/scripts/conditional-reboot.sh)\n\nThis script will reboot your router at specified time if it's been running for fixed amount of time.\n\nBy default, reboot happens at \u003cins\u003e5AM when uptime exceeds 7 days\u003c/ins\u003e.\n\n```sh\ncurl -fsSL \"https://raw.githubusercontent.com/jacklul/asuswrt-scripts/master/scripts/conditional-reboot.sh\" -o /jffs/scripts/conditional-reboot.sh\n```\n\n\u003ca href=\"#available-scripts\"\u003e\u003ci\u003e ^ back to the list ^ \u003c/i\u003e\u003c/a\u003e\u003cbr\u003e\n\n## [`cron-queue.sh`](/scripts/cron-queue.sh)\n\nWhen running multiple scripts from this repository that run every minute via cron they can cause a CPU spike (and network wide ping spike on weaker devices).  \nThis script will run all \"every minute\" tasks synchronously which will reduce the CPU load in exchange for task execution delays.\n\nAll scripts from this repository integrate with this script and will use it instead of `cru` when it's available.\n\n```sh\ncurl -fsSL \"https://raw.githubusercontent.com/jacklul/asuswrt-scripts/master/scripts/cron-queue.sh\" -o /jffs/scripts/cron-queue.sh\n```\n\n\u003ca href=\"#available-scripts\"\u003e\u003ci\u003e ^ back to the list ^ \u003c/i\u003e\u003c/a\u003e\u003cbr\u003e\n\n## [`custom-configs.sh`](/scripts/custom-configs.sh)\n\nThis script implements [Custom config files from Asuswrt-Merlin firmware](https://github.com/RMerl/asuswrt-merlin.ng/wiki/Custom-config-files) that allows you to use custom config files for certain services.\n\n\u003cdetails\u003e\n\u003csummary\u003eSupported config files\u003c/summary\u003e\n\n\u003cbr\u003e\n\n- avahi-daemon.conf\n- dnsmasq.conf\n- hosts\n- igmpproxy.conf\n- ipsec.conf\n- mcpd.conf\n- minidlna.conf\n- mt-daapd.conf\n- pptpd.conf\n- profile (profile.add only)\n- ripd.conf\n- smb.conf\n- snmpd.conf\n- stubby.yml (stubby.yml.add only)\n- torrc\n- vsftpd.conf\n- upnp\n- zebra.conf\n\n\u003c/details\u003e\n\n\u003cdetails\u003e\n\u003csummary\u003eSupported postconf scripts\u003c/summary\u003e\n\n\u003cbr\u003e\n\n- avahi-daemon.postconf\n- dnsmasq.postconf\n- hosts.postconf\n- igmpproxy.postconf\n- ipsec.postconf\n- mcpd.postconf\n- minidlna.postconf\n- mt-daapd.postconf\n- pptpd.postconf\n- ripd.postconf\n- smb.postconf\n- snmpd.postconf\n- stubby.postconf\n- torrc.postconf\n- vsftpd.postconf\n- upnp.postconf\n- zebra.postconf\n\n\u003c/details\u003e\n\n\u003e [!IMPORTANT]\n\u003e In **postconf scripts** you have to reference `.new` in the file name instead (for example `/etc/smb.conf.new`), the correct file path will be passed as an argument to the script (just like on Asuswrt-Merlin).\n\n_Recommended to use [`service-event.sh`](#user-content-service-eventsh) as well._\n\n```sh\ncurl -fsSL \"https://raw.githubusercontent.com/jacklul/asuswrt-scripts/master/scripts/custom-configs.sh\" -o /jffs/scripts/custom-configs.sh\n```\n\n\u003ca href=\"#available-scripts\"\u003e\u003ci\u003e ^ back to the list ^ \u003c/i\u003e\u003c/a\u003e\u003cbr\u003e\n\n## [`disable-diag.sh`](/scripts/disable-diag.sh)\n\nThis script prevent `conn_diag` from (re)starting `amas_portstatus` which likes to hog the CPU sometimes.\n\n\u003e [!CAUTION]\n\u003e Do not install this script if you don't have mentioned CPU usage issue.\n\n```sh\ncurl -fsSL \"https://raw.githubusercontent.com/jacklul/asuswrt-scripts/master/scripts/disable-diag.sh\" -o /jffs/scripts/disable-diag.sh\n```\n\n\u003ca href=\"#available-scripts\"\u003e\u003ci\u003e ^ back to the list ^ \u003c/i\u003e\u003c/a\u003e\u003cbr\u003e\n\n## [`disable-wps.sh`](/scripts/disable-wps.sh)\n\nThis script does exactly what you would expect - makes sure WPS stays disabled.\n\nBy default, runs check \u003cins\u003eat boot and at 00:00\u003c/ins\u003e, and when `service-event.sh` is used it also \u003cins\u003eruns every time wireless is restarted\u003c/ins\u003e.\n\n_Recommended to use [`service-event.sh`](#user-content-service-eventsh) as well._\n\n```sh\ncurl -fsSL \"https://raw.githubusercontent.com/jacklul/asuswrt-scripts/master/scripts/disable-wps.sh\" -o /jffs/scripts/disable-wps.sh\n```\n\n\u003ca href=\"#available-scripts\"\u003e\u003ci\u003e ^ back to the list ^ \u003c/i\u003e\u003c/a\u003e\u003cbr\u003e\n\n## [`dynamic-dns.sh`](/scripts/dynamic-dns.sh)\n\nThis script implements [custom DDNS feature from Asuswrt-Merlin firmware](https://github.com/RMerl/asuswrt-merlin.ng/wiki/DDNS-services#using-one-of-the-services-supported-by-in-a-dyn-but-not-by-the-asuswrt-merlin-webui) that allows you to use custom [Inadyn](https://github.com/troglobit/inadyn) config file.\n\nScript checks \u003cins\u003eevery minute\u003c/ins\u003e for new IP in NVRAM variable `wan0_ipaddr`.  \nYou can alternatively configure it to use website API like \"[ipecho.net/plain](https://ipecho.net/plain)\".\n\n\u003e [!TIP]\n\u003e On Asuswrt-Merlin you should call this script from `/jffs/scripts/ddns-start` with `force` argument instead of `start`.\n\n\u003e [!IMPORTANT]\n\u003e You might have to install Entware's `curl` (and `ca-bundle`) to bypass the security limitations of the one included in the firmware.\n\n_Recommended to use [`service-event.sh`](#user-content-service-eventsh) as well._\n\n```sh\ncurl -fsSL \"https://raw.githubusercontent.com/jacklul/asuswrt-scripts/master/scripts/dynamic-dns.sh\" -o /jffs/scripts/dynamic-dns.sh\n```\n\n\u003ca href=\"#available-scripts\"\u003e\u003ci\u003e ^ back to the list ^ \u003c/i\u003e\u003c/a\u003e\u003cbr\u003e\n\n## [`entware.sh`](/scripts/entware.sh)\n\nThis script installs and enables [Entware](https://github.com/Entware/Entware), even in RAM (`/tmp`).\n\n\u003e [!TIP]\n\u003e When installing to RAM the script will automatically install specified packages from `IN_RAM` variable and symlink files from `/jffs/entware` to `/opt`.  \n\u003e Create `.symlinkthisdir` file in directory's root to symlink it directly or `.copythisdir` to copy it instead.  \n\u003e If you want a single file to be copied then create a file with the same name and `.copythisfile` extension, e.g. `file.txt.copythisfile`. \n\n\u003e [!IMPORTANT]\n\u003e If you want to use HTTPS to download packages you might have to install Entware's `wget-ssl` and `ca-bundle`.\n\n_Recommended to use [`hotplug-event.sh`](#user-content-hotplug-eventsh) as well._\n\n```sh\ncurl -fsSL \"https://raw.githubusercontent.com/jacklul/asuswrt-scripts/master/scripts/entware.sh\" -o /jffs/scripts/entware.sh\n```\n\n\u003ca href=\"#available-scripts\"\u003e\u003ci\u003e ^ back to the list ^ \u003c/i\u003e\u003c/a\u003e\u003cbr\u003e\n\n## [`extra-ip.sh`](/scripts/extra-ip.sh)\n\nThis script allows you to add extra IP address to specific interface (usually `br0` bridge).\n\nThis is mainly for running services on ports normally taken by the firmware (like webserver).\n\n_Recommended to use [`service-event.sh`](#user-content-service-eventsh) as well._\n\n```sh\ncurl -fsSL \"https://raw.githubusercontent.com/jacklul/asuswrt-scripts/master/scripts/extra-ip.sh\" -o /jffs/scripts/extra-ip.sh\n```\n\n\u003ca href=\"#available-scripts\"\u003e\u003ci\u003e ^ back to the list ^ \u003c/i\u003e\u003c/a\u003e\u003cbr\u003e\n\n## [`force-dns.sh`](/scripts/force-dns.sh)\n\nThis script will force specified DNS server to be used by LAN and Guest WiFi, can also prevent clients from querying the router's DNS server.\n\nThis script can be very useful when running [Pi-hole](https://pi-hole.net) in your LAN.\n\n\u003e [!TIP]\n\u003e On Asuswrt-Merlin you should use **DNS Director** instead.\n\n_Recommended to use [`service-event.sh`](#user-content-service-eventsh) as well._\n\n```sh\ncurl -fsSL \"https://raw.githubusercontent.com/jacklul/asuswrt-scripts/master/scripts/force-dns.sh\" -o /jffs/scripts/force-dns.sh\n```\n\n\u003ca href=\"#available-scripts\"\u003e\u003ci\u003e ^ back to the list ^ \u003c/i\u003e\u003c/a\u003e\u003cbr\u003e\n\n## [`guest-password.sh`](/scripts/guest-password.sh)\n\nThis script rotates **Guest WiFi** passwords.\n\nBy default, it rotates passwords for the first network pair at \u003cins\u003e4AM\u003c/ins\u003e.\n\n```sh\ncurl -fsSL \"https://raw.githubusercontent.com/jacklul/asuswrt-scripts/master/scripts/guest-password.sh\" -o /jffs/scripts/guest-password.sh\n```\n\n\u003ca href=\"#available-scripts\"\u003e\u003ci\u003e ^ back to the list ^ \u003c/i\u003e\u003c/a\u003e\u003cbr\u003e\n\n## [`hotplug-event.sh`](/scripts/hotplug-event.sh)\n\nThis script handles hotplug events.\n\nBy default, integrates with all scripts present in this repository (where applicable).\n\n```sh\ncurl -fsSL \"https://raw.githubusercontent.com/jacklul/asuswrt-scripts/master/scripts/hotplug-event.sh\" -o /jffs/scripts/hotplug-event.sh\n```\n\n\u003ca href=\"#available-scripts\"\u003e\u003ci\u003e ^ back to the list ^ \u003c/i\u003e\u003c/a\u003e\u003cbr\u003e\n\n## [`led-control.sh`](/scripts/led-control.sh)\n\n\u003e [!CAUTION]\n\u003e This script might not work on every device with the official firmware, it should work fine on Asuswrt-Merlin.\n\nThis script implements [scheduled LED control from Asuswrt-Merlin firmware](https://github.com/RMerl/asuswrt-merlin.ng/wiki/Scheduled-LED-control).\n\nBy default, LEDs shutdown at \u003cins\u003e00:00 and turn on at 06:00\u003c/ins\u003e.\n\n```sh\ncurl -fsSL \"https://raw.githubusercontent.com/jacklul/asuswrt-scripts/master/scripts/led-control.sh\" -o /jffs/scripts/led-control.sh\n```\n\n\u003ca href=\"#available-scripts\"\u003e\u003ci\u003e ^ back to the list ^ \u003c/i\u003e\u003c/a\u003e\u003cbr\u003e\n\n## [`modify-features.sh`](/scripts/modify-features.sh)\n\nThis script modifies `rc_support` NVRAM variable to enable/disable some features, this is mainly for hiding Web UI menus and tabs.\n\nA good place to look for potential values are `init.c` and `state.js` files in the firmware sources.\n\n_Recommended to use [`service-event.sh`](#user-content-service-eventsh) as well._\n\n```sh\ncurl -fsSL \"https://raw.githubusercontent.com/jacklul/asuswrt-scripts/master/scripts/modify-features.sh\" -o /jffs/scripts/modify-features.sh\n```\n\n\u003ca href=\"#available-scripts\"\u003e\u003ci\u003e ^ back to the list ^ \u003c/i\u003e\u003c/a\u003e\u003cbr\u003e\n\n## [`modify-webui.sh`](/scripts/modify-webui.sh)\n\nThis script modifies some web UI elements.\n\n**Currently applied modifications:**\n- display CPU temperature on the system status screen (with realtime updates)\n- show connect QR code on guest network edit screen and hide the passwords on the main screen\n- add `notrendmicro` rc_support option (to be used with [`modify-features.sh`](#user-content-modify-featuressh)) that hides all Trend Micro services, **Speed Test** will be moved to **Network Tools** menu\n- allow use of port 443 for HTTPS LAN port in system settings\n\n\u003e [!NOTE]\n\u003e Tested only with English language!\n\n```sh\ncurl -fsSL \"https://raw.githubusercontent.com/jacklul/asuswrt-scripts/master/scripts/modify-webui.sh\" -o /jffs/scripts/modify-webui.sh\n```\n\n\u003ca href=\"#available-scripts\"\u003e\u003ci\u003e ^ back to the list ^ \u003c/i\u003e\u003c/a\u003e\u003cbr\u003e\n\n## [`netboot-download.sh`](/scripts/netboot-download.sh)\n\nAutomatically download specified bootloader files from [netboot.xyz](https://netboot.xyz).\n\n\u003e [!TIP]\n\u003e This and [`custom-configs.sh`](#user-content-custom-configssh) can help you setup a **netboot.xyz** PXE server on the router.\n\u003e \n\u003e \u003cdetails\u003e\n\u003e \u003csummary\u003eExample dnsmasq.conf.add\u003c/summary\u003e\n\u003e \n\u003e ```\n\u003e dhcp-option=66,192.168.1.1\n\u003e enable-tftp\n\u003e tftp-no-fail\n\u003e tftp-root=/tmp/netboot.xyz\n\u003e dhcp-match=set:bios,option:client-arch,0\n\u003e dhcp-boot=tag:bios,netboot.xyz.kpxe,,192.168.1.1\n\u003e dhcp-boot=tag:!bios,netboot.xyz.efi,,192.168.1.1\n\u003e ```\n\u003e \n\u003e Replace `192.168.1.1` with your router's IP address.\n\u003e \n\u003e \u003c/details\u003e\n\n\u003e [!IMPORTANT]\n\u003e You might have to install Entware's `curl` (and `ca-bundle`) to bypass the security limitations of the one included in the firmware.\n\n```sh\ncurl -fsSL \"https://raw.githubusercontent.com/jacklul/asuswrt-scripts/master/scripts/netboot-download.sh\" -o /jffs/scripts/netboot-download.sh\n```\n\n\u003ca href=\"#available-scripts\"\u003e\u003ci\u003e ^ back to the list ^ \u003c/i\u003e\u003c/a\u003e\u003cbr\u003e\n\n## [`process-affinity.sh`](/scripts/process-affinity.sh)\n\nThis script allows setting custom CPU affinity masks on processes.\n\nIf no mask is specified, it takes the affinity mask of `init` process and decreases its value by one, thus preventing the process from running on the first CPU core.\n\n```sh\ncurl -fsSL \"https://raw.githubusercontent.com/jacklul/asuswrt-scripts/master/scripts/process-affinity.sh\" -o /jffs/scripts/process-affinity.sh\n```\n\n\u003ca href=\"#available-scripts\"\u003e\u003ci\u003e ^ back to the list ^ \u003c/i\u003e\u003c/a\u003e\u003cbr\u003e\n\n## [`process-killer.sh`](/scripts/process-killer.sh)\n\nThis script can kill processes by their names, unfortunately on the official firmware most of them will restart, there is an attempt to prevent that in that script but it is not guaranteed to work.\n\n\u003e [!CAUTION]\n\u003e Use this script at your own risk.\n\n```sh\ncurl -fsSL \"https://raw.githubusercontent.com/jacklul/asuswrt-scripts/master/scripts/process-killer.sh\" -o /jffs/scripts/process-killer.sh\n```\n\n\u003ca href=\"#available-scripts\"\u003e\u003ci\u003e ^ back to the list ^ \u003c/i\u003e\u003c/a\u003e\u003cbr\u003e\n\n## [`rclone-backup.sh`](/scripts/rclone-backup.sh)\n\nThis script can backup all NVRAM variables and selected `/jffs` contents to cloud service using [Rclone](https://github.com/rclone/rclone).\n\nYou have to download the binary and place it on the USB drive. If you installed it through the **Entware** then it will be automatically detected, alternatively it will install it when it detects **Entware** installation (then remove it after the job is done - this feature is targeted for Entware installation in RAM).\n\n[Example backup list](/extras/rclone.list) that can be used with this script.\n\n\u003e [!IMPORTANT]\n\u003e If automatic installation of `rclone` fails then you might have to install Entware's `wget` (or `wget-ssl` when using HTTPS) to bypass the security limitations of the firmware one.\n\n```sh\ncurl -fsSL \"https://raw.githubusercontent.com/jacklul/asuswrt-scripts/master/scripts/rclone-backup.sh\" -o /jffs/scripts/rclone-backup.sh\n```\n\n\u003ca href=\"#available-scripts\"\u003e\u003ci\u003e ^ back to the list ^ \u003c/i\u003e\u003c/a\u003e\u003cbr\u003e\n\n## [`samba-masquerade.sh`](/scripts/samba-masquerade.sh)\n\nEnables masquerading for Samba ports to allow VPN clients to connect to your LAN shares.\n\nBy default, default networks for WireGuard, OpenVPN and IPSec are allowed.\n\n_Recommended to use [`service-event.sh`](#user-content-service-eventsh) as well._\n\n```sh\ncurl -fsSL \"https://raw.githubusercontent.com/jacklul/asuswrt-scripts/master/scripts/samba-masquerade.sh\" -o /jffs/scripts/samba-masquerade.sh\n```\n\n\u003ca href=\"#available-scripts\"\u003e\u003ci\u003e ^ back to the list ^ \u003c/i\u003e\u003c/a\u003e\u003cbr\u003e\n\n## [`service-event.sh`](/scripts/service-event.sh)\n\nThis script tries to emulate [service-event script from Asuswrt-Merlin firmware](https://github.com/RMerl/asuswrt-merlin.ng/wiki/User-scripts#service-event-end) but there is no guarantee whenever it will run before or after the event.\n\nBy default, integrates with all scripts present in this repository (where applicable).\n\n```sh\ncurl -fsSL \"https://raw.githubusercontent.com/jacklul/asuswrt-scripts/master/scripts/service-event.sh\" -o /jffs/scripts/service-event.sh\n```\n\n\u003ca href=\"#available-scripts\"\u003e\u003ci\u003e ^ back to the list ^ \u003c/i\u003e\u003c/a\u003e\u003cbr\u003e\n\n## [`swap.sh`](/scripts/swap.sh)\n\nThis script enables swap file on start, with configurable size and location.\n\n_Recommended to use [`hotplug-event.sh`](#user-content-hotplug-eventsh) as well._\n\n```sh\ncurl -fsSL \"https://raw.githubusercontent.com/jacklul/asuswrt-scripts/master/scripts/swap.sh\" -o /jffs/scripts/swap.sh\n```\n\n\u003ca href=\"#available-scripts\"\u003e\u003ci\u003e ^ back to the list ^ \u003c/i\u003e\u003c/a\u003e\u003cbr\u003e\n\n## [`temperature-warning.sh`](/scripts/temperature-warning.sh)\n\nThis script will send log message when CPU or WLAN chip temperatures reach specified threshold.\n\nBe default, the treshold is set to \u003cins\u003e80C\u003c/ins\u003e.\n\n```sh\ncurl -fsSL \"https://raw.githubusercontent.com/jacklul/asuswrt-scripts/master/scripts/temperature-warning.sh\" -o /jffs/scripts/temperature-warning.sh\n```\n\n\u003ca href=\"#available-scripts\"\u003e\u003ci\u003e ^ back to the list ^ \u003c/i\u003e\u003c/a\u003e\u003cbr\u003e\n\n## [`update-notify.sh`](/scripts/update-notify.sh)\n\nThis script will send you a notification when new router firmware is available.\n\n**Currently supported notification providers:**\n- Email\n- [Telegram](https://telegram.org)\n- [Pushover](https://pushover.net)\n- [Pushbullet](https://www.pushbullet.com)\n\n\u003e [!TIP]\n\u003e You can test the notifications by using `update-notify.sh test` (if it works from the cron) and `update-notify.sh test now` (if it actually sends) commands.\n\n\u003e [!IMPORTANT]\n\u003e You might have to install Entware's `curl` (and `ca-bundle`) to bypass the security limitations of the one included in the firmware.\n\n```sh\ncurl -fsSL \"https://raw.githubusercontent.com/jacklul/asuswrt-scripts/master/scripts/update-notify.sh\" -o /jffs/scripts/update-notify.sh\n```\n\n\u003ca href=\"#available-scripts\"\u003e\u003ci\u003e ^ back to the list ^ \u003c/i\u003e\u003c/a\u003e\u003cbr\u003e\n\n## [`update-scripts.sh`](/scripts/update-scripts.sh)\n\nThis script updates all scripts from this repository present in the same directory.\n\n**This is on-demand script that must be ran manually.**\n\n```sh\ncurl -fsSL \"https://raw.githubusercontent.com/jacklul/asuswrt-scripts/master/scripts/update-scripts.sh\" -o /jffs/scripts/update-scripts.sh\n```\n\n\u003ca href=\"#available-scripts\"\u003e\u003ci\u003e ^ back to the list ^ \u003c/i\u003e\u003c/a\u003e\u003cbr\u003e\n\n## [`usb-mount.sh`](/scripts/usb-mount.sh)\n\nThis script will mount any USB storage device in `/tmp/mnt` directory if for some reason the official firmware does not automount it for you.\n\n_Recommended to use [`hotplug-event.sh`](#user-content-hotplug-eventsh) as well._\n\n```sh\ncurl -fsSL \"https://raw.githubusercontent.com/jacklul/asuswrt-scripts/master/scripts/usb-mount.sh\" -o /jffs/scripts/usb-mount.sh\n```\n\n\u003ca href=\"#available-scripts\"\u003e\u003ci\u003e ^ back to the list ^ \u003c/i\u003e\u003c/a\u003e\u003cbr\u003e\n\n## [`usb-network.sh`](/scripts/usb-network.sh)\n\nThis script will add any USB networking gadget to LAN bridge interface, making it member of your LAN network.\n\nThis is a great way of running Pi-hole in your network on a [Raspberry Pi Zero connected through USB port](https://github.com/jacklul/asuswrt-usb-raspberry-pi).\n\n_Recommended to use [`service-event.sh`](#user-content-service-eventsh) and [`hotplug-event.sh`](#user-content-hotplug-eventsh) as well._\n\n```sh\ncurl -fsSL \"https://raw.githubusercontent.com/jacklul/asuswrt-scripts/master/scripts/usb-network.sh\" -o /jffs/scripts/usb-network.sh\n```\n\n\u003ca href=\"#available-scripts\"\u003e\u003ci\u003e ^ back to the list ^ \u003c/i\u003e\u003c/a\u003e\u003cbr\u003e\n\n## [`vpn-killswitch.sh`](/scripts/vpn-killswitch.sh)\n\nThis script will prevent your LAN from accessing the internet through the WAN interface.\n\nThere might be a small window after router boots and before this script runs when you can connect through the WAN interface but there is no way to avoid this on the official firmware.\n\n\u003e [!TIP]\n\u003e On Asuswrt-Merlin you should use build-in VPN killswitch function instead.\n\n_Recommended to use [`service-event.sh`](#user-content-service-eventsh) as well._\n\n```sh\ncurl -fsSL \"https://raw.githubusercontent.com/jacklul/asuswrt-scripts/master/scripts/vpn-killswitch.sh\" -o /jffs/scripts/vpn-killswitch.sh\n```\n\n\u003ca href=\"#available-scripts\"\u003e\u003ci\u003e ^ back to the list ^ \u003c/i\u003e\u003c/a\u003e\u003cbr\u003e\n\n## [`wgs-lanonly.sh`](/scripts/wgs-lanonly.sh)\n\nThis script will prevent clients connected to WireGuard server from accessing the internet.\n\n_Recommended to use [`service-event.sh`](#user-content-service-eventsh) as well._\n\n```sh\ncurl -fsSL \"https://raw.githubusercontent.com/jacklul/asuswrt-scripts/master/scripts/wgs-lanonly.sh\" -o /jffs/scripts/wgs-lanonly.sh\n```\n\n\u003ca href=\"#available-scripts\"\u003e\u003ci\u003e ^ back to the list ^ \u003c/i\u003e\u003c/a\u003e\u003cbr\u003e\n","project_url":"https://awesome.ecosyste.ms/api/v1/projects/github.com%2Fjacklul%2Fasuswrt-scripts","html_url":"https://awesome.ecosyste.ms/projects/github.com%2Fjacklul%2Fasuswrt-scripts","lists_url":"https://awesome.ecosyste.ms/api/v1/projects/github.com%2Fjacklul%2Fasuswrt-scripts/lists"}