{"id":5645,"date":"2018-03-31T08:59:54","date_gmt":"2018-03-31T08:59:54","guid":{"rendered":"https:\/\/www.milesweb.co.uk\/blog\/?p=5645"},"modified":"2024-03-20T11:33:41","modified_gmt":"2024-03-20T11:33:41","slug":"an-insight-on-wordpress-cloud-hosting-a-cluster-that-is-highly-available-and-auto-scalable","status":"publish","type":"post","link":"https:\/\/www.milesweb.co.uk\/blog\/hosting\/cloud\/an-insight-on-wordpress-cloud-hosting-a-cluster-that-is-highly-available-and-auto-scalable\/","title":{"rendered":"An Insight On WordPress Cloud Hosting : A Cluster That Is Highly-Available And Auto-Scalable"},"content":{"rendered":"<p>High availability and excellent performance are extremely important attributes considered by the developers while selecting a hosting platform. It is obvious that no one likes to lose money because of the downtimes caused to the website; but having said that it is also true that no one can be completely safe from downtimes. Therefore, in order to reduce the risk of the occurrences of downtime and in order to ensure an additional level of redundancy the cluster approach can be utilized.<!--more--><\/p>\n<p><img loading=\"lazy\" decoding=\"async\" class=\"aligncenter size-full wp-image-5646\" src=\"https:\/\/www.milesweb.co.uk\/blog\/wp-content\/uploads\/2018\/03\/wordpress-cluster-min.png\" alt=\"wordpress, wordpress cluster\" width=\"450\" height=\"247\" srcset=\"https:\/\/www.milesweb.co.uk\/blog\/wp-content\/uploads\/2018\/03\/wordpress-cluster-min.png 450w, https:\/\/www.milesweb.co.uk\/blog\/wp-content\/uploads\/2018\/03\/wordpress-cluster-min-300x165.png 300w\" sizes=\"auto, (max-width: 450px) 100vw, 450px\" \/><\/p>\n<p>This article will illustrate the process of adjusting an ordinary application in order to match the enterprise level demands with the example of the \u2018WordPress Cluster\u2019. WordPress is considered as a widely used blogging platform and an efficient content management system (CMS) that is powered by PHP. By applying some special configurations to run WordPress as a highly available and auto-scalable cluster, we will demonstrate the process of easily creating a trustworthy and affordable <a href=\"https:\/\/www.milesweb.co.uk\/hosting\/wordpress-hosting\/wordpress-cloud-hosting\" target=\"_blank\" rel=\"noopener\">managed WordPress cloud hosting<\/a> solution for your website or blog with a wide range of users. This solution can ensure the functionality of your service in many complex situations like single server downtime or high users influx (also known as traffic spikes).<\/p>\n<p><strong>Let\u2019s have a look at the pre-packaged WordPress cluster specifications along with the ways of its deployment and management:<\/strong><\/p>\n<h2><strong>Auto-Scalable WordPress Cluster In Containers<\/strong><\/h2>\n<p>The distinctive automated WordPress cluster solution provided by MilesWeb is created on the basis of dockerized templates and consists of the latest WordPress version. The main elements of this WordPress cluster environment deployed with this package are mentioned below:<\/p>\n<ul>\n<li>In order to distribute the incoming traffic within a cluster an NGINX load balancer is utilized. After this, it can be manually scaled horizontally once the installation is done while the node(s) that are newly added detect the available application servers automatically.<\/li>\n<li>The WordPress application is managed with two NGINX PHP servers that are scaled automatically on the basis of pre-configured triggers.<\/li>\n<li>Two replicated MySQL servers are provided for storing and operating the user data.<\/li>\n<li>In order to eliminate data duplication, a dedicated data storage node is offered and it is ensured that the same content is present throughout all the application servers.<\/li>\n<\/ul>\n<p>All the software stacks use the default image tag while creating suitable containers. The containers generally point to the latest software version by default; but they can be customized by your <a href=\"https:\/\/www.milesweb.co.uk\/\">web hosting provider<\/a>. Every node has a resource limit of 8 cloudlets by default that equals to 1 GiB of RAM and 3.2 GHz of CPU. It is possible to subsequently increase this limit.<\/p>\n<p><img loading=\"lazy\" decoding=\"async\" class=\"aligncenter size-full wp-image-5647\" src=\"https:\/\/www.milesweb.co.uk\/blog\/wp-content\/uploads\/2018\/03\/master-master-async-replication-min.png\" alt=\"\" width=\"732\" height=\"383\" srcset=\"https:\/\/www.milesweb.co.uk\/blog\/wp-content\/uploads\/2018\/03\/master-master-async-replication-min.png 732w, https:\/\/www.milesweb.co.uk\/blog\/wp-content\/uploads\/2018\/03\/master-master-async-replication-min-300x157.png 300w, https:\/\/www.milesweb.co.uk\/blog\/wp-content\/uploads\/2018\/03\/master-master-async-replication-min-390x205.png 390w\" sizes=\"auto, (max-width: 732px) 100vw, 732px\" \/><\/p>\n<p>During the process of WordPress cluster installation, the system automatically runs the operations mentioned below with the use of the cloud orchestration.<\/p>\n<p>Configuration of the automatic horizontal scaling process to tackle the load spikes on the application servers, where usually the bottlenecks happen; one more node is added if the CPU usage exceeds 70% of the allocated resources. This node is removed if the CPU consumption falls below 20%.<\/p>\n<ul>\n<li>Implementing \u2018asynchronous Multi-Master Replication\u2019 for the DB cluster in order to increase the data reliability, attain high-availability and to prevent app downtime in case of a failure of a single database server.<\/li>\n<li>Using the official WordPress website to install the latest WordPress version and extracting its content in the <strong>\/data<\/strong> directory present on the \u2018Storage\u2019 node, this will be subsequently added to the application server layer.<\/li>\n<li>Mounting the <strong>\/data<\/strong> folder on the \u2018Data Storage\u2019 container to the application server\u2019s directory that is named &#8211; <strong>\/var\/www\/webroot\/ROOT<\/strong> so that all the present nodes including the automatically connected newly added nodes will operate through a single data set instead of managing and constantly synchronizing changes within their own content copies. This is done with the common cached pages storage.<\/li>\n<li>Configuration of an advanced \u2018HyperDB\u2019 class for supporting replication, load balancing, failover and partitioning.<\/li>\n<li>Adding the \u2018SuperCache\u2019 plugin to improve the cluster productivity and response time by returning the auto-generated static HTML pages for the frequently created requests rather than processing relatively heavier WordPress PHP scripts every time.<\/li>\n<\/ul>\n<p>In this way, a user can be confident of data safety and availability as these are the most important elements for production-propose websites. As these actions are entirely automated, the process of creating an auto-scalable, efficient and reliable WordPress cluster is simplified for the users.<\/p>\n<h2><strong>Deploying The WordPress Cluster In One Click<\/strong><\/h2>\n<p>Deploying a cluster can be complicated and time-consuming but with MilesWeb, the process of WordPress cluster deployment and configuration is completely automated. All you need to do is perform some simple tasks mentioned below:<\/p>\n<ol>\n<li>Login to MilesWeb\u2019s dashboard with your login credentials and start the installation process through one of the following ways:<\/li>\n<\/ol>\n<p><strong>Marketplace<\/strong><\/p>\n<p>Just type the name of the package in the search field within the opened window and click on the \u2018Install\u2019 button.<\/p>\n<p><img loading=\"lazy\" decoding=\"async\" class=\"aligncenter size-full wp-image-5648\" src=\"https:\/\/www.milesweb.co.uk\/blog\/wp-content\/uploads\/2018\/03\/marketplace-min.png\" alt=\"\" width=\"731\" height=\"348\" srcset=\"https:\/\/www.milesweb.co.uk\/blog\/wp-content\/uploads\/2018\/03\/marketplace-min.png 731w, https:\/\/www.milesweb.co.uk\/blog\/wp-content\/uploads\/2018\/03\/marketplace-min-300x143.png 300w\" sizes=\"auto, (max-width: 731px) 100vw, 731px\" \/><\/p>\n<p><strong>Import<\/strong><\/p>\n<p>Within the open window, go to the \u2018URL\u2019 tab and import this link &#8211; https:\/\/github.com\/jelastic-jps\/wordpress-cluster\/blob\/master\/manifest.jps for fetching the appropriate WordPress cluster manifest file.<\/p>\n<p><img loading=\"lazy\" decoding=\"async\" class=\"aligncenter size-full wp-image-5649\" src=\"https:\/\/www.milesweb.co.uk\/blog\/wp-content\/uploads\/2018\/03\/import-min.png\" alt=\"\" width=\"570\" height=\"409\" srcset=\"https:\/\/www.milesweb.co.uk\/blog\/wp-content\/uploads\/2018\/03\/import-min.png 570w, https:\/\/www.milesweb.co.uk\/blog\/wp-content\/uploads\/2018\/03\/import-min-300x215.png 300w\" sizes=\"auto, (max-width: 570px) 100vw, 570px\" \/><\/p>\n<ol start=\"2\">\n<li>In the confirmation window, enter the appropriate WP title for your blog website<\/li>\n<\/ol>\n<p><img loading=\"lazy\" decoding=\"async\" class=\"aligncenter size-full wp-image-5650\" src=\"https:\/\/www.milesweb.co.uk\/blog\/wp-content\/uploads\/2018\/03\/wordpress-cluster-jelastic-min.png\" alt=\"\" width=\"609\" height=\"422\" srcset=\"https:\/\/www.milesweb.co.uk\/blog\/wp-content\/uploads\/2018\/03\/wordpress-cluster-jelastic-min.png 609w, https:\/\/www.milesweb.co.uk\/blog\/wp-content\/uploads\/2018\/03\/wordpress-cluster-jelastic-min-300x208.png 300w, https:\/\/www.milesweb.co.uk\/blog\/wp-content\/uploads\/2018\/03\/wordpress-cluster-jelastic-min-392x272.png 392w, https:\/\/www.milesweb.co.uk\/blog\/wp-content\/uploads\/2018\/03\/wordpress-cluster-jelastic-min-130x90.png 130w\" sizes=\"auto, (max-width: 609px) 100vw, 609px\" \/><\/p>\n<p>Also, enter \u2018Environment\u2019 name and customize its \u2018Display Name\u2019 (optional). After this, select the appropriate region (if several are available) and click on the \u2018Install\u2019 button.<\/p>\n<p>Note : Keeping in mind the complex nature of the packages topology, you might have to upgrade to the paid option in order to get the required amount of resources.<\/p>\n<ol start=\"3\">\n<li>When the environment installation and configuration is done, a frame will be displayed that shows your administration data and your credentials will be sent to your account email as well.<\/li>\n<\/ol>\n<p><img loading=\"lazy\" decoding=\"async\" class=\"aligncenter size-full wp-image-5651\" src=\"https:\/\/www.milesweb.co.uk\/blog\/wp-content\/uploads\/2018\/03\/wordpress-cluster-administration-min.png\" alt=\"\" width=\"430\" height=\"321\" srcset=\"https:\/\/www.milesweb.co.uk\/blog\/wp-content\/uploads\/2018\/03\/wordpress-cluster-administration-min.png 430w, https:\/\/www.milesweb.co.uk\/blog\/wp-content\/uploads\/2018\/03\/wordpress-cluster-administration-min-300x224.png 300w\" sizes=\"auto, (max-width: 430px) 100vw, 430px\" \/><\/p>\n<p>You have now successfully deployed WordPress cluster to the cloud and you can start using it immediately. Click on the option \u2013 \u2018Open in browser\u2019 in order to enable the created environment to access your website or utilize the credentials mentioned above for getting into the WP control panel.<\/p>\n<p><img loading=\"lazy\" decoding=\"async\" class=\"aligncenter size-full wp-image-5652\" src=\"https:\/\/www.milesweb.co.uk\/blog\/wp-content\/uploads\/2018\/03\/hello-world-min.png\" alt=\"\" width=\"1012\" height=\"611\" srcset=\"https:\/\/www.milesweb.co.uk\/blog\/wp-content\/uploads\/2018\/03\/hello-world-min.png 1012w, https:\/\/www.milesweb.co.uk\/blog\/wp-content\/uploads\/2018\/03\/hello-world-min-300x181.png 300w, https:\/\/www.milesweb.co.uk\/blog\/wp-content\/uploads\/2018\/03\/hello-world-min-768x464.png 768w\" sizes=\"auto, (max-width: 1012px) 100vw, 1012px\" \/><\/p>\n<p>Now you can start working with your automatically scaled WordPress content management system and post the required content to it for getting maximum incoming traffic without the fear of overloading the website.<\/p>\n<h2><strong>Management Of Your Scalable WordPress Cluster<\/strong><\/h2>\n<p>Even though there is a pre-defined structure in place, this WordPress cluster solution is fully customizable after the installation process is complete. For instance, the user can adjust the triggers for automatic scaling for some specific needs and the user can also extend the environment with additional services or features.<\/p>\n<p><strong>Here is an insight on the most common operations that can be performed through the intuitive UI with just a few clicks:<\/strong><\/p>\n<h2><strong>Adjusting The Environment Topology<\/strong><\/h2>\n<p>The current structure and the main elements of your WordPress cluster can be instantly changed by clicking on the option \u2013 \u2018Change environment topology\u2019 that is present next to the environment name.<\/p>\n<p><img loading=\"lazy\" decoding=\"async\" class=\"aligncenter size-full wp-image-5653\" src=\"https:\/\/www.milesweb.co.uk\/blog\/wp-content\/uploads\/2018\/03\/change-environment-topology-min.png\" alt=\"\" width=\"801\" height=\"430\" srcset=\"https:\/\/www.milesweb.co.uk\/blog\/wp-content\/uploads\/2018\/03\/change-environment-topology-min.png 801w, https:\/\/www.milesweb.co.uk\/blog\/wp-content\/uploads\/2018\/03\/change-environment-topology-min-300x161.png 300w, https:\/\/www.milesweb.co.uk\/blog\/wp-content\/uploads\/2018\/03\/change-environment-topology-min-768x412.png 768w, https:\/\/www.milesweb.co.uk\/blog\/wp-content\/uploads\/2018\/03\/change-environment-topology-min-800x430.png 800w\" sizes=\"auto, (max-width: 801px) 100vw, 801px\" \/><\/p>\n<p>Inside the open window, you can adjust the required topology settings (same as during the creation of environment) and \u2018Apply\u2019 the changes made. For example, in this window you can enlarge the default number of containers in every layer or bound a public IP address to the cluster entry point for increased availability.<\/p>\n<h2><strong>Encrypt Connection With Customized SSL<\/strong><\/h2>\n<p>For safeguarding the environment and ensuring safety for application data, the user can activate an SSL certificate. In order to do this, the user can enable <a href=\"https:\/\/www.milesweb.co.uk\/web-security\/ssl-certificates\">MilesWeb SSL<\/a> while editing the environment topology.<\/p>\n<p><img loading=\"lazy\" decoding=\"async\" class=\"aligncenter size-full wp-image-5654\" src=\"https:\/\/www.milesweb.co.uk\/blog\/wp-content\/uploads\/2018\/03\/enable-ssl-min.png\" alt=\"\" width=\"627\" height=\"282\" srcset=\"https:\/\/www.milesweb.co.uk\/blog\/wp-content\/uploads\/2018\/03\/enable-ssl-min.png 627w, https:\/\/www.milesweb.co.uk\/blog\/wp-content\/uploads\/2018\/03\/enable-ssl-min-300x135.png 300w\" sizes=\"auto, (max-width: 627px) 100vw, 627px\" \/><\/p>\n<p>An easier way of achieving this is by applying the \u2018Let\u2019s Encrypt\u2019 addon. This addon can be automatically installed through the Marketplace and it provides the required protection level for the internal and external environment domain(s) without any kind of manual configurations. Note that this process will require a public IP that is available in a full account only.<\/p>\n<p>During the process of installation, select the cluster environment and entry node, enter the preliminary bound domain name and confirm \u2013 the rest of the configurations will be done by MilesWeb for saving your time.<\/p>\n<p><img loading=\"lazy\" decoding=\"async\" class=\"aligncenter size-full wp-image-5655\" src=\"https:\/\/www.milesweb.co.uk\/blog\/wp-content\/uploads\/2018\/03\/lets-encrypt-free-ssl-min.png\" alt=\"\" width=\"940\" height=\"570\" srcset=\"https:\/\/www.milesweb.co.uk\/blog\/wp-content\/uploads\/2018\/03\/lets-encrypt-free-ssl-min.png 940w, https:\/\/www.milesweb.co.uk\/blog\/wp-content\/uploads\/2018\/03\/lets-encrypt-free-ssl-min-300x182.png 300w, https:\/\/www.milesweb.co.uk\/blog\/wp-content\/uploads\/2018\/03\/lets-encrypt-free-ssl-min-768x466.png 768w\" sizes=\"auto, (max-width: 940px) 100vw, 940px\" \/><\/p>\n<h2><strong>Customizing The Automatic Scaling Conditions<\/strong><\/h2>\n<p>The user can increase the resource range that is allocated for the highly-loaded node in the \u2018Change environment topology\u2019 window by adjusting the \u2018Scaling limit\u2019 of the cloudlet. This process will not affect the real consumption of resources but it will provide some buffer for the traffic load spikes.<\/p>\n<p>The distinctive \u2018automatic vertical scaling\u2019 method followed by MilesWeb\u2019s PaaS environment enables you to pay only for the real resources that are used and you don\u2019t have to pay for the allocated resource limits. Therefore, even the complex clusters ensure affordability.<\/p>\n<p><img loading=\"lazy\" decoding=\"async\" class=\"aligncenter size-full wp-image-5656\" src=\"https:\/\/www.milesweb.co.uk\/blog\/wp-content\/uploads\/2018\/03\/vertical-scaling-per-node-min.png\" alt=\"\" width=\"380\" height=\"179\" srcset=\"https:\/\/www.milesweb.co.uk\/blog\/wp-content\/uploads\/2018\/03\/vertical-scaling-per-node-min.png 380w, https:\/\/www.milesweb.co.uk\/blog\/wp-content\/uploads\/2018\/03\/vertical-scaling-per-node-min-300x141.png 300w\" sizes=\"auto, (max-width: 380px) 100vw, 380px\" \/><\/p>\n<p>Moreover, the user can re-configure the behavior of the default WordPress cluster horizontal auto-scaling through <strong>Settings &gt; Monitoring &gt; Auto Horizontal Scaling <\/strong>section by editing the available setup.<\/p>\n<p><img loading=\"lazy\" decoding=\"async\" class=\"aligncenter size-full wp-image-5657\" src=\"https:\/\/www.milesweb.co.uk\/blog\/wp-content\/uploads\/2018\/03\/auto-horizontal-scaling-min.png\" alt=\"\" width=\"861\" height=\"505\" srcset=\"https:\/\/www.milesweb.co.uk\/blog\/wp-content\/uploads\/2018\/03\/auto-horizontal-scaling-min.png 861w, https:\/\/www.milesweb.co.uk\/blog\/wp-content\/uploads\/2018\/03\/auto-horizontal-scaling-min-300x176.png 300w, https:\/\/www.milesweb.co.uk\/blog\/wp-content\/uploads\/2018\/03\/auto-horizontal-scaling-min-768x450.png 768w\" sizes=\"auto, (max-width: 861px) 100vw, 861px\" \/><\/p>\n<p>Keep a track on the resource usage level for every node through \u2018Statistics\u2019 and scaling rules whenever required.<\/p>\n<p><img loading=\"lazy\" decoding=\"async\" class=\"aligncenter size-full wp-image-5658\" src=\"https:\/\/www.milesweb.co.uk\/blog\/wp-content\/uploads\/2018\/03\/wordpress-cluster-1-min.png\" alt=\"\" width=\"968\" height=\"493\" srcset=\"https:\/\/www.milesweb.co.uk\/blog\/wp-content\/uploads\/2018\/03\/wordpress-cluster-1-min.png 968w, https:\/\/www.milesweb.co.uk\/blog\/wp-content\/uploads\/2018\/03\/wordpress-cluster-1-min-300x153.png 300w, https:\/\/www.milesweb.co.uk\/blog\/wp-content\/uploads\/2018\/03\/wordpress-cluster-1-min-768x391.png 768w\" sizes=\"auto, (max-width: 968px) 100vw, 968px\" \/><\/p>\n<p>It is very easy to improve the quality of your service with a wide range of features provided by the MilesWeb PaaS platform.<\/p>\n","protected":false},"excerpt":{"rendered":"<p>High availability and excellent performance are extremely important attributes considered by the developers while selecting a hosting platform. It is obvious that no one likes to lose money because of the downtimes caused to the website; but having said that it is also true that no one can be completely safe from downtimes. Therefore, in&#8230; <a class=\"read-more\" href=\"https:\/\/www.milesweb.co.uk\/blog\/hosting\/cloud\/an-insight-on-wordpress-cloud-hosting-a-cluster-that-is-highly-available-and-auto-scalable\/\">Read More<\/a><\/p>\n","protected":false},"author":5,"featured_media":5659,"comment_status":"open","ping_status":"closed","sticky":false,"template":"","format":"standard","meta":{"footnotes":""},"categories":[366,281],"tags":[221,534,5,61,533],"class_list":["post-5645","post","type-post","status-publish","format-standard","has-post-thumbnail","hentry","category-cloud","category-wordpress","tag-cloud-hosting","tag-cluster-technology","tag-web-hosting-2","tag-wordpress","tag-wordpress-cloud-hosting"],"_links":{"self":[{"href":"https:\/\/www.milesweb.co.uk\/blog\/wp-json\/wp\/v2\/posts\/5645","targetHints":{"allow":["GET"]}}],"collection":[{"href":"https:\/\/www.milesweb.co.uk\/blog\/wp-json\/wp\/v2\/posts"}],"about":[{"href":"https:\/\/www.milesweb.co.uk\/blog\/wp-json\/wp\/v2\/types\/post"}],"author":[{"embeddable":true,"href":"https:\/\/www.milesweb.co.uk\/blog\/wp-json\/wp\/v2\/users\/5"}],"replies":[{"embeddable":true,"href":"https:\/\/www.milesweb.co.uk\/blog\/wp-json\/wp\/v2\/comments?post=5645"}],"version-history":[{"count":6,"href":"https:\/\/www.milesweb.co.uk\/blog\/wp-json\/wp\/v2\/posts\/5645\/revisions"}],"predecessor-version":[{"id":19169,"href":"https:\/\/www.milesweb.co.uk\/blog\/wp-json\/wp\/v2\/posts\/5645\/revisions\/19169"}],"wp:featuredmedia":[{"embeddable":true,"href":"https:\/\/www.milesweb.co.uk\/blog\/wp-json\/wp\/v2\/media\/5659"}],"wp:attachment":[{"href":"https:\/\/www.milesweb.co.uk\/blog\/wp-json\/wp\/v2\/media?parent=5645"}],"wp:term":[{"taxonomy":"category","embeddable":true,"href":"https:\/\/www.milesweb.co.uk\/blog\/wp-json\/wp\/v2\/categories?post=5645"},{"taxonomy":"post_tag","embeddable":true,"href":"https:\/\/www.milesweb.co.uk\/blog\/wp-json\/wp\/v2\/tags?post=5645"}],"curies":[{"name":"wp","href":"https:\/\/api.w.org\/{rel}","templated":true}]}}