Communitygithub.com

cisco-ios-patterns

Cisco IOSおよびIOS-XEのレビューパターン。showコマンド、設定階層、ワイルドカードマスク、ACL配置、インターフェース管理、安全な変更ウィンドウ検証を網羅。Cisco IOS / IOS-XEの設定を読む、書く、レビューする場合、または変更ウィンドウを計画する際に使用します。

cisco-ios-patterns とは?

このスキルは、Cisco IOS および IOS-XE プラットフォーム向けの設定レビューと変更検証に特化した技術パターンを提供します。主な用途は、変更ウィンドウ前の設定レビュー、トラブルシューティングのための読み取り専用showコマンドの選択、ACLのワイルドカードマスクとインターフェース方向の確認、グローバル/インターフェース/ルーティングプロセス/ライン設定モードの説明、変更が意図的に保存されたかの検証です。このスキルは、Claude Code、Cursor、CodexなどのAIエージェント上で動作することを前提としており、SKILL.mdに定義された一連のパターンと運用ルールに従います。具体的には、変更前の状態取得、候補設定のレビュー、管理アクセスのロックアウト防止、最小限の変更適用、変更後の状態確認と検証後の保存というワークフローを推奨します。また、典型的なモード遷移例、読み取り専用コマンド一覧、ワイルドカードマスクとサブネットマスクの変換表、ACL配置前のチェックリスト、インターフェース設定のベストプラクティス、変更前後比較のためのshowコマンド、一般的なアンチパターンをカバーしています。

対応~Claude Code~Codex CLI~Cursor
npx skills add https://github.com/affaan-m/everything-claude-code/tree/main/skills/cisco-ios-patterns

お気に入りのAIに質問する

このエージェントスキルを事前に読み込んだ状態で新しいチャットを開きます。

ドキュメント

Cisco IOS パターン

このスキルは、Cisco IOS または IOS-XE のスニペットをレビューしたり、変更ウィンドウのチェックリストを作成したり、インシデントを悪化させずにルーターやスイッチから証拠を収集する方法を説明する場合に使用します。

使用するタイミング

  • 計画された変更前に IOS または IOS-XE 設定をレビューする場合。
  • トラブルシューティングのために読み取り専用の show コマンドを選択する場合。
  • ACL のワイルドカードマスクとインターフェース方向を確認する場合。
  • グローバル、インターフェース、ルーティングプロセス、ライン設定モードについて説明する場合。
  • 変更がランニングコンフィグに適用され、意図的に保存されたことを確認する場合。

運用ルール

IOS の例はパターンとして扱い、そのまま本番環境に適用できる変更としては扱わないでください。実際のデバイスで変更を行う前に、プラットフォーム、インターフェース名、現在の設定、ロールバックパス、アウトオブバンドアクセスを確認してください。

以下のワークフローを推奨します:

  1. 読み取り専用コマンドで現在の状態を取得する。
  2. 正確な変更候補設定をレビューする。
  3. 管理アクセスがロックアウトされないことを確認する。
  4. メンテナンスウィンドウ内で最小限の変更を適用する。
  5. 状態を再読み取りし、ベースラインと比較し、検証後にのみ保存する。

モードリファレンス

Router> enable
Router# show running-config
Router# configure terminal
Router(config)# interface GigabitEthernet0/1
Router(config-if)# description UPLINK-TO-CORE
Router(config-if)# no shutdown
Router(config-if)# exit
Router(config)# end
Router# show running-config interface GigabitEthernet0/1

running-config はアクティブメモリです。startup-config は再起動後も保持される設定です。コマンドが受け入れられたからといって変更を保存しないでください。まず動作を検証し、変更が承認された場合のみ copy running-config startup-config を使用してください。

読み取り専用収集

show version
show inventory
show processes cpu sorted
show memory statistics
show logging
show running-config | section line vty
show running-config | section interface
show running-config | section router bgp
show ip interface brief
show interfaces
show interfaces status
show vlan brief
show mac address-table
show spanning-tree
show ip route
show ip protocols
show ip access-lists
show route-map
show ip prefix-list

設定にシークレット、顧客名、プライベートトポロジが含まれている可能性がある場合、チケットに全設定をダンプするのではなく、必要な特定のセクションのみを収集してください。

ワイルドカードマスク

IOS の ACL および多くのルーティングステートメントは、サブネットマスクではなくワイルドカードマスクを使用します。

サブネットマスク       ワイルドカードマスク
255.255.255.255   0.0.0.0
255.255.255.252   0.0.0.3
255.255.255.0     0.0.0.255
255.255.0.0       0.0.255.255

展開前にワイルドカードマスクをレビューしてください。サブネットマスクを誤ってワイルドカードとして使用すると、意図したよりもはるかに多くのトラフィックに一致する可能性があります。

ip access-list extended WEB-IN
  10 permit tcp 192.0.2.0 0.0.0.255 any eq 443
  999 deny ip any any log

すべての ACL の最後には暗黙の deny があります。運用目標にミスの監視が含まれる場合は、明示的なログ付き deny を追加し、ログ量が安全であることを確認してください。

ACL 配置レビュー

ACL をインターフェースに適用する前に、以下の質問に答えてください:

  • フィルタリングされるトラフィックの方向は、in ですか、それとも out ですか?
  • 管理トラフィックは、既知のジャンプホストまたは管理サブネットから発信されていますか?
  • 必要なルーティング、DNS、NTP、監視、アプリケーショントラフィックに対する明示的な permit がありますか?
  • 安全なテストソースからのヒットカウンターは利用可能ですか?
  • ロールバックコマンドとアクティブなコンソールまたはアウトオブバンドパスはありますか?

ファイアウォールや ACL の保護を削除して到達可能性をテストしないでください。最初にカウンター、ログ、ルート状態を読み取ってください。

インターフェース管理

interface GigabitEthernet0/1
 description UPLINK-TO-CORE
 switchport mode trunk
 switchport trunk allowed vlan 10,20,30
 switchport trunk native vlan 999
 no shutdown

明確な説明、明示的な switchport モード、文書化されたネイティブ VLAN を使用してください。ルーテッドインターフェースでは、リンク状態が転送の正しさを意味すると想定する前に、マスク、ピアアドレス、ルーティングプロセスを確認してください。

変更ウィンドウ検証

実際の変更に一致する before/after チェックを使用してください。

show running-config | section interface GigabitEthernet0/1
show interfaces GigabitEthernet0/1
show logging | include GigabitEthernet0/1|changed state|line protocol
show ip route <prefix>
show ip access-lists <name>

ルーティング変更の場合は、変更の前後でネイバー状態とルートテーブルも取得してください。ACL 変更の場合は、汎用的な ping に頼るのではなく、計画されたテストソースからのヒットカウンターを比較してください。

アンチパターン

  • デバイス固有の差分を取らずに生成された設定を適用する。
  • 変更後のチェックが合格する前に設定を保存する。
  • IOS がワイルドカードマスクを期待する場所でサブネットマスクを使用する。
  • ACL を間違ったインターフェース方向に適用する。
  • ACL、ルートポリシー、認証を無効にしてトラブルシューティングを行う。
  • シークレットやトポロジをサニタイズせずに、完全な設定を公開ツールに貼り付ける。

関連情報

  • エージェント: network-config-reviewer
  • エージェント: network-troubleshooter
  • スキル: network-config-validation
  • スキル: network-interface-health

Individual skills in this repo

This repo contains 20 individual skills — each has its own dedicated page.

accessibility

Design, implement, and audit inclusive digital products using WCAG 2.2 Level AA. Use when building or auditing UI that must meet WCAG 2.2 Level AA, or when reviewing a change for keyboard, contrast, or screen-reader support.

affaan-m/claude-api

Anthropic Claude API patterns for Python and TypeScript. Covers Messages API, streaming, tool use, vision, extended thinking, batches, prompt caching, and Claude Agent SDK. Use when building applications with the Claude API or Anthropic SDKs.

affaan-m/everything-claude-code

End-to-end marketing campaign planning and execution. Covers audience research, positioning, campaign angle definition, landing page copy, email sequences, social posts, ad copy, short-form video scripts, and content calendars. Use as the orchestration layer for multi-channel product launches. Use when planning or executing a multi-channel product launch, or producing landing page, email, social, or ad copy.

affaan-m/everything-claude-code

Development conventions and patterns for everything-claude-code. JavaScript project with conventional commits.

affaan-m/everything-claude-code-conventions

Development conventions and patterns for everything-claude-code. JavaScript project with conventional commits.

affaan-m/frontend-design

Create distinctive, production-grade frontend interfaces with high design quality. Use when the user asks to build web components, pages, or applications and the visual direction matters as much as the code quality.

affaan-m/gget

gget CLI and Python workflow for quick genomic database queries, sequence lookup, BLAST-style searches, enrichment checks, and reproducible bioinformatics evidence logs.

affaan-m/literature-review

Systematic literature-review workflow for academic, biomedical, technical, and scientific topics, including search planning, source screening, synthesis, citation checks, and evidence logging.

affaan-m/motion-ui

Production-ready UI motion system for React/Next.js. Use when implementing animations, transitions, or motion patterns.

affaan-m/project-guidelines-example

Example project-specific skill template based on a real production application.

affaan-m/pubmed-database

Direct PubMed and NCBI E-utilities search workflows for biomedical literature, MeSH queries, PMID lookup, citation retrieval, and API-backed literature monitoring.

affaan-m/scholar-evaluation

Structured scholarly-work evaluation for papers, proposals, literature reviews, methods sections, evidence quality, citation support, and research-writing feedback.

affaan-m/uspto-database

USPTO patent and trademark data workflow for official record lookup, PatentSearch queries, TSDR checks, assignment data, and reproducible IP research logs.

agent-architecture-audit

Full-stack diagnostic for agent and LLM applications. Audits the 12-layer agent stack for wrapper regression, memory pollution, tool discipline failures, hidden repair loops, and rendering corruption. Produces severity-ranked findings with code-first fixes. Essential for developers building agent applications, autonomous loops, or any LLM-powered feature. Use when an agent or LLM feature misbehaves and the failing layer is unknown, or before shipping an agent stack.

agent-eval

Head-to-head comparison of coding agents (Claude Code, Aider, Codex, etc.) on custom tasks with pass rate, cost, time, and consistency metrics. Use when choosing between coding agents, or when a change to an agent setup needs measured pass rate, cost, and time rather than an impression.

agent-harness-construction

Design and optimize AI agent action spaces, tool definitions, and observation formatting for higher completion rates. Use when defining or revising an agent

agentic-engineering

Operate as an agentic engineer using eval-first execution, decomposition, and cost-aware model routing. Use when planning or executing engineering work that agents will carry out end to end.

agentic-os

Build persistent multi-agent operating systems on Claude Code. Covers kernel architecture, specialist agents, slash commands, file-based memory, scheduled automation, and state management without external databases. Use when building a persistent multi-agent system on Claude Code with its own memory, commands, and scheduling.

agent-introspection-debugging

Structured self-debugging workflow for AI agent failures using capture, diagnosis, contained recovery, and introspection reports. Use when an agent run fails and you need a reproducible diagnosis instead of a retry.

agent-payment-x402

Add x402 payment execution to AI agents with per-task budgets, spending controls, and non-custodial wallets. Supports Base through agentwallet-sdk and X Layer through OKX Payments / OKX Agent Payments Protocol. Use when an agent must pay for something itself and needs per-task budgets, spending controls, and a non-custodial wallet.

関連スキル