Tüm Ürünler
Search
Belge Merkezi

:ModifyInstanceSpec

Son Güncelleme:Oct 02, 2026

Kullandıkça öde ECS örneğinin örnek türünü veya genel bant genişliğini değiştirir.

Operation description

Bu işlemi kullanmadan önce, ECS'nin faturalandırma yöntemlerini ve fiyatlandırmasını tam olarak anladığınızdan emin olun.

Kullandıkça öde bir örneğin örnek türünü değiştirmeden önce, mevcut örneğin hangi örnek türlerine değiştirilebileceğini sorgulamak için DescribeResourcesModification işlemini çağırabilirsiniz.

Dikkat Edilmesi Gerekenler

  • Hesabınızda vadesi geçmiş ödeme bulunmamalıdır.

  • Her çağrı yalnızca bir yapılandırmayı değiştirebilir. Tek bir istekte yalnızca örnek türünü değiştirebilir veya yalnızca genel bant genişliğini ayarlayabilirsiniz.

  • Genel bant genişliğini ayarlayabilmeniz için örnek durumunun Çalışıyor (Running) veya Durduruldu (Stopped) olması gerekir. Değişiklik hemen yürürlüğe girer.

  • Örnek türünü değiştirebilmeniz için örnek durumunun Durduruldu (Stopped) olması gerekir. Değişiklikten sonra, değişikliğin yürürlüğe girmesi için örneği başlatmanız gerekir.

Not

Bant genişliğine göre ödeme temelinde faturalandırılan toplam maksimum genel bant genişliği, tek bir bölge ve tek bir Alibaba Cloud hesabı için sınırlara tabidir. Daha fazla bilgi için bkz. Genel bant genişliği sınırları.

Try it now

Try this API in OpenAPI Explorer, no manual signing needed. Successful calls auto-generate SDK code matching your parameters. Download it with built-in credential security for local usage.

Test

RAM authorization

The table below describes the authorization required to call this API. You can define it in a Resource Access Management (RAM) policy. The table's columns are detailed below:

  • Action: The actions can be used in the Action element of RAM permission policy statements to grant permissions to perform the operation.

  • API: The API that you can call to perform the action.

  • Access level: The predefined level of access granted for each API. Valid values: create, list, get, update, and delete.

  • Resource type: The type of the resource that supports authorization to perform the action. It indicates if the action supports resource-level permission. The specified resource must be compatible with the action. Otherwise, the policy will be ineffective.

    • For APIs with resource-level permissions, required resource types are marked with an asterisk (*). Specify the corresponding Alibaba Cloud Resource Name (ARN) in the Resource element of the policy.

    • For APIs without resource-level permissions, it is shown as All Resources. Use an asterisk (*) in the Resource element of the policy.

  • Condition key: The condition keys defined by the service. The key allows for granular control, applying to either actions alone or actions associated with specific resources. In addition to service-specific condition keys, Alibaba Cloud provides a set of common condition keys applicable across all RAM-supported services.

  • Dependent action: The dependent actions required to run the action. To complete the action, the RAM user or the RAM role must have the permissions to perform all dependent actions.

Action

Access level

Resource type

Condition key

Dependent action

ecs:ModifyInstanceSpec

update

*Instance

acs:ecs:{#regionId}:{#accountId}:instance/{#instanceId}

  • ecs:AssociatePublicIpAddress
None

Request parameters

Parameter

Type

Required

Description

Example

InstanceId

string

Yes

Örnek kimliği.

i-bp67acfmxazb4p****

InstanceType

string

No

Hedef örnek türü. Daha fazla bilgi için bkz. Örnek ailesi. En güncel örnek türü listesini sorgulamak için DescribeInstanceTypes işlemini de çağırabilirsiniz.

ecs.g6.large

InternetMaxBandwidthOut

integer

No

Maksimum giden genel bant genişliği. Birim: Mbit/s. Geçerli değerler: 0 ile 100 arası.

Not

Trafiğe göre ödeme modunda, maksimum gelen ve giden bant genişlikleri bant genişliği üst sınırları olarak kullanılır ve garanti edilmez. Kaynak çekişmesi meydana geldiğinde, maksimum bant genişlikleri sınırlandırılabilir. İşletmeniz garanti edilen bant genişliği gerektiriyorsa, bant genişliğine göre ödeme modunu kullanın.

10

InternetMaxBandwidthIn

integer

No

Maksimum gelen genel bant genişliği. Birim: Mbit/s. Geçerli değerler:

  • Satın alınan giden genel bant genişliği 10 Mbit/s'den küçük veya buna eşitse: 1 ile 10 arası. Varsayılan değer: 10.

  • Satın alınan giden genel bant genişliği 10 Mbit/s'den büyükse: 1 ile InternetMaxBandwidthOut değeri arası. Varsayılan değer: InternetMaxBandwidthOut değeri.

Not

Trafiğe göre ödeme modunda, maksimum gelen ve giden bant genişlikleri bant genişliği üst sınırları olarak kullanılır ve garanti edilmez. Kaynak çekişmesi meydana geldiğinde, maksimum bant genişlikleri sınırlandırılabilir. İşletmeniz garanti edilen bant genişliği gerektiriyorsa, bant genişliğine göre ödeme modunu kullanın.

10

Temporary.StartTime

string

No

Not

Bu parametre davetiye tabanlı ön izlemededir ve herkese açık değildir.

null

Temporary.EndTime

string

No

Not

Bu parametre davetiye tabanlı ön izlemededir ve herkese açık değildir.

null

Temporary.InternetMaxBandwidthOut

integer

No

Not

Bu parametre davetiye tabanlı ön izlemededir ve herkese açık değildir.

null

Async

boolean

No

Eşzamansız bir istek gönderilip gönderilmeyeceğini belirtir. Geçerli değerler:

  • true: İstek eşzamansız olarak gönderilir.

  • false: İstek eşzamansız olarak gönderilmez.

Varsayılan değer: false.

false

AllowMigrateAcrossZone

boolean

No

Kullanılabilirlik bölgeleri arası örnek türü yükseltmesinin desteklenip desteklenmediğini belirtir. Geçerli değerler:

  • true: Desteklenir.

  • false: Desteklenmez.

Varsayılan değer: false.

AllowMigrateAcrossZone parametresini true olarak ayarlar ve yanıta göre Elastic Compute Service örneğini yükseltirseniz aşağıdakilere dikkat edin:

Klasik ağ türü örnekler:

  • Kullanımdan kaldırılmış örnek türleri için, I/O açısından optimize edilmemiş bir örnek I/O açısından optimize edilmiş bir örneğe değiştirildiğinde, örneğin özel IP adresi, disk aygıt adları ve yazılım yetkilendirme kodları değişir. Linux örnekleri için temel diskler (cloud) xvda veya xvdb olarak, ultra diskler (cloud_efficiency) ve standart SSD'ler (cloud_ssd) ise vda veya vdb olarak tanımlanır.

  • Satın alınabilir örnek aileleri için, örneğin özel IP adresi değişir.

VPC türü örnekler: Kullanımdan kaldırılmış örnek türleri için, I/O açısından optimize edilmemiş bir örnek I/O açısından optimize edilmiş bir örneğe değiştirildiğinde, örneğin sunucu disk aygıt adları ve yazılım yetkilendirme kodları değişir. Linux örnekleri için temel diskler (cloud) xvda veya xvdb olarak, ultra diskler (cloud_efficiency) ve standart SSD'ler (cloud_ssd) ise vda veya vdb olarak tanımlanır.

false

SystemDisk.Category

string

No

Sistem diskinin yeni kategorisi. Geçerli değerler:

  • cloud_efficiency: ultra disk

  • cloud_ssd: standart SSD

Not

Bu parametre yalnızca kullanımdan kaldırılmış bir örnek türünden satın alınabilir bir örnek ailesine yükseltme yaptığınızda ve I/O açısından optimize edilmemiş bir örneği I/O açısından optimize edilmiş bir örneğe değiştirdiğinizde geçerlidir.

cloud_ssd

ClientToken

string

No

İsteğin idempotansını sağlamak için kullanılan istemci belirteci. Belirteci oluşturmak için istemciyi kullanabilirsiniz, ancak belirtecin farklı istekler arasında benzersiz olduğundan emin olun. ClientToken değeri yalnızca ASCII karakterleri içerebilir ve uzunluğu 64 karakteri aşamaz. Daha fazla bilgi için bkz. İdempotansın nasıl sağlanacağı.

0c593ea1-3bea-11e9-b96b-88e9fe637760

ModifyMode

string

No

Not

Bu parametre herkese açık değildir.

null

Disk

array<object>

No

Not

Bu parametre herkese açık değildir.

object

No

Not

Bu parametre herkese açık değildir.

DiskId

string

No

Not

Bu parametre herkese açık değildir.

null

Category

string

No

Not

Bu parametre herkese açık değildir.

null

PerformanceLevel

string

No

Not

Bu parametre herkese açık değildir.

null

DryRun

boolean

No

Yalnızca deneme çalıştırması yapılıp yapılmayacağını belirtir. Geçerli değerler:

  • true: Yalnızca deneme çalıştırması yapılır. Örnek türü ve genel bant genişliği değiştirilmez. Sistem gerekli parametrelerin belirtilip belirtilmediğini, istek biçiminin geçerli olup olmadığını, iş kısıtlamalarının karşılanıp karşılanmadığını ve ECS kaynaklarının kullanılabilir olup olmadığını kontrol eder. Kontrol başarısız olursa, ilgili hata döndürülür. Kontrol başarılı olursa, DryRunOperation hata kodu döndürülür.

  • false (varsayılan): Deneme çalıştırması yapılır ve istek gönderilir. Kontrol başarılı olursa, örnek türü ve genel bant genişliği doğrudan değiştirilir.

false

Response elements

Element

Type

Description

Example

object

RequestId

string

İstek kimliği.

473469C7-AA6F-4DC5-B3DB-A3DC0DE3C83E

Examples

Success response

JSON format

{
  "RequestId": "473469C7-AA6F-4DC5-B3DB-A3DC0DE3C83E"
}

Error codes

HTTP status code

Error code

Error message

Description

400 InvalidInternetChargeType.ValueNotSupported The specified InternetChargeType is not valid. The specified InternetChargeType parameter is invalid.
400 InvalidInstanceType.ValueUnauthorized The specified InstanceType does not exist or beyond the permitted range. The specified instance type does not exist or you are not authorized to manage instances of this instance type.
400 InvalidInstanceType.ValueNotSupported The specified InstanceType does not exist or beyond the permitted range. The specified instance type does not exist or you are not authorized to manage instances of this instance type.
400 InvalidParameter The specified parameter "InternetMaxBandwidthOut" is not valid.
400 InvalidParameter.Mismatch Too many parameters in one request. The number of parameters contained in the request exceeds the upper limit.
400 BandwidthUpgradeDenied.EipBoundInstance The specified VPC instance has bound EIP, temporary bandwidth upgrade is denied. The instance is associated with an EIP and cannot have its bandwidth temporarily upgraded.
400 InvalidTemporary.StartTime The specifed Temporary.StartTime is not valid. The specified start time of the temporary upgrade period is invalid.
400 InvalidTemporary.EndTime The specifed Temporary.EndTime is not valid. The specified end time of the temporary upgrade period is invalid.
400 Downgrade.NotSupported Downgrade operation is not supported. Configuration downgrades are not supported.
400 DependencyViolation.InstanceType The current InstanceType cannot be changed to the specified InstanceType. The current instance type cannot be changed to the specified instance type.
400 Account.Arrearage Your account has an outstanding payment. Your account has overdue payments.
400 InvalidParameter.Bandwidth The specified parameter Bandwidth is not valid. The specified bandwidth value is invalid.
400 InvalidParameter.Conflict The specified image does not support the specified instance type. The specified image cannot be used for instances of the specified instance type.
400 InvalidParameter.AllowMigrateAcrossZone The specified parameter CanMigrateAcrossZone is not valid. The specified AllowMigrateAcrossZone parameter is invalid.
400 InvalidParam.SystemDiskCategory The specified param SystemDisk.Category is not valid. The specified system disk category is invalid.
400 Throttling Request was denied due to request throttling, please try again after 5 minutes. The request is throttled.
400 InvalidInstanceStatus.NotStopped The specified Instance status is not stopped. The specified instance is not in the Stopped state.
400 InvalidAction Specified action is not valid. The operation is invalid.
400 IdempotenceParamNotMatch There is a idempotence signature mismatch between this and last request. This request and the previous request contain the same client token but different other parameters.
400 InvalidClientToken.ValueNotSupported The ClientToken provided is invalid. The specified ClientToken parameter is invalid.
400 Price.PricePlanResultNotFound The internetMaxBandwidthIn or internetMaxBandwidthOut provided is invalid. The specified InternetMaxBandwidthIn or InternetMaxBandwidthOut parameter is invalid.
400 InvalidAction.NotSupport The ecs on dedicatedHost not support modify instanceType. Instance types cannot be changed for instances hosted on dedicated hosts.
400 InvalidMarketImageStatus.NotSupported The status of specified market image does not support this operation. The Alibaba Cloud Marketplace image is in a state that does not support the current operation.
400 InvalidOperation.VpcHasEnabledAdvancedNetworkFeature The specified vpc has enabled advanced network feature. Advanced features are enabled for the specified VPC. You cannot create low-specification instances in the VPC.
400 Invalid.PrivatePoolOptions.MatchCriteria Target mode does not support this operation. The operation is not supported while the PrivatePoolOptions.MatchCriteria parameter is set to Target.
400 InstanceTypeNotSupported.TooManyDisksAttached %s
400 InvalidDiskCategory.NotSupported The upgrade operation of instance does not support this category of disk.
400 InvalidParameter.CloudboxNotSupported %s
400 QuotaExceed.DiskCapacity The used capacity of disk type has exceeded the quota in the zone, %s. The capacity of disks that belong to the specified disk category exceeds the quota limit for the zone.
400 InvalidParam.Async The specified parameter async is not valid. The Async parameter is invalid.
400 MissingParameter.DiskCategory The specified parameter Disk.Category can not be null when Disk.DiskId is specified.
400 InvalidParameter.DiskCategory The specified parameter Disk.Category is not valid.
400 InvalidPerformanceLevel.Malformed The specified parameter Disk.n.PerformanceLevel is not valid.
400 NoPermission.Price The operation requires price permission. Please either apply for permission from your main account, or set the parameter AutoPay as true. This operation requires price permission. Please apply for permission to your master account, or set the parameter AutoPay to true for automatic payment.
400 InvalidParameter.DedicatedRegionNotSupported The specified action is rejected because the specified ECS instance in the dedicated region does not support public IP. Parameter error codes not supported in the dedicated region
400 InvalidOperation.OnlineModificationUnsupported Online modification of instance type is not supported for the specified instance due to its CPU topology. The current CPU topology type does not support hot specification changes.
400 QuotaExceeded.InternetBandwidth %s. Under your current account, the public network bandwidth of the Pay-As-You-Go ECS instance charged by fixed bandwidth exceeds the total bandwidth quota limit.
400 InvalidOperation.InstanceTypeNotSupportRss The ECS instance type does not support Rss. The ECS instance type does not support Rss.
400 InvalidInstanceType.NotSupportCpuOptionsNestedVirtualization The specified instance type does not support CpuOptions.NestedVirtualization: %s. The specified instance type does not support CpuOptions.NestedVirtualization value.
401 InvalidInstanceType.ValueUnauthorized The specified InstanceType is not authorized. You are not authorized to use the specified instance type.
500 InternalError The request processing has failed due to some unknown error, exception or failure. An internal error has occurred. Try again later.
403 CategoryViolation The specified instance does not support this operation because of its disk category.
403 InvalidStatus.ValueNotSupported The current status of the resource does not support this operation. The resource is in a state that does not support the current operation.
403 InstanceLockedForSecurity The specified operation is denied as your instance is locked for security reasons. The instance to which the disk is attached is locked due to security reasons.
403 InvalidAccountStatus.NotEnoughBalance Your account does not have enough balance.
403 ChargeTypeViolation The operation is not permitted due to charge type of the instance.
403 OperationDenied The specified instance is out of usage. The resources of the specified instance type are insufficient.
403 LastTokenProcessing The last token request is processing.
403 InvalidInstance.UnpaidOrder The specified instance has unpaid order.
403 InstanceSpecModification.NotEffective The specified instance has been reserved for making a spec modification and not taken effective in the current contract period. The specified instance is retained due to the instance type change. The instance type change cannot take effect during the current contract period.
403 InvalidInstanceType.ValueNotSupported The specified zone does not offer the specified instancetype. The specified instance type is unavailable in the specified region.
403 ImageNotSupportInstanceType The specified image do not support the InstanceType instance. The specified image does not support the instance type.
403 InstanceType.Offline The specified InstanceType has been offline. The specified InstanceType has been offline.
403 InvalidParameter.NotMatch %s A specified parameter is invalid. Check whether parameter conflicts exist.
403 InvalidInstance.EipNotSupport The specified instance with eip is not supported, please unassociate eip first. The operation is not supported while an EIP is associated with the instance. Disassociate the EIP first.
403 InvalidInstance.NatPortMapNotSupport The special instance with nat port map not support operate, please remove nat port map first.
403 InvalidOperation.StarterPackage StarterPackage not support modification.
403 OperationDenied.NoStock The resource is out of usage.
403 OperationDenied.UnpaidOrder The specified instance has unpaid order. Your account has unpaid orders for the specified instance. You can log on to the ECS console to pay for the orders.
403 InvalidOperation.EipNotSupport The special instance with eip not support operate, please unassociate eip first.
403 InvalidParameter.InternetMaxBandwidthOut The specified parameter InternetMaxBandwidthOut is invalid.
403 InvalidOperation.EniCountExceeded %s
403 InvalidOperation.Ipv4CountExceeded %s The operation is valid because the maximum number of IPv4 addresses has been reached.
403 InvalidOperation.Ipv6CountExceeded %s The operation is valid because the maximum number of IPv6 addresses has been reached.
403 InvalidOperation.Ipv6NotSupport %s IPv6 does not support the current operation.
403 InvalidOperation.Ipv4NotSupport %s
403 InvalidOperation.InstanceWithEipNotSupport The special instance with eip not support operate, please unassociate eip first. The operation is not supported while an EIP is associated with the instance. Disassociate the EIP first.
403 SecurityRisk.3DVerification We have detected a security risk with your default credit or debit card. Please proceed with verification via the link in your email. A security risk has been detected on your default credit or debit card. Verify your identity by using the link in the email.
403 InvalidInstance.NotFoundSystemDisk The specified instance has no system disk.
403 InvalidInstanceType.NotSupportDiskCategory The instanceType of the specified instance does not support this disk category. The instance type does not support the current disk category. Try another instance type. For information about the disk categories supported by instance types, see the instance family documentation.
403 QuotaExceed.ElasticQuota No additional quota is available for the specified ECS instance type. The maximum number of instances of the specified instance type in the region has been reached. Reduce the quantity of instances that you want to purchase or try another region or instance type. Alternatively, you can go to the ECS console or Quota Center to request a quota increase.
403 InvalidResourceType.NotSupported %s The specified resource combination does not exist. Change to another zone or specification.
403 InvalidOperation.NotAllowed The specified vpc %s has enabled senior network feature.
403 InvalidOperation.InstanceTypeNotSupportEniTrunking %s This operation is not supported. For more information, see the actual value returned for the %s placeholder in the error message.
403 InvalidOperation.MaxEniQueueNumberExceeded %s The number of Elastic Network Interface (ENI) queues exceeds the upper limit. For more information, see the actual return result of the %s placeholder in the error message.
403 InvalidOperation.ExceedInstanceTypeQueueNumber %s The maximum number of queues for all ENIs on an instance has been exceeded. For more information, see the return value of the %s placeholder in the error message.
403 InvalidParameter.InvalidEniQueueNumber %s The number of Elastic Network Interface (ENI) queues is incorrect. For more information, see the actual return result of the %s placeholder in the error message.
403 HibernationConfigured.InstanceOperationForbidden The operation is not permitted due to limit of the hibernation configured instance. The operation cannot be performed due to the limitations of instances for which the instance hibernation feature is enabled.
403 InvalidOperation.InstanceTypeNotSupportHighPerformanceTrafficMode %s The instance type of the specified instance does not support the NIC of the RDMA communication mode.
403 InvalidOperation.EniQueuePairNumberOverflow %s
403 InvalidOperation.HighPerformanceEniPerInstanceLimitExceeded %s
403 InvalidOperation.MaxEniQueuePairNumberExceed %s
403 InvalidOperation.MaxModifyOnlineNumberExceeded The specified instance has reached the maximum number of modify online attempts and needs to be rebooted.
403 InvalidOperation.RebootingRequired The specified instance needs to be rebooted.
403 InvalidOperation.OSTypeNotSupported The specified OS type is not supported.
403 InvalidSystemDiskCategory.ValueNotSupported The specified parameter SystemDisk.Category is not valid. The specified SystemDisk.Category value is not supported.
403 InvalidDataDiskCategory.ValueNotSupported The specified Category of Data Disk is not valid. The specified data disk type is not supported.
403 InvalidDiskCategory.NotSupported The upgrade operation of instance does not support this category of disk. The specified disk category is not supported by the instance type.
403 InvalidOperation.InstanceTypeSecureBootUnsupported The instance type does not support secure boot. The instance type does not support secure boot.
404 InvalidInstanceId.NotFound The specified InstanceId does not exist. The specified instanceId is invalid.
404 MissingTemporary.StartTime Temporary.StartTime is not specified. The start time of the temporary upgrade period must be specified.
404 MissingTemporary.EndTime Temporary.EndTime is not specified. The end time of the temporary upgrade period must be specified.
404 InvalidInstanceChargeType.NotFound The InstanceChargeType does not exist in our records.
503 LimitedOperation.ServiceUnavailable The service is currently unavailable. Please try again later. The service is currently unavailable. Please try again later.

See Error Codes for a complete list.

Release notes

See Release Notes for a complete list.