How to Provision Vultr Managed Databases for MySQL

Updated on November 27, 2024

Vultr Managed Database for MySQL is a highly available, scalable, and secure database that offers speed and reliability. You can integrate the MySQL database with modern programming languages like Python, PHP, and Node.js to make backends for Content Management Systems (CMS) and web applications. Vultr supports the latest MySQL version in its global locations, and you can choose from CPU-optimized, memory-optimized and general-purpose server types. You can also set up database users, configure trusted sources, and download SSL certificates to securely access the managed databases.

Follow this guide to provision Vultr Managed Databases for MySQL using the Vultr Customer Portal, API, and CLI.

  • Vultr Customer Portal
  • Vultr API
  • Vultr CLI
  1. Navigate to Products and select Databases.

  2. Click Add Managed Database.

    Add Managed Database

  3. Choose MySQL as the database engine.

    Choose the Database Engine

  4. Select the Server Type, Plan, and Number of Replica Nodes.

    Select the plan

  5. Choose a server location.

    Choose a server location

  6. Select a VPC Network.

    Choose a VPC Network

  7. Enter a database label, review the monthly and hourly cost estimates, and click Deploy Now.

    Enter a Database Label

  1. Send a GET request to the List Managed Database Plans endpoint to view all available plans.

    console
    $ curl "https://api.vultr.com/v2/databases/plans" \
        -X GET \
        -H "Authorization: Bearer ${VULTR_API_KEY}"
    
  2. Send a POST request to the Create Database endpoint to create a new database instance.

    console
    $ curl "https://api.vultr.com/v2/databases" \
        -X POST \
        -H "Authorization: Bearer ${VULTR_API_KEY}" \
        -H "Content-Type: application/json" \
        --data '{
            "database_engine" : "mysql",
            "database_engine_version" : "8",
            "plan" : "vultr-dbaas-startup-cc-1-55-2",
            "region" : "jnb",        
            "label" : "Remote-MySQL-Db"
        }'
    

    Visit the Create Database endpoint to view additional attributes to add to your request.

  3. Send a GET request to the List Managed Databases endpoint to list all database instances.

    console
    $ curl "https://api.vultr.com/v2/databases" \
        -X GET \
        -H "Authorization: Bearer ${VULTR_API_KEY}" \
        -H "Content-Type: application/json"
    
  1. List the available database plans.

    console
    $ vultr-cli database plan list
    
  2. Create a new database instance.

    console
    $ vultr-cli database create \
    --database-engine mysql \
    --database-engine-version 8 \
    --plan vultr-dbaas-startup-cc-1-55-2 \
    --region jnb \
    --label Remote-MySQL-Db
    
  3. List all database instances.

    console
    $ vultr-cli database list --summarize
    

    Run vultr-cli database create --help to view all options.