ubuntu 14.04lts 安装mysql

1.配置网络 dns 8.8.8.8,关闭防火墙

2.apt-get install python-mysqldb mysql-server 安装mysql

3.修改/etc/mysql/my.cnf文件

    1)去掉 #bind-address = 127.0.0.1

    2) 添加InnoDB, UTF-8

       default-storage-engine = innodb
       innodb_file_per_table
      collation-server = utf8_general_ci
      init-connect = 'SET NAMES utf8'
      character-set-server = utf8

4.重启数据库 service mysql restart

5.删除匿名用户

   #mysql_install_db

   #mysql_secure_installation

7.GRANT ALL PRIVILEGES ON keystone.* TO 'root'@'%' IDENTIFIED BY '123456';

你可能感兴趣的:(ubuntu 14.04lts 安装mysql)