zoukankan      html  css  js  c++  java
  • mysql 权限处理

    这是对mysql 业务用户在权限处理中遇到的坑:

      之前在新建mysql 实例后会做两件事

      1、增加业务库

      2、为业务库增加一个与之对应的用户

    create database appdb char set utf8;
    create user app@'%' identified by 'app@1234';
    grant all on appdb.* to app@'%';

    可能存在的问题:

      1、如果实例开启了binlog 日志,业务用户在创建procedure的时候会报以下错误:

    ERROR 1419 (HY000): You do not have the SUPER privilege and binary logging is enabled (you *might* want to use the less safe log_bin_trust_function_creators variable)

      为了解决这面的问题有两个方案可以解决:

      a、设置log_bin_trust_function_creators为on

      b、给业务用户一个super权限,根据提示b解决方案会更好。

    grant super on *.* to app@'%';

    ----

  • 相关阅读:
    async 和 await
    C#中lock死锁
    Attribute特性
    数据库优化
    EF(ORM)
    依赖注入
    面向接口编程
    EF乐观锁与悲观锁
    为什么要使用RESTFUL风格?
    cloudsim 3.0.3下载与安装教程
  • 原文地址:https://www.cnblogs.com/JiangLe/p/7232667.html
Copyright © 2011-2022 走看看