pt_device_power
Power a Packet Tracer device on or off to simulate equipment failure or restart a router so it rereads its startup-config, with a read-back confirming the resulting power state.
Instructions
Powers a device in PT on or off, with a verification read.
Useful to simulate equipment failure and see how routing reacts, or to restart a router so it rereads its startup-config.
Works on every model, PCs included. Hosts have no IOS boot,
so when powering them on booting comes back null; on a router
or switch the boot is skipped so as not to wait for the full start-up.
Parameters:
device: device name in PT.
on: True powers on (default), False powers off.
Example: simulate R2 going down: pt_device_power(device="R2", on=False)
Tool call template
Replace each placeholder with a value matching the input schema. Only required parameters are included; add optional parameters as needed.
{
"id": 1,
"jsonrpc": "2.0",
"method": "tools/call",
"params": {
"arguments": {
"device": "<device>"
},
"name": "pt_device_power"
}
}Input Schema
| Name | Required | Description | Default |
|---|---|---|---|
| on | No | ||
| device | Yes |