Utility_Operations
This section illustrates the adapter request and response for the Get Console Output Utility operation.
Get Console Output operation
The Get Console Output operation retrieves console output for a specified instance.
The console output for an instance is buffered and posted after an instance is booted, rebooted, or terminated. Amazon EC2 preserves the most recent 64 KB output, which is available for at least one hour after the latest post to the console output.
The following figure shows the sample <items> XML element for the Get Console Output operation.
Sample <items> XML element for the Get Console Output operation
<item>
<parameters>
<instance-id></instance-id>
</parameters>
</item>
</items>
The following table describes the adapter request elements for the Get Console Output operation.
Adapter request elements for the Get Console Output operation
Element | Definition | Required |
|---|---|---|
<wsdl-location> | Specifies the target Web Service Description Language (WSDL) URL for Amazon EC2 | Conditional:
|
<endpoint-address> | Specifies the web service endpoint for the adapter to use while performing operations on Amazon EC2 instances across different regions | No |
<signature-properties> | Specifies the mode for signing the adapter request | Conditional:
|
<operation-name> | Contains the name of the operation: get-console-output | Yes |
<instance-id> | Specifies the ID of the instance for which you want console output | Yes |
The following figure shows a sample adapter request for the Get Console Output operation.
Sample adapter request for the Get Console Output operation
<wsdl-location>http://ec2.amazonaws.com/doc/2009-11-30/</wsdl-location>
<endpoint-address>http://us-east-1.ec2.amazonaws.com/</endpoint-address>
<signature-properties mode = "key-files">
<private-key-file>C:\Security\
pk-MJ5GIUNLM2XJ3VRJSYTKOFDWILELDQHB.PEM</private-key-file>
<certificate-file>C:\Security\
cert-MJ5GIUNLM2XJ3VRJSYTKOFDWILELDQHB.PEM</certificate-file>
</signature-properties>
<operation-name>get-console-output</operation-name>
<parameters>
<instance-id>i-6448440c</instance-id>
</parameters>
</amazon-ec2-request>
The following figure shows the response for the sample adapter request for the Get Console Output operation.
Sample adapter response for the Get Console Output operation
<metadata>
<status>success</status>
</metadata>
<GetConsoleOutputResponse>
<requestId>30d8baba-9ea1-440a-b056-9dfda1561cd5</requestId>
<instanceId>i-6448440c</instanceId>
<timestamp>2010-01-27T08:17:15.000Z</timestamp>
<output>
<![CDATA[<Password>
Vvyx7lZUUVsjNvmaShQ1cH6cwBZYjyq6JK1hZS8krWrwL
j/HftPfDs/+bNW6VIvuFUg2o9KsctsKbe2ZymjSKuc6+AYAN2x2ZCtzAsz
kwUz3Ppj23udoh5gwg7UtG34nbjRX0VUXJdj2OSnYg4q+pRH7SLH481n08
IU9ipad26yHTa8npaYv0PhheIEmqyHHTYoY7f91NcdM+EnerG+c8JnWVWiX
yn98Xlvo4q8SNXRHbFsGevCHgtQHGNdy1TIZyhG7Qxgj7D6bqB89aX
PuJFvqMswsrpb3mxJ1ESoN37YeJO8xGz6t4oVh8X2I7nG2uBFEDMOt
460sKUfm7YKgRA==
</Password>
<RDPCERTIFICATE>
<DN>CN=I-6448440c, OU=EC2, O=Amazon.com
</DN><THUMBPRINT>A5F95577C2B87DA858644773D3
43961349D3B18F</THUMBPRINT>
</RDPCERTIFICATE>
½7/2010 12:16:58 AM: Message: Ec2Config Service is
rebooting the instance. Please be patient.
]]>
</output>
</GetConsoleOutputResponse>
</amazon-ec2-response>