Automation · Network Automation
SSH Automation
Cheat sheet · https://pcornel.dk/topic.php?topic=5589
Answer
SSH Automation uses authenticated encrypted sessions to execute network management operations, commonly CLI commands or subsystem protocols, against selected devices.
Remember
- TCP/22 reachable ≠ SSH authenticated.
- SSH authenticated ≠ command authorized.
- Host-key acceptance ≠ host identity trustworthy when trust-on-first-use or stale keys are involved.
- Command exit/channel success ≠ intended network state.
First checks
ssh -o BatchMode=yes <user>@<device> 'show version'— SSH works non-interactively- Host key verification — security
- Netmiko/Scrapli/ansible network_cli — libraries
Verify in this order
controller → SSH → device CLI
Where it usually breaks
SSH proves a management transport/session boundary; it does not prove command semantics, configuration persistence or network service correctness.
SSH Automation Network Automation proof-boundary map
| Boundary | Healthy evidence | Suspicious evidence |
|---|---|---|
| Intent / scope | Source revision and exact targets are explicit | Stale inventory, hidden selector or wrong variables change scope |
| Management operation | Transport/model/payload and per-device response are traceable | Auth/capability/parser differences hide partial or wrong execution |
| Device state | Effective and persistent state are read back | Accepted config/API result is mistaken for convergence |
| Network proof | Original control/data-plane or service test passes | Automation summary substitutes for actual network acceptance |
Read-only verification commands unless stated otherwise. Confirm syntax for your platform and release. Full reference: https://pcornel.dk/topic.php?topic=5589