Getting Console Output and Rebooting Instances
Console output is a valuable tool for problem diagnosis. It is especially useful for troubleshooting kernel problems and service configuration issues that could cause an instance to terminate or become unreachable before its SSH daemon can be started.
Similarly, the ability to reboot instances that are otherwise unreachable is valuable for both troubleshooting and general instance management.
Amazon EC2 instances do not have a physical monitor through which you can view their console output. They also lack physical controls that allow you to power up, reboot, or shut them down. To allow these actions, we provide them through the Amazon EC2 SOAP API, Query API, and command line tools.
Console Output
For Linux and UNIX instances, the Amazon EC2 instance console output displays the exact console output that would normally be displayed on a physical monitor attached to a machine. This output is buffered because the instance produces it and then posts it to a store where the instances owner can retrieve it.
For Windows instances, the Amazon EC2 instance console output displays the last three system event log errors.
The posted output is not continuously updated; only when it is likely to be of the most value. This includes shortly after instance boot, after reboot, and when the instance terminates.
Note | |
---|---|
Only the most recent 64 KB of posted output is stored, which is available for at least 1 hour after the last posting. |
You can retrieve the console output for an instance using GetConsoleOutput
. For
more information, go to the Amazon Elastic Compute Cloud API Reference or Amazon Elastic Compute Cloud Command Line Reference.
Note | |
---|---|
Only the instance owner can access the console output. |
Instance Reboot
Just as you can reset a machine by pressing the reset button,
you can reset Amazon EC2 instances using RebootInstances
. For
more information, go to the Amazon Elastic Compute Cloud API Reference or Amazon Elastic Compute Cloud Command Line Reference.
Caution | |
---|---|
For Windows instances, this operation performs a hard reboot that might result in data corruption. |