{"id":51329,"date":"2024-10-08T17:44:15","date_gmt":"2024-10-08T09:44:15","guid":{"rendered":"https:\/\/server.hk\/cnblog\/51329\/"},"modified":"2024-11-14T10:43:45","modified_gmt":"2024-11-14T02:43:45","slug":"ubuntu-14-04-%e5%ae%89%e8%a3%9d-chkconfig-%e6%9c%8d%e5%8b%99%e7%ae%a1%e7%90%86%e7%a8%8b%e5%ba%8f","status":"publish","type":"post","link":"https:\/\/server.hk\/cnblog\/51329\/","title":{"rendered":"Ubuntu 14.04 \u5b89\u88dd chkconfig \u670d\u52d9\u7ba1\u7406\u7a0b\u5e8f"},"content":{"rendered":"<h1 id=\"ubuntu-14-04-%e5%ae%89%e8%a3%9d-chkconfig-%e6%9c%8d%e5%8b%99%e7%ae%a1%e7%90%86%e7%a8%8b%e5%ba%8f-tFWjoKQiam\">Ubuntu 14.04 \u5b89\u88dd chkconfig \u670d\u52d9\u7ba1\u7406\u7a0b\u5e8f<\/h1>\n<p>\u5728\u4f3a\u670d\u5668\u7ba1\u7406\u4e2d\uff0c\u670d\u52d9\u7684\u555f\u52d5\u548c\u505c\u6b62\u662f\u65e5\u5e38\u7dad\u8b77\u7684\u91cd\u8981\u90e8\u5206\u3002Ubuntu 14.04 \u4f5c\u70ba\u4e00\u500b\u6d41\u884c\u7684 Linux \u767c\u884c\u7248\uff0c\u63d0\u4f9b\u4e86\u591a\u7a2e\u5de5\u5177\u4f86\u7ba1\u7406\u7cfb\u7d71\u670d\u52d9\u3002\u5176\u4e2d\uff0cchkconfig \u662f\u4e00\u500b\u5e38\u7528\u7684\u670d\u52d9\u7ba1\u7406\u5de5\u5177\uff0c\u96d6\u7136\u5b83\u5728\u67d0\u4e9b Linux \u767c\u884c\u7248\u4e2d\u66f4\u70ba\u5e38\u898b\uff0c\u4f46\u5728 Ubuntu \u4e2d\u4e5f\u53ef\u4ee5\u5b89\u88dd\u548c\u4f7f\u7528\u3002\u672c\u6587\u5c07\u4ecb\u7d39\u5982\u4f55\u5728 Ubuntu 14.04 \u4e0a\u5b89\u88dd chkconfig \u670d\u52d9\u7ba1\u7406\u7a0b\u5e8f\u3002<\/p>\n<h2 id=\"chkconfig-%e7%9a%84%e5%8a%9f%e8%83%bd-tFWjoKQiam\">chkconfig \u7684\u529f\u80fd<\/h2>\n<p>chkconfig \u662f\u4e00\u500b\u7528\u65bc\u7ba1\u7406\u7cfb\u7d71\u670d\u52d9\u7684\u547d\u4ee4\u884c\u5de5\u5177\uff0c\u4e3b\u8981\u7528\u65bc\u555f\u7528\u6216\u7981\u7528\u7cfb\u7d71\u555f\u52d5\u6642\u81ea\u52d5\u555f\u52d5\u7684\u670d\u52d9\u3002\u5b83\u7684\u4e3b\u8981\u529f\u80fd\u5305\u62ec\uff1a<\/p>\n<ul>\n<li>\u67e5\u770b\u670d\u52d9\u7684\u555f\u52d5\u72c0\u614b<\/li>\n<li>\u555f\u7528\u6216\u7981\u7528\u670d\u52d9<\/li>\n<li>\u5217\u51fa\u6240\u6709\u53ef\u7528\u7684\u670d\u52d9\u53ca\u5176\u72c0\u614b<\/li>\n<\/ul>\n<h2 id=\"%e5%ae%89%e8%a3%9d-chkconfig-tFWjoKQiam\">\u5b89\u88dd chkconfig<\/h2>\n<p>\u5728 Ubuntu 14.04 \u4e2d\uff0cchkconfig \u4e26\u4e0d\u9810\u88dd\uff0c\u56e0\u6b64\u9700\u8981\u901a\u904e\u4ee5\u4e0b\u6b65\u9a5f\u9032\u884c\u5b89\u88dd\uff1a<\/p>\n<h3 id=\"%e6%ad%a5%e9%a9%9f-1-%e6%9b%b4%e6%96%b0%e7%b3%bb%e7%b5%b1-tFWjoKQiam\">\u6b65\u9a5f 1: \u66f4\u65b0\u7cfb\u7d71<\/h3>\n<pre><code>sudo apt-get update<\/code><\/pre>\n<p>\u9996\u5148\uff0c\u78ba\u4fdd\u4f60\u7684\u7cfb\u7d71\u662f\u6700\u65b0\u7684\u3002\u4f7f\u7528\u4e0a\u8ff0\u547d\u4ee4\u66f4\u65b0\u53ef\u7528\u7684\u8edf\u4ef6\u5305\u5217\u8868\u3002<\/p>\n<h3 id=\"%e6%ad%a5%e9%a9%9f-2-%e5%ae%89%e8%a3%9d-chkconfig-tFWjoKQiam\">\u6b65\u9a5f 2: \u5b89\u88dd chkconfig<\/h3>\n<pre><code>sudo apt-get install chkconfig<\/code><\/pre>\n<p>\u63a5\u4e0b\u4f86\uff0c\u4f7f\u7528 apt-get \u5b89\u88dd chkconfig\u3002\u9019\u500b\u547d\u4ee4\u6703\u81ea\u52d5\u4e0b\u8f09\u4e26\u5b89\u88dd chkconfig \u53ca\u5176\u4f9d\u8cf4\u9805\u3002<\/p>\n<h2 id=\"%e4%bd%bf%e7%94%a8-chkconfig-%e7%ae%a1%e7%90%86%e6%9c%8d%e5%8b%99-tFWjoKQiam\">\u4f7f\u7528 chkconfig \u7ba1\u7406\u670d\u52d9<\/h2>\n<p>\u5b89\u88dd\u5b8c\u6210\u5f8c\uff0c\u4f60\u53ef\u4ee5\u4f7f\u7528 chkconfig \u4f86\u7ba1\u7406\u670d\u52d9\u3002\u4ee5\u4e0b\u662f\u4e00\u4e9b\u5e38\u7528\u7684\u547d\u4ee4\uff1a<\/p>\n<h3 id=\"%e6%9f%a5%e7%9c%8b%e6%9c%8d%e5%8b%99%e7%8b%80%e6%85%8b-tFWjoKQiam\">\u67e5\u770b\u670d\u52d9\u72c0\u614b<\/h3>\n<pre><code>chkconfig --list<\/code><\/pre>\n<p>\u9019\u500b\u547d\u4ee4\u6703\u5217\u51fa\u6240\u6709\u53ef\u7528\u7684\u670d\u52d9\u53ca\u5176\u7576\u524d\u7684\u555f\u52d5\u72c0\u614b\u3002<\/p>\n<h3 id=\"%e5%95%9f%e7%94%a8%e6%9c%8d%e5%8b%99-tFWjoKQiam\">\u555f\u7528\u670d\u52d9<\/h3>\n<pre><code>sudo chkconfig  on<\/code><\/pre>\n<p>\u5c07 <code>&lt;service_name&gt;<\/code> \u66ff\u63db\u70ba\u4f60\u60f3\u8981\u555f\u7528\u7684\u670d\u52d9\u540d\u7a31\u3002\u4f8b\u5982\uff0c\u8981\u555f\u7528 Apache \u670d\u52d9\uff0c\u53ef\u4ee5\u4f7f\u7528\uff1a<\/p>\n<pre><code>sudo chkconfig apache2 on<\/code><\/pre>\n<h3 id=\"%e7%a6%81%e7%94%a8%e6%9c%8d%e5%8b%99-tFWjoKQiam\">\u7981\u7528\u670d\u52d9<\/h3>\n<pre><code>sudo chkconfig  off<\/code><\/pre>\n<p>\u540c\u6a23\u5730\uff0c\u4f7f\u7528\u4e0a\u8ff0\u547d\u4ee4\u53ef\u4ee5\u7981\u7528\u6307\u5b9a\u7684\u670d\u52d9\u3002\u4f8b\u5982\uff0c\u8981\u7981\u7528 Apache \u670d\u52d9\uff0c\u53ef\u4ee5\u4f7f\u7528\uff1a<\/p>\n<pre><code>sudo chkconfig apache2 off<\/code><\/pre>\n<h2 id=\"%e6%b3%a8%e6%84%8f%e4%ba%8b%e9%a0%85-tFWjoKQiam\">\u6ce8\u610f\u4e8b\u9805<\/h2>\n<p>\u96d6\u7136 chkconfig \u662f\u4e00\u500b\u5f37\u5927\u7684\u5de5\u5177\uff0c\u4f46\u5728\u4f7f\u7528\u6642\u9700\u8981\u8b39\u614e\u3002\u8aa4\u64cd\u4f5c\u53ef\u80fd\u6703\u5c0e\u81f4\u7cfb\u7d71\u7121\u6cd5\u6b63\u5e38\u555f\u52d5\u67d0\u4e9b\u95dc\u9375\u670d\u52d9\u3002\u56e0\u6b64\uff0c\u5728\u9032\u884c\u4efb\u4f55\u66f4\u6539\u4e4b\u524d\uff0c\u5efa\u8b70\u5148\u5099\u4efd\u7cfb\u7d71\u914d\u7f6e\u3002<\/p>\n<h2 id=\"%e7%b8%bd%e7%b5%90-tFWjoKQiam\">\u7e3d\u7d50<\/h2>\n<p>\u5728 Ubuntu 14.04 \u4e0a\u5b89\u88dd chkconfig \u670d\u52d9\u7ba1\u7406\u7a0b\u5e8f\u662f\u4e00\u500b\u7c21\u55ae\u7684\u904e\u7a0b\uff0c\u80fd\u5920\u5e6b\u52a9\u7528\u6236\u66f4\u6709\u6548\u5730\u7ba1\u7406\u7cfb\u7d71\u670d\u52d9\u3002\u901a\u904e\u4f7f\u7528 chkconfig\uff0c\u7cfb\u7d71\u7ba1\u7406\u54e1\u53ef\u4ee5\u8f15\u9b06\u5730\u555f\u7528\u6216\u7981\u7528\u670d\u52d9\uff0c\u5f9e\u800c\u63d0\u9ad8\u4f3a\u670d\u5668\u7684\u7a69\u5b9a\u6027\u548c\u5b89\u5168\u6027\u3002\u5982\u679c\u4f60\u6b63\u5728\u5c0b\u627e\u9ad8\u6548\u7684 <a href=\"https:\/\/server.hk\">VPS<\/a> \u89e3\u6c7a\u65b9\u6848\uff0cServer.HK \u63d0\u4f9b\u591a\u7a2e\u9078\u64c7\uff0c\u6eff\u8db3\u4e0d\u540c\u9700\u6c42\u7684\u4f3a\u670d\u5668\u7ba1\u7406\u3002\u4e86\u89e3\u66f4\u591a\u4fe1\u606f\uff0c\u8acb\u8a2a\u554f\u6211\u5011\u7684\u7db2\u7ad9\u3002<\/p>\n","protected":false},"excerpt":{"rendered":"<p>Learn how to install and configure chkconfig service management on Ubuntu 14.04 for efficient service control and management.<\/p>\n","protected":false},"author":1,"featured_media":0,"comment_status":"closed","ping_status":"","sticky":false,"template":"","format":"standard","meta":{"footnotes":""},"categories":[4924],"tags":[],"class_list":["post-51329","post","type-post","status-publish","format-standard","hentry","category-setup-tutorials"],"_links":{"self":[{"href":"https:\/\/server.hk\/cnblog\/wp-json\/wp\/v2\/posts\/51329","targetHints":{"allow":["GET"]}}],"collection":[{"href":"https:\/\/server.hk\/cnblog\/wp-json\/wp\/v2\/posts"}],"about":[{"href":"https:\/\/server.hk\/cnblog\/wp-json\/wp\/v2\/types\/post"}],"author":[{"embeddable":true,"href":"https:\/\/server.hk\/cnblog\/wp-json\/wp\/v2\/users\/1"}],"replies":[{"embeddable":true,"href":"https:\/\/server.hk\/cnblog\/wp-json\/wp\/v2\/comments?post=51329"}],"version-history":[{"count":1,"href":"https:\/\/server.hk\/cnblog\/wp-json\/wp\/v2\/posts\/51329\/revisions"}],"predecessor-version":[{"id":51330,"href":"https:\/\/server.hk\/cnblog\/wp-json\/wp\/v2\/posts\/51329\/revisions\/51330"}],"wp:attachment":[{"href":"https:\/\/server.hk\/cnblog\/wp-json\/wp\/v2\/media?parent=51329"}],"wp:term":[{"taxonomy":"category","embeddable":true,"href":"https:\/\/server.hk\/cnblog\/wp-json\/wp\/v2\/categories?post=51329"},{"taxonomy":"post_tag","embeddable":true,"href":"https:\/\/server.hk\/cnblog\/wp-json\/wp\/v2\/tags?post=51329"}],"curies":[{"name":"wp","href":"https:\/\/api.w.org\/{rel}","templated":true}]}}