Bobcares

DigitalOcean Managed Database WordPress | How to setup?

by | Aug 27, 2022

We can install WordPress on DigitalOcean using Managed Database with the simple steps in this article. As a part of our DigitalOcean Managed Service, Bobcares provides answers to all of your questions.

WordPress With A Managed Database On DigitalOcean

Nowadays, WordPress programmers choose to use managed databases when building their websites since they enable users to automatically scale their databases with a substantially lower risk of data loss. WordPress developers now have the best option available thanks to Digital Ocean’s managed database cluster, which makes it simple, quick, and worry-free for developers to set up database clusters without having to manage their database cluster themselves.

In this article, we will explain the steps to install WordPress on DigitalOcean using Managed Database.

digitalocean managed database wordpress

1: Create A Droplet With WordPress

  1. Go to the DigitalOcean dashboard and select new droplet.
  2. Select a preferable size. Then confirm to enable Private networking and click Create Droplet.
  3. Connect to the droplet using the SSH client once the droplet is ready.
  4. After establishing the connection, run the following commands:
    apt update     //updates the APT repositories on the droplet.
    apt install php apache2 php-mysql php-gd     //installs apache2 and PHP which are required to run WordPress.

     

  5. Now we can download the latest version of WordPress with this command:
    wget wordpress.org/latest.tar.gz

     

  6. Now extract the file using the command:
    tar -zxf latest.tar.gz -C /var/www/html
    chown www-data /var/www/html/wordpress

     

2: Create MySQL Cluster

  1. Firstly, create a Database cluster like how the droplet is created. Choose MySQL for the database engine, select the same region as the one we used previously, and click Create a Database Cluster.
  2. We can choose which IP addresses can be used to connect to the database from the section secure this database cluster. Here, we access the cluster from the WordPress droplet only. So select the droplet and click Allow these inbound sources only.
  3. Now we can create a new database and user for WordPress by using the Users & Databases tab respectively.
  4. When creating a new user make sure to select the legacy encryption algorithm to be able to connect to the database from WordPress.
  5. A random password will be generated, click the show button and copy it somewhere safe because we will need it later.
  6. Once the database cluster is ready we can then run WordPress.

3: Install WordPress

  1. Open this link http:///wordpress in the browser and replace wordpress_ip with the IP address of the WordPress droplet.
  2. When we see the start page, click Let’s go.
  3. On the loading page, provide the required details. Provide the database name as wp, username, and password. For the Database Host, go to cluster’s page>>Overview tab>>Connection details>>Private network. Take the values for host and port and concatenate them together using a colon and put them in the Database Host field on the WordPress installation page.
  4. Click Submit option on the installation page.
  5. Now click Run the installation to start creating the needed tables for WordPress.
  6. Then enter some information about the site such as the Title, admin username, password, and email address.
  7. Finally, click Install WordPress to finish.

[Looking for a solution to another query? We are just a click away.]

Conclusion

To conclude, we went over the following details from our Support team in this article.

  • Create a droplet and install Apache, PHP, and WordPress in it.
  • Create a MySQL database cluster using Digital Ocean Managed Database Service.
  • Create a MySQL user on the Managed MySQL cluster using the old native password encryption algorithm and grants it full access to a new Database for WordPress.
  • Point the WordPress installation to use the new cluster as its database.

PREVENT YOUR SERVER FROM CRASHING!

Never again lose customers to poor server speed! Let us help you.

Our server experts will monitor & maintain your server 24/7 so that it remains lightning fast and secure.

GET STARTED

0 Comments

Submit a Comment

Your email address will not be published. Required fields are marked *

Never again lose customers to poor
server speed! Let us help you.