At 09:36 AM 9/23/2016, you wrote:>On 2016-09-22 18:07, david wrote:
> > Folks
> >
> > I'm having problems installing Mariadb in Centos 7.
> >
> >
> > Here's what I did:
> >
> > 0) Become root
> > 1) Make sure that mariadb and mysql are NOT installed.
> > 2) Delete residual libs
> > rm -rf /var/lib/mysq*
> > 3) yum install -y mariadb-server
> > installed mariadb-5.5.50-1.el7_2.x86_64 from the Centos
'updates'
> > repository
> > 4) systemctl start mariadb
> > 5) systemctl status mariadb
> >
> > All works well until step 5, where I get the result:
> >
> >
> >
> > # systemctl status mariadb
> > ? mariadb.service - MariaDB database server
> > Loaded: loaded (/usr/lib/systemd/system/mariadb.service; enabled;
vendor
> > preset: disabled)
> > Active: failed (Result: exit-code) since Thu 2016-09-22 17:46:38
PDT;
> > 4min 3s ago
> > Main PID: 16261 (code=exited, status=1/FAILURE)
> >
> > Sep 22 17:46:37 goat.xxx.com mysqld_safe[16261]: /usr/bin/mysqld_safe:
line
> > 139: /var/log/mysqld.log: Permission denied
> > Sep 22 17:46:37 goat.xxx.com mysqld_safe[16261]: /usr/bin/mysqld_safe:
line
> > 183: /var/log/mysqld.log: Permission denied
> > Sep 22 17:46:37 goat.xxx.com mysqld_safe[16261]: touch: cannot touch
> > `/var/log/mysqld.log': Permission denied
> > Sep 22 17:46:37 goat.xxx.com mysqld_safe[16261]: chown: cannot access
> > `/var/log/mysqld.log': No such file or directory
> > Sep 22 17:46:37 goat.xxx.com mysqld_safe[16261]: chmod: cannot access
> > `/var/log/mysqld.log': No such file or directory
> > Sep 22 17:46:37 goat.xxx.com systemd[1]: mariadb.service: main process
> > exited, code=exited, status=1/FAILURE
> > Sep 22 17:46:38 goat.xxx.com systemd[1]: mariadb.service: control
process
> > exited, code=exited status=1
> > Sep 22 17:46:38 goat.xxx.com systemd[1]: Failed to start MariaDB
database
> > server.
> > Sep 22 17:46:38 goat.xxx.com systemd[1]: Unit mariadb.service
> entered failed
> > state.
> > Sep 22 17:46:38 goat.xxx.com systemd[1]: mariadb.service failed.
> > Hint: Some lines were ellipsized, use -l to show in full.
> > [root at goat ~]#
> >
> > My environment is a Centos 7 installation running as a VM inside
> Vmware, and
> > is not a production system. It is updated nightly.
> >
> > When I examined the files alluded to,
> >
> > /var/log/mysqld.log
> > does not exist
> > but
> > /var/log/mariadb/mariadb.log
> > exists and is empty.
>
>Hi David,
>
>What do these commands show?
>
> ls -lF /var/log/mysqld.log
> ls -lZ /var/log/mysqld.log
> getenforce
>
>Best regards,
>--
>Charles Polisher
Charles
As the original note pointed out, /var/log/mysqld.log does not exist,
as shown by these two commands:
[root at goat ~]# ls -1F /var/log/mysqld.log
ls: cannot access /var/log/mysqld.log: No such file or directory
[root at goat ~]# ls -1Z /var/log/mysqld.log
ls: cannot access /var/log/mysqld.log: No such file or directory
[root at goat ~]#
HOWEVER, /var/log/mariadb/mariadb.log does exist and is empty
[root at goat ~]# ls -l /var/log/mariadb/*
-rw-r----- 1 mysql mysql 0 Sep 23 10:08 /var/log/mariadb/mariadb.log
David
PS: I forgot to say that SELinux is disabled:
[root at goat ~]# getenforce
Disabled
[root at goat ~]#