Routeros Netinstall logo

Routeros Netinstall

Organization
tikoci
routeros-netinstall

MikroTik netinstall-cli for automated RouterOS device flashing. Use when: automating netinstall, writing scripts that invoke netinstall-cli, building netinstall tooling, understanding etherboot/BOOTP/TFTP protocols, working with RouterOS package files (.npk), using modescript or configure script, or when the user mentions netinstall, etherboot, or device flashing.

Overview

Publishertikoci
Repositoryrouteros-skills
Skill namerouteros-netinstall
Stars
85
Forks
18
Bundled files
Instructions only
LicenseMIT
Links
  • Markdown instructions

    A SKILL.md file the model loads on demand, so it only costs tokens when a request actually matches.

  • Works with any LLM

    AI skills are plain Markdown, not provider-specific code, so this works with GPT, Claude, Gemini, Grok, or a local model.

  • Self-contained

    Everything the model needs lives in the instructions — no extra files to sync.

  • Open source

    Published by tikoci on GitHub. Read the source before you install it.

Installation

Install the Routeros Netinstall AI skill in TypingMind to use it with any LLM, or drop it into another agent that reads SKILL.md.

1

Install in TypingMind

TypingMind installs a skill straight from its GitHub folder — it reads SKILL.md, bundles the resource files, and stores the result locally.

  1. Open the app and go to Plugins → Skills.
  2. Choose "Install from GitHub".
  3. Paste the skill folder URL below and confirm.
    https://github.com/tikoci/routeros-skills/tree/main/routeros-netinstall
  4. Enable the skill in any chat where you want it available.
Plugins → Skills → Add skill → From GitHub URL, then paste the folder URL and press Continue.
2

Install in another agent

Any agent that reads the Agent Skills format can use this skill — copy the folder into that agent's skills directory.

Claude Code — .claude/skills
git clone --depth 1 https://github.com/tikoci/routeros-skills.git /tmp/routeros-skills
mkdir -p .claude/skills
cp -r /tmp/routeros-skills/routeros-netinstall .claude/skills/routeros-netinstall
Restart Claude Code after copying so it picks up the new skill.

Use it in TypingMind

Enable Routeros Netinstall in any TypingMind chat and the model takes it from there. Its name and description sit in the system prompt, and the moment a request matches, the model loads the full instructions itself — you never invoke it by hand, and it costs no tokens until it is actually used.

The model loads Routeros Netinstall on its own as soon as a request matches it.

Works with any AI model

AI skills are plain Markdown instructions rather than provider-specific code, so Routeros Netinstall is not tied to the model it was written for. Install it once in TypingMind and use it with GPT-5, Claude, Gemini, Grok, DeepSeek, Mistral, Llama, or a local model you run yourself — all on your own API keys.

  • Loaded only when it is needed

    The system prompt carries just the name and description. The instructions are fetched on the first matching request, so an idle skill costs nothing.

  • Switch models mid-chat

    Because the skill is instructions rather than code, changing model does not break it — the next model reads the same SKILL.md.

Skill instructions

This is the SKILL.md content the model loads. Read it before installing — a skill is instructions your model will follow.

RouterOS Netinstall

This skill focuses on official Netinstall / netinstall-cli behavior. tikoci/netinstall is a useful wrapper and source of grounded examples, but it is only one way to drive the tool.

What netinstall-cli Does

Netinstall reinstalls RouterOS onto a device that has booted into etherboot mode. The Linux tool, netinstall-cli, listens for BOOTP requests and then sends the RouterOS boot image and selected .npk packages.

Grounded behavior from MikroTik docs:

  • Netinstall re-formats the system drive
  • It does not erase the RouterOS license key
  • It does not reset RouterBOOT settings
  • It works over a direct Layer 2 path using BOOTP/DHCP ports and TFTP
  • It requires root / sudo

netinstall-cli is the Linux command-line variant. The Windows GUI exposes nearly the same core options.

Command Syntax

text
netinstall-cli [-r] [-e] [-b] [-m [-o]] [-f] [-v] [-c]
               [-k <keyfile>] [-s <userscript>] [-sm <modescript>]
               [--mac <mac>] {-i <interface> | -a <client-ip>} [PACKAGES...]

Flags

FlagMeaning
-rReinstall and apply the default-configuration stage
-eReinstall with empty configuration
-bDiscard the currently installed branding package
-mEnable repeated installs in one run
-oWith -m, only reinstall a given MAC once per run; by itself it behaves like a normal single install
-fIgnore storage-size checks
-vVerbose output
-cAllow multiple netinstall instances on the same host
-k <keyfile>Install a license key (.KEY)
-s <userscript>Install a persistent configure script that replaces the RouterOS-supplied default configuration script
-sm <modescript>Install a one-time mode script for the first boot after install
--mac <mac>Only respond to this MAC address
-i <interface>Bind to a specific interface
-a <client-ip>Assign a specific client IP; if -i is used, server IP is auto-detected

Hard Rules

  1. The system package must be listed first. Put routeros-...npk first in the package list.
  2. Root privileges are required. Netinstall uses privileged BOOTP/TFTP ports.
  3. Multi-arch package sets are allowed. Netinstall detects the device architecture and only uses matching packages.
  4. No -r and no -e means "keep old configuration". Netinstall downloads the current configuration database, reformats the device, and uploads that configuration back. This does not preserve user files or databases such as Dude or User Manager.

Install Workflow and Script Order

The official workflow is:

  1. Put the device into etherboot
  2. Run Netinstall with the desired packages and optional scripts
  3. On the next boot, RouterOS runs the initial-configuration steps

For Linux netinstall-cli, the important first-boot order is:

  1. Mode script (-sm) runs first
  2. Custom/default configuration runs after that
  3. If the mode script changes device-mode, the device reboots immediately after the mode script completes

That ordering matters: use -sm for first-boot state that must happen before default or custom configuration, especially /system/device-mode and protected-routerboot.

Configure Script vs Mode Script

The docs use several names for the persistent -s script: configure script, initial configuration, and the custom default configuration script visible at:

routeros
/system/default-configuration/custom-script/print

These two script types are different:

FeatureConfigure script (-s)Mode script (-sm)
PurposeReplace RouterOS-supplied default config scriptOne-time first-boot actions before config scripts
When it runsAs the device's default-configuration stageOn first boot after install, before custom/default config
PersistenceStored on deviceAuto-removed after execution
Survives upgradesYesNo
Later /system reset-configurationRuns again after resetDoes not persist for later resets
Version requirementAvailable in RouterOS 7.x docsRequires RouterOS 7.22+ and netinstall-cli 7.22+
Timeout120 seconds120 seconds
File formatRegular RouterOS import file (.rsc)Regular RouterOS import file (.rsc)

Additional grounded details:

  • Configure scripts can read $defconfPassword and $defconfWifiPassword starting with RouterOS 7.10beta8
  • MikroTik docs explicitly suggest introducing a delay before configure-script execution
  • If a router was netinstalled with a configure script, later /system reset-configuration runs that same script again until the device is re-netinstalled without it

Package URLs and Naming

Use the normal RouterOS download tree:

text
https://download.mikrotik.com/routeros/{version}/routeros-{version}-{arch}.npk
https://download.mikrotik.com/routeros/{version}/all_packages-{arch}-{version}.zip
https://download.mikrotik.com/routeros/{version}/netinstall-{version}.tar.gz

Use download.mikrotik.com first for all release channels. Treat cdn.mikrotik.com as a fallback mirror/cache, not the primary version rule.

Architecture suffixes

ArchitecturePackage form
armrouteros-7.22-arm.npk
arm64routeros-7.22-arm64.npk
mipsberouteros-7.22-mipsbe.npk
mmipsrouteros-7.22-mmips.npk
smipsrouteros-7.22-smips.npk
ppcrouteros-7.22-ppc.npk
tilerouteros-7.22-tile.npk
x86routeros-7.22.npk

x86 is the naming exception: the package filename omits the architecture suffix, but the all-packages ZIP still uses x86, for example all_packages-x86-7.22.zip.

Download and Run

Official Linux quick-start pattern:

sh
wget https://download.mikrotik.com/routeros/7.22/netinstall-7.22.tar.gz
tar -xzf netinstall-7.22.tar.gz

sudo ./netinstall-cli -r -i eth0 \
  routeros-7.22-arm64.npk \
  container-7.22-arm64.npk

Static IP on the netinstall host is strongly recommended, for example:

sh
sudo ifconfig eth0 192.168.88.2/24

Common Scripted Cases

Empty config

sh
sudo ./netinstall-cli -e -b -i eth0 \
  routeros-7.22-arm64.npk

Keep old configuration

sh
sudo ./netinstall-cli -i eth0 \
  routeros-7.22-arm64.npk

This keeps the configuration database only; it does not preserve files stored on the device.

First-boot mode script

routeros
/system/device-mode update mode=advanced container=yes
sh
sudo ./netinstall-cli -r -sm modescript.rsc -i eth0 \
  routeros-7.22-arm64.npk \
  container-7.22-arm64.npk

This is the main documented use for -sm: set device mode during the first boot without requiring a later manual confirmation flow.

Etherboot Notes

Devices must be in etherboot mode before Netinstall can see them. Common entry methods:

  • reset button
  • serial console (Ctrl+E)
  • RouterOS setting boot-device=try-ethernet-once-then-nand

Netinstall uses BOOTP/DHCP ports, so avoid other DHCP sources on the same segment. The docs also call out two common failure cases:

  • some USB Ethernet adapters create an extra link flap and the device is missed
  • DHCP snooping can block the packets unless the Netinstall-facing port is trusted

Non-x86 Hosts

netinstall-cli is a Linux i386 ELF binary.

HostPractical approach
x86_64 LinuxRun it directly
ARM/ARM64 LinuxUse QEMU user-mode (qemu-i386-static or qemu-i386)
macOSRun Linux in a VM with bridged networking

This is where tikoci/netinstall is useful as a reference wrapper: it automates package download, QEMU-on-ARM, and macOS VM execution, but the underlying Netinstall behavior is still the same netinstall-cli flow documented above.

Related References

Frequently asked questions

What does the Routeros Netinstall AI skill do?

MikroTik netinstall-cli for automated RouterOS device flashing. Use when: automating netinstall, writing scripts that invoke netinstall-cli, building netinstall tooling, understanding etherboot/BOOTP/TFTP protocols, working with RouterOS package files (.npk), using modescript or configure script, or when the user mentions netinstall, etherboot, or device flashing.

Why use Routeros Netinstall on TypingMind?

Because you install it once and use it with any model. Routeros Netinstall is plain Markdown rather than provider-specific code, so the same skill runs on GPT-5, Claude, Gemini, Grok, or a local model — and you can switch model mid-chat without it breaking. TypingMind runs on your own API keys, so you pay providers directly instead of a per-seat subscription, and your skills and chats stay in your own storage.

How do I install Routeros Netinstall in TypingMind?

Open Plugins → Skills → Install from GitHub in TypingMind and paste https://github.com/tikoci/routeros-skills/tree/main/routeros-netinstall. TypingMind reads its SKILL.md and installs it as a skill you can enable per chat.

Which AI models can use Routeros Netinstall?

Any model you connect in TypingMind. AI skills are plain Markdown instructions rather than provider-specific code, so GPT, Claude, Gemini, Grok, and local models can all load this skill when a request matches it.

How many AI models can I use with Routeros Netinstall?

As many as you like. As long as a model supports skills, you can use Routeros Netinstall with it — GPT, Claude, Gemini, Grok, DeepSeek, Mistral, Llama and more — all on TypingMind with your own API keys.

Is the Routeros Netinstall AI skill free?

Yes. It is published on GitHub by tikoci under the MIT license. You only pay your own AI provider for the tokens you use.

What are AI skills?

An AI skill is a reusable instruction bundle that teaches an AI model how to do one specific task. It follows the open Agent Skills format: a SKILL.md file with a name and description, plus any scripts, templates or reference files the model may need. The model reads the instructions only when your request matches the skill, so an installed skill costs nothing until it is used.

How are AI skills different from plugins or MCP servers?

A plugin or MCP server gives a model new tools to call — code that runs somewhere and returns a result. An AI skill gives the model knowledge and process instead: how to approach a task, which steps to follow, what good output looks like. Skills are plain Markdown, so they need no server, no API key and no runtime, and they work with any model.

View all

Set up your own AI workspace now

Get notified about new features and future giveaways by subscribing to our newsletter 👇