一、Mac OS X的升级或其他原因可能会导致MySQL启动或开机自动运行时

在MySQL操作面板上会提示Warning:The /usr/local/mysql/data directory is not owned by the 'mysql' or '_mysql' ”,

这应该是某种情况下导致/usr/local/mysql/data的宿主发生了改变,

只需要运行“sudo chown -R mysql /usr/local/mysql/data”即可

mac 下面运行 “sudo chown -R  _mysql:wheel  /usr/local/mysql/data

-------------------------------------------------

    -c 显示更改的部分的信息

    -f 忽略错误信息

    -h 修复符号链接

    -R 处理指定目录以及其子目录下的所有文件

    -v 显示详细的处理信息

-------------------------------------------------

二、what is wheel

    

在Linux中wheel组就类似于一个管理员的组。
通常在LUNIX下,即使我们有系统管理员root的权限,也不推荐用root用户登录。一般情况下用普通用户登录就可以了,在需要root权限执行一些操作时,再su登录成为root用户。但是,任何人只要知道了root的密码,就都可以通过su命令来登录为root用户--这无疑为系统带来了安全隐患。所以,将普通用户加入到wheel组,被加入的这个普通用户就成了管理员组内的用户,但如果不对一些相关的配置文件进行配置,这个管理员组内的用户与普通用户也没什么区别--就像警察下班后,没有带枪、穿这便衣和普通人(用户)一样,虽然他的的确确是警察。
根据应用的实例不同应用wheel组的方法也不同。这里对于服务器来说,我们希望的是剥夺被加入到wheel组用户以外的普通用户通过su命令来登录为root的机会(只有属于wheel组的用户才可以用su登录为root)。这样就进一步增强了系统的安全性。

三、查看用户组

cat /etc/group | grep [group_name]

启动mysql 失败,“Warning:The /usr/local/mysql/data directory is not owned by the 'mysql' or '_mysql' ”的更多相关文章

  1. 启动 mysql 失败 Warning:The /usr/local/mysql/data directory is not owned by the 'mysql' or '_mysql'

    Warning:The /usr/local/mysql/data directory is not owned by the 'mysql' or '_mysql' 这应该是某种情况下导致/usr/ ...

  2. Warning:The /usr/local/mysql/data directory is not owned by the 'mysql' or '_mysql'

    Mac OS X的升级或其他原因可能会导致MySQL启动或开机自动运行时   在MySQL操作面板上会提示“Warning:The /usr/local/mysql/data directory is ...

  3. Mac下启动MySQL出现错误“the /usr/local/mysql/data directory is not owned by the 'mysql' or '_mysql' user”解决

    错误如下: Warring the /usr/local/mysql/data directory is not owned by the 'mysql' or '_mysql' user 这应该是某 ...

  4. Warning the user/local/mysql/data directory is not owned by the mysql user

    sudo chown -RL root:mysql /usr/local/mysql sudo chown -RL mysql:mysql /usr/local/mysql/data sudo /us ...

  5. mysql: symbol lookup error: /usr/local/lib/libreadline.so.6: undefined symbol: UP

    Error Symptom: when you run $mysql -u root -p command in the linux you get an error message ” mysql: ...

  6. ERROR 2002 (HY000): Can't connect to local MySQL server through socket '/usr/local/mysql/tmp/mysql.sock'

    查看是否开启服务 # ps -ef | grep mysql root 5605 5457 0 11:45 pts/2 00:00:00 grep mysql 查看my.cnf # cat /etc/ ...

  7. mysql 初始化报错 /usr/local/mysql/bin/mysqld:error while loading shared libraries :libaio.so.1

    安装mysql在初始化的时候,出现/usr/local/mysql/bin/mysqld:error while loading shared libraries:libaio.so.1 :canno ...

  8. linux下编译安装php5.6出现 configure: error: Cannot find MySQL header files under /usr/local/mysql.

    #yum install gcc gcc-c++ libxml2 libxml2-devel libjpeg-devel libpng-devel freetype-devel openssl-dev ...

  9. 解决MAC下PHP连接MYSQL错误Warning: mysql_connect(): No such file or directory in conn.php

    今天在mac上用php去连接mysql数据库,出现了 mac PHP Warning:  mysql_connect(): [2002] No such file... 详细例如以下所看到的: Dir ...

随机推荐

  1. HIVE大数据出现倾斜怎么办

      hive在跑数据时经常会出现数据倾斜的情况,使的作业经常reduce完成在99%后一直卡住,最后的1%花了几个小时都没跑完,通过YARN的管理界面配合日志,可以清楚其中的具体原因,这种情况就很可能 ...

  2. 一个linux命令(6/13):traceroute命令

    通过traceroute 我们可以知道信息从你的计算机到互联网另一端的主机是走的什么路径.当然每次数据包由某一同样的出发点(source)到达某一同样的目的地(destination)走的路径可能会不 ...

  3. Nginx 启动脚本

    Nginx 启动脚本 1.vim /etc/init.d/nginx #!/bin/bash # chkconfig: - 30 21 # description: http service. # S ...

  4. SpringBoot AOP 与 IoC

    Spring的核心就是AOP与IoC,想要学习SpringBoot,首先得理解这些概念: AOP(Aspect Oriented Programming 面向切面编程) IoC(Inversion o ...

  5. springboot--配置文件加载顺序

    -file:./config(内部配置) -file:./ (内部配置) -classpath:/config (外部配置) -classpath:/ (外部配置) 运维: spring -jar s ...

  6. maven项目包结构

    groupId填写公司名称,如com.enn.ennewartifactId填写项目名称webapps如父工程: <groupId>com.enn.ennew</groupId> ...

  7. SMM+maven下的log4j配置打印sql

    1加入依赖包 <!--LOG4日志 start --> <dependency> <groupId>org.slf4j</groupId> <ar ...

  8. Android -- junit测试框架,logcat获取log信息

    1. 相关概念 白盒测试: 知道程序源代码. 根据测试的粒度分为不同的类型   方法测试 function test         单元测试 unit test                 集成 ...

  9. Spring -- spring整合struts2

    1. 概述 spring和struts整合: 1.创建web程序 2.引入struts2类库. 3.创建HelloWorldAction package cn.itcast.struts2.actio ...

  10. MyEclipse安装aptana插件, 8.5之前版本 和 之后版本, MyEclipse10安装aptana

    MyEclipse8.5安装aptana插件说明: 1.在myeclipse的安装目录下,有个common文件夹,建一个myplugIns,此目录下建aptana_update_024747目录 2. ...