Page 1 of 1

Migrating VESTCP powered droplet in Digital Ocean

Posted: Mon Jul 11, 2016 3:30 pm
by msheeraz
Hi,

I really love VESTACP, have been using it for the past couple of years.

All my droplets in digital ocean are powered by VESTCP in the back end. I take regular snapshots of each droplet everyday.
Due blacklisting of one of my droplet, i had to recreate fresh droplet from a snapshot. Everything went good but after restoration, APACHE and NGINX did not start.

When i checked VESTAP admin panel, i see that the IPs were old ones, so i ran a command, "/usr/local/vesta/bin/v-update-sys-ip" after which i am seeing new IPs in admin panel to be assigned to web applications.

However at this point, APACHE and NGINX did not start.
" * Restarting web server apache2
(99)Cannot assign requested address: AH00072: make_sock: could not bind to address 10.130.211.187:8080
no listening sockets available, shutting down
AH00015: Unable to open logs
Action 'start' failed. "

above is the error is see when i start APACHE from ssh.

can someone help me to fix this problem. I would like to know the steps involved to successfully run all VESTACP services after such IP change. Please HELP.

Thank you in advance.

Re: Migrating VESTCP powered droplet in Digital Ocean

Posted: Mon Jul 11, 2016 7:12 pm
by joem
You need to rebuild each user. Run the following command from ssh repeat for each user,

Code: Select all

v-rebuild-user USERNAME

Re: Migrating VESTCP powered droplet in Digital Ocean

Posted: Mon Jul 11, 2016 9:48 pm
by skamasle
HI

Log in in vestacp, go to IPs -> read new IPs, it get new IPs, change all your website ips for new IPs, then remove old IPs from panel and rebuild dns, web etc-

Re: Migrating VESTCP powered droplet in Digital Ocean

Posted: Tue Jul 12, 2016 4:03 pm
by msheeraz
XoXiLhJ0mn wrote:BTW, someone has offered a script to change from old IP to new Ip and make respective changes everywhere.

Search in the forum to find the script for download and use it for an ease. Otherwise you will have to manually go through IP changes everywhere.

DO you know where i can get this particular script??

Re: Migrating VESTCP powered droplet in Digital Ocean

Posted: Mon Jan 23, 2017 3:48 pm
by kinnth
I've also had this exact problem.

I followed the steps in the posts and went back and added the new IP within the IP tab and then assigned it out but I still get Nginx starting error whenever i try to get it to work.

Could someone explain what is happening when you are adding a new IP and what rebuilding a user actually means? As currently for nginx it's not working. Should i also be rebuilding the specific apache and nginx users? Any way to do this automatically?

Re: Migrating VESTCP powered droplet in Digital Ocean

Posted: Mon Jan 23, 2017 5:01 pm
by tjebbeke
Check if there is IP specific config files in /etc/nginx if there are files with your old IP delete this files.

Re: Migrating VESTCP powered droplet in Digital Ocean

Posted: Tue Jan 24, 2017 10:59 pm
by kinnth
I check the config files in both Vesta and via Nano and I can't see any IP addresses listed directly. I am also not sure exactly which line I am looking for, but when I run the

Code: Select all

sudo nginx -t
I get the following output

Code: Select all

nginx: the configuration file /etc/nginx/nginx.conf syntax is ok
nginx: [emerg] bind() to 10.16.0.5:80 failed (99: Cannot assign requested address)
nginx: configuration file /etc/nginx/nginx.conf test failed
So I have the 10.16.0.5 IP listed under the IPs but assigned to no server as on my previous installation which is still up and running their is no element attributed to it either.

Which config files should I be deleting as if I mv and rename in nginx.conf file I get an error, whereas inside the conf.d folder there are a number of files with listed ips and confs.

Whats really confusing to me is how does Vesta handle IP addresses and if i've removed and reassigned IP addresses inside of the control panel itself, what is stopping both Apache and nginx from using them once the old one has been removed? I've been reading the forums and documentation and I havn't seen an article directly related to moving a snapshot of a server to a new ip address? Any more help would be massive.

Re: Migrating VESTCP powered droplet in Digital Ocean

Posted: Wed Jan 25, 2017 3:44 pm
by mike08
Why didn't you just fix the issues with blacklisted IPs instead of running away and letting this IP to be loaded by another poor customer?