service XXX does not support chkconfig(service报错)
报错 not Service does xxx support chkconfig
2023-09-11 14:14:47 时间
有时候为了方便管理,我们常常喜欢在Linux中将之安装为服务,然后就可以使用服务来管理。
但是当我们运行安装服务的命令时候,假设服务名为 myservice
#chkconfig --add myservice
常常会出现
service myservice does not support chkconfig
我们一般在脚本开头加入下面两句就好了
#gedit /etc/init.d/myservice
添加下面两句到 #!/bin/bash 之后。
# chkconfig: 2345 10 90
# description: myservice ....
其中2345是默认启动级别,级别有0-6共7个级别。
- 等级0表示:表示关机
- 等级1表示:单用户模式
- 等级2表示:无网络连接的多用户命令行模式
- 等级3表示:有网络连接的多用户命令行模式
- 等级4表示:不可用
- 等级5表示:带图形界面的多用户模式
- 等级6表示:重新启动
10是启动优先级,90是停止优先级,优先级范围是0-100,数字越大,优先级越低。
相关文章
- MacOS安装Eclipse后启动报错:The JVM shared library "/Library/Internet Plug-Ins/JavaAppletPlugin.plugin/Contents/Home/bin/../lib/server/libjvm.dylib" does not contain the JNI_CreateJavaVM symbol.
- 在系统下文件上传报错:The temporary upload location [/tmp/tomcat.xxx/work/Tomcat/localhost/ROOT] is not valid
- 使用maven创建工程报错Could not resolve archetype org.apache.maven.archetype
- docker报错Error response from daemon: Get https://registry-1.docker.io/v2/: x509: certificate has expired or is not yet valid
- 当SID=racdb时 当sys system 分别 报错 ORA-27101: shared memory realm does not exist
- 【22】报错ERROR:./depthai_sdk is not a valid editable requirement. It should either be a path to a local
- cordova报错:ANDROID_SDK_ROOT=undefined (recommended setting)
- maven报错解决:执行mvn package时package org.apache.ibatis.annotations does not exist
- Atitit tomcat 启动报错 ZipException: archive is not a ZIP archive. 1.1. ----Should sh lib jar err...1
- Android【报错】This class should be public (android.support.v7.internal.widget.ActionBarView.HomeView)
- 【错误记录】Android 命令行执行 7zr 可执行程序报错 ( Cannot run program “7zr“ : error=13, Permission denied )
- Python numpy 安装以及处理报错 is not a supported wheel on this platform
- 报错:PermissionError: [WinError 5] Access is denied: 'C:Program FilesAnaconda3Libsite-packagespywebhdfs'
- Ubuntu20.04下qt交叉编译报错::15: error: ‘nullptr‘ was not declared in this scope
- Mac解压Linux平台tar包报错:tar: Error reading Truncated input file
- docker pull / docker login 报错 Error response from daemon: Get https://registry-1.docker.io/v2/: x509
- Linux 比较奇怪的docker启动报错,原因暂时不清楚
- 使用wsdl4j调用WebService接口报错:NoSuchMethodError: javax.wsdl.extensions.registerExtensionAttributeType
- 使用jsoup爬取网页数据,报错:org.jsoup.UnsupportedMimeTypeException:
- IntelliJ IDEA 编译报错:java: Compilation failed: internal java compile error
- Mysql报错:Got fatal error 1236 from master when reading data from binary log: ‘Could not find first lo
- 嵌入式Linux开发,Ubuntu下交叉编译报错:error while loading shared libraries: libc++.so: cannot open shared objec
- java开发,编译报错:The package java.awt is not accessible main.java
- Android Studio 2.3报错: Error:Cause: buildToolsVersion is not specified解决