Skip to content

seancrites/def-rosDownload

Folders and files

NameName
Last commit message
Last commit date

Latest commit

 

History

8 Commits
 
 
 
 
 
 
 
 

Repository files navigation

def-rosDownload

A RouterOS v7 global function script for staging a specific RouterOS version (upgrade or downgrade) by downloading the main package and all currently enabled extra packages (e.g., ups) as local .npk files.

Ideal for controlled upgrades/downgrades to specific versions, not just latest. Supports feature preservation and provides contextual next-steps (reboot for upgrades; /system package downgrade for downgrades).

Features

  • Individual .npk downloads for main + extras (direct from MikroTik servers)
  • Detailed per-package CLI output and accurate staging status
  • Contextual guidance: upgrade vs downgrade instructions

Requirements

  • RouterOS >= v7.14.3
  • Outbound HTTPS access to download.mikrotik.com (port 443)

Quick Start

  1. Fetch def-rosDownload.rsc from GitHub

    /tool fetch url="https://raw.githubusercontent.com/seancrites/def-rosDownload/refs/heads/master/def-rosDownload.rsc" mode=https dst-path="def-rosDownload.rsc" output=file
  2. Load the file as a script

    /system script add name=def-rosDownload source=[:file get def-rosDownload.rsc contents]
  3. Run script to load global function

    /system script run def-rosDownload
  4. Verify function registration

    /system script environment print where name=rosDownload
  5. Make persistent on boot:

    /system scheduler add name="load-rosDownload" interval=0 \
       on-event="/system script run def-rosDownload" start-time=startup
  6. Use:

  • Upgrade:

    $rosDownload 7.20.1
  • Downgrade:

    $rosDownload 7.18.1
  • LTS downgrade:

    $rosDownload 6.49.10

After successful staging

  • Upgrade: /system reboot
  • Downgrade: /system package downgrade (confirm prompt → auto-reboot)

Production Notes

  • Always export config (/export file=config-backup) before staging.
  • In HA setups (VRRP clusters), stage on standby unit first.
  • Rare unavailable extras (architecture-specific): Manual upload from "Extra packages" ZIP if needed.
  • Monitor: /log print where message~"rosDownload" | /file print detail where name~"\.npk$"

License

This project is licensed under the BSD 3-Clause License. See the LICENSE file for details.

Author

December 2025

About

Upgrade/Downgrade to specific RouterOS versions via CLI.

Resources

License

Stars

Watchers

Forks

Releases

No releases published

Packages

 
 
 

Contributors