Guides tagged “database”
Step-by-step MdmHost guides about database, sorted A-Z.
93 guides · page 2 of 5
Create MongoDB Users and Assign Roles
Create MongoDB users with db.createUser, give them built-in or custom roles scoped to one database, and confirm each login with mongosh.
Create MySQL databases and users in DirectAdmin
Create a MySQL database and user in DirectAdmin, manage privileges, open phpMyAdmin, import or export SQL dumps and allow remote MySQL hosts.
Create PostgreSQL users, roles and databases
Create a PostgreSQL login role and a database for your application, set a password, grant the right privileges on the database and schema, and manage ownership.
Diagnosing slow database performance: slow query optimization with EXPLAIN
Read MySQL and PostgreSQL execution plans with EXPLAIN, find full table scans and filesorts, add the index the query actually needs, and confirm the speed-up.
Docker Compose for WordPress: Nginx, PHP-FPM and MariaDB
Build a WordPress stack with Docker Compose using separate Nginx, PHP-FPM and MariaDB containers, a persistent wp-content volume and a free Let's Encrypt certificate.
Edit, delete, optimise and repair database tables in phpMyAdmin (cPanel)
Open phpMyAdmin from cPanel to edit rows, empty or drop tables, and run Optimize, Check and Repair table to reclaim space and fix crashed tables safely.
Enable MySQL TLS and Require Encrypted Connections
Enable TLS on MySQL or MariaDB, point the server at its certificate files, and force every client to connect over an encrypted channel.
Find and shrink large MySQL databases in cPanel
See which databases and tables use the most space in cPanel, clean logs, sessions, revisions and transients safely, then optimise tables to reclaim disk space.
Find High-Cost MySQL Queries with Performance Schema
Use MySQL Performance Schema to find the statements and wait events that consume the most time on your server, then confirm the fix with fresh measurements.
Find Slow PostgreSQL Queries with pg_stat_statements
Enable the pg_stat_statements extension on PostgreSQL and use it to find the queries consuming the most time on your server.
Find slow queries in MySQL with the slow query log
Turn on the MySQL slow query log, read it with mysqldumpslow and pt-query-digest, then use EXPLAIN to fix the queries that slow your app down.
Fix "Error establishing a database connection" in WordPress
Fix the WordPress database connection error: check wp-config.php credentials, the cPanel database user and privileges, repair tables and rule out server limits.
Fix MariaDB Authentication Plugin Errors After Upgrade
MariaDB upgrades often change how accounts authenticate, so logins that worked yesterday fail with plugin or access-denied errors. This guide shows how to check which plugin a user has and switch it safely.
Fix MySQL Charset and Collation Mismatches
Find where a MySQL charset or collation mismatch lives — server, database, table, column or connection — and fix it without corrupting your data.
Fix MySQL or MariaDB error 1045: Access denied for user
Error 1045 means MySQL or MariaDB rejected the login. Find which user and host the client asked for, fix the password or grants, and reset a lost root password safely.
Fix MySQL Socket Error: Can't Connect to Local Server
ERROR 2002 means the MySQL client could not reach the server over its Unix socket. Check the service, find the real socket path, and fix the client config.
Fix MySQL Too Many Connections Errors
Diagnose MySQL error 1040, find which clients are holding connections open, raise max_connections safely and tune wait_timeout to stop the leak coming back.
Fix PostgreSQL "Too Many Clients Already" Errors
Diagnose and fix the PostgreSQL FATAL: sorry, too many clients already error by finding idle backends, tuning max_connections and adding a connection pooler.
Fix PostgreSQL Password Authentication Failed for User
Diagnose and fix the PostgreSQL "password authentication failed for user" error by checking pg_hba.conf rules, resetting the role password and reloading the server.
Fix Redis MISCONF RDB Snapshot Saving Error
The Redis MISCONF error means a background RDB save failed, so Redis stopped accepting writes. This guide finds the cause and restores saving safely.
Browse by topic
- Getting startedYour first hour with a new server: access, logins and basics.69 guides
- cPanelFiles, databases, email, domains and every cPanel tool, step by step.37 guides
- WHM & resellingWHM, packages, reseller accounts, WHMReseller and running a hosting brand.49 guides
- WordPressInstall, secure, speed up, migrate and fix WordPress sites.40 guides
- Email & webmailMailboxes, webmail, forwarders, spam filters and email delivery.37 guides
- DomainsRegistering, transferring and managing domains and nameservers.20 guides
- SSL certificatesFree AutoSSL, Let's Encrypt, paid certificates and HTTPS.19 guides
- CloudLinuxCloudLinux setup and use: LVE limits, CloudLinux Manager, CageFS and PHP/Node.js selectors.31 guides
- LiteSpeedLiteSpeed Web Server, LSCache and the LiteSpeed Cache plugin: install, settings and tuning.30 guides
- Imunify360Malware scanning, firewall and proactive defence with Imunify360.23 guides
- SoftaculousInstall, update, clone and back up apps with Softaculous.23 guides
- WP SquaredcPanel's WordPress platform: sites, plugins, staging and backups.9 guides
- SitePadBuild and publish websites with the SitePad builder.9 guides
- SitejetDesign, edit and publish sites with the Sitejet builder.9 guides
- WHMResellerAlpha and master resellers with WHMReseller: install, setup and use.12 guides
- VirtFusionInstall, set up and manage VirtFusion: hypervisors, packages, servers and WHMCS integration.7 guides
- VirtualizorManage your VPS with Virtualizor: power, OS reinstall, VNC, IPs and backups.30 guides
- PleskWebsites, email, databases and settings in the Plesk panel.52 guides
- DirectAdminUsers, domains, email and reseller tools in DirectAdmin.40 guides
- WHMCSBilling, automation, products and client management with WHMCS.51 guides
- Control panelscPanel & WHM, Plesk, DirectAdmin and other panels on your VPS.106 guides
- SecurityKeys, passwords, firewalls and keeping a server patched.115 guides
- Networking & DNSIP addresses, reverse DNS, ports and traffic.34 guides
- Websites & appsWeb servers, WordPress, PHP, Node.js, SSL and app hosting.52 guides
- DatabasesMySQL, MariaDB, PostgreSQL, Redis and MongoDB on a VPS.64 guides
- Billing & accountInvoices, renewals, the client area and your account.9 guides
- TroubleshootingWhen something is not working: checks and fixes.68 guides
- Linux VPSSSH, packages, services and everyday Linux administration.70 guides
- Windows VPS & RDPRemote Desktop, Windows Server settings and Admin RDP tips.58 guides
- Docker & DevOpsContainers, Git deploys, automation, monitoring and backups.58 guides
Still stuck?
Ask MdmHost AI for a quick answer, or open a ticket and our team will take a look. We are here 24/7.
