-bash-4.2# service mysqld restart
Redirecting to /bin/systemctl restart mysqld.service
Failed 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: This output shows SysV services only and does not include native
systemd services. SysV configuration data might be overridden by native
systemd configuration. If you want to list systemd services use 'systemctl list-unit-files'.
To see services enabled on particular target use
'systemctl list-dependencies [target]'. aegis :off :off :on :on :on :on :off
agentwatch :off :off :on :on :on :on :off
iprdump :off :off :on :on :on :on :off
iprinit :off :off :on :on :on :on :off
iprupdate :off :off :on :on :on :on :off
jexec :off :on :on :on :on :on :off
mysql.server :off :off :on :on :on :on :off
netconsole :off :off :off :off :off :off :off
network :off :off :on :on :on :on :off

可见,服务名不是mysqld 而是 mysql.server

于是:

-bash-4.2# service mysql.server restart
Shutting down MySQL....[ OK ]
Starting MySQL.[ OK ]

mysqld服务启动失败, Failed to restart mysqld.service: Unit not found.的更多相关文章

  1. Failed to restart ssh.service: Unit not found.

    环境 操作系统:CentOS 7 问题 重启ssh服务,启动报错:Failed to restart ssh.service: Unit not found. 操作步骤 1. 编辑sshd_confi ...

  2. docker报错:Failed to restart docker.service: Unit not found.

    前言:我之前安装好docker了,但是关机重启后,发现docker就没了 报错:Failed to restart docker.service: Unit not found.   解决方法: 1. ...

  3. Redirecting to /bin/systemctl restart mysql. service Failed to restart mysql.service: Unit not found.

    使用如下命令操作mysql即可: systemctl restart mysqld.service systemctl start mysqld.service systemctl stop mysq ...

  4. 最新cenos执行service httpd restart 报错Failed to restart httpd.service: Unit not found.

    原来是需要将Apache注册到Linux服务里面啊!注册Apache到Linux服务在Linux下用源代码方式编译安装完Apache后,启动关闭Apache可以通过如下命令实现: /usr/local ...

  5. 【解决】Failed to restart network.service: Unit network.service not found.

    问题:使用systemctl restart network 或 service network restart 命令重启网卡失败. 分析:原因其实也很简单,命令用错了,造成了找不到相应的网卡服务. ...

  6. Failed to restart docker.service: Unit not found 镜像加速

    解决方案 以前的安装残留 重新安装 find / -name "docker*" centos8 添加软件源信息 yum-config-manager --add-repo htt ...

  7. CentOS 7 防火墙 出现Failed to start iptables.service: Unit iptables.service failed to load

    错误信息如下: [root]# service iptables start Redirecting to /bin/systemctl start iptables.service Failed t ...

  8. Linux_异常_03_Failed to restart iptables.service: Unit not found.

    启动防火墙时出现: Failed to restart iptables.service: Unit not found. 解决方案: 1.https://stackoverflow.com/ques ...

  9. CentOS 7下MySQL服务启动失败的解决思路

    今天,启动MySQL服务器失败,如下所示: [root@spark01 ~]# /etc/init.d/mysqld start Starting mysqld (via systemctl): Jo ...

随机推荐

  1. 并行计算——理想的PRAM模型

    PRAM(Parallel Random Access Machine)模型是多指令流多数据流(MIMD)并行机中的一种具有共享存储的模型.它假设有一个无限大容量的共享存储器,并且有多个功能相同的处理 ...

  2. HMM(隐马尔科夫模型)与分词、词性标注、命名实体识别

    转载自 http://www.cnblogs.com/skyme/p/4651331.html HMM(隐马尔可夫模型)是用来描述隐含未知参数的统计模型,举一个经典的例子:一个东京的朋友每天根据天气{ ...

  3. 瑞萨S5D9实现UART环形缓冲

    队列的常见两种形式,普通队列和环形队列: 普通队列: 环形队列: 当有大量数据的时候,我们不能存储所有的数据,那么计算机处理数据的时候,只能先处理先来的,那么处理完后呢,就会把数据释放掉,再处理下一个 ...

  4. sql 语句收集

    SELECT type as 'plan cache store', buckets_count  FROM sys.dm_os_memory_cache_hash_tables WHERE type ...

  5. Laravel 输出最后一条sql

    $queries = DB::getQueryLog(); $last_query = end($queries); print_r( $last_query);

  6. pytest.10.使用fixture参数化测试预期结果

    From: http://www.testclass.net/pytest/test_api_with_expected_result/ 背景 接上一节v2ex网站的查看论坛节点信息的api. 我们在 ...

  7. 【springBoot】之配置文件application

    springboot使用一个全局的配置文件application.properties或者是application.yml,放在在src/main/recesources下或者在类路径下的/confi ...

  8. 学习笔记之TensorFlow

    TensorFlow https://www.tensorflow.org/ An open source machine learning framework for everyone Tensor ...

  9. BBC曝光:每天10000步,竟是商家的营销骗局

    原文: https://new.qq.com/cmsn/20190112A14JRD00 导语:日本人平均每天行走3500-5000步,于是计步器公司就想,既然这么个数值大部分人都能达到,如果把平均值 ...

  10. Access、SQLServer、Oracle常见SQL语句应用区别

    Access.SQLServer.Oracle常见SQL语句应用区别 关劲松 PMP 如果要兼容Access.SQL Server.Oracle三个数据库版本:我们在编写SQL语句的过程中,尽量使用一 ...