zoukankan      html  css  js  c++  java
  • 阿里云安装MySQL5.7

    长话短说:

    step1:下载mysql源安装包:wget http://dev.mysql.com/get/mysql57-community-release-el7-8.noarch.rpm

    step2:安装MySQL源:yum localinstall mysql57-community-release-el7-8.noarch.rpm

    step3:检测是否安装完成:yum repolist enabled | grep "mysql.*-community.*"

    step4:安装mysql:yum install mysql-community-server


    step5:设置开启启动mysql服务:systemctl enable mysqld


    step6:启动MySQL服务:systemctl restart mysqld

    step7:查看MySQL初始密码:grep 'A temporary password' /var/log/mysqld.log

    step8:更改MySQL密码:mysqladmin -u root -p'step7中的就密码' password '您的新密码'

    step9:设置mysql能够远程访问:
    登录进MySQL:mysql -uroot -p密码
    增加一个用户给予访问权限:grant all privileges on *.* to '用户名'@'ip地址' identified by '密码' with grant option; //可将ip改为%%,表示开启所有的

    注意这里需要再阿里云安全组中开放3306端口供公网访问。详情可参考本人博客:https://www.cnblogs.com/funnyboy0128/p/7966531.html

    完成以上步骤,在公网通过工具连接测试即可。

  • 相关阅读:
    jquery queryBuilder过滤插件的使用
    前端跨域问题
    [BZOJ 3326] 数数
    [BZOJ 2427] 软件安装
    [BZOJ 3675] 序列分割
    [Atcoder Grand Contest 004] Tutorial
    [P2831] 愤怒的小鸟
    [Atcoder Regular Contest 065] Tutorial
    [P3806] Divide and Conquer on Tree
    [POJ 1741] Tree
  • 原文地址:https://www.cnblogs.com/funnyboy0128/p/9694936.html
Copyright © 2011-2022 走看看