Psychz - Manish
Votes: 0Posted On: Jan 08, 2018 06:56:12
In this article, we will guide you through the various aspects necessary for migrating from a shared hosting provider to a dedicated server.
Sign up and Order
The first step of moving from your shared hosting provider to our dedicated servers is to sign up and order our server in accordance with your preferred location. To sign up to our dedicated servers all you have to do is visit the dedicated server range along with all its services.
https://www.psychz.net/dedicated-hosting.html
It is also recommended to get a quote from us to get pricing as per your specifications.
https://www.psychz.net/dedicated-hosting.html#Quote
Setting Up your Server
Once you have purchased The server with us, the next logical step is to set up the server. Your server situated in our data center will be installed with the operating system of your choice. Once the server is installed with an operating system, the software relevant to your process will be installed on the server like software related to server monitoring and maintenance. You will be able to access the server from a remote location. However, to move your website from your shared hosting provider you will be required to migrate all your data from the shared server you are currently hosted on.
cPanel Installation
By ordering cPanel from us, you will get managed hosting services that include 24/7 reboots, button pushing, screen readouts, external device attachment/movement among others. Please visit the following link to order cPanel.
https://www.psychz.net/managed-hosting.html
You can also install cPanel by yourself. Please follow the guide to install cPanel in Centos7.
1. Please check that the hostname of your server is a FQDN(Fully Qualified Domain Name). The FQDN is used by other systems to identify your machine. It consists of both hostname and domain name. If not, you can set it by the following command.
systemctl set-hostname hostname.domain name
2. For the installation of cPanel, it is necessary to install Perl. You can install Perl by running the following command.
yum install perl
3. The next step is to install the curl command so that the cPanel installer script can be downloaded to the server. The curl command is used to run the auto installer script.
yum install curl
4. The latest installer script of cPanel is downloaded to home directory.
curl -o latest -L https://securedownloads.cpanel.net/latest
5. After the cPanel installer script is downloaded, we just have to run the auto installer script. It would take some time to install cPanel on to your system.
sh latest
Secure Linux server
There are a few steps you should take to secure your dedicated server. Dedicated server security is paramount to protect your server from malicious users, system crashes, DDoS attacks and unauthorized remote access.
Root Login Access
The "root" user has access to all the services and permissions. Through the root login, any system files can be altered. Hence, it is essential to provide the root login only to trusted users. Also, it is recommended to not prove root access for remote access.
Backup
It is recommended to take regular backups of your system. In the event of a system crash, it can be restored to its last stable state. You can also setup automated backups so the system takes the backup automatically after a fixed interval of time.
Strong Passwords
Always keep secure passwords for your server. Along with the "root" user, all other users should have a password for logging in to the server. The password should be a combination of alphabets, numerals and special character.
DNS Update
You can go to your cPanel account and look for DNS Settings.
This field Decides how the domain's nameservers should be configured on the server. If the nameservers specified for this domain name are going to be on another server, choose the option "Use the nameservers specified at the Domain's Registrar".
The first thing you'll need to do is to find out the list of name servers used by your web host.
This information is usually sent by our provisioning team after your order/machine is deployed for use.
The list of name servers will often look like "ns1.example.com", "ns2.example.com", and so on.
Now once you have the information you need to login to your domain registrar account and look for some option to either set your domain's name servers or change them. Basically look for things that say "DNS" or "Name Servers" or "Nameservers", whether to "set" it, "change" it, "manage" it, "modify" it, "edit" it or some other thing to that effect. Now once you find it Put your first name server from your list, usually the name beginning with "ns1", into the "Primary Name Server" field. Then type your second name server, the name beginning with "ns2", into the "Secondary Name Server" field. And so on. A domain name should have at least 2 nameservers associated with it.
DNS record can take between one and three days to fully process and propagate.
If no DNS, how to point the website to server IP address
You should map your domain name to this machines IP address. This can be done by adding an ‘A’ record to your domain. Visit your domain name registrar by logging into the account from where you purchased your domain name.
(Note: Before you do this, you must know that Only make this change once the website hosted on your server is ready.)
Migrating Website
Using cPanel, migrating a website should be a piece of cake. cPanel allows fast compression, download, upload of full site. It creates a compressed backup of website files at the old host, and then upload those files at the new host using the same directory structure.
The compressed file then can be simply expanded onto the new server. This all can be done without any manual moves required within an FTP client or file manager.
How to minimize website downtime?
The most scary part of the migration is downtime. Often customers make mistakes by closing the subscription of previous service before completing the migration and testing process on the new machine. Keep in mind that one should keep the old service live for at least 2-3 days post migration and testing just to ensure that everything is operational like before.
Now, as we already told you that cPanel allows fast compression, download, upload of full site. It creates compressed backup of website files at the old host, and then upload those files at the new host using the same directory structure.
The compressed file then can be simply expanded onto the new server. This all can be done without any manual moves required within an FTP client or file manager.
This reduces a whole lot of effort, error, and downtime.
Stop or disable posting new content on the old data for brief period of time. And hence make sure to inform the clients (if any) or stop any data update on the site before you start migrating. Because altering a DNS record can take between one and three days to fully process and propagate.
Apache Web Server
Once the website is migrated from your old hosting provider, we set up Apache web server on your new dedicated server. Apache Web Server is one of the most popular web servers in the world.
Installation
Please run the following commands to install Apache web server.
sudo apt-get update
sudo apt-get install apache2
The first command will update your repository while the second command installs apache 2.
Firewall setting
You can change the local firewall settings to allow the incoming traffic to interact with Apache. Here are the steps with which you can do so.
1. Check the permissions of your firewall by running the following command.
sudo ufw status
The list will show all the services allowed by your server. Here is a list of some of the services.
Apache - For opening port 80(web traffic)
Apache Full: For opening port 80 as well as port 443 (TLS/SSL encrypted traffic)
Apache Secure: For opening port 443.
2. To allow any of the services, please run the following command.
sudo ufw allow 'Apache Full'
3. In the previous sections, we have discussed about the domain name. If you have a domain name, you can type in the domain name or the server's IP address in your web browser to access the Apache default page.
http://server_domain_or_IP