CentOS7安装mysql后无法启动服务,提示Failed to start mysqld.service: Unit not found

首先:需要更新你的yum源,保证yum源最新。

1.安装:

yum install -y mariadb-server

2.启动maria DB服务:

systemctl start mariadb.service

(说明:CentOS 7.x开始,CentOS开始使用systemd服务来代替daemon,原来管理系统启动和管理系统服务的相关命令全部由systemctl命令来代替。)

3.将mariadb服务添加至开机自启动:

systemctl enable mariadb.service

原文地址:https://www.cnblogs.com/nhdlb/p/11569211.html

时间: 2024-08-29 23:08:57

CentOS7安装mysql后无法启动服务,提示Failed to start mysqld.service: Unit not found的相关文章

CentOS7安装mysql后无法启动服务,提示Unit not found

1.最近在centos7上面进行mysql安装完成后,无法启动,报如下错误: Failed to start mysql.server.service: Unit not found. 2.这个是知乎上面找到的无法启动的答案:https://www.zhihu.com/question/41832866 3.解决办法一:使用MariaDB代替mysql数据库(MariaDB数据库管理系统是MySQL的一个分支,主要由开源社区在维护,采用GPL授权许可.开发这个分支的原因之一是:甲骨文公司收购了M

mysqld服务启动失败, Failed to restart mysqld.service: Unit not found.

-bash-4.2# service mysqld restart Redirecting to /bin/systemctl restart mysqld.serviceFailed to restart mysqld.service: Unit not found. 并不存在 mysqld 的服务, -bash-4.2# -bash-4.2# chkconfig -list -list: unknown option -bash-4.2# chkconfig --list Note: Thi

安装MySQL后无法启动服务问题

安装MySQL后服务一直无法启动,在services.msc中启动后报错:1037 检查错误日志文件WIN-01408110001.err: 2014-12-28 00:33:54 2c3c  InnoDB: Error: unable to create temporary file; errno: 22014-12-28 00:33:54 11300 [ERROR] Plugin 'InnoDB' init function returned error.2014-12-28 00:33:5

CentOS7.2安装mariadb-server,解决Failed to start mysqld.service: Unit not found

当输入命令 ~]# systemctl start mysql.service 要启动MySQL数据库是却是这样的提示 Failed to start mysqld.service: Unit not found 解决方法如下: 首先需要安装mariadb-server ~]# mariadb-server 启动服务 ~]# systemctl start mariadb.service 添加到开机启动 ~]# systemctl enable mariadb.service 至此完成! 可以测

CentOS7安装MySQL报错Failed to start mysqld.service: Unit not found解决办法

1 ~]# systemctl start mysql.service 要启动MySQL数据库是却是这样的提示 1 ~]# Failed to start mysqld.service: Unit not found 解决方法如下: 首先需要安装mysql-server 1 ~]# yum install -y mysql-server 启动服务 1 ~]# systemctl start mysqld.service 添加到开机启动 1 ~]# systemctl enable mysqld.

Centos7安装完后,重新启动系统提示Initial setup of CentOS Linux 7 (Core)的解决办法

今天安装完Centos7(CentOS-7-x86_64-DVD-1511.iso)后,重新启动系统提示Initial setup of CentOS Linux 7 (Core): 解决办法: 按提示步骤分别输入"1"."2"."q"."yes"即可.

在centos下启动nginx出现Failed to start nginx.service:unit not found

错误的原因就是没有添加nginx服务,所以启动失败. 解决方法: 1.    在/root/etc/init.d/目录下新建文件,文件名为nginx 或者用命令在根目录下执行:# vim /etc/init.d/nginx    (注意vim旁边有一个空格) 2.    插入以下代码  #!/bin/sh # nginx - this script starts and stops the nginx daemin # # chkconfig: - 85 15 # description: Ng

阿里云安装mysql后查看不到初始密码的解决办法

在阿里云安装mysql后用grep 'A temporary password' /var/log/mysqld.log命令查看MySQL初始密码,毛线都没有看到,然后直接到/var/log/mysqld.log查看mysqld.log文件发现文件是一片空白,一脸懵逼. 解决办法如下: 修改mysql的配置文件,使之可以跳过密码直接用root进入数据库 (1)首先找到mysql的配置文件my.cnf 一般在  /etc/my.cnf (2)cd进 /etc 直接 vim my.cnf 编辑他 (

Windows10安装Mysql后没有服务并且不能启动解决办法

在安装mysql过程中遇到一个问题  install/remove of the Service Denied,这个问题说明自己没有安装和删除的权利,原因是自己在运行cmd过程是没有使用管理员身份运行,解决方法:就是以管理员身份运行cmd,再进行安装 步骤: 1 .打我的电脑C:\Windows\System32\cmd.exe,右击cmd选择以管理员身份运行 2.在dos命令窗口执行cd e:\workspace\mysql-5.6.24-win32\lib 转到bin目录下,执行 mysql