MySQL Server

Installation

Ubuntu

sudo apt-get install mysql-server

Configuring for remote access

  1. Edit the my.cnf file
    In Ubuntu, type

    sudo nano /etc/mysql/my.cnf
  2. Locate the bind-address line and replace it with
    bind-address = <appropriate ip address>

Logging in

Locally

mysql -u -p

Remotely

mysql -u -p -h

User Management

Creating a user

CREATE USER <username>

Setting a user’s password

SET PASSWORD FOR @localhost= PASSWORD(“”);

Removing a user

DROP USER <username>

Granting access to a local user

GRANT ALL PRIVILEGES ON wordpress.* TO [email protected] IDENTIFIED BY ‘password’;

Granting access to a user to access remotely

GRANT ALL PRIVILEGES ON wordpress.* TO ‘wordpressuser’@’%’ IDENTIFIED BY ‘password’;

Database Management

Create a database

CREATE DATABASE <database name>

Opinions about People, Process and Technology

Optimization WordPress Plugins & Solutions by W3 EDGE