MySQL

MySQL is a prominent open-source relational database management system. An incredibly flexible and powerful program, MySQL is used to store and retrieve data for a wide variety of popular applications.

MySQL subscription active
You will receive email notifications for new publications on MySQL.
916 Results
  • Question

    How to add an Lets encrypt certificate dynamically using CNAME verification?

    I have been working on a web app where users can create custom profiles of them and see it on their custom domain by adding an A record and CNAME record. If they have their profile on https://webapp.com/profile they c...
    Accepted Answer: Hello, If I understand this correctly, it sounds like that you need some kind of automation to create a new Nginx server block for each website, and then install the Let's Encrypt SSL certificate for the new domain. T...
    1 By Cybil Apache PHP MySQL Ubuntu 18.04 Security
  • Question

    Can host Wordpress on domain and Angular on subdomain?

    Dear All, First of all sorry if it will be a silly question. My plan is to host a WordPress website to www.example.com for an introduction page. Is it possible to host an Angular SPA to www.angular.example.com or exa...
    Accepted Answer: Hi @tothtomi7, This is entirely possible! What I'll recommend using in this case is a LAMP droplet. Good thing is DigitalOcean does have a pretty good article about the same process you are describing - https://www.di...
    1 By tothtomi7 API WordPress Docker MySQL
  • Question

    How to change caching_sha2_password to mysql_native_password on a DigitalOcean's Managed MySQL Database?

    I want to use the new DigitalOcean MySQL Managed Databases with my PHP application but I'm getting this error here: ER_NOT_SUPPORTED_AUTH_MODE: Client does not support authentication protocol requested by server; con...
    Accepted Answer: Hello, The easiest way to fix that would be to alter your existing user with the following: ALTER USER <^>myuser <^>IDENTIFIED WITH mysql_native_password BY '<^>mypassword<^>'; Another thing that you could do is to ...
    6 By devdojo Databases MySQL PHP WordPress
  • Question

    How to synchronize my mysql cluster with database in droplet

    I have a managed cluster with mysql and a droplet with mysql. Can i sync them. Data will change on the managed cluster. After changing the data, I want to update them in my mysql droplet as well. This can be done?
    Accepted Answer: Hello, I believe that you can only do a manual sync, for example, use the mysqldump command to export your database from your Managed MySQL cluster and then import the .sql dump to your local MySQL instance on your Dr...
    1 By degorych MySQL
  • Question

    SQL requests with double-quotes not working with managed database

    I have a php app that successfully makes SQL requests against MySQL servers. Nevertheless the same app breaks against DO managed database whenever the requests include double-quotes. The following request returns an e...
    Accepted Answer: This is related to the sql_mode used. There's a sqlmode setting, 'ANSIQUOTES' that will make the " an identifier character. e.g. ``` mysql> set session sqlmode = 'ONLYFULLGROUPBY,STRICTTRANSTABLES,NOZEROINDATE,NOZERO...
    1 By shonore MySQL
  • Question

    CPU usage problem by MySQL In a WordPress site

    I have a wordpress site on digital ocean with following configuration ubuntu 18 OS, php7.2-fpm, mariadb, wordpress they are hosted on a 80$ droplet, A 4 core dedicated cpu droplet still my site goes DOWN, on checking ...
    Accepted Answer: Guessing you're using the default Wordpress Droplet "out of the box"? If so, you likely need to do some tuning as I recall it is not configured to run production. Really truly need more information about what plugins...
    3 By theyouth2u MySQL Ubuntu 18.04 WordPress
  • Question

    Can't connect to MySQL instance in managed databases

    Managed MySQL instances were just released yesterday so I decided to spin one up to test it out. I have not been able to connect to the instance using any tool at my disposal. Running OSX 10.14.6 Sequel Pro (nightly b...
    Accepted Answer: <^>Answer:<^> Okay I think I've gotten to the bottom of this. I can't edit my original question but leaving this here in case someone else runs into it. The use of the non-standard port must have been blocked on my ne...
    6 By jhazel DigitalOcean MySQL
  • Question

    Access denied for user 'test'@'localhost' (using password: NO)

    My login attempts fail for a new user account that I have created, and I have spent several hours learning how authentication is handled by MySQL, with no progress. Everything is on the same server: - MySQL 5.7 - phpM...
    Accepted Answer: Hello, I think that you have a typo in your grant privileges query. I've tried your queries and it worked as normal, I just had to adjust the grant privileges query a little bit. Here's what I did: I created a databas...
    2 By CommunityUser1121 MySQL LAMP Stack
  • Question

    How to Tweak MySQL/MariaDB Configuration for Increased Performance and Stability?

    Hi all, Do you have any suggestions on how to make sure that MySQL/MariaDB is configured properly for optimal performance and stability? Thanks!
    Accepted Answer: Hello, What you could do is use the MySQLTuner script (https://github.com/major/MySQLTuner-perl). The MySQLTuner is a script written in Perl and allows you to quickly test your MySQL configuration and it gives you sug...
    1 By devdojo MySQL MariaDB Linux Basics
  • Question

    How can I kill all MySQL sleeping queries?

    Hello, I've noticed that I have a lot of sleeping MySQL processes. I tried killing them one by one but there are too many to do so. Does anyone know if there is an easier way to kill all sleeping processes at once? Th...
    Accepted Answer: Hello, Yes, you can kill all of your sleeping connections with this command: for i in `mysql -e "show processlist" | awk '/Sleep/ {print $1}'` ; do mysql -e "KILL $i;"; done However, this is not a permanent solution...
    2 By devdojo MySQL Linux Basics
  • Question

    Reseting WordPress admin password via the command line (terminal)

    I've seen this question a lot where people have forgotten their WordPress admin password and they don't remember their email in order to use the "Lost Password" feature. The password can be changed/reset from MySQL/Ma...
    Accepted Answer: First you need to identify the table responsible for storing WordPress user accounts. Usually the table that stores all user information is <^>wp_users<^> but you may have different database prefix so you can check yo...
    2 By alexdo WordPress MySQL MariaDB
  • Question

    "Cannot log in to the MySQL server" without code using phpMyAdmin on CentOS7

    I've set up a new CentOS 7 server with Apache, MySQL and phpMyAdmin using Digital Ocean's guides. However, when I try to log in to phpMyAdmin via the browser, I get the message "Cannot log in to the MySQL server" with...
    Accepted Answer: Assuming MySQL 8. ALTER USER root IDENTIFIED WITH mysql_native_password BY 'PASSWORD'; Reason: Some applications are having trouble with <^>caching _sha2 _password<^> method. Above sets the credentials to use the...
    4 By NielsKersic MySQL Databases CentOS
  • Question

    Phpmyadmin or Alternative for PHP7 + Nginx + MySql 5.7 + Ubuntu 16.04

    Hello, I have been reading up on the tutorials and some of the comments on the community pages but I would like to know if there are any better alternatives or any advice to better manage my databases. I use Phpmyadmi...
    Accepted Answer: Phpmyadmin does support PHP 7 and Mysql 5.7. I recommend you to grab latest release from their download page (https://www.phpmyadmin.net/downloads/). Current download link is: https://files.phpmyadmin.net/phpMyAdmin/4...
    2 By Lilap Nginx MySQL PHP Ubuntu 16.04
  • Question

    Why can't I connect to a remote MySQL server from a PHP application, but can connect from mysql-client

    Hi! I'm bamboozled. Here's the setup: * One application server, Ubuntu 18.04 LTS (PHP 7.2, mysql-client) * One database server, Ubuntu 18.04 LTS (mysql-server 5.7) I need to connect to the database from a PHP appl...
    Accepted Answer: Hello, This is quite interesting. As you are able to connect to the database with the mysql command, my guess would be that the password that you are using might not be correct, does your password have any special cha...
    1 By firestormbe352da97c3f50bea MySQL PHP Ubuntu 18.04
  • Question

    mysql remote access

    Hello. I am trying to acces a MySql server from another one with no results. I configured MySql to accept connections remotely. Open firewall at 3306... Inserted new DB remote users, checked their passwords... And n...
    Accepted Answer: Please follow the steps in the link below to get remote access to MySQL - http://www.cyberciti.biz/tips/how-do-i-enable-remote-access-to-mysql-database-server.html
    5 By kimberlysystems MySQL DigitalOcean Ubuntu 16.04
  • Question

    Has anyone solved this error?A PHP Error was encountered Severity: Warning Msg: mysqli:real_connect(): (HY000/2002): Connection refused

    error 1 A PHP Error was encountered Severity: Warning Message: mysqli::real_connect(): (HY000/2002): Connection refused Filename: mysqli/mysqli_driver.php Line Number: 201 error 2 A PHP Error was encountered Severity:...
    Accepted Answer: Hello, It looks like that your server is running out of disk space. You can check that with this command: df -h My guess would be that the server ran out of space and MySQL crashed, that is why you are getting the f...
    1 By thiago20 MySQL PHP Ubuntu
  • Question

    PDO Unknown database

    Getting an error stating that the database is unknown for my user even though it exists and is spelled correctly. I have granted them all permissions on the db, I can access it through the mysql command line in my ser...
    Accepted Answer: @paulie5457 I would speculate that the issue you had was based on the transport method being used. GRANT ALL PRIVILEGES ON *.* TO 'user'@'localhost' WITH GRANT OPTION GRANT ALL PRIVILEGES ON casinoChecklist.* TO '...
    2 By paulie5457 MySQL
  • Question

    Connection pooling is not supported?

    I just want to make sure I read that correctly, pooling is not supported by your managed Mysql instances? https://www.digitalocean.com/docs/databases/mysql/ Does this mean I can only have a single connection from my ...
    Accepted Answer: Hello, Connection pooling is just a specific technique in handling connections, it means that connections are reused rather than created each time a connection is requested. Connection pooling is different from max_c...
    2 By eparry MySQL DigitalOcean Managed MySQL Database
  • Question

    How to enable /wp-admin on subdomains

    Hello, I've created 2 subdomains for my domain.com: dev.domain.com and dev2.domain.com. I created them by copying databases and apache configs. I made the necessary changes in apache configs and enabled them, but did ...
    Accepted Answer: Hello, Yes, indeed you are correct. What you need to do is: Make sure that your wp-config.php files for your new subdomain names are set to the new databases and database users that you've created You need to run a se...
    1 By aleshkjee Apache WordPress MySQL
  • Question

    Remote Connection to MySQL Database

    I am attempting to connect, remotely, to the MySQL server created on my Droplet. However, every time I attempt to connect, I get the error of "Can't connect to MySQL server on 'xxx.xxx.xxx.xxx'(10060)" and I can't fin...
    Accepted Answer: Take a read through Allowing remote access to MySQL (https://www.digitalocean.com/community/tutorials/how-to-troubleshoot-issues-mysql#allowing-remote-access) Start by changing the bind address to 0.0.0.0 instead of j...
    1 By YaBoyBlue MySQL Ubuntu 16.04