Documentation

esc
    Networking / Dynamic IPs

    Dynamic IPs

    Give a standard VPS an outbound public IPv4 address that changes on a schedule without downtime or dropping open connections.

    What a dynamic IP is

    A Dynamic IP gives a standard VPS an outbound public IPv4 address that changes automatically on a schedule, without restarting the VM or interrupting running workloads.

    • Outbound traffic leaves from the VM's current dynamic public IPv4 address.
    • Inbound traffic (such as SSH or any open service ports) still reaches the VM on its static public IPv4 address.
    • Open connections can finish cleanly on the previous address while new connections switch immediately to the new one.

    Dynamic IPs are designed for outbound-heavy workloads, such as web scraping, data collection, privacy-sensitive egress, and avoiding IP-based rate limits, that need fresh public IPv4 addresses on a predictable schedule.

    Availability and prerequisites

    To use a Dynamic IP, a VM must meet these requirements:

    • Standard VPS only. Dynamic IPs are supported on standard VPSes (in af-abj-1), not VMs placed inside a VPC subnet.
    • A new VM on Ubuntu 24.04 LTS or Ubuntu 26.04 LTS. Turn Dynamic IP on when you create the VM. The platform sets everything up and starts changing the outbound address on your schedule.
    • A custom security group that allows nothing inbound from the private network. A security group applies to every network interface on a standard VPS. Any inbound rule whose source overlaps the zone's private_network_cidr (shown in GET /regions and pantech regions) is refused, ICMP included.

    Schedules and open connections

    Every Dynamic IP configuration has two core settings:

    • schedule: how often the outbound IPv4 address changes:
      • every_12_hours
      • daily
      • weekly
      • monthly
    • connections: how open outbound connections behave when the address changes:
      • keep (default): existing open connections finish on the previous IPv4 address while new outbound connections use the new address immediately.
      • move: all outbound traffic switches to the new address immediately; existing open connections are reset.

    Rotate now (on_demand)

    Need a fresh address outside your schedule? Rotate now lets you trigger an immediate IP change at any time.

    • Rotate now is enabled per organization by support. Once enabled for your organization, turn it on per VM (on_demand: true).
    • Each VM can trigger up to 10 on-demand changes in any rolling 24 hours. Past that limit, further requests return 429 ADDRESS_ROTATION_LIMIT_REACHED until an earlier slot falls out of the 24-hour window.
    • Rotate now is not offered during VM creation; turn it on after the VM is running.

    Pricing

    Dynamic IP adds a percentage surcharge to the VM's hourly charges while it is turned on:

    SettingHourly surcharge
    monthly+30%
    weekly+40%
    daily+50%
    every_12_hours+60%
    on_demand enabled (any schedule)+95%
    • Follows your plan and state. The surcharge mirrors the VM's own meters, so it adjusts automatically when you resize the VM. A stopped VM pays the surcharge on its storage charge only.
    • Upfront payment at creation. When you turn Dynamic IP on at VM creation, the upfront payment includes the chosen schedule's surcharge.
    • Stopping the surcharge. Turning Dynamic IP off ends the surcharge immediately. Changing schedules applies the new tier's rate from that hour onward.

    Prices exclude VAT, which is added to your end-of-period invoice.

    Turn on when creating a VM

    In the console

    1. Open Create a virtual machine and choose Standard VPS.
    2. Pick Ubuntu 24.04 LTS or Ubuntu 26.04 LTS.
    3. In Network, select or create a custom security group with no inbound rules covering the zone's private_network_cidr.
    4. Turn on Dynamic IP, choose your Schedule (every_12_hours, daily, weekly, or monthly), and choose how to handle Open connections (keep or move).
    5. Review the upfront total (which includes the schedule's surcharge) and create the VM.

    Once the VM is running, its Dynamic IP becomes active and outbound traffic leaves from the first dynamic address.

    With the CLI

    Pass --security-group with a narrowed custom security group and --dynamic-ip with a schedule:

    Terminal
    $ pantech vm create --name scraper-1 --plan starter --image ubuntu-24-04 \    --ssh-key deploy --security-group sg_… --dynamic-ip weekly

    With the API

    Send address_rotation in POST /public/v1/instances together with a custom security_group_id:

    Terminal
    $ curl -X POST https://api.pantechdynamics.com/public/v1/instances \    -H "Authorization: Bearer $PANTECH_API_KEY" \    -H "Idempotency-Key: $(uuidgen)" \    -H "Content-Type: application/json" \    -d '{      "name": "scraper-1",      "plan_slug": "starter",      "image_slug": "ubuntu-24-04",      "ssh_key_id": "sshk_…",      "security_group_id": "sg_…",      "address_rotation": {        "schedule": "weekly",        "connections": "keep"      }    }'

    Follow the order until the VM is provisioned, then poll GET /public/v1/instances/{instance_id}/address-rotation until state is active.

    With Terraform

    Add a dynamic_ip block to pantechdynamics_instance:

    main.tf
    resource "pantechdynamics_instance" "scraper" {
      name              = "scraper-1"
      plan_slug         = "starter"
      image_slug        = "ubuntu-24-04"
      ssh_key_id        = pantechdynamics_ssh_key.deploy.id
      security_group_id = pantechdynamics_security_group.scraper.id
    
      dynamic_ip {
        schedule    = "weekly"
        connections = "keep"
      }
    }

    With the SDKs

    Go
    order, err := client.Instances.Create(ctx, pantech.CreateInstanceRequest{
    	Name:            "scraper-1",
    	PlanSlug:        "starter",
    	ImageSlug:       "ubuntu-24-04",
    	SSHKeyID:        "sshk_…",
    	SecurityGroupID: pantech.Ptr("sg_…"),
    	DynamicIP: &pantech.CreateInstanceDynamicIP{
    		Schedule:    "weekly",
    		Connections: pantech.Ptr("keep"),
    	},
    })

    Manage a VM's Dynamic IP

    Once a VM is running with Dynamic IP on, you can check its current address, change its settings, rotate now, or turn it off.

    In the console

    Open the VM and go to its Networking tab, then use the Dynamic IP card:

    • Change settings: update the schedule, switch between keep and move, or toggle Rotate now (when enabled for your organization).
    • Rotate now: press Rotate now to assign a new outbound IP immediately. The card shows how many of your 10 daily on-demand changes have been used.
    • Turn off: disable Dynamic IP to return outbound traffic to the VM's static IP and stop the surcharge.

    With the CLI

    Terminal
    $ pantech vm dynamic-ip get scraper-1$ pantech vm dynamic-ip set scraper-1 --schedule daily --connections keep$ pantech vm dynamic-ip set scraper-1 --schedule daily --on-demand$ pantech vm dynamic-ip rotate scraper-1$ pantech vm dynamic-ip off scraper-1
    • get shows the current state, active dynamic IPv4 address, schedule, next scheduled change, on-demand usage, and recent history.
    • set updates --schedule, --connections (keep or move), and --on-demand.
    • rotate triggers an immediate on-demand IP change.
    • off turns Dynamic IP off and stops the surcharge.

    With the API

    All Dynamic IP routes live under /public/v1/instances/{instance_id}/address-rotation:

    • GET /public/v1/instances/{instance_id}/address-rotation: read current state, active address, schedule, surcharge rate, on-demand usage, and recent events (newest first). Returns 404 ADDRESS_ROTATION_NOT_FOUND when Dynamic IP is off (or returns the last failed attempt with state: "failed" and failure_reason).
    • PUT /public/v1/instances/{instance_id}/address-rotation: update settings (200 OK). Requires Idempotency-Key.
    • POST /public/v1/instances/{instance_id}/address-rotation/rotate: trigger an immediate IP change (200 OK). Requires on_demand: true and Idempotency-Key.
    • DELETE /public/v1/instances/{instance_id}/address-rotation: turn Dynamic IP off (200 OK, disabling or off). Requires Idempotency-Key.
    Terminal
    # Update Dynamic IP settings$ curl -X PUT https://api.pantechdynamics.com/public/v1/instances/vm_…/address-rotation \    -H "Authorization: Bearer $PANTECH_API_KEY" \    -H "Idempotency-Key: $(uuidgen)" \    -H "Content-Type: application/json" \    -d '{"schedule": "daily", "connections": "keep", "on_demand": true}'# Read current state and recent IP changes$ curl https://api.pantechdynamics.com/public/v1/instances/vm_…/address-rotation \    -H "Authorization: Bearer $PANTECH_API_KEY"# Trigger an immediate change$ curl -X POST https://api.pantechdynamics.com/public/v1/instances/vm_…/address-rotation/rotate \    -H "Authorization: Bearer $PANTECH_API_KEY" \    -H "Idempotency-Key: $(uuidgen)"# Turn off$ curl -X DELETE https://api.pantechdynamics.com/public/v1/instances/vm_…/address-rotation \    -H "Authorization: Bearer $PANTECH_API_KEY" \    -H "Idempotency-Key: $(uuidgen)"

    With Terraform

    Read a VM's live Dynamic IP status with the pantechdynamics_dynamic_ip data source:

    dynamic_ip.tf
    data "pantechdynamics_dynamic_ip" "scraper" {
      instance_id = pantechdynamics_instance.scraper.id
    }
    
    output "scraper_dynamic_ip" {
      value = data.pantechdynamics_dynamic_ip.scraper.current_address
    }

    With the SDKs

    Go
    // Update settings (returns *pantech.DynamicIP)
    rot, err := client.Instances.SetDynamicIP(ctx, "vm_…", pantech.PutDynamicIPRequest{
    	Schedule:    "daily",
    	Connections: pantech.Ptr("keep"),
    	OnDemand:    pantech.Ptr(true),
    })
    
    // Read status and history (*pantech.DynamicIP)
    rot, err = client.Instances.GetDynamicIP(ctx, "vm_…")
    
    // Rotate now (requires on_demand: true; returns *pantech.DynamicIP)
    rot, err = client.Instances.RotateDynamicIP(ctx, "vm_…")
    
    // Turn off (returns *pantech.DynamicIP)
    rot, err = client.Instances.DisableDynamicIP(ctx, "vm_…")

    States and history

    States

    stateWhat it means
    enablingSetting up Dynamic IP on the VM. current_address is null until the first dynamic address is ready
    activeRunning normally. Outbound traffic leaves from current_address, and the next scheduled switch is at next_rotation_at
    degradedTemporarily impaired: either running with reduced redundancy, or falling back to the VM's static IP (current_address is null) while the dynamic address recovers. failure_reason explains what is happening, and the state returns to active automatically once recovered
    disablingTurning Dynamic IP off and returning outbound traffic to the VM's static IP
    offTurned off. Outbound traffic uses the VM's static IP and the surcharge has stopped
    failedCould not finish enabling; failure_reason explains why. Fix the cause and call PUT (or turn it on again in the console/CLI) to retry

    Event history

    The events array lists recent changes, newest first. Each event carries kind, from_address, to_address, degraded, and occurred_at.

    kindWhat happened
    enabledDynamic IP was turned on and the initial address was assigned
    scheduledAutomatic change on the VM's configured schedule
    on_demandManual change triggered via Rotate now
    failoverUnscheduled recovery switch handled automatically by the platform
    handoverPlanned switch during routine platform maintenance
    disabledDynamic IP was turned off

    Troubleshooting

    Every Dynamic IP API error code is listed in Dynamic IP error codes. The most common setup issues:

    • Default security group refused (422 ADDRESS_ROTATION_NEEDS_SECURITY_GROUP). The default security group allows inbound ICMP from 0.0.0.0/0, which overlaps the zone's private_network_cidr. Create a custom security group that excludes private_network_cidr on every inbound rule; see narrowing a security group.
    • This VM can't take Dynamic IP (409). Create a new VM from Ubuntu 24.04 LTS or 26.04 LTS with Dynamic IP turned on.
    • Closed beta or Rotate now not enabled (403 ADDRESS_ROTATION_NOT_ENABLED, 403 ADDRESS_ROTATION_ON_DEMAND_OFF). Contact support to enable Dynamic IPs or Rotate now for your organization.
    • Daily Rotate now limit reached (429 ADDRESS_ROTATION_LIMIT_REACHED). Each VM is limited to 10 on-demand changes per rolling 24 hours. Wait until an earlier change ages past 24 hours, or rely on your scheduled interval.
    • Stuck in degraded. While degraded with current_address: null, the VM keeps internet access by falling back to its static IP while the platform recovers. Check failure_reason, and contact support if it does not return to active.

    Was this page helpful?

    Updated