zoukankan      html  css  js  c++  java
  • mysql


    cat <<EOF

    *************************************
    * 即 将 进 行 的 操 作 *
    * 4. mysql -- mysql 安装 *
    *************************************

    EOF


    cd /root
    wget https://repo.mysql.com//mysql57-community-release-el6-11.noarch.rpm
    yum -y install mysql57-community-release-el6-11.noarch.rpm
    yum -y install mysql-community-server
    service mysqld start
    grep 'temporary password' /var/log/mysqld.log|awk '{print $11}'

    echo "请手动更改密码,并创建数据库"
    cat <<EOF
    ~]# grep 'temporary password' /var/log/mysqld.log
    2017-05-01T20:40:30.385752Z 1 [Note] A temporary password is generated for root@localhost: 70sgfd23
    ~]# mysql -u root -p #==>复制临时密码
    Enter password:
    mysql> SHOW DATABASES; #==>必须修改密码
    ERROR 1820 (HY000): You must reset your password using ALTER USER statement before executing this statement.
    mysql> ALTER USER 'root'@'localhost' IDENTIFIED BY 'your_passwd';
    Query OK, 0 rows affected (0.00 sec)
    mysql> FLUSH PRIVILEGES;
    mysql> exit
    ~]# service mysqld restart
    EOF

  • 相关阅读:
    普通平衡树(treap与splay模板)
    NOIP2009T4 靶形数独
    单调队列模板
    NOIP2010引水入城
    数差
    NOIP2016DAY2T1 组合数问题
    NOIP2016 D2T3 愤怒的小鸟
    NOIP双栈排序
    膜拜
    斐波那契数列
  • 原文地址:https://www.cnblogs.com/i-honey/p/8646805.html
Copyright © 2011-2022 走看看