How to Use Vultr's Grafana Marketplace Application

Grafana is an open-source platform for visualizing and analyzing data from various sources. It provides interactive dashboards with customizable graphs, charts, and panels for real-time monitoring and data exploration. With its extensive plugin ecosystem, Grafana integrates with numerous data sources including Prometheus, InfluxDB, Elasticsearch, MySQL, and PostgreSQL, making it a powerful tool for tracking system performance and gaining actionable insights. The Vultr Marketplace provides a pre-configured Grafana instance, enabling quick deployment and setup on a Vultr server.
This guide explains deploying and using Vultr's Grafana Marketplace Application. You will deploy an instance, configure security and SSL, connect data sources like Prometheus, create dashboards, set up alerts, and implement best practices for production monitoring.
Deploy Vultr's Grafana Marketplace Application
Log in to your Vultr Customer Portal and click the Deploy Server button.
Select your preferred server type.
Choose a server location.
Select a server plan with at least 2GB RAM and 2 CPU cores for production workloads.
Click the Configure button to proceed.
Under Marketplace Apps, search for
Grafanaand select it as the Marketplace Application.Select the Limited Login option from the Additional Features section to create a limited user with sudo access.
Review your configurations and click the Deploy Now button to start deployment.
It may take up to 10 minutes for your server to finish installing Grafana.NoteAfter the instance shows the status of Running, navigate to the Server Overview page and copy the SSH connection details.
Initial Setup and Configuration
After deployment, configure DNS, verify the installation, and secure your Grafana instance with proper authentication and SSL/TLS before exposing it to production traffic.
Create a DNS A record pointing to your server's IP address, such as
grafana.example.com.Connect to your Vultr server instance over SSH using the connection details from the Server Overview page.
Verify Grafana Installation
Check the Grafana service status.
console$ sudo systemctl status grafana-server
The service should show as
active (running).Verify the installed Grafana version.
console$ grafana-server -v
Output:
Version 12.2.0 (commit: 92f1fba9b4b6700328e99e97328d6639df8ddc3d, branch: release-12.2.0)Access Grafana by visiting
grafana.example.comin a web browser.Log in with the default credentials from the Server Overview page.
Configure Firewall Security
Secure your server by configuring the firewall to allow only necessary traffic before enabling SSL.
Allow SSH connections.
console$ sudo ufw allow OpenSSH
Allow HTTP and HTTPS traffic for Nginx and Certbot.
console$ sudo ufw allow 80/tcp $ sudo ufw allow 443/tcp
Enable the firewall.
console$ sudo ufw enable
Verify firewall status.
console$ sudo ufw status
Port 3000 is used by Grafana's backend service before HTTPS is configured through Nginx. You will remove this rule after enabling SSL.
Configure Reverse Proxy with Nginx
Set up Nginx as a reverse proxy to serve Grafana over standard HTTP/HTTPS ports.
Install the Nginx web server package.
console$ sudo apt install nginx -y
Create an Nginx virtual host configuration for Grafana.
console$ sudo nano /etc/nginx/sites-available/grafana
iniserver { listen 80; server_name grafana.example.com; location / { proxy_pass http://localhost:3000; proxy_set_header Host $host; proxy_set_header X-Real-IP $remote_addr; proxy_set_header X-Forwarded-For $proxy_add_x_forwarded_for; proxy_set_header X-Forwarded-Proto $scheme; proxy_read_timeout 300; proxy_send_timeout 300; } }
Replace
grafana.example.comwith your domain name.Save and close the file.
Enable the Grafana server block.
console$ sudo ln -s /etc/nginx/sites-available/grafana /etc/nginx/sites-enabled/
Test the Nginx configuration syntax.
console$ sudo nginx -t
Output:
nginx: the configuration file /etc/nginx/nginx.conf syntax is ok nginx: configuration file /etc/nginx/nginx.conf test is successfulReload Nginx to apply the changes.
console$ sudo systemctl reload nginx
Secure Grafana with SSL/TLS
Protect your Grafana instance with HTTPS using Let's Encrypt certificates via Certbot.
Install Certbot and the Nginx plugin.
console$ sudo apt install certbot python3-certbot-nginx -y
Request an SSL certificate for your domain.
console$ sudo certbot --nginx -d grafana.example.com
Follow the prompts and select the option to redirect HTTP traffic to HTTPS when asked.
Update Grafana configuration to use the domain URL.
console$ sudo nano /etc/grafana/grafana.ini
Update the following settings under the
[server]section.ini[server] domain = grafana.example.com root_url = https://grafana.example.com/ serve_from_sub_path = false
Save and close the file.
Restart Grafana to apply changes.
console$ sudo systemctl restart grafana-server
Verify SSL certificate auto-renewal.
console$ sudo certbot renew --dry-run
Access Grafana securely at
https://grafana.example.com.Close direct port 3000 access now that traffic goes through the Nginx reverse proxy.
console$ sudo ufw delete allow 3000/tcp
Configure Grafana
Set up data sources, configure authentication, and prepare Grafana for monitoring.
Update Grafana Configuration
Edit the main Grafana configuration file.
console$ sudo nano /etc/grafana/grafana.ini
Configure important settings under relevant sections.
ini[security] admin_user = admin disable_gravatar = true cookie_secure = true cookie_samesite = strict content_security_policy = true [users] allow_sign_up = false allow_org_create = false [auth.anonymous] enabled = false [snapshots] external_enabled = false
Save and close the file.
Avoid storingNoteadmin_passwordin the configuration file. Usegrafana-cli admin reset-admin-passwordto set or rotate passwords securely.Restart Grafana to apply configuration changes.
console$ sudo systemctl restart grafana-server
Add Data Sources
Configure data sources to visualize metrics from various systems.
Log in to Grafana at
https://grafana.example.com.Navigate to Connections > Data sources and click Add data source.
Select Prometheus and configure:
- Name: Prometheus
- URL:
http://localhost:9090
Click Save & test to verify the connection.
If Prometheus is remote, confirm firewall rules allow connections and verify the URL is correct.
Connect to Vultr Managed Database
Integrate Grafana with a Vultr Managed Database to store dashboard configurations and user data persistently.
Deploy a Vultr Managed Database for MySQL from the Vultr Customer Portal.
From the Managed Database dashboard, note the connection details.
Configure Grafana to use MySQL via environment variables.
console$ sudo nano /etc/default/grafana-server
iniGF_DATABASE_TYPE=mysql GF_DATABASE_HOST=your-managed-db-host.vultr.com:16751 GF_DATABASE_NAME=grafana GF_DATABASE_USER=vultradmin GF_DATABASE_PASSWORD=your_secure_password GF_DATABASE_SSL_MODE=require
Replace the connection details with your Managed Database credentials.
Save and close the file.
Create the Grafana database in your MySQL instance.
console$ mysql -h your-managed-db-host.vultr.com -P 16751 -u vultradmin -p
Enter your password when prompted, then create the database:
sql> CREATE DATABASE grafana CHARACTER SET utf8mb4 COLLATE utf8mb4_unicode_ci; > EXIT;
Restart Grafana to migrate to the new database.
console$ sudo systemctl restart grafana-server
Explore Grafana Features
Learn to create dashboards, visualize data, and set up alerts for comprehensive monitoring.
Create a Dashboard
From the Grafana home page, click Dashboards in the left sidebar.
Click New and select New Dashboard.
Click Add visualization.
Select your data source (e.g., Prometheus).
Configure the query panel:
- For Prometheus, enter a query like
rate(node_cpu_seconds_total[5m]) - Select the visualization type (Time series, Graph, Gauge, etc.)
- Customize the panel title and description
- For Prometheus, enter a query like
Click Save dashboard.
Import Pre-built Dashboards
Navigate to Dashboards > New > Import.
Enter a dashboard ID from Grafana Dashboards:
- Node Exporter Full:
1860 - Docker and System Monitoring:
893 - MySQL Overview:
7362
- Node Exporter Full:
Click Load, select your data source, and click Import.
Configure Alerts
Set up alert rules to receive notifications when metrics exceed thresholds.
Open an existing dashboard panel or create a new one.
Click the three dots next to the panel title and select Edit.
Navigate to the Alert tab.
Click New alert rule.
Configure the alert:
- Alert rule name: High CPU Usage
- Condition: WHEN avg() OF query(A, 5m) IS ABOVE 80
- Evaluate every: 1m
- For: 5m
Add notification channel:
- Click Contact points in the sidebar
- Add email, Slack, PagerDuty, or other notification methods
Click Save to create the alert rule.
Manage Users and Teams
From the Grafana home page, click Administration in the left sidebar.
Select Users and access, followed by Users.
You can add a new user here, or invite one by navigating to Organization users.
Enter the user's email and assign a role:
- Admin: Full control over Grafana
- Editor: Can create and edit dashboards
- Viewer: Read-only access
Create teams for organized access control:
- Navigate to Administration > Users and acess > Teams
- Click New team
- Add users to teams and assign dashboard permissions
Best Practices and Configuration
Implement these recommendations to ensure your Grafana instance runs securely and efficiently.
Security Hardening
Disable anonymous access (already configured in
grafana.ini).Use strong passwords and enable two-factor authentication.
console$ sudo nano /etc/grafana/grafana.ini
Under
[auth]section:ini[auth] disable_login_form = false oauth_auto_login = false
Limit admin privileges to necessary users only.
Regularly update Grafana to the latest version.
console$ sudo apt update $ sudo apt upgrade grafana
Enable audit logging.
ini[log] mode = console file level = info
Performance Optimization
Configure query caching to reduce data source load.
ini[caching] enabled = true
Set appropriate data retention policies on data sources.
Use dashboard variables for efficient query reuse.
Limit the time range of queries to improve performance.
Enable gzip compression for faster dashboard loading.
ini[server] enable_gzip = true
Backup and Restore
Back up Grafana's database (if using external database, use database backup tools).
Export important dashboards as JSON:
- Open a dashboard
- Click the dashboard Settings (top right)
- Select JSON Model
- Copy and save the JSON
Back up the Grafana configuration file.
console$ sudo cp /etc/grafana/grafana.ini /etc/grafana/grafana.ini.backup
Troubleshooting
This section covers common issues and diagnostic commands to help resolve problems with your Grafana instance.
Check Service Status and Logs
Verify service status and view logs.
console$ sudo systemctl status grafana-server $ sudo journalctl -u grafana-server -e $ sudo tail -f /var/log/nginx/error.log
Common Issues
Cannot Connect to Data Source
Verify the data source is running and accessible.
console$ curl http://localhost:9090/api/v1/status/config # For Prometheus
Check firewall rules allow connections to the data source.
Verify data source URL and credentials in Grafana settings.
Login Issues
Reset the admin password.
console$ sudo grafana-cli admin reset-admin-password newpassword
Check authentication settings in
/etc/grafana/grafana.ini.
Dashboard Not Loading
Clear browser cache and reload.
Check browser console for JavaScript errors.
Verify data source queries are valid.
Increase query timeout in Grafana settings.
High Memory Usage
Reduce dashboard refresh intervals.
Limit the number of panels per dashboard.
Optimize data source queries.
Increase server resources if necessary.
Use Cases
Grafana excels in various monitoring and visualization scenarios:
- Infrastructure Monitoring: Visualize server metrics, CPU usage, memory consumption, and network traffic from tools like Prometheus, InfluxDB, or Telegraf.
- Application Performance Monitoring: Track application metrics, response times, error rates, and throughput to identify performance bottlenecks.
- Business Analytics: Create dashboards for business KPIs, sales metrics, and operational data from databases like MySQL, PostgreSQL, or Elasticsearch.
- IoT Device Monitoring: Visualize sensor data, device health, and telemetry from IoT platforms and time-series databases.
- Log Analysis: Integrate with Loki or Elasticsearch to visualize log patterns, error frequencies, and system events.
- Cloud Resource Monitoring: Monitor AWS, Azure, or Google Cloud resources with native cloud data source plugins.
Conclusion
In this guide, you deployed Vultr's Grafana Marketplace Application and configured it for production use. You secured the instance with SSL/TLS through Nginx reverse proxy, configured firewall rules, connected data sources like Prometheus, and created monitoring dashboards with alerts. You also integrated with a Vultr Managed Database for persistent storage and implemented security best practices. With Grafana's powerful visualization capabilities and Vultr's infrastructure, you can build comprehensive monitoring solutions for infrastructure, applications, and business metrics.