How to change Floating IP on Droplet?

May 3, 2017 224 views
Load Balancing DigitalOcean Ubuntu 16.04

Ok, DO! How to change Floating IP on Droplet? I already assigned one. But I need to change it to another one.
If I delete the current floating IP on Droplet and reassign it again, then I'm geting the same floating IP. But I need different one.

2 Answers
jtittle1 May 3, 2017
Accepted Answer

@VladimirChanaev

You can reserve any number of IP's, in any number of data centers by clicking that link -- this will allow you to reserve a Floating IP first, then you can go in, remove the existing from the Droplet, replace it with the new Floating IP and finally, remove the old Floating IP from your account.

As of right now, there's not a way to be selective without using the above method and having two IP's for a limited amount of time (until you remove the old one).

DigitalOcean's backend is setup to attempt to give a customer the same IP that they had if they IP has not yet been reassigned in the time it took to reattach it to the account. If you remove the floating IP and attempt to grab another one seconds later, this is most likely what's happening.

The above solution works around that, though it does introduce one more step to the process :-).

@VladimirChanaev

Networking => Floating IP's

You can reserve a Floating IP by clicking the link under "Assign a Floating IP" -- To reserve a floating IP for a specific datacenter, click here.

That'll allow you to reserve a Floating IP in a specific data center but not assign it. You can then assign it to the Droplet of your choosing.

  • Ok, Jtittle. Tnx for default guide. I already have Floating IP and it works great.
    1 Droplet IP: xxx.xxx.xxx.xxx
    1 Floating IP: yyy.yyy.yyy.yyy
    And the question is: «How to change Floating IP yyy.yyy.yyy.yyy to another Floating IP zzz.zzz.zzz.zzz on the same Droplet and same Datacenter».
    In other words - I need to delete Floating IP and get different Floating IP on same Droplet.

    You can test this: assign Floating IP on Droplet, after that delete the Floating IP, and assign it again on same Droplet.
    In my situation I always getting the same Floating IP yyy.yyy.yyy.yyy.

    Is it clear now?

Have another answer? Share your knowledge.