jpskill.com
💬 コミュニケーション コミュニティ

routeros-fundamentals

MikroTik RouterOS v7に関するAIエージェント向けSkillで、RouterOSのCLIやREST API操作、設定に関する問題解決に役立ち、MikroTik製品や特定のパス名が言及された際に、的確な情報を提供するSkill。

📜 元の英語説明(参考)

RouterOS v7 domain knowledge for AI agents. Use when: working with MikroTik RouterOS, writing RouterOS CLI/script commands, calling RouterOS REST API, debugging why a Linux command fails on RouterOS, or when the user mentions MikroTik, RouterOS, CHR, or /ip /system /interface paths. Scope: RouterOS 7.x (long-term and newer) only — v6 is NOT covered and accuracy for v6 problems will be low.

🇯🇵 日本人クリエイター向け解説

一言でいうと

MikroTik RouterOS v7に関するAIエージェント向けSkillで、RouterOSのCLIやREST API操作、設定に関する問題解決に役立ち、MikroTik製品や特定のパス名が言及された際に、的確な情報を提供するSkill。

※ jpskill.com 編集部が日本のビジネス現場向けに補足した解説です。Skill本体の挙動とは独立した参考情報です。

⚡ おすすめ: コマンド1行でインストール(60秒)

下記のコマンドをコピーしてターミナル(Mac/Linux)または PowerShell(Windows)に貼り付けてください。 ダウンロード → 解凍 → 配置まで全自動。

🍎 Mac / 🐧 Linux
mkdir -p ~/.claude/skills && cd ~/.claude/skills && curl -L -o routeros-fundamentals.zip https://jpskill.com/download/20953.zip && unzip -o routeros-fundamentals.zip && rm routeros-fundamentals.zip
🪟 Windows (PowerShell)
$d = "$env:USERPROFILE\.claude\skills"; ni -Force -ItemType Directory $d | Out-Null; iwr https://jpskill.com/download/20953.zip -OutFile "$d\routeros-fundamentals.zip"; Expand-Archive "$d\routeros-fundamentals.zip" -DestinationPath $d -Force; ri "$d\routeros-fundamentals.zip"

完了後、Claude Code を再起動 → 普通に「動画プロンプト作って」のように話しかけるだけで自動発動します。

💾 手動でダウンロードしたい(コマンドが難しい人向け)
  1. 1. 下の青いボタンを押して routeros-fundamentals.zip をダウンロード
  2. 2. ZIPファイルをダブルクリックで解凍 → routeros-fundamentals フォルダができる
  3. 3. そのフォルダを C:\Users\あなたの名前\.claude\skills\(Win)または ~/.claude/skills/(Mac)へ移動
  4. 4. Claude Code を再起動

⚠️ ダウンロード・利用は自己責任でお願いします。当サイトは内容・動作・安全性について責任を負いません。

🎯 このSkillでできること

下記の説明文を読むと、このSkillがあなたに何をしてくれるかが分かります。Claudeにこの分野の依頼をすると、自動で発動します。

📦 インストール方法 (3ステップ)

  1. 1. 上の「ダウンロード」ボタンを押して .skill ファイルを取得
  2. 2. ファイル名の拡張子を .skill から .zip に変えて展開(macは自動展開可)
  3. 3. 展開してできたフォルダを、ホームフォルダの .claude/skills/ に置く
    • · macOS / Linux: ~/.claude/skills/
    • · Windows: %USERPROFILE%\.claude\skills\

Claude Code を再起動すれば完了。「このSkillを使って…」と話しかけなくても、関連する依頼で自動的に呼び出されます。

詳しい使い方ガイドを見る →
最終更新
2026-05-18
取得日時
2026-05-18
同梱ファイル
14

📖 Skill本文(日本語訳)

※ 原文(英語/中国語)を Gemini で日本語化したものです。Claude 自身は原文を読みます。誤訳がある場合は原文をご確認ください。

[スキル名] routeros-fundamentals

RouterOSの基礎

RouterOSはGNU/Linuxではありません

RouterOSはLinuxカーネル(5.6.3)上で動作しますが、カーネルより上のすべてはMikroTik独自のnovaシステムです。これは、エージェントが理解すべき最も重要な事実です。

RouterOSに存在しないもの:

  • /bin/usr/etc/varはありません — FHSレイアウトではありません
  • bash、sh、ash、zshはありません — Unixシェルはまったくありません
  • coreutils(lscatgreppsmountipiptablesなど)はありません
  • glibc、musl、busyboxはありません
  • apt、pkg、opkgはありません — パッケージマネージャーはありません(パッケージはアップロードと再起動によってインストールされる.npkファイルです)
  • systemctlservice、initシステムはありません
  • ユーザーランドからアクセスできる/proc/sysはありません
  • dockerpodmanはありません — RouterOSには独自の/containerサブシステムがあります(7.x以降)

存在するものは次のとおりです:

  • RouterOS CLI — シェルではなく、独自の言語です。SSH、シリアル、WinBox、またはWebFig経由でアクセスします
  • /rest/にあるREST API(HTTP、デフォルトでポート80) — 主要なプログラムインターフェースです
  • RouterOSスクリプト言語(.rscファイル) — bashではなく、独自の構文です。スクリプトのリファレンスを参照してください
  • ポート80上のWebFig(Web UI)
  • ポート8291上のWinBoxプロトコル

エージェントが避けるべき一般的な間違い:

  • ssh admin@host 'ls /'を試さないでください — シェルではなくRouterOS CLIが開きます
  • mountfdiskmkfsを提案しないでください — 代わりに/diskコマンドを使用してください
  • /etc/で設定ファイルを探さないでください — 設定はRouterOSデータベースにあります
  • pingが同じように動作すると仮定しないでください — CLIでは/tool/pingまたは/pingです
  • aptopkg経由でパッケージをインストールすることを提案しないでください — SCP経由で.npkをアップロードし、その後/system/package/apply-changes(7.18以降)または/system/reboot(7.18未満)を実行してください
  • 完全なパッケージリストとインストールパターンについては、追加パッケージのリファレンスを参照してください

RouterOS CLIの構文

RouterOS CLIは、Unixコマンドパイプラインではなく、パスベースのナビゲーションを使用します。

# ナビゲーション
/ip/address/print
/interface/print
/system/resource/print

# エントリの追加
/ip/address/add address=192.168.1.1/24 interface=ether1

# 変更(内部IDまたは検索式による)
/ip/address/set [find interface=ether1] address=10.0.0.1/24

# 削除
/ip/address/remove [find address="192.168.1.1/24"]

# コマンドの実行
/system/reboot
/tool/fetch url="http://example.com/file.npk" dst-path="/"

シェルとの主な構文の違い:

  • =はプロパティを割り当てます(その周りにスペースはありません)
  • [find ...]はクエリ式です(WHEREのようなもの)
  • 文字列は""を使用します(二重引用符のみ)
  • コメントは#を使用します
  • 変数: :local myVar "value"$myVar
  • パイプ、リダイレクト、サブシェルはありません

REST API

RouterOS REST APIはhttp://HOST:PORT/rest/にあります。HTTP動詞は非標準的にマッピングされます。

HTTP RouterOSアクション CLI相当
GET print (リスト/読み取り) /path/print
PUT add (作成) /path/add
PATCH set (更新) /path/set
DELETE remove (削除) /path/remove
POST command (実行) /path/command

主な注意点:

  • PUTは作成します(更新ではありません) — 多くのREST APIとは逆です
  • 空のパスワード認証: admin:(コロンは必須で、その後に何もありません)
  • WebFigのルート(GET /)は認証なしでHTTP 200を返します — ヘルスチェックとして使用してください
  • REST API(/rest/)は認証が必要です(認証なしではHTTP 401)
  • .idフィールドは*HEX形式です(例: *1*A

完全なパターン、エラー処理、フィルタリング、POSTコマンド、および/console/inspectについては、REST APIリファレンスを参照してください。

バージョンスキーム

形式: MAJOR.MINOR[.PATCH][betaN|rcN] — 例: 7.227.22.17.23beta27.22rc1

チャネル: stable / long-term / testing / development

バージョンエンドポイント(プレーンテキスト): https://upgrade.mikrotik.com/routeros/NEWESTa7.<channel>

バージョン解析、比較、ダウンロードURL、およびパッケージ命名については、バージョン解析リファレンスを参照してください。

アーキテクチャ名

MikroTikはこれらのアーキテクチャ識別子を使用します(標準のLinuxアーキテクチャ名ではありません)。

MikroTik名 CPU 一般的なハードウェア
x86 x86_64 CHR、x86ベースのRouterBOARD
arm64 aarch64 最新のARMボード(RB5009、Chateau)
arm ARMv7 古いARMボード
mipsbe MIPSビッグエンディアン レガシーRouterBOARD
mmips MIPSマルチコア hAP ac、RB4011
smips MIPSシングルコア hAP lite、mAP
ppc PowerPC CCR1xxxシリーズ
tile Tilera CCR(古いモデル)

CHR(Cloud Hosted Router)はx86arm64のみで利用可能です。

デフォルトの認証情報

  • ユーザー名: admin
  • パスワード: (空 — パスワードなし)
  • SSH/コンソール経由での初回ログイン時、RouterOS 7.xはパスワードを設定するか、aを押してスキップするよう促します
  • REST APIとWebFigは空のパスワードでのアクセスを許可します

RouterOS CLIからのハードウェアの検査

# PCIデバイス(lspciに相当するRouterOSのコマンド)
/system/resource/hardware/print

# IRQ割り当て(ドライバーのバインディングを表示)
/system/resource/irq/print

# システム概要
/system/resource/print

# ディスク情報
/disk/print

# インストールされているパッケージ
/system/package/print

# IPサービスとポート
/ip/service/print

# ネットワークインターフェース
/interface/print

追加リソース

リファレンスファイル:

📜 原文 SKILL.md(Claudeが読む英語/中国語)を展開

RouterOS Fundamentals

RouterOS Is NOT GNU/Linux

RouterOS runs a Linux kernel (5.6.3) but everything above the kernel is MikroTik's proprietary nova system. This is the single most important fact for agents to internalize.

What does NOT exist on RouterOS:

  • No /bin, /usr, /etc, /var — no FHS layout
  • No bash, sh, ash, zsh — no Unix shell at all
  • No coreutils (ls, cat, grep, ps, mount, ip, iptables, etc.)
  • No glibc, musl, busybox
  • No apt, pkg, opkg — no package manager (packages are .npk files installed via upload + reboot)
  • No systemctl, service, init system
  • No /proc or /sys accessible from userland
  • No docker, podman — RouterOS has its own /container subsystem (7.x+)

What DOES exist:

  • RouterOS CLI — its own language, not shell. Accessed via SSH, serial, WinBox, or WebFig
  • REST API at /rest/ (HTTP, port 80 by default) — the primary programmatic interface
  • RouterOS scripting language (.rsc files) — its own syntax, not bash. See Scripting reference
  • WebFig (web UI) on port 80
  • WinBox protocol on port 8291

Common agent mistakes to avoid:

  • Do NOT try ssh admin@host 'ls /' — it opens RouterOS CLI, not a shell
  • Do NOT suggest mount, fdisk, mkfs — use /disk commands instead
  • Do NOT look for config files at /etc/ — configuration is in the RouterOS database
  • Do NOT assume ping works the same — it's /tool/ping or /ping in CLI
  • Do NOT suggest installing packages via apt or opkg — upload .npk via SCP then /system/package/apply-changes (7.18+) or /system/reboot (<7.18)
  • See Extra packages reference for the full package list and installation pattern

RouterOS CLI Syntax

RouterOS CLI uses path-based navigation, not Unix command pipelines:

# Navigation
/ip/address/print
/interface/print
/system/resource/print

# Adding entries
/ip/address/add address=192.168.1.1/24 interface=ether1

# Modifying (by internal ID or find expression)
/ip/address/set [find interface=ether1] address=10.0.0.1/24

# Removing
/ip/address/remove [find address="192.168.1.1/24"]

# Running a command
/system/reboot
/tool/fetch url="http://example.com/file.npk" dst-path="/"

Key syntax differences from shell:

  • = assigns properties (no spaces around it)
  • [find ...] is the query expression (like WHERE)
  • Strings use "" (double quotes only)
  • Comments use #
  • Variables: :local myVar "value" and $myVar
  • No pipes, no redirection, no subshell

REST API

RouterOS REST API at http://HOST:PORT/rest/. HTTP verbs map non-standardly:

HTTP RouterOS Action CLI Equiv
GET print (list/read) /path/print
PUT add (create) /path/add
PATCH set (update) /path/set
DELETE remove /path/remove
POST command (execute) /path/command

Key gotchas:

  • PUT creates (NOT updates) — opposite of many REST APIs
  • Empty password auth: admin: (colon required, nothing after)
  • WebFig root (GET /) returns HTTP 200 without auth — use as health check
  • REST API (/rest/) requires auth (HTTP 401 without it)
  • .id field is *HEX format (e.g., *1, *A)

See REST API reference for full patterns, error handling, filtering, POST commands, and /console/inspect.

Version Scheme

Format: MAJOR.MINOR[.PATCH][betaN|rcN] — e.g., 7.22, 7.22.1, 7.23beta2, 7.22rc1

Channels: stable / long-term / testing / development

Version endpoint (plain text): https://upgrade.mikrotik.com/routeros/NEWESTa7.<channel>

For version parsing, comparison, download URLs, and package naming: see Version parsing reference.

Architecture Names

MikroTik uses these architecture identifiers (not standard Linux arch names):

MikroTik name CPU Common hardware
x86 x86_64 CHR, x86-based RouterBOARDs
arm64 aarch64 Modern ARM boards (RB5009, Chateau)
arm ARMv7 Older ARM boards
mipsbe MIPS big-endian Legacy RouterBOARDs
mmips MIPS multi-core hAP ac, RB4011
smips MIPS single-core hAP lite, mAP
ppc PowerPC CCR1xxx series
tile Tilera CCR (older models)

CHR (Cloud Hosted Router) is available only for x86 and arm64.

Default Credentials

  • Username: admin
  • Password: (empty — no password)
  • On first login via SSH/console, RouterOS 7.x prompts to set a password or press a to skip
  • REST API and WebFig allow empty-password access

Inspecting Hardware from RouterOS CLI

# PCI devices (the RouterOS equivalent of lspci)
/system/resource/hardware/print

# IRQ assignments (shows driver binding)
/system/resource/irq/print

# System overview
/system/resource/print

# Disk info
/disk/print

# Installed packages
/system/package/print

# IP services and ports
/ip/service/print

# Network interfaces
/interface/print

Additional Resources

Reference files:

Related skills:

  • For the /container subsystem (VETH, device-mode, lifecycle): see the routeros-container skill
  • For netinstall-cli and device flashing: see the routeros-netinstall skill
  • For the /app YAML container format (7.22+): see the routeros-app-yaml skill
  • For /console/inspect tree traversal and schema generation: see the routeros-command-tree skill
  • For running CHR in QEMU (local or CI): see the routeros-qemu-chr skill
  • For packet capture, /tool/sniffer, and TZSP streaming: see the routeros-sniffer skill

MCP tools:

  • For command tree browsing and property lookups: use the rosetta MCP server tools (routeros_search, routeros_get_page, routeros_command_tree)

同梱ファイル

※ ZIPに含まれるファイル一覧。`SKILL.md` 本体に加え、参考資料・サンプル・スクリプトが入っている場合があります。