How to change the server IP?

Hi to all,
After a long trials and errors. Searching the forum here and on VestaCP. I come to understand that i need help with this.
My system is Debian 10 and
I have setup one ip with nat (external).
For the example:
Current interface file have
Ip: 172.16.0.100
Subnet: 255.255.255.0
Gw: 172.26.0.254

How can change my current network settings to deferent one 192.168.0.100 and so on …?

When i add new ip it doesn’t ask for gateway, dns so I’m confused.

Any help would be good.

I think there is a CLI command for that… v-add-sys-ip or similar

First v-update-sys-ip

Only then nginx will not start due to a bug it but you can just rebuild all mail domains via

v-rebuild-mail-domains user

Yes you’re right. But as I said you don’t have gw to setup.

So this is the one that telling the panel or the server to switch the ip? Again no GW in that command.
What are the stages exactly needed in order to get this done?

v-update-sys-ip requires no input how ever it does reload webmail configs due to a bug it will be fixed in the next release or apply this patch

Thanks @eris As I see it there is no way to change network from the panel.

So my conclusion is to do it manually.

Can you clarify those are the right steps?

  1. v-add-sys-ip (new)
  2. Change all users web and dns to the new ip
  3. v-delete-sys-ip (old)
  4. Change the gateway on the interfaces file
  5. v-update-sys-ip
  6. v-rebuild-mail-domains
  7. Reboot the server and pray …
  1. v-update-sys-ip
  2. v-rebuild-mail-domains of al users …

And it should be enough

Got it now … Thanks!

This topic was automatically closed 30 days after the last reply. New replies are no longer allowed.