systemctl automatically restart service
systemctl automatically restart service
References:
- Ensure systemd services restart on failure by Jon Archer
- php-fpm systemd unit with auto-restart by Juan Luis Boya García
- systemd Project Web Page
systemd is a system and service manager that runs as PID 1 and starts the rest of the system and services. The main command used to introspect and control systemd is systemctl.
Basically do the following to let a service restart automatically…
- Edit /lib/systemd/system/name.service file
- Insert “Restart=on-failure” under the section “Service”. Save the file
- Execute the command… systemctl daemon-reload
- Execute the command… systemctl restart name_of_the_service
- (optional) try killing the process now
See https://wiki.archlinux.org/index.php/Systemd#Examples for more examples.
systemctl automatically restart service的更多相关文章
- Job for httpd.service failed because the control process exited with error code. See "systemctl status httpd.service" and "journalctl -xe" for details
thinkphp 在Apache上配置启用伪静态,重启Apache1 restart 竟然失败了,报错 Job for httpd.service failed because the control ...
- Linux 重启网卡失败 Job for network.service failed because the control process exited with error code. See "systemctl status network.service" and "journalctl -xe" for details.
linux下重启网卡使用命令 : service network restart 时报错: [root@slave01 hadoop]# service network restart Startin ...
- Centos7下的systemctl命令与service和chkconfig
博主使用的操作系统是最新的CentOS 7,所以可能和网上一些老的博文有一定出入,那是因为版本更新的原因. 这里写图片描述1 service service命令用于对系统服务进行管理,比如启动(sta ...
- 通过 systemctl 设置自定义 Service
如果要在Linux 上设置一个开机自启,出现问题自动重启,并且有良好日志的程序,比较流行的方法有 supervisord.systemd,除此之外,还有 upstart.runit 等类似的工具. 但 ...
- systemctl enable rc-local.service error
/******************************************************************************* * systemctl enable ...
- 启动Nginx服务失败:Job for nginx.service failed because the control process exited with error code. See "systemctl status nginx.service" and "journalctl -xe" for details.
首次接触nginx,安装完使用命令 service nignx restart 后,出现这个错误,并按照提示给出的命令查看错误详情 systemctl status nginx.service ...
- 对比centos7的systemctl和其他service+chkconfig
syetemctl就是service和chkconfig这两个命令的整合,在CentOS 7就开始被使用了.systemctl 是系统服务管理器命令,它实际上将 service 和 chkconfig ...
- 有关linux中出现systemctl status network.service" and "journalctl -xe" for details.
Job for network.service failed because the control process exited with error code >**[root@mina0 ...
- Linux系统Docker启动问题Job for docker.service failed because the control process exited with error code. See "systemctl status docker.service"
在Liunx中使用Docker, 注: Liunx使用的是在虚拟机下的centOS7版本在刚开始安装Docker时没有任何错误, 但是在后续的docker启动过程中, 出现以下问题: [root@zk ...
随机推荐
- 用Python搞出自己的云词图 | 【带你装起来】
作者:AI算法与图像处理 参考:http://www.sohu.com/a/149657007_236714 云词图简介 什么词云 由词汇组成类似云的彩色图形.“词云”就是对网络文本中出现频率较高的“ ...
- OpenCV3编程入门.知识点
1. 第三部分 掌握 imgproc 组件 第六章 图像处理 6.1.线性滤波: Pdf.P170 Pdf.P171 平滑处理(smoothing)(模糊处理(bluring))-- 使用频率很高 - ...
- JAVA连接Sql-Server教程
一.下载相应的版本的jar文件(官网:https://docs.microsoft.com/zh-cn/sql/connect/jdbc/system-requirements-for-the-jdb ...
- kindeditor 在JSP 中上传文件的配置
1.将kindeditor,jsp,lib目录下的jar文件放到工程的lib目录下 2.将admin-login.jsp,upload_json.jsp,复制到admin的files目录下 3.复制以 ...
- list第二部分
# lst = ['alex',[1,2,3], 'wusir','cgon', "女神", "太白"]# # l1= lst[0]# ## # print(l ...
- ######【Python】【基础知识】【一些未知的知识点】######
在查资料.看书过程中遇到的一些未知的领域.知识点: 1.模仿静态变量 可参考: https://www.runoob.com/python/python-exercise-example41.html ...
- Java:集合类的数据结构
本文源自参考<Think in Java>,多篇博文以及阅读源码的总结 前言 Java的集合其实就是各种基本的数据结构(栈,队列,hash表等),基于业务需求进而演变出的Java特有的数据 ...
- F12的用法
F12在Web测试中十分重要,可以定位元素(UI自动化常用),查看网页响应时间/数据(定位BUG,测单页面响应时间→性能) Elements 点击这个按钮,将光标移至“Google”图片位置并点击,右 ...
- 什么是Sprint?
Sprint指Scrum团队完成一定数量工作所需的短暂.固定的周期.Sprint是Scrum和敏捷的核心,找到正确的Sprint周期将帮助您的敏捷团队交付更高质量的产品. “在Scrum框架中,庞大且 ...
- 怎样查看 MySQL 版本号
1. 在命令行中直接查看版本号 mysql -V 2. 在 mysql --help 中查找与版本相关的信息 mysql --help | grep Ver 3. 在mysql命令行里面查看版本信息 ...