MySQL学习10_使用chown更改/var/lib所有者导致Starting MySQL. ERROR! The server quit without updating PID file错误

19 篇文章 0 订阅

安装好MySQL后,查看/var/lib/mysql的所有者,发现是mysql:

[root@Master lib]# pwd
/var/lib
[root@Master lib]# ls
alternatives     dnsmasq           mysql           postfix      samba
authconfig       fprint            net-snmp        prelink      stateless
bluetooth        games             NetworkManager  pulse        udev
dav              gdm               ntp             random-seed  udisks
dbus             logrotate.status  PackageKit      readahead    xkb
DeviceKit-power  misc              plymouth        rpm          yum
dhclient         mlocate           polkit-1        rsyslog
[root@Master lib]# ll
total 136
drwxr-xr-x.  2 root    root    4096 Aug 25 01:44 alternatives
drwx------.  3 root    root    4096 Aug 25 01:49 authconfig
drwxr-xr-x.  3 root    root    4096 Aug 25 01:50 bluetooth
drwx------.  2 apache  apache  4096 Aug 13  2013 dav
drwxr-xr-x.  2 root    root    4096 Aug 25 01:50 dbus
drwxr-xr-x.  2 root    root    4096 Sep 23  2011 DeviceKit-power
drwxr-xr-x.  2 root    root    4096 Sep 16 20:19 dhclient
drwxr-xr-x.  2 root    root    4096 Feb 21  2013 dnsmasq
drwxr-xr-x.  2 root    root    4096 Nov 22  2013 fprint
drwxr-xr-x.  2 root    root    4096 Sep 23  2011 games
drwxrwx--T. 10 gdm     gdm     4096 Jan 17 17:33 gdm
-rw-r--r--.  1 root    root     500 Jan 18 03:22 logrotate.status
drwxr-xr-x.  2 root    root    4096 Aug 25 01:50 misc
drwxr-x---.  2 root    slocate 4096 Oct 10  2012 mlocate
<span style="color:#ff0000;">drwxr-xr-x.  5 mysql   mysql   4096 Jan 19 00:29 mysql</span>
drwxr-xr-x.  2 root    root    4096 Nov 22  2013 net-snmp
drwxr-xr-x.  2 root    root    4096 Jan 19 00:33 NetworkManager
drwxr-xr-x.  2 ntp     ntp     4096 Nov 23  2013 ntp
drwxr-xr-x.  2 root    root    4096 Jan 19 00:08 PackageKit
drwxr-xr-x.  2 root    root    4096 Aug 25 01:42 plymouth
drwx------.  3 root    root    4096 Sep 19  2013 polkit-1
drwx------.  2 postfix root    4096 Aug 25 01:50 postfix
drwxr-xr-x.  2 root    root    4096 Aug 24 18:08 prelink
drwx------.  2 pulse   pulse   4096 Jul 11  2012 pulse
-rw-------.  1 root    root     512 Jan 17 17:32 random-seed
drwxr-xr-x.  2 root    root    4096 Nov 23  2013 readahead
drwxr-xr-x.  2 root    root    4096 Jan 17 18:09 rpm
drwx------.  2 root    root    4096 Nov 22  2013 rsyslog
drwxr-xr-x.  5 root    root    4096 Aug 25 01:44 samba
drwxr-xr-x.  4 root    root    4096 Aug 25 01:42 stateless
drwxr-xr-x.  3 root    root    4096 Aug 25 01:42 udev
drwx------.  2 root    root    4096 Jan 18 17:00 udisks
drwxr-xr-x.  2 root    root    4096 Jan 17 17:33 xkb
drwxr-xr-x.  6 root    root    4096 Sep 17 18:41 yum
[root@Master lib]# 

所以,想对它的所有者进行更改,改为hadoop:hadoop,

但是,更改后,出现下面的错误:

[root@Master etc]# service mysql start
Starting MySQL. ERROR! The server quit without updating PID file (/var/lib/mysql/Master.pid).


重新改正后,错误消失。


  • 0
    点赞
  • 0
    收藏
    觉得还不错? 一键收藏
  • 0
    评论
评论
添加红包

请填写红包祝福语或标题

红包个数最小为10个

红包金额最低5元

当前余额3.43前往充值 >
需支付:10.00
成就一亿技术人!
领取后你会自动成为博主和红包主的粉丝 规则
hope_wisdom
发出的红包
实付
使用余额支付
点击重新获取
扫码支付
钱包余额 0

抵扣说明:

1.余额是钱包充值的虚拟货币,按照1:1的比例进行支付金额的抵扣。
2.余额无法直接购买下载,可以购买VIP、付费专栏及课程。

余额充值