PHP 클래스 Scalr\Service\Aws\Ec2\DataType\InstanceData

Describes a running instance.
부터: 09.01.2013
저자: Vitaliy Demidov ([email protected])
상속: extends Scalr\Service\Aws\Ec2\AbstractEc2DataType
파일 보기 프로젝트 열기: scalr/scalr 1 사용 예제들

공개 프로퍼티들

프로퍼티 타입 설명
$amiLaunchIndex string The AMI launch index, which can be used to find this instance within the launch group.
$architecture string i386 | x86_64
$clientToken string The idempotency token you provided when you launched the instance.
$dnsName string The public DNS name assigned to the instance. This DNS name is contactable from outside the Amazon EC2 network. This element remains empty until the instance enters a running state.
$ebsOptimized boolean This optimization provides dedicated throughput to Amazon EBS and an optimized configuration stack to provide optimal EBS I/O performance. This optimization isn’t available with all instance types. Additional usage charges apply when using an EBS Optimized instance.
$hypervisor string ovm | xen
$imageId string The ID of the AMI used to launch the instance.
$instanceId string The ID of the instance launched.
$instanceLifecycle string spot | blank (no value)
$instanceType string The instance type (for example, m1.small).
$ipAddress string The IP address of the instance
$kernelId string The kernel associated with this instance.
$keyName string The key pair name, if this instance was launched with an associated key pair.
$launchTime DateTime The time the instance was launched.
$platform string The platform of the instance (e.g., Windows).
$privateDnsName string The private DNS name assigned to the instance. This DNS name can only be used inside the Amazon EC2 network. This element remains empty until the instance enters a running state.
$privateIpAddress string The private IP address assigned to the instance.
$ramdiskId string The RAM disk associated with this instance.
$reason string This might be an empty string.
$rootDeviceName string The root device name (e.g., /dev/sda1).
$rootDeviceType string ebs | instance-store
$sourceDestCheck boolean Specifes whether to enable a Network Address Translation (NAT) instance in a VPC to perform NAT. This controls whether source/destination checking is enabled on the instance. A value of true means checking is enabled, and false means checking is disabled. The value must be false for the instance to perform NAT
$spotInstanceRequestId string The ID of the Spot Instance request
$sriovNetSupport string Specifies whether enhanced networking is enabled.
$subnetId string The subnet ID in which the instance is running.
$virtualizationType string The instance's virtualization type
$vpcId string The VPC in which the instance is running.

보호된 프로퍼티들

프로퍼티 타입 설명
$_externalKeys array List of external identifier names.
$_properties array List of the public properties which is managed by magic getter and setters internally.

공개 메소드들

메소드 설명
attachNetworkInterface ( string $networkInterfaceId, integer $deviceIndex ) : string AttachNetworkInterface action
attachVolume ( string $volumeId, string $device ) : AttachmentSetResponseData AttachVolume action
createTags ( Scalr\Service\Aws\Ec2\DataType\ResourceTagSetList | Scalr\Service\Aws\Ec2\DataType\ResourceTagSetData | array $tagList ) : boolean CreateTags action
deleteTags ( Scalr\Service\Aws\Ec2\DataType\ResourceTagSetList | Scalr\Service\Aws\Ec2\DataType\ResourceTagSetData | array $tagList ) : boolean DeleteTags action
describeAttribute ( Scalr\Service\Aws\Ec2\DataType\InstanceAttributeType | string $attribute ) : mixed DescribeInstanceAttribute action
describeStatus ( ) : Scalr\Service\Aws\Ec2\DataType\InstanceStatusData | null DescribeInstanceStatus action
detachVolume ( string $volumeId, string $device = null, boolean $force = null ) : AttachmentSetResponseData DetachVolume action
getConsoleOutput ( ) : GetConsoleOutputResponseData GetConsoleOutput action
getPasswordData ( ) : GetPasswordDataResponseData GetPasswordData action
modifyAttribute ( Scalr\Service\Aws\Ec2\DataType\InstanceAttributeType | string $attribute, mixed $value ) : boolean ModifyInstanceAttribute action
monitor ( ) : Scalr\Service\Aws\Ec2\DataType\MonitorInstancesResponseSetList MonitorInstances action
reboot ( ) : boolean RebootInstances action
refresh ( ) : InstanceData DescribeInstances action
start ( ) : Scalr\Service\Aws\Ec2\DataType\InstanceStateChangeList StartInstances action
stop ( boolean $force = null ) : Scalr\Service\Aws\Ec2\DataType\InstanceStateChangeList StopInstances action
terminate ( ) : Scalr\Service\Aws\Ec2\DataType\InstanceStateChangeList TerminateInstances
unmonitor ( ) : Scalr\Service\Aws\Ec2\DataType\MonitorInstancesResponseSetList UnmonitorInstances action

보호된 메소드들

메소드 설명
throwExceptionIfNotInitialized ( )

메소드 상세

attachNetworkInterface() 공개 메소드

Attaches a network interface to an instance.
public attachNetworkInterface ( string $networkInterfaceId, integer $deviceIndex ) : string
$networkInterfaceId string The ID of the network interface
$deviceIndex integer The index of the device for the network interface attachment.
리턴 string Returns Attachment ID on success or throws an exception

attachVolume() 공개 메소드

Attaches an Amazon EBS volume to a running instance and exposes it to the instance with the specified device name. For a list of supported device names, see Attaching the Volume to an Instance. Any device names that aren't reserved for instance store volumes can be used for Amazon EBS volumes. Note! If a volume has an AWS Marketplace product code: -The volume can only be attached to the root device of a stopped instance. -You must be subscribed to the AWS Marketplace code that is on the volume. -The configuration (instance type, operating system) of the instance must support that specific AWS Marketplace code. For example, you cannot take a volume from a Windows instance and attach it to a Linux instance. -AWS Marketplace product codes are copied from the volume to the instance.
public attachVolume ( string $volumeId, string $device ) : AttachmentSetResponseData
$volumeId string The ID of the Amazon EBS volume. The volume and instance must be within the same Availability Zone
$device string The device name as exposed to the instance
리턴 AttachmentSetResponseData Returns AttachmentSetResponseData on success

createTags() 공개 메소드

Adds or overwrites one or more tags for the specified EC2 resource or resources. Each resource can have a maximum of 10 tags. Each tag consists of a key and optional value. Tag keys must be unique per resource.
public createTags ( Scalr\Service\Aws\Ec2\DataType\ResourceTagSetList | Scalr\Service\Aws\Ec2\DataType\ResourceTagSetData | array $tagList ) : boolean
$tagList Scalr\Service\Aws\Ec2\DataType\ResourceTagSetList | Scalr\Service\Aws\Ec2\DataType\ResourceTagSetData | array The key/value pair list of the Tags.
리턴 boolean Returns true on success or throws an exception otherwise

deleteTags() 공개 메소드

Deletes a specific set of tags from a specific set of resources. This call is designed to follow a DescribeTags call. You first determine what tags a resource has, and then you call DeleteTags with the resource ID and the specific tags you want to delete.
public deleteTags ( Scalr\Service\Aws\Ec2\DataType\ResourceTagSetList | Scalr\Service\Aws\Ec2\DataType\ResourceTagSetData | array $tagList ) : boolean
$tagList Scalr\Service\Aws\Ec2\DataType\ResourceTagSetList | Scalr\Service\Aws\Ec2\DataType\ResourceTagSetData | array The key/value pair list of the Tags.
리턴 boolean Returns true on success or throws an exception otherwise

describeAttribute() 공개 메소드

Describes an attribute of the specified instance
public describeAttribute ( Scalr\Service\Aws\Ec2\DataType\InstanceAttributeType | string $attribute ) : mixed
$attribute Scalr\Service\Aws\Ec2\DataType\InstanceAttributeType | string The attribute.
리턴 mixed Returns attribute value. It may be scalar value or object depends on attribute.

describeStatus() 공개 메소드

DescribeInstanceStatus action
public describeStatus ( ) : Scalr\Service\Aws\Ec2\DataType\InstanceStatusData | null
리턴 Scalr\Service\Aws\Ec2\DataType\InstanceStatusData | null Returns InstanceStatusData object or NULL

detachVolume() 공개 메소드

Detaches an Amazon EBS volume from an instance. Make sure to unmount any file systems on the device within your operating system before detaching the volume. Failure to do so will result in volume being stuck in "busy" state while detaching. Note! If an Amazon EBS volume is the root device of an instance, it cannot be detached while the instance is in the "running" state. To detach the root volume, stop the instance first. If the root volume is detached from an instance with an AWS Marketplace product code, then the AWS Marketplace product codes from that volume are no longer associated with the instance.
public detachVolume ( string $volumeId, string $device = null, boolean $force = null ) : AttachmentSetResponseData
$volumeId string The ID of the EBS volume.
$device string optional The device name.
$force boolean optional Forces detachment if the previous detachment attempt did not occur cleanly (logging into an instance, unmounting the volume, and detaching normally). This option can lead to data loss or a corrupted file system. Use this option only as a last resort to detach a volume from a failed instance. The instance won't have an opportunity to flush file system caches or file system metadata. If you use this option, you must perform file system check and repair procedures.
리턴 AttachmentSetResponseData Returns AttachmentSetResponseData on success

getConsoleOutput() 공개 메소드

Retrieves console output for the specified instance. Instance console output is buffered and posted shortly after instance boot, reboot, and termination. Amazon EC2 preserves the most recent 64 KB output which will be available for at least one hour after the most recent post.
public getConsoleOutput ( ) : GetConsoleOutputResponseData
리턴 GetConsoleOutputResponseData Returns object which represents console output.

getPasswordData() 공개 메소드

Retrieves the encrypted administrator password for an instance running Windows. Note! The Windows password is only generated the first time an AMI is launched. It is not generated for rebundled AMIs or after the password is changed on an instance. The password is encrypted using the key pair that you provided.
public getPasswordData ( ) : GetPasswordDataResponseData
리턴 GetPasswordDataResponseData Returns object which represents console output.

modifyAttribute() 공개 메소드

Modifies the specified attribute of the specified instance. You can specify only one attribute at a time. To modify some attributes, the instance must be stopped.
public modifyAttribute ( Scalr\Service\Aws\Ec2\DataType\InstanceAttributeType | string $attribute, mixed $value ) : boolean
$attribute Scalr\Service\Aws\Ec2\DataType\InstanceAttributeType | string The attribute name.
$value mixed The attribute value can be string, boolean, array or object depends on attribute name.
리턴 boolean Returns TRUE on success

monitor() 공개 메소드

Enables monitoring for a running instance.
public monitor ( ) : Scalr\Service\Aws\Ec2\DataType\MonitorInstancesResponseSetList
리턴 Scalr\Service\Aws\Ec2\DataType\MonitorInstancesResponseSetList Returns the MonitorInstancesResponseSetList

reboot() 공개 메소드

Requests a reboot of one or more instances. This operation is asynchronous; it only queues a request to reboot the specified instance(s). The operation will succeed if the instances are valid and belong to you. Requests to reboot terminated instances are ignored. Note! If a Linux/UNIX instance does not cleanly shut down within four minutes, Amazon EC2 will perform a hard reboot.
public reboot ( ) : boolean
리턴 boolean Returns true on success or throws an exception otherwise

refresh() 공개 메소드

This action will refresh current InstanceData object with retrieved information from AWS. Describes one or more of your instances. If you specify one or more instance IDs, Amazon EC2 returns information for those instances. If you do not specify instance IDs, Amazon EC2 returns information for all relevant instances. If you specify an invalid instance ID, an error is returned. If you specify an instance that you do not own, it is not included in the returned results. Recently terminated instances might appear in the returned results. This interval is usually less than one hour. NOTE! It refreshes object itself only when EntityManager is enabled. Decision is to use $object = object->refresh() instead;
public refresh ( ) : InstanceData
리턴 InstanceData

start() 공개 메소드

Starts an Amazon EBS-backed AMI that you've previously stopped. Instances that use Amazon EBS volumes as their root devices can be quickly stopped and started. When an instance is stopped, the compute resources are released and you are not billed for hourly instance usage. However, your root partition Amazon EBS volume remains, continues to persist your data, and you are charged for Amazon EBS volume usage. You can restart your instance at any time. Each time you transition an instance from stopped to started, we charge a full instance hour, even if transitions happen multiple times within a single hour. Note! Before stopping an instance, make sure it is in a state from which it can be restarted. Stopping an instance does not preserve data stored in RAM. Performing this operation on an instance that uses an instance store as its root device returns an error.
public start ( ) : Scalr\Service\Aws\Ec2\DataType\InstanceStateChangeList
리턴 Scalr\Service\Aws\Ec2\DataType\InstanceStateChangeList Return the InstanceStateChangeList

stop() 공개 메소드

Stops an Amazon EBS-backed instance. Each time you transition an instance from stopped to started, we charge a full instance hour, even if transitions happen multiple times within a single hour. Important! Although Spot Instances can use Amazon EBS-backed AMIs, they don't support Stop/Start. In other words, you can't stop and start Spot Instances launched from an AMI with an Amazon EBS root device. Instances that use Amazon EBS volumes as their root devices can be quickly stopped and started.When an instance is stopped, the compute resources are released and you are not billed for hourly instance usage. However, your root partition Amazon EBS volume remains, continues to persist your data, and you are charged for Amazon EBS volume usage.You can restart your instance at any time. Note! Before stopping an instance, make sure it is in a state from which it can be restarted. Stopping an instance does not preserve data stored in RAM. Performing this operation on an instance that uses an instance store as its root device returns an error. You can stop, start, and terminate EBS-backed instances.You can only terminate S3-backed instances. What happens to an instance differs if you stop it or terminate it. For example, when you stop an instance, the root device and any other devices attached to the instance persist. When you terminate an instance, the root device and any other devices attached during the instance launch are automatically deleted
public stop ( boolean $force = null ) : Scalr\Service\Aws\Ec2\DataType\InstanceStateChangeList
$force boolean optional Forces the instance to stop. The instance will not have an opportunity to flush file system caches or file system metadata. If you use this option, you must perform file system check and repair procedures. This option is not recommended for Windows instances.
리턴 Scalr\Service\Aws\Ec2\DataType\InstanceStateChangeList Return the InstanceStateChangeList

terminate() 공개 메소드

Shuts down one or more instances. This operation is idempotent; if you terminate an instance more than once, each call will succeed. Terminated instances will remain visible after termination (approximately one hour). Note! By default, Amazon EC2 deletes all Amazon EBS volumes that were attached when the instance launched. Amazon EBS volumes attached after instance launch continue running. You can stop, start, and terminate EBS-backed instances.You can only terminate S3-backed instances. What happens to an instance differs if you stop it or terminate it. For example, when you stop an instance, the root device and any other devices attached to the instance persist. When you terminate an instance, the root device and any other devices attached during the instance launch are automatically deleted.
public terminate ( ) : Scalr\Service\Aws\Ec2\DataType\InstanceStateChangeList
리턴 Scalr\Service\Aws\Ec2\DataType\InstanceStateChangeList Returns the InstanceStateChangeList

throwExceptionIfNotInitialized() 보호된 메소드

unmonitor() 공개 메소드

Disables monitoring for a running instance.
public unmonitor ( ) : Scalr\Service\Aws\Ec2\DataType\MonitorInstancesResponseSetList
리턴 Scalr\Service\Aws\Ec2\DataType\MonitorInstancesResponseSetList Returns the MonitorInstancesResponseSetList

프로퍼티 상세

$_externalKeys 보호되어 있는 프로퍼티

List of external identifier names.
protected array $_externalKeys
리턴 array

$_properties 보호되어 있는 프로퍼티

List of the public properties which is managed by magic getter and setters internally.
protected array $_properties
리턴 array

$amiLaunchIndex 공개적으로 프로퍼티

The AMI launch index, which can be used to find this instance within the launch group.
public string $amiLaunchIndex
리턴 string

$architecture 공개적으로 프로퍼티

i386 | x86_64
public string $architecture
리턴 string

$clientToken 공개적으로 프로퍼티

The idempotency token you provided when you launched the instance.
public string $clientToken
리턴 string

$dnsName 공개적으로 프로퍼티

The public DNS name assigned to the instance. This DNS name is contactable from outside the Amazon EC2 network. This element remains empty until the instance enters a running state.
public string $dnsName
리턴 string

$ebsOptimized 공개적으로 프로퍼티

This optimization provides dedicated throughput to Amazon EBS and an optimized configuration stack to provide optimal EBS I/O performance. This optimization isn’t available with all instance types. Additional usage charges apply when using an EBS Optimized instance.
public bool $ebsOptimized
리턴 boolean

$hypervisor 공개적으로 프로퍼티

ovm | xen
public string $hypervisor
리턴 string

$imageId 공개적으로 프로퍼티

The ID of the AMI used to launch the instance.
public string $imageId
리턴 string

$instanceId 공개적으로 프로퍼티

The ID of the instance launched.
public string $instanceId
리턴 string

$instanceLifecycle 공개적으로 프로퍼티

spot | blank (no value)
public string $instanceLifecycle
리턴 string

$instanceType 공개적으로 프로퍼티

The instance type (for example, m1.small).
public string $instanceType
리턴 string

$ipAddress 공개적으로 프로퍼티

The IP address of the instance
public string $ipAddress
리턴 string

$kernelId 공개적으로 프로퍼티

The kernel associated with this instance.
public string $kernelId
리턴 string

$keyName 공개적으로 프로퍼티

The key pair name, if this instance was launched with an associated key pair.
public string $keyName
리턴 string

$launchTime 공개적으로 프로퍼티

The time the instance was launched.
public DateTime $launchTime
리턴 DateTime

$platform 공개적으로 프로퍼티

The platform of the instance (e.g., Windows).
public string $platform
리턴 string

$privateDnsName 공개적으로 프로퍼티

The private DNS name assigned to the instance. This DNS name can only be used inside the Amazon EC2 network. This element remains empty until the instance enters a running state.
public string $privateDnsName
리턴 string

$privateIpAddress 공개적으로 프로퍼티

The private IP address assigned to the instance.
public string $privateIpAddress
리턴 string

$ramdiskId 공개적으로 프로퍼티

The RAM disk associated with this instance.
public string $ramdiskId
리턴 string

$reason 공개적으로 프로퍼티

This might be an empty string.
public string $reason
리턴 string

$rootDeviceName 공개적으로 프로퍼티

The root device name (e.g., /dev/sda1).
public string $rootDeviceName
리턴 string

$rootDeviceType 공개적으로 프로퍼티

ebs | instance-store
public string $rootDeviceType
리턴 string

$sourceDestCheck 공개적으로 프로퍼티

Specifes whether to enable a Network Address Translation (NAT) instance in a VPC to perform NAT. This controls whether source/destination checking is enabled on the instance. A value of true means checking is enabled, and false means checking is disabled. The value must be false for the instance to perform NAT
public bool $sourceDestCheck
리턴 boolean

$spotInstanceRequestId 공개적으로 프로퍼티

The ID of the Spot Instance request
public string $spotInstanceRequestId
리턴 string

$sriovNetSupport 공개적으로 프로퍼티

Specifies whether enhanced networking is enabled.
public string $sriovNetSupport
리턴 string

$subnetId 공개적으로 프로퍼티

The subnet ID in which the instance is running.
public string $subnetId
리턴 string

$virtualizationType 공개적으로 프로퍼티

The instance's virtualization type
public string $virtualizationType
리턴 string

$vpcId 공개적으로 프로퍼티

The VPC in which the instance is running.
public string $vpcId
리턴 string