With VPS (Virtual private server) we get more power and full control for quite equal price in comparing with shared hostings. It started from 5$ per month (e.g. Contabo or Server4You). The main disadvantage from shared hostings is requiring installation and configuration.
It looks complicated but it contains only 3 main steps.
Just choose any liked provider and server type. We recommend to use next providers due to good prices and given power: Contabo (excellent combination of price and German’s quality, and many awards), Server4You (Europe and USA region), OVHCloud, Hostens, CloudWays (Linode is recommended for India region), MakeCloud (Asia and Russia region).
Let’s look at the process in Contabo.
- Go to the VPS page (or VDS or VPS with big HDD storage if needed), select the needed plan and click the ‘Select’ button.
- Next, select the needed set of options. Please, choose Ubuntu 20.* (it’s important) as operating system. Also, set root’s login and password – it will be required in further steps. Then, click ‘Next’.
- Do payment (note that the server installation fee depends on the selected payment period).
- Now, wait for a letter from Contabo about the completion of the installation and server’s IP address. Now you have become the owner of a VPS server!
- Finally, set the new server’s IP address for our site name.
- If previous site is needed to be alive while configuring the new one, real DNS adjusting should be done as the last step (after installing WordPress part). And the new IP should be temporary set by using Awesome Host Manager Chrome Extension by adding mapping of IP to domain name.
After testing is complete, the temporary mapping should be removed and the next step should be done finally.
To save money, we will install popular free aaPanel that it is very powerful and flexible. FastPanel is also free, but it has smaller features. Also, many hosting providers offer paid control panels like powerful cPanel – it can be definitely used too.
- Run any SSH client (Mac, Windows), connect using server’s IP address, and login there using and root’s login and password that were setup while server installation.
- Begin installation process by typing below command and pressing enter:
sudo apt-get update && sudo apt-get install wget && sudo wget http://www.aapanel.com/script/install-ubuntu_6.0_en.sh && sudo bash install-ubuntu_6.0_en.sh
During installation, please, type
yto the question
Do you want to install aaPanel to the /www directory now?(y/n)and type
yesto the question
Do you need to enable the panel SSL? (yes/n).
- After successful installation, information with a panel’s Web-address, login and password for entering the control panel will be displayed, for example:
Congratulations! Installed successfully!
If you cannot access the panel,
release the following port (7800|888|80|443|20|21) in the security group
Time consumed: 2 Minute!
Note. On some hostings (except Contabo), it will be necessary to open the specified ports in the firewall manually.
Then, login to our control panel via provided username and password.
- Setup packages. Choose default set if not sure.
Then wait for installation completion. It can take some time, please, be patient.
Now the window can be closed.
- Turn off ‘putenv’ in PHP’s settings.
- Enable SSL for ‘phpMyAdmin’.
If NGINX is used (it is by default) then setup WordPress rewrites.
- Set site’s SSL.
It can be done by:
It is more complex but it allows to copy large database and files.
It is simpler but there can be problems with copying large data due to PHP often has limits to file size and execution time.
Note. If new site doesn’t work then there will be a need to correct some configuration files and database tables that is out of scope of current manual due to complexity and variability of possible issues.
There will be needed a copy of site’s directory content as
zip file e.g.
files.zip (it should contain files like ‘wp-config.php’ and all other files from WordPress directory). Also, there will be needed a database copy as
sql.gz file e.g.
database.sql.gz. It can be made manually or got from backup.
files.zipfile to our new website path.
Then, extract it.
- Import database
database.sql.gzfile. When importing is finished the window can be closed.
Download and install Duplicator plugin on the source site. Ensure that backup exists in source site or make it.
- Now, just upload (as in manual mode) all created files to our new website path.
- Then in browser run site’s name appended with
https://mysite.com/installer.phpand follow onscreen instructions.
Download and install UpdraftPlus plugin on the source site. Ensure that backup exists in source site or make it.
- Create new WordPress destination installation and install UpdraftPlus plugin there.
- Now, just upload (as in manual mode) all backed up data to our new website path under
- Finally, in destination site admin in ‘Settings -> UpdraftPlus Backups’ run searching new files and restore found backup.
- Upload and extract (as in manual mode) needed ZIP WordPress archive to
- Then delete existing website directory (e.g.
mysite.com) and rename
wordpressdirectory to website directory’s name.
- Then in browser open website name (e.g.
https://mysite.com) and follow onscreen instructions.
More information can be discovered in the original post about Install VPS (Virtual private server) with WordPress and on the main site.