Yandex Cloud
  • Services
  • Solutions
  • Why Yandex Cloud
  • Pricing
  • Documentation
  • Contact us
Get started
Language / Region
© 2022 Yandex.Cloud LLC
Yandex Virtual Private Cloud
  • Getting started
  • Step-by-step instructions
    • All instructions
    • Cloud network
      • Creating a cloud network
      • Deleting a cloud network
      • Updating a cloud network
    • Subnet
      • Creating a subnet
      • Deleting a subnet
      • Updating a subnet
      • Viewing a list of used addresses
    • IP address
      • Reserving a static public IP address
      • Making a dynamic public IP address static
      • Making a static public IP address dynamic
      • Deleting a static public IP address
    • Static routing
      • Creating a static route
      • Enabling NAT to the internet
    • Security groups
      • Create a security group
      • Update a security group and rules
      • Delete a security group
    • Enable a software-accelerated network
    • Protection from DDoS attacks
      • Enable protection from DDoS attacks
  • Practical guidelines
    • Architecture and protection of a basic internet service
    • DHCP settings for working with a corporate DNS server
  • Concepts
    • Relationship between service resources
    • Cloud networks and subnets
    • Cloud resource addresses
    • Static routes
    • Security groups
    • Public IP address ranges
    • MTU and MSS
    • DHCP settings
    • Software-accelerated network
    • Quotas and limits
  • DDoS Protection
  • Recommendations
    • Using public IP addresses
  • Access management
  • Pricing policy
    • Current pricing policy
    • Archive
      • Before January 1, 2019
  • API reference
    • Authentication in the API
    • REST
      • Overview
      • Address
        • Overview
        • create
        • delete
        • get
        • getByValue
        • list
        • listOperations
        • move
        • update
      • Gateway
        • Overview
        • create
        • delete
        • get
        • list
        • listOperations
        • move
        • update
      • Network
        • Overview
        • create
        • delete
        • get
        • list
        • listOperations
        • listRouteTables
        • listSecurityGroups
        • listSubnets
        • move
        • update
      • RouteTable
        • Overview
        • create
        • delete
        • get
        • list
        • listOperations
        • move
        • update
      • SecurityGroup
        • Overview
        • create
        • delete
        • get
        • list
        • listOperations
        • move
        • update
        • updateRule
        • updateRules
      • Subnet
        • Overview
        • addCidrBlocks
        • create
        • delete
        • get
        • list
        • listOperations
        • move
        • removeCidrBlocks
        • update
      • Operation
        • Overview
        • get
    • gRPC
      • Overview
      • AddressService
      • GatewayService
      • NetworkService
      • RouteTableService
      • SecurityGroupService
      • SubnetService
      • OperationService
  • Questions and answers
  1. Step-by-step instructions
  2. IP address
  3. Making a dynamic public IP address static

Making a dynamic public IP address static

Written by
Yandex Cloud

    You can make a dynamic public IP address static. Static public IP addresses are reserved and remain attached to respective resources when VMs and network load balancers are stopped.

    Note

    Pay attention to the pricing policy for inactive static public IPs.

    Management console
    CLI

    To change a public IP address from dynamic to static:

    1. In the management console, select the folder containing the appropriate address.
    2. In the list of services, select Virtual Private Cloud.
    3. On the left-hand panel, select IP addresses.
    4. Click in the row of the address that you want to make static.
    5. In the menu that opens, select Make static.
    6. In the window that opens, click Change.

    If you don't have the Yandex Cloud command line interface yet, install and initialize it.

    The folder specified in the CLI profile is used by default. You can specify a different folder using the --folder-name or --folder-id parameter.

    To change a public IP address from dynamic to static:

    1. See the description of the CLI's update address attribute command:

      yc vpc address update --help
      
    2. Get a list of addresses in the default folder:

      yc vpc address list
      

      Result:

      +----------------------+------+---------------+----------+------+
      |          ID          | NAME |    ADDRESS    | RESERVED | USED |
      +----------------------+------+---------------+----------+------+
      | e2l46k8conff8n6ru1jl |      | 84.201.177.41 | false    | true |
      +----------------------+------+---------------+----------+------+
      

      The false value of the RESERVED parameter of the IP address with the ID e2l46k8conff8n6ru1jl shows that this address is dynamic.

    3. Make the address static by using the --reserved=true key and address ID:

      yc vpc address update --reserved=true e2l46k8conff8n6ru1jl
      

      Result:

      id: e2l46k8conff8n6ru1jl
      folder_id: b1g7gvsi89m34pipa3ke
      created_at: "2021-01-14T09:36:46Z"
      external_ipv4_address:
        address: 84.201.177.41
        zone_id: ru-central1-a
        requirements: {}
      reserved: true
      used: true
      

      The reserved parameter value changed to true and the IP address is now static.

    Was the article helpful?

    Language / Region
    © 2022 Yandex.Cloud LLC