You can modify an attribute of a stopped instance, like its type, user data, or termination behavior.

This feature is not available from Cockpit. This documentation only describes the procedure using AWS CLI.

Before you begin: Stop the instance you want to modify. For more information, see Stopping and Starting Instances.


  • To modify an instance attribute, use the modify-instance-attribute command following this syntax:


    You can modify only one instance attribute at a time.

    Request sample
    $> aws ec2 modify-instance-attribute \
    	--profile YOUR_PROFILE \
    	--instance-id i-12345678 \
    	--attribute ATTRIBUTE_NAME \
    	--value ATTRIBUTE_VALUE \
    	--block-device-mappings VALUE \
    	--disable-api-termination \
    	--instance-type m1.large \
    	--user-data VALUE \
    	--instance-initiated-shutdown-behavior stop \
    	--groups sg-12345678 \
    	--source-dest-check \
    	[--ebs-optimized NOT_SPECIFIED] \

    This command contains the following attributes that you need to specify:

    • (optional) profile: The named profile you want to use, created when configuring AWS CLI. For more information, see Using AWS CLI in the Outscale Cloud.
    • instance-id: The ID of the instance whose attribute you want to modify. 
    • (optional) attribute: The name of the attribute (userData | rootDeviceName | instanceType | groupSet | ebsOptimized | sourceDestCheck |  deleteOnTermination  | disableApiTermination | instanceInitiatedShutdownBehavior).
    • (optional) value: The value of the attribute (only for the following attributes: userDatadisableApiTermination, or instanceInitiatedShutdownBehavior).
    • (optional) disable-api-termination: If set to true, prevents instance termination (by default, set to false). 
    • (optional) block-device-mappings: Information about BSU volumes attached to the instance. This attribute contains the following elements that you need to specify: 

    • (optional) Ebs: Information about the volume attached to the instance. This element contains the following element that you need to specify: 
      • (optional) DeleteOnTermination: By default or if set to true, the volume is deleted when the instance is terminated. If set to false, it is not. 


      To modify the block-device-mappings attribute for several volumes at the same time, use the following syntax:

      [{"DeviceName" :"/dev/sda1", "Ebs":{ "DeleteOnTermination" : False} }, {"DeviceName":"/dev/sdb","Ebs":{}} ]
    • (optional) instance-type: The type of instance (amount of vCores, memory, storage). For more information, see Instance Types
    • (optional) user-data: New user data for the instance. For more information, see Configuring an Instance with User Data and Outscale Tags.


      Existing user data is erased and replaced by the one you specify here.

    • (optional) groups: One or more security groups IDs for the instance. 
    • (optional) source-dest-check|no-source-dest-check: If set to  source-dest-check, the source-destination check is enabled. If set to no-source-dest-check, it is disabled. This attribute must be disabled for a NAT instance to perform NAT. For more information, see Tutorial: Setting Up a NAT Instance.

    • (optional) ebs-optimizedWhether the instance is BSU-optimized. Aways set to true, as Outscale instances are all BSU-optimized. For more information, see Instance Types.
    • endpoint: The endpoint corresponding to the Region you want to send the request to.

The specified attribute is modified.


Windows® is a registered mark of Microsoft Corporation in the United States and/or other countries.

AWS™ and Amazon Web Services™ are trademarks of Amazon Technologies, Inc or its affiliates in the United States and/or other countries.

See Legal Mentions.