Runbook Template

Copy this template when creating new runbooks. Runbooks document repeatable procedures with explicit steps, validation commands, and rollback procedures.

Template

= [RUNBOOK-YYYY-MM-DD] Procedure Name
:description: Brief description of what this runbook accomplishes
:author: Your Name
:revdate: YYYY-MM-DD
:icons: font

== Overview

Brief description of the procedure and when to use it.

=== Prerequisites

* [ ] Prerequisite 1
* [ ] Prerequisite 2
* [ ] Required access/permissions

=== Scope

* *In Scope:* What this runbook covers
* *Out of Scope:* What this runbook does NOT cover

== Variables

Define variables at the start for easy customization:

[source,bash,subs=attributes+]
----
HOSTNAME="example-host"
TARGET_IP="10.50.1.100"
----

== Procedure

=== Phase 1: Preparation

==== 1.1 Verify Prerequisites

[source,bash]
----
# Verify connectivity
ping -c 3 ${TARGET_IP}
----

.Expected Output
----
3 packets transmitted, 3 received, 0% packet loss
----

==== 1.2 Backup Current State

[source,bash]
----
# Backup current configuration
cp /etc/config /etc/config.backup.$(date +%Y%m%d)
----

=== Phase 2: Execution

==== 2.1 Step Name

[source,bash]
----
# Command to execute
command --option value
----

[NOTE]
====
Important notes about this step.
====

==== 2.2 Validation

[source,bash]
----
# Verify the change
validation-command
----

.Expected Output
----
Expected output here
----

=== Phase 3: Verification

==== 3.1 Functional Test

[source,bash]
----
# Test that the change works
test-command
----

==== 3.2 Cleanup

[source,bash]
----
# Remove temporary files
rm -f /tmp/temp-file
----

== Rollback

If issues occur, follow these steps to revert:

[source,bash]
----
# Restore backup
cp /etc/config.backup.$(date +%Y%m%d) /etc/config
----

== Troubleshooting

=== Issue: Common Problem

*Symptom:* Description of the problem

*Cause:* Why it happens

*Resolution:*
[source,bash]
----
# Fix command
fix-command
----

== Post-Execution Checklist

* [ ] Verified service is running
* [ ] Tested functionality
* [ ] Updated documentation
* [ ] Notified stakeholders

== Related

* xref:related-runbook.adoc[Related Runbook]
* External documentation link

Runbook Naming Convention

Prefix Purpose Example

RUNBOOK-

Standard operational procedure

RUNBOOK-2026-02-12-vault-pki-issuance.adoc

INCIDENT-

Incident response procedure

INCIDENT-2026-02-12-auth-failure.adoc

DEPLOY-

Deployment procedure

DEPLOY-2026-02-12-ise-upgrade.adoc

RECOVERY-

Disaster recovery procedure

RECOVERY-2026-02-12-backup-restore.adoc

Best Practices

  1. Be explicit - Include exact commands, not just descriptions

  2. Include validation - Every step should have a verification command

  3. Show expected output - So operators know if the command succeeded

  4. Provide rollback - Every procedure should be reversible

  5. Use variables - Make runbooks reusable across environments

  6. Test first - Validate runbooks in non-production before use

Example Runbooks

See these runbooks for reference:

  • Vault PKI Certificate Issuance (infra-ops)

  • Backup Strategy (infra-ops)

  • Linux AD Auth dACL (ise-linux)