{"id":40,"date":"2019-02-03T19:00:18","date_gmt":"2019-02-03T11:00:18","guid":{"rendered":""},"modified":"2020-10-08T13:38:02","modified_gmt":"2020-10-08T05:38:02","slug":"%e5%88%86%e4%ba%ab%ef%bc%9a%e3%80%8alinux%e5%b0%b1%e8%af%a5%e8%bf%99%e4%b9%88%e5%ad%a6-%e3%80%8b%e7%ac%ac4%e7%ab%a0-vim%e7%bc%96%e8%be%91%e5%99%a8%e4%b8%8eshell%e5%91%bd%e4%bb%a4%e8%84%9a%e6%9c%ac","status":"publish","type":"post","link":"https:\/\/www.fatesky.com\/?p=40","title":{"rendered":"\u5206\u4eab\uff1a\u300aLinux\u5c31\u8be5\u8fd9\u4e48\u5b66 \u300b\u7b2c4\u7ae0 Vim\u7f16\u8f91\u5668\u4e0eShell\u547d\u4ee4\u811a\u672c"},"content":{"rendered":"<h2 style=\"white-space: normal; margin: 8px 0px; padding: 2px 0px; font-size: 1.3em; border-left-width: 4px; border-left-style: solid; border-left-color: rgb(252, 46, 46); text-indent: 16px; color: rgb(74, 74, 74); font-family: &quot;Microsoft YaHei&quot;; line-height: 25px; background-color: rgb(255, 255, 255);\">\u63a8\u8350\u7b80\u8ff0\uff1a<\/h2>\n<p style=\"margin-top: 0px; margin-bottom: 10px; white-space: normal; box-sizing: border-box; line-height: 23px; color: rgb(61, 68, 80); font-family: &quot;Microsoft Yahei&quot;, Helvetica, Arial, sans-serif; font-size: 12px; text-indent: 2em; background-color: rgb(255, 255, 255);\"><span style=\"text-indent: 1em;\">\u8bf4\u5230Linux\u7cfb\u7edf\u4ece01\u5e74\u5f00\u59cb\u6211\u5c31\u4e00\u76f4\u5728\u63a5\u89e6\uff0c\u76f4\u523003\u5e74\u8fd8\u662f04\u5e74\u7684\u65f6\u5019\u5728\u60e0\u5dde\u65b0\u534e\u4e66\u5e97\u4e70\u4e86\u4e00\u672c\u300a<\/span><span style=\"font-size: 13.3333px; text-indent: 13.3333px;\">\u9e1f\u54e5\u7684\u79c1\u623f\u83dc<\/span><span style=\"text-indent: 1em;\">\u300b\uff0c\u81ea\u6b64\u6211\u7684LINUX\u8d77\u6b65\u624d\u7b97\u662f\u771f\u6b63\u7684\u5f00\u59cb\uff0c\u4eca\u5929\u5ffd\u7136\u5728\u7f51\u4e0a\u53d1\u73b0\u4e86\u4e00\u672c\u300aLinux\u5c31\u8be5\u8fd9\u4e48\u5b66\u300b<\/span><span style=\"font-size: 13.3333px; text-indent: 13.3333px;\">\u5fcd\u4e0d\u4f4f\u770b\u4e86\u4e8c\u7ae0\uff0c<\/span><span style=\"text-indent: 1em;\">\u89c9\u5f97\u8fd9\u672c\u4e66\u5728\u73b0\u65f6\u7684Linux\u73af\u5883\u4e0b\u66f4\u9002\u5408\u65b0\u624b\u5165\u95e8\uff0c\u4e0d\u7531\u5f3a\u70c8\u63a8\u8350\u4e00\u4e0b\uff0c\u5e76\u4e14\u81ea\u5df1\u4e5f\u51b3\u5b9a\u4e09\u6708\u4efd\u91cc\u6bcf\u5929\u5fc5\u770b\u4e00\u7ae0\u8282\uff0c\u5728\u770b\u7684\u540c\u65f6\u4e5f\u8f6c\u8f7d\u5728\u535a\u5ba2\u91cc\u3002<\/span><span style=\"text-indent: 1em; color: #FF0000;\">\u6e29\u6545\u77e5\u65b0\uff0c\u5b66\u4e60\u8fd9\u4e2a\u4e8b\u60c5\u6c38\u8fdc\u5e94\u8be5\u5728\u8def\u4e0a\uff01<\/span><\/p>\n<p style=\"margin-top: 0px; margin-bottom: 10px; white-space: normal; box-sizing: border-box; line-height: 23px; color: rgb(61, 68, 80); font-family: &quot;Microsoft Yahei&quot;, Helvetica, Arial, sans-serif; font-size: 12px; text-indent: 2em; background-color: rgb(255, 255, 255);\"><span style=\"text-indent: 1em; color: #FF0000;\"><br \/><\/span><\/p>\n<p style=\"margin-top: 0px; margin-bottom: 10px; white-space: normal; box-sizing: border-box; line-height: 23px; color: rgb(61, 68, 80); font-family: &quot;Microsoft Yahei&quot;, Helvetica, Arial, sans-serif; font-size: 12px; text-indent: 2em; background-color: rgb(255, 255, 255);\"><span style=\"text-indent: 1em; color: #FF0000;\"><br \/><\/span><\/p>\n<p style=\"margin-top: 0px; margin-bottom: 10px; white-space: normal; box-sizing: border-box; line-height: 23px; text-indent: 1em; color: rgb(61, 68, 80); font-family: &quot;Microsoft Yahei&quot;, Helvetica, Arial, sans-serif; font-size: 12px; background-color: rgb(255, 255, 255);\"><div class='fancybox-wrapper lazyload-container-unload' data-fancybox='post-images' href='https:\/\/ss2.bdstatic.com\/70cFvnSh_Q1YnxGkpoWK1HF6hhy\/it\/u=246279818,2032250538&#038;fm=26&#038;gp=0.jpg'><img class=\"lazyload lazyload-style-1\" src=\"data:image\/svg+xml;base64,PCEtLUFyZ29uTG9hZGluZy0tPgo8c3ZnIHdpZHRoPSIxIiBoZWlnaHQ9IjEiIHhtbG5zPSJodHRwOi8vd3d3LnczLm9yZy8yMDAwL3N2ZyIgc3Ryb2tlPSIjZmZmZmZmMDAiPjxnPjwvZz4KPC9zdmc+\"  decoding=\"async\" data-original=\"https:\/\/ss2.bdstatic.com\/70cFvnSh_Q1YnxGkpoWK1HF6hhy\/it\/u=246279818,2032250538&#038;fm=26&#038;gp=0.jpg\" src=\"data:image\/png;base64,iVBORw0KGgoAAAANSUhEUgAAAAEAAAABCAYAAAAfFcSJAAAAAXNSR0IArs4c6QAAAARnQU1BAACxjwv8YQUAAAAJcEhZcwAADsQAAA7EAZUrDhsAAAANSURBVBhXYzh8+PB\/AAffA0nNPuCLAAAAAElFTkSuQmCC\"\/><\/div><\/p>\n<h2 style=\"white-space: normal; margin: 8px 0px; padding: 2px 0px; font-size: 1.3em; border-left-width: 4px; border-left-style: solid; border-left-color: rgb(252, 46, 46); text-indent: 16px; color: rgb(74, 74, 74); font-family: &quot;Microsoft YaHei&quot;; line-height: 25px; background-color: rgb(255, 255, 255);\">\u672c\u4e66\u76f8\u6bd4\u300a\u9e1f\u54e5\u7684linux\u79c1\u623f\u83dc\u300b\u6709\u4ec0\u4e48\u4f18\u52bf\uff1f<\/h2>\n<p style=\"margin-top: 0px; margin-bottom: 0px; white-space: normal; padding: 5px 0px 14px; text-indent: 2em; color: rgb(74, 74, 74); font-family: &quot;Microsoft YaHei&quot;; font-size: 15px; line-height: 25px; background-color: rgb(255, 255, 255);\">\u5766\u767d\u6765\u8bb2\uff0c\u9e1f\u54e5\u7684linux\u79c1\u623f\u83dc\u4e5f\u662f\u6211\u7684linux\u5165\u95e8\u4e66\u7c4d\uff0c\u6211\u7edd\u5bf9\u7684\u8ba4\u53ef\u9e1f\u54e5\u4e3a\u8fd9\u672c\u4e66\u7684\u4ed8\u51fa\uff0c\u5176\u4e66\u53d1\u884c\u91cf\u5de8\u5927\uff0c\u966a\u4f34\u4e86\u4e00\u4ee3\u7684\u8fd0\u7ef4\u4eba\u5458\uff0c\u751a\u81f3\u88ab\u5c01\u4e3a\u201clinux\u5165\u95e8\u795e\u4e66\u201d\uff0c\u6e10\u6e10\u7684\u4ece\u4e00\u672clinux\u6280\u672f\u4e66\u7c4d\uff0c\u4e0a\u5347\u81f3\u7cbe\u795e\u7684\u9ad8\u5ea6\uff0c\u4e0d\u5141\u8bb8\u518d\u6709\u4e00\u70b9\u53cd\u9a73\u4e4b\u58f0\uff0c\u4f46\u601d\u7d22\u518d\u4e09\uff0c\u8fd8\u662f\u51b3\u5b9a\u9610\u660e\u6211\u7684\u89c2\u70b9\uff0c\u4e0e\u521d\u5b66\u8005\u5206\u4eab\u4e0b\u8fd9\u4e0d\u540c\u7684\u770b\u6cd5\uff1a<br style=\"margin: 0px; padding: 0px;\"\/>\u9996\u5148\u9e1f\u54e5\u5728\u5f00\u7bc7\u5373\u63d0\u5230\u4e86\u5199\u4e66\u7684\u7f18\u7531\u662f\u56e0\u4e3a\u8bb0\u6027\u4e0d\u597d\uff0c\u6240\u4ee5\u60f3\u5199\u51fa\u4e00\u672c\u80fd\u591f\u653e\u5728\u6848\u5934\u7684\u5907\u5fd8\u5f55\uff0c\u5bf9\u4e66\u7c4d\u7684\u5185\u5bb9\u81ea\u7136\u5c31\u6ca1\u6709\u4e86\u592a\u591a\u7684\u7b5b\u9009\uff0c\u53cd\u800c\u4e00\u518d\u7684\u6269\u5927\u77e5\u8bc6\u8303\u56f4\uff0c\u6700\u7ec8\u5199\u51fa\u7684\u4e24\u672c\u4e66\u539a\u5ea6\u8db3\u8db3\u8d85\u8fc7\u5341\u5398\u7c73\uff0c\u6562\u95ee\u8fd9\u79cd\u201c\u5907\u5fd8\u5f55\u5f0f\u7684\u5165\u95e8\u4e66\u7c4d\u201d\u771f\u7684\u9002\u5408\u65b0\u624b\u6765\u8bfb\uff1f\u6211\u8ba4\u4e3a\u4e66\u7c4d\u65e2\u7136\u53d1\u884c\u4e86\uff0c\u5c31\u4e0d\u80fd\u518d\u662f\u4e2a\u5907\u5fd8\u5f55\uff0c\u800c\u5e94\u8be5\u662f\u901a\u8fc7\u4f5c\u8005\u7684\u7ecf\u9a8c\u5c06\u77e5\u8bc6\u4e0d\u65ad\u63d0\u70bc\uff0c\u771f\u6b63\u8ba9\u6367\u8d77\u4e66\u7684\u8bfb\u8005\u770b\u5b8c\u6709\u6536\u83b7\u624d\u53ef\u4ee5\u3002<\/p>\n<p style=\"margin-top: 0px; margin-bottom: 0px; white-space: normal; padding: 5px 0px 14px; text-indent: 2em; color: rgb(74, 74, 74); font-family: &quot;Microsoft YaHei&quot;; font-size: 15px; line-height: 25px; background-color: rgb(255, 255, 255);\">\u5176\u6b21\u662f\u9e1f\u54e5\u7684linux\u79c1\u623f\u83dc\u7684\u4e66\u7c4d\u66f4\u65b0\u5468\u671f\u8fc7\u957f\uff0c2014\u5e74\u672b\u65f6RHEL7\u4e0eCentos7\u5c31\u5df2\u7ecf\u516c\u5e03\uff0c\u7ecf\u8fc7\u4e86\u4e00\u5e74\u591a\u7684\u8fed\u4ee3\uff0c\u5df2\u7ecf\u5f88\u7a33\u5b9a\u5e76\u88ab\u5e7f\u6cdb\u4f7f\u7528\u4e86\uff0c\u5982\u679c\u5185\u5bb9\u6ca1\u6709\u5b9a\u671f\u66f4\u65b0\uff0c\u4f7f\u5f97\u6280\u672f\u8131\u79bb\u4e86\u751f\u4ea7\u73af\u5883\uff0c\u8fd8\u600e\u4e48\u79f0\u4f5c\u662f\u771f\u6b63\u5b9e\u7528\u7684linux\u6280\u672f\uff1f\u800c\u4e14\u9e1f\u54e5\u7684linux\u79c1\u623f\u83dc\u7f3a\u5c11\u4e86\u5bf9\u65b0\u624b\u975e\u5e38\u91cd\u8981\u7684\u7b54\u7591\u4e0e\u5e2e\u52a9\uff0c\u5982\u679c\u9047\u5230\u4e86\u5b9e\u9a8c\u51fa\u9519\uff0c\u6216\u8005\u6709\u77e5\u8bc6\u70b9\u609f\u4e0d\u900f\uff0c\u8fd9\u4e9b\u90fd\u53ef\u80fd\u8ba9\u521d\u5b66\u8005\u4e27\u5931\u6389\u5bf9linux\u6280\u672f\u7684\u5174\u8da3\u3002<\/p>\n<h2 style=\"white-space: normal; margin: 8px 0px; padding: 2px 0px; font-size: 1.3em; border-left-width: 4px; border-left-style: solid; border-left-color: rgb(252, 46, 46); text-indent: 16px; color: rgb(74, 74, 74); font-family: &quot;Microsoft YaHei&quot;; line-height: 25px; background-color: rgb(255, 255, 255);\">RHEL\u4e0eCentos\u7cfb\u7edf\u533a\u522b\uff1a<\/h2>\n<p style=\"margin-top: 0px; margin-bottom: 0px; white-space: normal; padding: 5px 0px 14px; text-indent: 2em; color: rgb(74, 74, 74); font-family: &quot;Microsoft YaHei&quot;; font-size: 15px; line-height: 25px; background-color: rgb(255, 255, 255);\">\u73b0\u5728\u56fd\u5185\u7684\u5f88\u591a\u4e66\u7c4d\u662f\u4ee5Centos\u7cfb\u7edf\u4e3a\u5e73\u53f0\u7f16\u5199\u7684\uff0c\u5f53\u7136\u4f5c\u8005\u5927\u591a\u4f1a\u5217\u51fa\u6765\u8bf8\u591a\u7684\u7406\u7531\uff0c\u4f46\u5f88\u591a\u90fd\u662f\u4ee5\u8bb9\u4f20\u8bb9\u7684\u6b6a\u66f2\u9053\u7406\uff0c\u6839\u672c\u6ca1\u6709\u5256\u6790\u5230RedHat\u516c\u53f8\u7684\u8fd0\u4f5c\u65b9\u6cd5\u548cCentos\u7cfb\u7edf\u7684\u672c\u8d28\uff0cCentos\u7cfb\u7edf\u662f\u901a\u8fc7\u5c06RHEL\u7cfb\u7edf\u91ca\u653e\u51fa\u7684\u6e90\u4ee3\u7801\u4e8c\u6b21\u7f16\u8bd1\u7684Linux\u7cfb\u7edf\u4e4b\u4e00\uff0c\u547d\u4ee4\u64cd\u4f5c\u548c\u670d\u52a1\u914d\u7f6e\u65b9\u6cd5\u81ea\u7136\u90fd\u662f\u5b8c\u5168\u76f8\u540c\uff0c\u53bb\u6389\u4e86\u5f88\u591a\u7ea2\u5e3d\u6536\u8d39\u7684\u670d\u52a1\u5957\u4ef6\u529f\u80fd\uff0c\u5e76\u4e14\u4e0d\u63d0\u4f9b\u4efb\u4f55\u5f62\u5f0f\u7684\u6280\u672f\u652f\u6301\uff0c\u90a3\u4e48\u9009\u62e9\u7684\u7406\u7531\u53ea\u6709\u4e00\u4e2a\u2014\u2014\u514d\u8d39\uff01\uff0c\u5f53\u201c\u9ad8\u624b\u4eec\u201d\u5927\u4e3e\u514d\u8d39\u3001\u5f00\u6e90\u3001\u6b63\u4e49\u7684\u65d7\u5e1c\u6765\u5ba3\u626cCentos\u7cfb\u7edf\u7684\u65f6\u5019\uff0c\u8bf8\u4e0d\u77e5Centos\u7cfb\u7edf\u5176\u5b9e\u65e9\u57282014\u5e74\u521d\u5c31\u5df2\u7ecf\u88ab\u7ea2\u5e3d\u516c\u53f8\u6536\u8d2d\uff0c\u53ea\u662f\u6218\u7565\u6027\u7684\u514d\u8d39\u800c\u5df2\uff0c\u800c\u6839\u636eGnu GPL\u8bb8\u53ef\u534f\u8bae\uff0c\u6211\u4eec\u540c\u6837\u4e5f\u53ef\u4ee5\u514d\u8d39\u4f7f\u7528RHEL\u7cfb\u7edf\uff0c\u751a\u81f3\u662f\u4fee\u6539\u4ee3\u7801\u540e\u521b\u5efa\u51fa\u884d\u751f\u4ea7\u54c1\uff0c\u81ea\u7531\u7a0b\u5ea6\u662f\u6ca1\u6709\u4efb\u4f55\u7684\u5dee\u5f02\uff0c\u66f4\u65e0\u5173\u9053\u5fb7\u95ee\u9898\u3002<\/p>\n<p style=\"margin-top: 0px; margin-bottom: 0px; white-space: normal; padding: 5px 0px 14px; text-indent: 2em; color: rgb(74, 74, 74); font-family: &quot;Microsoft YaHei&quot;; font-size: 15px; line-height: 25px; background-color: rgb(255, 255, 255);\">\u60a8\u6b63\u5728\u9605\u8bfb\u7684\u8fd9\u672c\u300aLinux\u5c31\u8be5\u8fd9\u4e48\u5b66\u300b\u4fbf\u662f\u57fa\u4e8e\u6700\u65b0\u7684RHEL7\u7cfb\u7edf\u7f16\u5199\u7684\uff0c\u77e5\u8bc6\u53ca\u5b9e\u9a8c\u5b8c\u5168\u7684\u76f8\u901a\u4e8eCentos,fedora\u7b49\u7cfb\u7edf\uff0c\u56e0\u6b64\u5f53\u60a8\u5b66\u4e60\u5b8c\u672c\u5957\u8bfe\u7a0b\u540e\uff0c\u5373\u4fbf\u516c\u53f8\u5185\u7684\u751f\u4ea7\u73af\u5883\u662fCentos\u7cfb\u7edf\u4e5f\u4e00\u6837\u6ca1\u6709\u4efb\u4f55\u95ee\u9898\uff0c\u5e76\u4e14\u672c\u4e66\u914d\u5957\u8d44\u6599\u4e2d\u7684iso\u955c\u50cf\u4e0e\u7ea2\u5e3dRHCSA\u53caRHCE\u8003\u8bd5\u7cfb\u7edf\u4e00\u81f4\uff0c\u5c24\u5176\u9002\u5408\u51c6\u5907\u8003\u53d6\u7ea2\u5e3d\u8ba4\u8bc1\u7684\u5b66\u5458\u3002<\/p>\n<p style=\"margin-top: 0px; margin-bottom: 10px; text-indent: 0em; white-space: normal; box-sizing: border-box; line-height: 23px; color: rgb(61, 68, 80); font-family: &quot;Microsoft Yahei&quot;, Helvetica, Arial, sans-serif; font-size: 12px; background-color: rgb(255, 255, 255);\"><span style=\"font-size: 18px; font-family: \u5fae\u8f6f\u96c5\u9ed1, &quot;Microsoft YaHei&quot;;\"><\/span><\/p>\n<h2 style=\"white-space: normal; margin: 8px 0px; padding: 2px 0px; font-size: 1.3em; border-left-width: 4px; border-left-style: solid; border-left-color: rgb(252, 46, 46); text-indent: 16px; color: rgb(74, 74, 74); font-family: &quot;Microsoft YaHei&quot;; line-height: 25px; background-color: rgb(255, 255, 255);\"><strong style=\"color: rgb(61, 68, 80); font-family: \u5fae\u8f6f\u96c5\u9ed1, &quot;Microsoft YaHei&quot;; font-size: 18px; line-height: 23px;\">\u6b63\u6587\u5f00\u59cb\uff1a<\/strong><\/h2>\n<p><strong style=\"color: rgb(61, 68, 80); font-family: \u5fae\u8f6f\u96c5\u9ed1, &quot;Microsoft YaHei&quot;; font-size: 18px; line-height: 23px;\"><br \/><\/strong><\/p>\n<p style=\"white-space: normal;\">\u7b2c4\u7ae0 Vim\u7f16\u8f91\u5668\u4e0eShell\u547d\u4ee4\u811a\u672c\u3002<\/p>\n<p style=\"white-space: normal;\"><span style=\"color: #00B050;\"><\/span><\/p>\n<p style=\"white-space: normal;\"><span style=\"color: #92D050;\"><\/span><\/p>\n<p><span style=\"color: #92D050;\">4.1 Vim\u6587\u672c\u7f16\u8f91\u5668<\/span><\/p>\n<p><span style=\"color: #92D050;\">4.1.1 \u7f16\u5199\u7b80\u5355\u6587\u6863<\/span><\/p>\n<p><span style=\"color: #92D050;\">4.1.2 \u914d\u7f6e\u4e3b\u673a\u540d\u79f0<\/span><\/p>\n<p><span style=\"color: #92D050;\">4.1.3 \u914d\u7f6e\u7f51\u5361\u4fe1\u606f<\/span><\/p>\n<p><span style=\"color: #92D050;\">4.1.4 \u914d\u7f6eYum\u4ed3\u5e93<\/span><\/p>\n<p><span style=\"color: #92D050;\">4.2 \u7f16\u5199Shell\u811a\u672c<\/span><\/p>\n<p><span style=\"color: #92D050;\">4.2.1 \u7f16\u5199\u7b80\u5355\u7684\u811a\u672c<\/span><\/p>\n<p><span style=\"color: #92D050;\">4.2.2 \u63a5\u6536\u7528\u6237\u7684\u53c2\u6570<\/span><\/p>\n<p><span style=\"color: #92D050;\">4.2.3 \u5224\u65ad\u7528\u6237\u7684\u53c2\u6570<\/span><\/p>\n<p><span style=\"color: #92D050;\">4.3 \u6d41\u7a0b\u63a7\u5236\u8bed\u53e5<\/span><\/p>\n<p><span style=\"color: #92D050;\">4.3.1 if\u6761\u4ef6\u6d4b\u8bd5\u8bed\u53e5<\/span><\/p>\n<p><span style=\"color: #92D050;\">4.3.2 for\u6761\u4ef6\u5faa\u73af\u8bed\u53e5<\/span><\/p>\n<p><span style=\"color: #92D050;\">4.3.3 while\u6761\u4ef6\u5faa\u73af\u8bed\u53e5<\/span><\/p>\n<p><span style=\"color: #92D050;\">4.3.4 case\u6761\u4ef6\u6d4b\u8bd5\u8bed\u53e5<\/span><\/p>\n<p><span style=\"color: #92D050;\">4.4 \u8ba1\u5212\u4efb\u52a1\u670d\u52a1\u7a0b\u5e8f<\/span><\/p>\n<p style=\"white-space: normal;\"><span style=\"color: #92D050;\"><\/span><\/p>\n<h5 style=\"box-sizing: border-box; font-family: &quot;Helvetica Neue&quot;, Helvetica, Arial, sans-serif; font-weight: 100; line-height: 1.1; margin-top: 10px; margin-bottom: 10px; font-size: 14px; color: rgb(61, 68, 80); white-space: normal; background-color: rgb(255, 255, 255);\"><span id=\"41_Vim\" style=\"box-sizing: border-box;\"><span style=\"box-sizing: border-box; color: #008000;\"><strong style=\"box-sizing: border-box;\">4.1 Vim\u6587\u672c\u7f16\u8f91\u5668<\/strong><\/span><\/span><\/h5>\n<p style=\"box-sizing: border-box; margin-top: 0px; margin-bottom: 10px; line-height: 23px; text-indent: 1em; text-align: justify; color: rgb(61, 68, 80); font-family: &quot;Microsoft Yahei&quot;, Helvetica, Arial, sans-serif; font-size: 12px; white-space: normal; background-color: rgb(255, 255, 255);\">\u6bcf\u5f53\u5728\u8bb2\u8bfe\u65f6\u9047\u5230\u9700\u8981\u8ba9\u5b66\u751f\u8bb0\u4f4f\u7684\u77e5\u8bc6\u70b9\u65f6\uff0c\u4e3a\u4e86\u80fd\u8ba9\u4ed6\u4eec\u6253\u8d77\u7cbe\u795e\u6765\uff0c\u6211\u90fd\u4f1a\u7a81\u7136\u63d0\u9ad8\u55d3\u95e8\uff0c\u56e0\u6b64\u6709\u53e5\u8bdd\u4ed6\u4eec\u8bb0\u5f97\u5c24\u5176\u6df1\u523b\uff1a\u201c\u5728<a href=\"https:\/\/www.linuxprobe.com\/\" title=\"linux\u7cfb\u7edf\" target=\"_blank\" style=\"box-sizing: border-box; color: rgb(210, 50, 45); text-decoration: none;\" rel=\"noopener noreferrer\">Linux\u7cfb\u7edf<\/a>\u4e2d\u4e00\u5207\u90fd\u662f\u6587\u4ef6\uff0c\u800c\u914d\u7f6e\u4e00\u4e2a\u670d\u52a1\u5c31\u662f\u5728\u4fee\u6539\u5176\u914d\u7f6e\u6587\u4ef6\u7684\u53c2\u6570\u201d\u3002\u800c\u4e14\u5728\u65e5\u5e38\u5de5\u4f5c\u4e2d\u5927\u5bb6\u4e5f\u80af\u5b9a\u514d\u4e0d\u4e86\u8981\u7f16\u5199\u6587\u6863\uff0c\u8fd9\u4e9b\u5de5\u4f5c\u90fd\u662f\u901a\u8fc7\u6587\u672c\u7f16\u8f91\u5668\u6765\u5b8c\u6210\u7684\u3002<a href=\"https:\/\/www.linuxprobe.com\/\" title=\"\u5218\u9044\" target=\"_blank\" style=\"box-sizing: border-box; color: rgb(210, 50, 45); text-decoration: none;\" rel=\"noopener noreferrer\">\u5218\u9044<\/a>\u8001\u5e08\u5199\u4f5c\u672c\u4e66\u7684\u76ee\u7684\u662f\u8ba9\u8bfb\u8005\u5207\u5b9e\u638c\u63e1Linux\u7cfb\u7edf\u7684\u8fd0\u7ef4\u65b9\u6cd5\uff0c\u800c\u4e0d\u662f\u4ec5\u4ec5\u505c\u7559\u5728\u201c\u4f1a\u7528\u67d0\u4e2a\u64cd\u4f5c\u7cfb\u7edf\u201d\u7684\u5c42\u9762\u4e0a\uff0c\u6240\u4ee5\u6211\u4eec\u8fd9\u91cc\u9009\u62e9\u4f7f\u7528Vim\u6587\u672c\u7f16\u8f91\u5668\uff0c\u5b83\u9ed8\u8ba4\u4f1a\u5b89\u88c5\u5728\u5f53\u524d\u6240\u6709\u7684Linux\u64cd\u4f5c\u7cfb\u7edf\u4e0a\uff0c\u662f\u4e00\u6b3e\u8d85\u68d2\u7684\u6587\u672c\u7f16\u8f91\u5668\u3002<\/p>\n<p style=\"box-sizing: border-box; margin-top: 0px; margin-bottom: 10px; line-height: 23px; text-indent: 1em; text-align: justify; color: rgb(61, 68, 80); font-family: &quot;Microsoft Yahei&quot;, Helvetica, Arial, sans-serif; font-size: 12px; white-space: normal; background-color: rgb(255, 255, 255);\">Vim\u4e4b\u6240\u4ee5\u80fd\u5f97\u5230\u5e7f\u5927\u5382\u5546\u4e0e\u7528\u6237\u7684\u8ba4\u53ef\uff0c\u539f\u56e0\u5728\u4e8eVim\u7f16\u8f91\u5668\u4e2d\u8bbe\u7f6e\u4e86\u4e09\u79cd\u6a21\u5f0f\u2014\u547d\u4ee4\u6a21\u5f0f\u3001\u672b\u884c\u6a21\u5f0f\u548c\u7f16\u8f91\u6a21\u5f0f\uff0c\u6bcf\u79cd\u6a21\u5f0f\u5206\u522b\u53c8\u652f\u6301\u591a\u79cd\u4e0d\u540c\u7684\u547d\u4ee4\u5feb\u6377\u952e\uff0c\u8fd9\u5927\u5927\u63d0\u9ad8\u4e86\u5de5\u4f5c\u6548\u7387\uff0c\u800c\u4e14\u7528\u6237\u5728\u4e60\u60ef\u4e4b\u540e\u4e5f\u4f1a\u89c9\u5f97\u76f8\u5f53\u987a\u624b\u3002\u8981\u60f3\u9ad8\u6548\u7387\u5730\u64cd\u4f5c\u6587\u672c\uff0c\u5c31\u5fc5\u987b\u5148\u641e\u6e05\u8fd9\u4e09\u79cd\u6a21\u5f0f\u7684\u64cd\u4f5c\u533a\u522b\u4ee5\u53ca\u6a21\u5f0f\u4e4b\u95f4\u7684\u5207\u6362\u65b9\u6cd5\uff08\u89c1\u56fe4-1\uff09\u3002<\/p>\n<blockquote style=\"box-sizing: border-box; padding: 10px 20px; margin: 0px 0px 20px; border-left-width: 5px; border-left-style: solid; border-color: rgba(0, 0, 0, 0.14902); color: rgb(61, 68, 80); font-family: &quot;Microsoft Yahei&quot;, Helvetica, Arial, sans-serif; font-size: 12px; line-height: 17.1429px; white-space: normal; background-color: rgb(255, 255, 255);\">\n<p style=\"box-sizing: border-box; margin-top: 0px; margin-bottom: 10px; font-size: 14px; line-height: 23px; text-indent: 1em; text-align: justify;\">\u547d\u4ee4\u6a21\u5f0f\uff1a\u63a7\u5236\u5149\u6807\u79fb\u52a8\uff0c\u53ef\u5bf9\u6587\u672c\u8fdb\u884c\u590d\u5236\u3001\u7c98\u8d34\u3001\u5220\u9664\u548c\u67e5\u627e\u7b49\u5de5\u4f5c\u3002<\/p>\n<p style=\"box-sizing: border-box; margin-top: 0px; margin-bottom: 10px; font-size: 14px; line-height: 23px; text-indent: 1em; text-align: justify;\">\u8f93\u5165\u6a21\u5f0f\uff1a\u6b63\u5e38\u7684\u6587\u672c\u5f55\u5165\u3002<\/p>\n<p style=\"box-sizing: border-box; margin-top: 0px; margin-bottom: 0px; font-size: 14px; line-height: 23px; text-indent: 1em; text-align: justify;\">\u672b\u884c\u6a21\u5f0f\uff1a\u4fdd\u5b58\u6216\u9000\u51fa\u6587\u6863\uff0c\u4ee5\u53ca\u8bbe\u7f6e\u7f16\u8f91\u73af\u5883\u3002<\/p>\n<\/blockquote>\n<p style=\"box-sizing: border-box; margin-top: 0px; margin-bottom: 10px; line-height: 23px; text-indent: 1em; text-align: justify; color: rgb(61, 68, 80); font-family: &quot;Microsoft Yahei&quot;, Helvetica, Arial, sans-serif; font-size: 12px; white-space: normal; background-color: rgb(255, 255, 255);\"><div class='fancybox-wrapper lazyload-container-unload' data-fancybox='post-images' href='https:\/\/www.linuxprobe.com\/wp-content\/uploads\/2015\/03\/vim%E4%B8%8D%E5%90%8C%E6%A8%A1%E5%BC%8F%E9%97%B4%E7%9A%84%E5%88%87%E6%8D%A2.png'><img class=\"lazyload lazyload-style-1\" src=\"data:image\/svg+xml;base64,PCEtLUFyZ29uTG9hZGluZy0tPgo8c3ZnIHdpZHRoPSIxIiBoZWlnaHQ9IjEiIHhtbG5zPSJodHRwOi8vd3d3LnczLm9yZy8yMDAwL3N2ZyIgc3Ryb2tlPSIjZmZmZmZmMDAiPjxnPjwvZz4KPC9zdmc+\"  loading=\"lazy\" decoding=\"async\" class=\"size-full wp-image-607 aligncenter\" data-original=\"https:\/\/www.linuxprobe.com\/wp-content\/uploads\/2015\/03\/vim%E4%B8%8D%E5%90%8C%E6%A8%A1%E5%BC%8F%E9%97%B4%E7%9A%84%E5%88%87%E6%8D%A2.png\" src=\"data:image\/png;base64,iVBORw0KGgoAAAANSUhEUgAAAAEAAAABCAYAAAAfFcSJAAAAAXNSR0IArs4c6QAAAARnQU1BAACxjwv8YQUAAAAJcEhZcwAADsQAAA7EAZUrDhsAAAANSURBVBhXYzh8+PB\/AAffA0nNPuCLAAAAAElFTkSuQmCC\" alt=\"\u7b2c4\u7ae0 Vim\u7f16\u8f91\u5668\u4e0eShell\u547d\u4ee4\u811a\u672c\u3002\u7b2c4\u7ae0 Vim\u7f16\u8f91\u5668\u4e0eShell\u547d\u4ee4\u811a\u672c\u3002\" width=\"492\" height=\"195\"  sizes=\"auto, (max-width: 492px) 100vw, 492px\" title=\"\u7b2c4\u7ae0 Vim\u7f16\u8f91\u5668\u4e0eShell\u547d\u4ee4\u811a\u672c\u3002\u7b2c4\u7ae0 Vim\u7f16\u8f91\u5668\u4e0eShell\u547d\u4ee4\u811a\u672c\u3002\" style=\"box-sizing: border-box; max-width: 100%; border-radius: 4px; vertical-align: middle; height: auto; margin: 10px auto; display: block;\"\/><\/div><\/p>\n<p style=\"box-sizing: border-box; margin-top: 0px; margin-bottom: 10px; line-height: 23px; text-indent: 1em; text-align: center; color: rgb(61, 68, 80); font-family: &quot;Microsoft Yahei&quot;, Helvetica, Arial, sans-serif; font-size: 12px; white-space: normal; background-color: rgb(255, 255, 255);\">\u56fe4-1&nbsp; Vim\u7f16\u8f91\u5668\u6a21\u5f0f\u7684\u5207\u6362\u65b9\u6cd5<\/p>\n<p style=\"box-sizing: border-box; margin-top: 0px; margin-bottom: 10px; line-height: 23px; text-indent: 1em; text-align: justify; color: rgb(61, 68, 80); font-family: &quot;Microsoft Yahei&quot;, Helvetica, Arial, sans-serif; font-size: 12px; white-space: normal; background-color: rgb(255, 255, 255);\">\u5728\u6bcf\u6b21\u8fd0\u884cVim\u7f16\u8f91\u5668\u65f6\uff0c\u9ed8\u8ba4\u8fdb\u5165\u547d\u4ee4\u6a21\u5f0f\uff0c\u6b64\u65f6\u9700\u8981\u5148\u5207\u6362\u5230\u8f93\u5165\u6a21\u5f0f\u540e\u518d\u8fdb\u884c\u6587\u6863\u7f16\u5199\u5de5\u4f5c\uff0c\u800c\u6bcf\u6b21\u5728\u7f16\u5199\u5b8c\u6587\u6863\u540e\u9700\u8981\u5148\u8fd4\u56de\u547d\u4ee4\u6a21\u5f0f\uff0c\u7136\u540e\u518d\u8fdb\u5165\u672b\u884c\u6a21\u5f0f\uff0c\u6267\u884c\u6587\u6863\u7684\u4fdd\u5b58\u6216\u9000\u51fa\u64cd\u4f5c\u3002\u5728Vim\u4e2d\uff0c\u65e0\u6cd5\u76f4\u63a5\u4ece\u8f93\u5165\u6a21\u5f0f\u5207\u6362\u5230\u672b\u884c\u6a21\u5f0f\u3002Vim\u7f16\u8f91\u5668\u4e2d\u5185\u7f6e\u7684\u547d\u4ee4\u6709\u6210\u767e\u4e0a\u5343\u79cd\u7528\u6cd5\uff0c\u4e3a\u4e86\u80fd\u591f\u5e2e\u52a9\u8bfb\u8005\u66f4\u5feb\u5730\u638c\u63e1Vim\u7f16\u8f91\u5668\uff0c\u88684-1\u603b\u7ed3\u4e86\u5728\u547d\u4ee4\u6a21\u5f0f\u4e2d\u6700\u5e38\u7528\u7684\u4e00\u4e9b\u547d\u4ee4\u3002<\/p>\n<p style=\"box-sizing: border-box; margin-top: 0px; margin-bottom: 10px; line-height: 23px; text-indent: 1em; text-align: justify; color: rgb(61, 68, 80); font-family: &quot;Microsoft Yahei&quot;, Helvetica, Arial, sans-serif; font-size: 12px; white-space: normal; background-color: rgb(255, 255, 255);\">\u88684-1&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp; Vim\u4e2d\u5e38\u7528\u7684\u547d\u4ee4<\/p>\n<table id=\"tablepress-36\" class=\"tablepress tablepress-id-36\" width=\"712\">\n<tbody class=\"row-hover\" style=\"box-sizing: border-box;\">\n<tr class=\"row-1 odd firstRow\" style=\"box-sizing: border-box;\">\n<td class=\"column-1\" style=\"box-sizing: border-box; padding: 8px; border-top-width: 0px; border-right-style: none; border-bottom-style: none; border-left-style: none; border-color: initial; vertical-align: top; float: none !important; background: 0px 0px rgb(249, 249, 249);\">\u547d\u4ee4<\/td>\n<td class=\"column-2\" style=\"box-sizing: border-box; padding: 8px; border-top-width: 0px; border-right-style: none; border-bottom-style: none; border-left-style: none; border-color: initial; vertical-align: top; float: none !important; background: 0px 0px rgb(249, 249, 249);\">\u4f5c\u7528<\/td>\n<\/tr>\n<tr class=\"row-2 even\" style=\"box-sizing: border-box;\">\n<td class=\"column-1\" style=\"box-sizing: border-box; padding: 8px; border-right-style: none; border-bottom-style: none; border-left-style: none; vertical-align: top; float: none !important; background-image: initial; background-attachment: initial; background-size: initial; background-origin: initial; background-clip: initial; background-position: 0px 0px; background-repeat: initial;\">dd<\/td>\n<td class=\"column-2\" style=\"box-sizing: border-box; padding: 8px; border-right-style: none; border-bottom-style: none; border-left-style: none; vertical-align: top; float: none !important; background-image: initial; background-attachment: initial; background-size: initial; background-origin: initial; background-clip: initial; background-position: 0px 0px; background-repeat: initial;\">\u5220\u9664\uff08\u526a\u5207\uff09\u5149\u6807\u6240\u5728\u6574\u884c<\/td>\n<\/tr>\n<tr class=\"row-3 odd\" style=\"box-sizing: border-box;\">\n<td class=\"column-1\" style=\"box-sizing: border-box; padding: 8px; border-right-style: none; border-bottom-style: none; border-left-style: none; vertical-align: top; float: none !important; background: 0px 0px rgb(249, 249, 249);\">5dd<\/td>\n<td class=\"column-2\" style=\"box-sizing: border-box; padding: 8px; border-right-style: none; border-bottom-style: none; border-left-style: none; vertical-align: top; float: none !important; background: 0px 0px rgb(249, 249, 249);\">\u5220\u9664\uff08\u526a\u5207\uff09\u4ece\u5149\u6807\u5904\u5f00\u59cb\u76845\u884c<\/td>\n<\/tr>\n<tr class=\"row-4 even\" style=\"box-sizing: border-box;\">\n<td class=\"column-1\" style=\"box-sizing: border-box; padding: 8px; border-right-style: none; border-bottom-style: none; border-left-style: none; vertical-align: top; float: none !important; background-image: initial; background-attachment: initial; background-size: initial; background-origin: initial; background-clip: initial; background-position: 0px 0px; background-repeat: initial;\">yy<\/td>\n<td class=\"column-2\" style=\"box-sizing: border-box; padding: 8px; border-right-style: none; border-bottom-style: none; border-left-style: none; vertical-align: top; float: none !important; background-image: initial; background-attachment: initial; background-size: initial; background-origin: initial; background-clip: initial; background-position: 0px 0px; background-repeat: initial;\">\u590d\u5236\u5149\u6807\u6240\u5728\u6574\u884c<\/td>\n<\/tr>\n<tr class=\"row-5 odd\" style=\"box-sizing: border-box;\">\n<td class=\"column-1\" style=\"box-sizing: border-box; padding: 8px; border-right-style: none; border-bottom-style: none; border-left-style: none; vertical-align: top; float: none !important; background: 0px 0px rgb(249, 249, 249);\">5yy<\/td>\n<td class=\"column-2\" style=\"box-sizing: border-box; padding: 8px; border-right-style: none; border-bottom-style: none; border-left-style: none; vertical-align: top; float: none !important; background: 0px 0px rgb(249, 249, 249);\">\u590d\u5236\u4ece\u5149\u6807\u5904\u5f00\u59cb\u76845\u884c<\/td>\n<\/tr>\n<tr class=\"row-6 even\" style=\"box-sizing: border-box;\">\n<td class=\"column-1\" style=\"box-sizing: border-box; padding: 8px; border-right-style: none; border-bottom-style: none; border-left-style: none; vertical-align: top; float: none !important; background-image: initial; background-attachment: initial; background-size: initial; background-origin: initial; background-clip: initial; background-position: 0px 0px; background-repeat: initial;\">n<\/td>\n<td class=\"column-2\" style=\"box-sizing: border-box; padding: 8px; border-right-style: none; border-bottom-style: none; border-left-style: none; vertical-align: top; float: none !important; background-image: initial; background-attachment: initial; background-size: initial; background-origin: initial; background-clip: initial; background-position: 0px 0px; background-repeat: initial;\">\u663e\u793a\u641c\u7d22\u547d\u4ee4\u5b9a\u4f4d\u5230\u7684\u4e0b\u4e00\u4e2a\u5b57\u7b26\u4e32<\/td>\n<\/tr>\n<tr class=\"row-7 odd\" style=\"box-sizing: border-box;\">\n<td class=\"column-1\" style=\"box-sizing: border-box; padding: 8px; border-right-style: none; border-bottom-style: none; border-left-style: none; vertical-align: top; float: none !important; background: 0px 0px rgb(249, 249, 249);\">N<\/td>\n<td class=\"column-2\" style=\"box-sizing: border-box; padding: 8px; border-right-style: none; border-bottom-style: none; border-left-style: none; vertical-align: top; float: none !important; background: 0px 0px rgb(249, 249, 249);\">\u663e\u793a\u641c\u7d22\u547d\u4ee4\u5b9a\u4f4d\u5230\u7684\u4e0a\u4e00\u4e2a\u5b57\u7b26\u4e32<\/td>\n<\/tr>\n<tr class=\"row-8 even\" style=\"box-sizing: border-box;\">\n<td class=\"column-1\" style=\"box-sizing: border-box; padding: 8px; border-right-style: none; border-bottom-style: none; border-left-style: none; vertical-align: top; float: none !important; background-image: initial; background-attachment: initial; background-size: initial; background-origin: initial; background-clip: initial; background-position: 0px 0px; background-repeat: initial;\">u<\/td>\n<td class=\"column-2\" style=\"box-sizing: border-box; padding: 8px; border-right-style: none; border-bottom-style: none; border-left-style: none; vertical-align: top; float: none !important; background-image: initial; background-attachment: initial; background-size: initial; background-origin: initial; background-clip: initial; background-position: 0px 0px; background-repeat: initial;\">\u64a4\u9500\u4e0a\u4e00\u6b65\u7684\u64cd\u4f5c<\/td>\n<\/tr>\n<tr class=\"row-9 odd\" style=\"box-sizing: border-box;\">\n<td class=\"column-1\" style=\"box-sizing: border-box; padding: 8px; border-right-style: none; border-bottom-style: none; border-left-style: none; vertical-align: top; float: none !important; background: 0px 0px rgb(249, 249, 249);\">p<\/td>\n<td class=\"column-2\" style=\"box-sizing: border-box; padding: 8px; border-right-style: none; border-bottom-style: none; border-left-style: none; vertical-align: top; float: none !important; background: 0px 0px rgb(249, 249, 249);\">\u5c06\u4e4b\u524d\u5220\u9664\uff08dd\uff09\u6216\u590d\u5236\uff08yy\uff09\u8fc7\u7684\u6570\u636e\u7c98\u8d34\u5230\u5149\u6807\u540e\u9762<\/td>\n<\/tr>\n<\/tbody>\n<\/table>\n<p style=\"box-sizing: border-box; margin-top: 0px; margin-bottom: 10px; line-height: 23px; text-indent: 1em; text-align: justify; color: rgb(61, 68, 80); font-family: &quot;Microsoft Yahei&quot;, Helvetica, Arial, sans-serif; font-size: 12px; white-space: normal; background-color: rgb(255, 255, 255);\"><\/p>\n<p style=\"box-sizing: border-box; margin-top: 0px; margin-bottom: 10px; line-height: 23px; text-indent: 1em; text-align: justify; color: rgb(61, 68, 80); font-family: &quot;Microsoft Yahei&quot;, Helvetica, Arial, sans-serif; font-size: 12px; white-space: normal; background-color: rgb(255, 255, 255);\">\u672b\u884c\u6a21\u5f0f\u4e3b\u8981\u7528\u4e8e\u4fdd\u5b58\u6216\u9000\u51fa\u6587\u4ef6\uff0c\u4ee5\u53ca\u8bbe\u7f6eVim\u7f16\u8f91\u5668\u7684\u5de5\u4f5c\u73af\u5883\uff0c\u8fd8\u53ef\u4ee5\u8ba9\u7528\u6237\u6267\u884c\u5916\u90e8\u7684<a href=\"https:\/\/www.linuxprobe.com\/\" style=\"box-sizing: border-box; color: rgb(210, 50, 45); text-decoration: none;\">Linux\u547d\u4ee4<\/a>\u6216\u8df3\u8f6c\u5230\u6240\u7f16\u5199\u6587\u6863\u7684\u7279\u5b9a\u884c\u6570\u3002\u8981\u60f3\u5207\u6362\u5230\u672b\u884c\u6a21\u5f0f\uff0c\u5728\u547d\u4ee4\u6a21\u5f0f\u4e2d\u8f93\u5165\u4e00\u4e2a\u5192\u53f7\u5c31\u53ef\u4ee5\u4e86\u3002\u672b\u884c\u6a21\u5f0f\u4e2d\u53ef\u7528\u7684\u547d\u4ee4\u5982\u88684-2\u6240\u793a\u3002<\/p>\n<p style=\"box-sizing: border-box; margin-top: 0px; margin-bottom: 10px; line-height: 23px; text-indent: 1em; text-align: justify; color: rgb(61, 68, 80); font-family: &quot;Microsoft Yahei&quot;, Helvetica, Arial, sans-serif; font-size: 12px; white-space: normal; background-color: rgb(255, 255, 255);\">\u88684-2&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp; \u672b\u884c\u6a21\u5f0f\u4e2d\u53ef\u7528\u7684\u547d\u4ee4<\/p>\n<table id=\"tablepress-37\" class=\"tablepress tablepress-id-37\" width=\"712\">\n<tbody class=\"row-hover\" style=\"box-sizing: border-box;\">\n<tr class=\"row-1 odd firstRow\" style=\"box-sizing: border-box;\">\n<td class=\"column-1\" style=\"box-sizing: border-box; padding: 8px; border-top-width: 0px; border-right-style: none; border-bottom-style: none; border-left-style: none; border-color: initial; vertical-align: top; float: none !important; background: 0px 0px rgb(249, 249, 249);\">\u547d\u4ee4<\/td>\n<td class=\"column-2\" style=\"box-sizing: border-box; padding: 8px; border-top-width: 0px; border-right-style: none; border-bottom-style: none; border-left-style: none; border-color: initial; vertical-align: top; float: none !important; background: 0px 0px rgb(249, 249, 249);\">\u4f5c\u7528<\/td>\n<\/tr>\n<tr class=\"row-2 even\" style=\"box-sizing: border-box;\">\n<td class=\"column-1\" style=\"box-sizing: border-box; padding: 8px; border-right-style: none; border-bottom-style: none; border-left-style: none; vertical-align: top; float: none !important; background-image: initial; background-attachment: initial; background-size: initial; background-origin: initial; background-clip: initial; background-position: 0px 0px; background-repeat: initial;\">:w<\/td>\n<td class=\"column-2\" style=\"box-sizing: border-box; padding: 8px; border-right-style: none; border-bottom-style: none; border-left-style: none; vertical-align: top; float: none !important; background-image: initial; background-attachment: initial; background-size: initial; background-origin: initial; background-clip: initial; background-position: 0px 0px; background-repeat: initial;\">\u4fdd\u5b58<\/td>\n<\/tr>\n<tr class=\"row-3 odd\" style=\"box-sizing: border-box;\">\n<td class=\"column-1\" style=\"box-sizing: border-box; padding: 8px; border-right-style: none; border-bottom-style: none; border-left-style: none; vertical-align: top; float: none !important; background: 0px 0px rgb(249, 249, 249);\">:q<\/td>\n<td class=\"column-2\" style=\"box-sizing: border-box; padding: 8px; border-right-style: none; border-bottom-style: none; border-left-style: none; vertical-align: top; float: none !important; background: 0px 0px rgb(249, 249, 249);\">\u9000\u51fa<\/td>\n<\/tr>\n<tr class=\"row-4 even\" style=\"box-sizing: border-box;\">\n<td class=\"column-1\" style=\"box-sizing: border-box; padding: 8px; border-right-style: none; border-bottom-style: none; border-left-style: none; vertical-align: top; float: none !important; background-image: initial; background-attachment: initial; background-size: initial; background-origin: initial; background-clip: initial; background-position: 0px 0px; background-repeat: initial;\">:q!<\/td>\n<td class=\"column-2\" style=\"box-sizing: border-box; padding: 8px; border-right-style: none; border-bottom-style: none; border-left-style: none; vertical-align: top; float: none !important; background-image: initial; background-attachment: initial; background-size: initial; background-origin: initial; background-clip: initial; background-position: 0px 0px; background-repeat: initial;\">\u5f3a\u5236\u9000\u51fa\uff08\u653e\u5f03\u5bf9\u6587\u6863\u7684\u4fee\u6539\u5185\u5bb9\uff09<\/td>\n<\/tr>\n<tr class=\"row-5 odd\" style=\"box-sizing: border-box;\">\n<td class=\"column-1\" style=\"box-sizing: border-box; padding: 8px; border-right-style: none; border-bottom-style: none; border-left-style: none; vertical-align: top; float: none !important; background: 0px 0px rgb(249, 249, 249);\">:wq!<\/td>\n<td class=\"column-2\" style=\"box-sizing: border-box; padding: 8px; border-right-style: none; border-bottom-style: none; border-left-style: none; vertical-align: top; float: none !important; background: 0px 0px rgb(249, 249, 249);\">\u5f3a\u5236\u4fdd\u5b58\u9000\u51fa<\/td>\n<\/tr>\n<tr class=\"row-6 even\" style=\"box-sizing: border-box;\">\n<td class=\"column-1\" style=\"box-sizing: border-box; padding: 8px; border-right-style: none; border-bottom-style: none; border-left-style: none; vertical-align: top; float: none !important; background-image: initial; background-attachment: initial; background-size: initial; background-origin: initial; background-clip: initial; background-position: 0px 0px; background-repeat: initial;\">:set nu<\/td>\n<td class=\"column-2\" style=\"box-sizing: border-box; padding: 8px; border-right-style: none; border-bottom-style: none; border-left-style: none; vertical-align: top; float: none !important; background-image: initial; background-attachment: initial; background-size: initial; background-origin: initial; background-clip: initial; background-position: 0px 0px; background-repeat: initial;\">\u663e\u793a\u884c\u53f7<\/td>\n<\/tr>\n<tr class=\"row-7 odd\" style=\"box-sizing: border-box;\">\n<td class=\"column-1\" style=\"box-sizing: border-box; padding: 8px; border-right-style: none; border-bottom-style: none; border-left-style: none; vertical-align: top; float: none !important; background: 0px 0px rgb(249, 249, 249);\">:set nonu<\/td>\n<td class=\"column-2\" style=\"box-sizing: border-box; padding: 8px; border-right-style: none; border-bottom-style: none; border-left-style: none; vertical-align: top; float: none !important; background: 0px 0px rgb(249, 249, 249);\">\u4e0d\u663e\u793a\u884c\u53f7<\/td>\n<\/tr>\n<tr class=\"row-8 even\" style=\"box-sizing: border-box;\">\n<td class=\"column-1\" style=\"box-sizing: border-box; padding: 8px; border-right-style: none; border-bottom-style: none; border-left-style: none; vertical-align: top; float: none !important; background-image: initial; background-attachment: initial; background-size: initial; background-origin: initial; background-clip: initial; background-position: 0px 0px; background-repeat: initial;\">:\u547d\u4ee4<\/td>\n<td class=\"column-2\" style=\"box-sizing: border-box; padding: 8px; border-right-style: none; border-bottom-style: none; border-left-style: none; vertical-align: top; float: none !important; background-image: initial; background-attachment: initial; background-size: initial; background-origin: initial; background-clip: initial; background-position: 0px 0px; background-repeat: initial;\">\u6267\u884c\u8be5\u547d\u4ee4<\/td>\n<\/tr>\n<tr class=\"row-9 odd\" style=\"box-sizing: border-box;\">\n<td class=\"column-1\" style=\"box-sizing: border-box; padding: 8px; border-right-style: none; border-bottom-style: none; border-left-style: none; vertical-align: top; float: none !important; background: 0px 0px rgb(249, 249, 249);\">:\u6574\u6570<\/td>\n<td class=\"column-2\" style=\"box-sizing: border-box; padding: 8px; border-right-style: none; border-bottom-style: none; border-left-style: none; vertical-align: top; float: none !important; background: 0px 0px rgb(249, 249, 249);\">\u8df3\u8f6c\u5230\u8be5\u884c<\/td>\n<\/tr>\n<tr class=\"row-10 even\" style=\"box-sizing: border-box;\">\n<td class=\"column-1\" style=\"box-sizing: border-box; padding: 8px; border-right-style: none; border-bottom-style: none; border-left-style: none; vertical-align: top; float: none !important; background-image: initial; background-attachment: initial; background-size: initial; background-origin: initial; background-clip: initial; background-position: 0px 0px; background-repeat: initial;\">:s\/one\/two<\/td>\n<td class=\"column-2\" style=\"box-sizing: border-box; padding: 8px; border-right-style: none; border-bottom-style: none; border-left-style: none; vertical-align: top; float: none !important; background-image: initial; background-attachment: initial; background-size: initial; background-origin: initial; background-clip: initial; background-position: 0px 0px; background-repeat: initial;\">\u5c06\u5f53\u524d\u5149\u6807\u6240\u5728\u884c\u7684\u7b2c\u4e00\u4e2aone\u66ff\u6362\u6210two<\/td>\n<\/tr>\n<tr class=\"row-11 odd\" style=\"box-sizing: border-box;\">\n<td class=\"column-1\" style=\"box-sizing: border-box; padding: 8px; border-right-style: none; border-bottom-style: none; border-left-style: none; vertical-align: top; float: none !important; background: 0px 0px rgb(249, 249, 249);\">:s\/one\/two\/g<\/td>\n<td class=\"column-2\" style=\"box-sizing: border-box; padding: 8px; border-right-style: none; border-bottom-style: none; border-left-style: none; vertical-align: top; float: none !important; background: 0px 0px rgb(249, 249, 249);\">\u5c06\u5f53\u524d\u5149\u6807\u6240\u5728\u884c\u7684\u6240\u6709one\u66ff\u6362\u6210two<\/td>\n<\/tr>\n<tr class=\"row-12 even\" style=\"box-sizing: border-box;\">\n<td class=\"column-1\" style=\"box-sizing: border-box; padding: 8px; border-right-style: none; border-bottom-style: none; border-left-style: none; vertical-align: top; float: none !important; background-image: initial; background-attachment: initial; background-size: initial; background-origin: initial; background-clip: initial; background-position: 0px 0px; background-repeat: initial;\">:%s\/one\/two\/g<\/td>\n<td class=\"column-2\" style=\"box-sizing: border-box; padding: 8px; border-right-style: none; border-bottom-style: none; border-left-style: none; vertical-align: top; float: none !important; background-image: initial; background-attachment: initial; background-size: initial; background-origin: initial; background-clip: initial; background-position: 0px 0px; background-repeat: initial;\">\u5c06\u5168\u6587\u4e2d\u7684\u6240\u6709one\u66ff\u6362\u6210two<\/td>\n<\/tr>\n<tr class=\"row-13 odd\" style=\"box-sizing: border-box;\">\n<td class=\"column-1\" style=\"box-sizing: border-box; padding: 8px; border-right-style: none; border-bottom-style: none; border-left-style: none; vertical-align: top; float: none !important; background: 0px 0px rgb(249, 249, 249);\">?\u5b57\u7b26\u4e32<\/td>\n<td class=\"column-2\" style=\"box-sizing: border-box; padding: 8px; border-right-style: none; border-bottom-style: none; border-left-style: none; vertical-align: top; float: none !important; background: 0px 0px rgb(249, 249, 249);\">\u5728\u6587\u672c\u4e2d\u4ece\u4e0b\u81f3\u4e0a\u641c\u7d22\u8be5\u5b57\u7b26\u4e32<\/td>\n<\/tr>\n<tr class=\"row-14 even\" style=\"box-sizing: border-box;\">\n<td class=\"column-1\" style=\"box-sizing: border-box; padding: 8px; border-right-style: none; border-bottom-style: none; border-left-style: none; vertical-align: top; float: none !important; background-image: initial; background-attachment: initial; background-size: initial; background-origin: initial; background-clip: initial; background-position: 0px 0px; background-repeat: initial;\">\/\u5b57\u7b26\u4e32<\/td>\n<td class=\"column-2\" style=\"box-sizing: border-box; padding: 8px; border-right-style: none; border-bottom-style: none; border-left-style: none; vertical-align: top; float: none !important; background-image: initial; background-attachment: initial; background-size: initial; background-origin: initial; background-clip: initial; background-position: 0px 0px; background-repeat: initial;\">\u5728\u6587\u672c\u4e2d\u4ece\u4e0a\u81f3\u4e0b\u641c\u7d22\u8be5\u5b57\u7b26\u4e32<\/td>\n<\/tr>\n<\/tbody>\n<\/table>\n<p style=\"box-sizing: border-box; margin-top: 0px; margin-bottom: 10px; line-height: 23px; text-indent: 1em; text-align: justify; color: rgb(61, 68, 80); font-family: &quot;Microsoft Yahei&quot;, Helvetica, Arial, sans-serif; font-size: 12px; white-space: normal; background-color: rgb(255, 255, 255);\"><\/p>\n<h6 style=\"box-sizing: border-box; font-family: &quot;Helvetica Neue&quot;, Helvetica, Arial, sans-serif; font-weight: 500; line-height: 1.1; margin-top: 10px; margin-bottom: 10px; font-size: 12px; color: rgb(61, 68, 80); white-space: normal; background-color: rgb(255, 255, 255);\"><span id=\"411\" style=\"box-sizing: border-box;\"><span style=\"box-sizing: border-box; color: #008000;\"><strong style=\"box-sizing: border-box;\">4.1.1 \u7f16\u5199\u7b80\u5355\u6587\u6863<\/strong><\/span><\/span><\/h6>\n<p style=\"box-sizing: border-box; margin-top: 0px; margin-bottom: 10px; line-height: 23px; text-indent: 1em; text-align: justify; color: rgb(61, 68, 80); font-family: &quot;Microsoft Yahei&quot;, Helvetica, Arial, sans-serif; font-size: 12px; white-space: normal; background-color: rgb(255, 255, 255);\">\u76ee\u524d\u4e3a\u6b62\uff0c\u5927\u5bb6\u5df2\u7ecf\u5177\u5907\u4e86\u5728Linux\u7cfb\u7edf\u4e2d\u7f16\u5199\u6587\u6863\u7684\u7406\u8bba\u57fa\u7840\u4e86\uff0c\u63a5\u4e0b\u6765\u6211\u4eec\u4e00\u8d77\u52a8\u624b\u7f16\u5199\u4e00\u4e2a\u7b80\u5355\u7684\u811a\u672c\u6587\u6863\u3002<a href=\"https:\/\/www.linuxprobe.com\/\" title=\"\u5218\u9044\" target=\"_blank\" style=\"box-sizing: border-box; color: rgb(210, 50, 45); text-decoration: none;\" rel=\"noopener noreferrer\">\u5218\u9044<\/a>\u8001\u5e08\u4f1a\u5c3d\u529b\u628a\u6240\u6709\u64cd\u4f5c\u6b65\u9aa4\u548c\u6309\u952e\u8fc7\u7a0b\u90fd\u6807\u6ce8\u51fa\u6765\uff0c\u5982\u679c\u5fd8\u8bb0\u4e86\u67d0\u4e9b\u5feb\u6377\u952e\u547d\u4ee4\u7684\u4f5c\u7528\uff0c\u53ef\u4ee5\u518d\u8fd4\u56de\u524d\u6587\u8fdb\u884c\u590d\u4e60\u3002<\/p>\n<p style=\"box-sizing: border-box; margin-top: 0px; margin-bottom: 10px; line-height: 23px; text-indent: 1em; text-align: justify; color: rgb(61, 68, 80); font-family: &quot;Microsoft Yahei&quot;, Helvetica, Arial, sans-serif; font-size: 12px; white-space: normal; background-color: rgb(255, 255, 255);\">\u7f16\u5199\u811a\u672c\u6587\u6863\u7684\u7b2c1\u6b65\u5c31\u662f\u7ed9\u6587\u6863\u53d6\u4e2a\u540d\u5b57\uff0c\u8fd9\u91cc\u5c06\u5176\u547d\u540d\u4e3apractice.txt\u3002\u5982\u679c\u5b58\u5728\u8be5\u6587\u6863\uff0c\u5219\u662f\u6253\u5f00\u5b83\u3002\u5982\u679c\u4e0d\u5b58\u5728\uff0c\u5219\u662f\u521b\u5efa\u4e00\u4e2a\u4e34\u65f6\u7684\u8f93\u5165\u6587\u4ef6\uff0c\u5982\u56fe4-2\u6240\u793a\u3002<\/p>\n<p style=\"box-sizing: border-box; margin-top: 0px; margin-bottom: 10px; line-height: 23px; text-indent: 1em; text-align: center; color: rgb(61, 68, 80); font-family: &quot;Microsoft Yahei&quot;, Helvetica, Arial, sans-serif; font-size: 12px; white-space: normal; background-color: rgb(255, 255, 255);\"><div class='fancybox-wrapper lazyload-container-unload' data-fancybox='post-images' href='https:\/\/www.linuxprobe.com\/wp-content\/uploads\/2015\/03\/%E7%AC%AC1%E6%AD%A5%EF%BC%9A%E5%88%9B%E5%BB%BA%E6%96%87%E6%A1%A3.png'><img class=\"lazyload lazyload-style-1\" src=\"data:image\/svg+xml;base64,PCEtLUFyZ29uTG9hZGluZy0tPgo8c3ZnIHdpZHRoPSIxIiBoZWlnaHQ9IjEiIHhtbG5zPSJodHRwOi8vd3d3LnczLm9yZy8yMDAwL3N2ZyIgc3Ryb2tlPSIjZmZmZmZmMDAiPjxnPjwvZz4KPC9zdmc+\"  loading=\"lazy\" decoding=\"async\" class=\"size-full wp-image-727 aligncenter\" data-original=\"https:\/\/www.linuxprobe.com\/wp-content\/uploads\/2015\/03\/%E7%AC%AC1%E6%AD%A5%EF%BC%9A%E5%88%9B%E5%BB%BA%E6%96%87%E6%A1%A3.png\" src=\"data:image\/png;base64,iVBORw0KGgoAAAANSUhEUgAAAAEAAAABCAYAAAAfFcSJAAAAAXNSR0IArs4c6QAAAARnQU1BAACxjwv8YQUAAAAJcEhZcwAADsQAAA7EAZUrDhsAAAANSURBVBhXYzh8+PB\/AAffA0nNPuCLAAAAAElFTkSuQmCC\" alt=\"\u7b2c4\u7ae0 Vim\u7f16\u8f91\u5668\u4e0eShell\u547d\u4ee4\u811a\u672c\u3002\u7b2c4\u7ae0 Vim\u7f16\u8f91\u5668\u4e0eShell\u547d\u4ee4\u811a\u672c\u3002\" width=\"737\" height=\"494\"  sizes=\"auto, (max-width: 737px) 100vw, 737px\" title=\"\u7b2c4\u7ae0 Vim\u7f16\u8f91\u5668\u4e0eShell\u547d\u4ee4\u811a\u672c\u3002\u7b2c4\u7ae0 Vim\u7f16\u8f91\u5668\u4e0eShell\u547d\u4ee4\u811a\u672c\u3002\" style=\"box-sizing: border-box; max-width: 100%; border-radius: 4px; vertical-align: middle; height: auto; margin: 10px auto; display: block;\"\/><\/div><\/p>\n<p style=\"box-sizing: border-box; margin-top: 0px; margin-bottom: 10px; line-height: 23px; text-indent: 1em; text-align: center; color: rgb(61, 68, 80); font-family: &quot;Microsoft Yahei&quot;, Helvetica, Arial, sans-serif; font-size: 12px; white-space: normal; background-color: rgb(255, 255, 255);\">\u56fe4-2&nbsp; \u5c1d\u8bd5\u7f16\u5199\u811a\u672c\u6587\u6863<\/p>\n<p style=\"box-sizing: border-box; margin-top: 0px; margin-bottom: 10px; line-height: 23px; text-indent: 1em; text-align: justify; color: rgb(61, 68, 80); font-family: &quot;Microsoft Yahei&quot;, Helvetica, Arial, sans-serif; font-size: 12px; white-space: normal; background-color: rgb(255, 255, 255);\">\u6253\u5f00practice.txt\u6587\u6863\u540e\uff0c\u9ed8\u8ba4\u8fdb\u5165\u7684\u662fVim\u7f16\u8f91\u5668\u7684\u547d\u4ee4\u6a21\u5f0f\u3002\u6b64\u65f6\u53ea\u80fd\u6267\u884c\u8be5\u6a21\u5f0f\u4e0b\u7684\u547d\u4ee4\uff0c\u800c\u4e0d\u80fd\u968f\u610f\u8f93\u5165\u6587\u672c\u5185\u5bb9\uff0c\u6211\u4eec\u9700\u8981\u5207\u6362\u5230\u8f93\u5165\u6a21\u5f0f\u624d\u53ef\u4ee5\u7f16\u5199\u6587\u6863\u3002<\/p>\n<p style=\"box-sizing: border-box; margin-top: 0px; margin-bottom: 10px; line-height: 23px; text-indent: 1em; text-align: justify; color: rgb(61, 68, 80); font-family: &quot;Microsoft Yahei&quot;, Helvetica, Arial, sans-serif; font-size: 12px; white-space: normal; background-color: rgb(255, 255, 255);\">\u5728\u56fe4-1\u4e2d\u63d0\u5230\uff0c\u53ef\u4ee5\u5206\u522b\u4f7f\u7528a\u3001i\u3001o\u4e09\u4e2a\u952e\u4ece\u547d\u4ee4\u6a21\u5f0f\u5207\u6362\u5230\u8f93\u5165\u6a21\u5f0f\u3002\u5176\u4e2d\uff0ca\u952e\u4e0ei\u952e\u5206\u522b\u662f\u5728\u5149\u6807\u540e\u9762\u4e00\u4f4d\u548c\u5149\u6807\u5f53\u524d\u4f4d\u7f6e\u5207\u6362\u5230\u8f93\u5165\u6a21\u5f0f\uff0c\u800co\u952e\u5219\u662f\u5728\u5149\u6807\u7684\u4e0b\u9762\u518d\u521b\u5efa\u4e00\u4e2a\u7a7a\u884c\uff0c\u6b64\u65f6\u53ef\u6572\u51fba\u952e\u8fdb\u5165\u5230\u7f16\u8f91\u5668\u7684\u8f93\u5165\u6a21\u5f0f\uff0c\u5982\u56fe4-3\u6240\u793a\u3002<\/p>\n<p style=\"box-sizing: border-box; margin-top: 0px; margin-bottom: 10px; line-height: 23px; text-indent: 1em; text-align: justify; color: rgb(61, 68, 80); font-family: &quot;Microsoft Yahei&quot;, Helvetica, Arial, sans-serif; font-size: 12px; white-space: normal; background-color: rgb(255, 255, 255);\"><div class='fancybox-wrapper lazyload-container-unload' data-fancybox='post-images' href='https:\/\/www.linuxprobe.com\/wp-content\/uploads\/2015\/03\/%E7%AC%AC2%E6%AD%A5%EF%BC%9A%E6%95%B2%E5%87%BB%E5%AD%97%E6%AF%8D%E2%80%9Ca%E2%80%9D%EF%BC%8C%E8%BF%9B%E5%85%A5%E8%BE%93%E5%85%A5%E6%A8%A1%E5%BC%8F.png'><img class=\"lazyload lazyload-style-1\" src=\"data:image\/svg+xml;base64,PCEtLUFyZ29uTG9hZGluZy0tPgo8c3ZnIHdpZHRoPSIxIiBoZWlnaHQ9IjEiIHhtbG5zPSJodHRwOi8vd3d3LnczLm9yZy8yMDAwL3N2ZyIgc3Ryb2tlPSIjZmZmZmZmMDAiPjxnPjwvZz4KPC9zdmc+\"  loading=\"lazy\" decoding=\"async\" class=\"size-full wp-image-728 aligncenter\" data-original=\"https:\/\/www.linuxprobe.com\/wp-content\/uploads\/2015\/03\/%E7%AC%AC2%E6%AD%A5%EF%BC%9A%E6%95%B2%E5%87%BB%E5%AD%97%E6%AF%8D%E2%80%9Ca%E2%80%9D%EF%BC%8C%E8%BF%9B%E5%85%A5%E8%BE%93%E5%85%A5%E6%A8%A1%E5%BC%8F.png\" src=\"data:image\/png;base64,iVBORw0KGgoAAAANSUhEUgAAAAEAAAABCAYAAAAfFcSJAAAAAXNSR0IArs4c6QAAAARnQU1BAACxjwv8YQUAAAAJcEhZcwAADsQAAA7EAZUrDhsAAAANSURBVBhXYzh8+PB\/AAffA0nNPuCLAAAAAElFTkSuQmCC\" alt=\"\u7b2c4\u7ae0 Vim\u7f16\u8f91\u5668\u4e0eShell\u547d\u4ee4\u811a\u672c\u3002\u7b2c4\u7ae0 Vim\u7f16\u8f91\u5668\u4e0eShell\u547d\u4ee4\u811a\u672c\u3002\" width=\"735\" height=\"494\"  sizes=\"auto, (max-width: 735px) 100vw, 735px\" title=\"\u7b2c4\u7ae0 Vim\u7f16\u8f91\u5668\u4e0eShell\u547d\u4ee4\u811a\u672c\u3002\u7b2c4\u7ae0 Vim\u7f16\u8f91\u5668\u4e0eShell\u547d\u4ee4\u811a\u672c\u3002\" style=\"box-sizing: border-box; max-width: 100%; border-radius: 4px; vertical-align: middle; height: auto; margin: 10px auto; display: block;\"\/><\/div><\/p>\n<p style=\"box-sizing: border-box; margin-top: 0px; margin-bottom: 10px; line-height: 23px; text-indent: 1em; text-align: center; color: rgb(61, 68, 80); font-family: &quot;Microsoft Yahei&quot;, Helvetica, Arial, sans-serif; font-size: 12px; white-space: normal; background-color: rgb(255, 255, 255);\">\u56fe4-3&nbsp; \u5207\u6362\u81f3\u7f16\u8f91\u5668\u7684\u8f93\u5165\u6a21\u5f0f<\/p>\n<p style=\"box-sizing: border-box; margin-top: 0px; margin-bottom: 10px; line-height: 23px; text-indent: 1em; text-align: justify; color: rgb(61, 68, 80); font-family: &quot;Microsoft Yahei&quot;, Helvetica, Arial, sans-serif; font-size: 12px; white-space: normal; background-color: rgb(255, 255, 255);\">\u8fdb\u5165\u8f93\u5165\u6a21\u5f0f\u540e\uff0c\u53ef\u4ee5\u968f\u610f\u8f93\u5165\u6587\u672c\u5185\u5bb9\uff0cVim\u7f16\u8f91\u5668\u4e0d\u4f1a\u628a\u60a8\u8f93\u5165\u7684\u6587\u672c\u5185\u5bb9\u5f53\u4f5c\u547d\u4ee4\u800c\u6267\u884c\uff0c\u5982\u56fe4-4\u6240\u793a\u3002<\/p>\n<p style=\"box-sizing: border-box; margin-top: 0px; margin-bottom: 10px; line-height: 23px; text-indent: 1em; text-align: justify; color: rgb(61, 68, 80); font-family: &quot;Microsoft Yahei&quot;, Helvetica, Arial, sans-serif; font-size: 12px; white-space: normal; background-color: rgb(255, 255, 255);\"><div class='fancybox-wrapper lazyload-container-unload' data-fancybox='post-images' href='https:\/\/www.linuxprobe.com\/wp-content\/uploads\/2015\/03\/%E7%AC%AC3%E6%AD%A5%EF%BC%9A%E8%BE%93%E5%85%A5%E4%B8%80%E8%A1%8C%E5%AD%97%E7%AC%A6.png'><img class=\"lazyload lazyload-style-1\" src=\"data:image\/svg+xml;base64,PCEtLUFyZ29uTG9hZGluZy0tPgo8c3ZnIHdpZHRoPSIxIiBoZWlnaHQ9IjEiIHhtbG5zPSJodHRwOi8vd3d3LnczLm9yZy8yMDAwL3N2ZyIgc3Ryb2tlPSIjZmZmZmZmMDAiPjxnPjwvZz4KPC9zdmc+\"  loading=\"lazy\" decoding=\"async\" class=\"size-full wp-image-729 aligncenter\" data-original=\"https:\/\/www.linuxprobe.com\/wp-content\/uploads\/2015\/03\/%E7%AC%AC3%E6%AD%A5%EF%BC%9A%E8%BE%93%E5%85%A5%E4%B8%80%E8%A1%8C%E5%AD%97%E7%AC%A6.png\" src=\"data:image\/png;base64,iVBORw0KGgoAAAANSUhEUgAAAAEAAAABCAYAAAAfFcSJAAAAAXNSR0IArs4c6QAAAARnQU1BAACxjwv8YQUAAAAJcEhZcwAADsQAAA7EAZUrDhsAAAANSURBVBhXYzh8+PB\/AAffA0nNPuCLAAAAAElFTkSuQmCC\" alt=\"\u7b2c4\u7ae0 Vim\u7f16\u8f91\u5668\u4e0eShell\u547d\u4ee4\u811a\u672c\u3002\u7b2c4\u7ae0 Vim\u7f16\u8f91\u5668\u4e0eShell\u547d\u4ee4\u811a\u672c\u3002\" width=\"736\" height=\"495\"  sizes=\"auto, (max-width: 736px) 100vw, 736px\" title=\"\u7b2c4\u7ae0 Vim\u7f16\u8f91\u5668\u4e0eShell\u547d\u4ee4\u811a\u672c\u3002\u7b2c4\u7ae0 Vim\u7f16\u8f91\u5668\u4e0eShell\u547d\u4ee4\u811a\u672c\u3002\" style=\"box-sizing: border-box; max-width: 100%; border-radius: 4px; vertical-align: middle; height: auto; margin: 10px auto; display: block;\"\/><\/div><\/p>\n<p style=\"box-sizing: border-box; margin-top: 0px; margin-bottom: 10px; line-height: 23px; text-indent: 1em; text-align: center; color: rgb(61, 68, 80); font-family: &quot;Microsoft Yahei&quot;, Helvetica, Arial, sans-serif; font-size: 12px; white-space: normal; background-color: rgb(255, 255, 255);\">\u56fe4-4&nbsp; \u5728\u7f16\u8f91\u5668\u4e2d\u8f93\u5165\u6587\u672c\u5185\u5bb9<\/p>\n<p style=\"box-sizing: border-box; margin-top: 0px; margin-bottom: 10px; line-height: 23px; text-indent: 1em; text-align: justify; color: rgb(61, 68, 80); font-family: &quot;Microsoft Yahei&quot;, Helvetica, Arial, sans-serif; font-size: 12px; white-space: normal; background-color: rgb(255, 255, 255);\">\u5728\u7f16\u5199\u5b8c\u4e4b\u540e\uff0c\u60f3\u8981\u4fdd\u5b58\u5e76\u9000\u51fa\uff0c\u5fc5\u987b\u5148\u6572\u51fb\u952e\u76d8Esc\u952e\u4ece\u8f93\u5165\u6a21\u5f0f\u8fd4\u56de\u547d\u4ee4\u6a21\u5f0f\uff0c\u5982\u56fe4-5\u6240\u793a\u3002\u7136\u540e\u518d\u8f93\u5165:wq!\u5207\u6362\u5230\u672b\u884c\u6a21\u5f0f\u624d\u80fd\u5b8c\u6210\u4fdd\u5b58\u9000\u51fa\u64cd\u4f5c\uff0c\u5982\u56fe4-6\u6240\u793a\u3002<\/p>\n<p style=\"box-sizing: border-box; margin-top: 0px; margin-bottom: 10px; line-height: 23px; text-indent: 1em; text-align: justify; color: rgb(61, 68, 80); font-family: &quot;Microsoft Yahei&quot;, Helvetica, Arial, sans-serif; font-size: 12px; white-space: normal; background-color: rgb(255, 255, 255);\"><div class='fancybox-wrapper lazyload-container-unload' data-fancybox='post-images' href='https:\/\/www.linuxprobe.com\/wp-content\/uploads\/2015\/03\/%E7%AC%AC4%E6%AD%A5%EF%BC%9A%E6%95%B2%E5%87%BBESC%E8%BF%94%E5%9B%9E%E5%88%B0%E5%91%BD%E4%BB%A4%E6%A8%A1%E5%BC%8F.png'><img class=\"lazyload lazyload-style-1\" src=\"data:image\/svg+xml;base64,PCEtLUFyZ29uTG9hZGluZy0tPgo8c3ZnIHdpZHRoPSIxIiBoZWlnaHQ9IjEiIHhtbG5zPSJodHRwOi8vd3d3LnczLm9yZy8yMDAwL3N2ZyIgc3Ryb2tlPSIjZmZmZmZmMDAiPjxnPjwvZz4KPC9zdmc+\"  loading=\"lazy\" decoding=\"async\" class=\"size-full wp-image-730 aligncenter\" data-original=\"https:\/\/www.linuxprobe.com\/wp-content\/uploads\/2015\/03\/%E7%AC%AC4%E6%AD%A5%EF%BC%9A%E6%95%B2%E5%87%BBESC%E8%BF%94%E5%9B%9E%E5%88%B0%E5%91%BD%E4%BB%A4%E6%A8%A1%E5%BC%8F.png\" src=\"data:image\/png;base64,iVBORw0KGgoAAAANSUhEUgAAAAEAAAABCAYAAAAfFcSJAAAAAXNSR0IArs4c6QAAAARnQU1BAACxjwv8YQUAAAAJcEhZcwAADsQAAA7EAZUrDhsAAAANSURBVBhXYzh8+PB\/AAffA0nNPuCLAAAAAElFTkSuQmCC\" alt=\"\u7b2c4\u7ae0 Vim\u7f16\u8f91\u5668\u4e0eShell\u547d\u4ee4\u811a\u672c\u3002\u7b2c4\u7ae0 Vim\u7f16\u8f91\u5668\u4e0eShell\u547d\u4ee4\u811a\u672c\u3002\" width=\"736\" height=\"495\"  sizes=\"auto, (max-width: 736px) 100vw, 736px\" title=\"\u7b2c4\u7ae0 Vim\u7f16\u8f91\u5668\u4e0eShell\u547d\u4ee4\u811a\u672c\u3002\u7b2c4\u7ae0 Vim\u7f16\u8f91\u5668\u4e0eShell\u547d\u4ee4\u811a\u672c\u3002\" style=\"box-sizing: border-box; max-width: 100%; border-radius: 4px; vertical-align: middle; height: auto; margin: 10px auto; display: block;\"\/><\/div><\/p>\n<p style=\"box-sizing: border-box; margin-top: 0px; margin-bottom: 10px; line-height: 23px; text-indent: 1em; text-align: center; color: rgb(61, 68, 80); font-family: &quot;Microsoft Yahei&quot;, Helvetica, Arial, sans-serif; font-size: 12px; white-space: normal; background-color: rgb(255, 255, 255);\">\u56fe4-5&nbsp; Vim\u7f16\u8f91\u5668\u7684\u547d\u4ee4\u6a21\u5f0f<\/p>\n<p style=\"box-sizing: border-box; margin-top: 0px; margin-bottom: 10px; line-height: 23px; text-indent: 1em; text-align: justify; color: rgb(61, 68, 80); font-family: &quot;Microsoft Yahei&quot;, Helvetica, Arial, sans-serif; font-size: 12px; white-space: normal; background-color: rgb(255, 255, 255);\"><div class='fancybox-wrapper lazyload-container-unload' data-fancybox='post-images' href='https:\/\/www.linuxprobe.com\/wp-content\/uploads\/2015\/03\/%E7%AC%AC5%E6%AD%A5%EF%BC%9A%E6%95%B2%E5%87%BB%E2%80%9C%EF%BC%9Awq%E2%80%9D%EF%BC%8C%E4%BF%9D%E5%AD%98%E5%B9%B6%E9%80%80%E5%87%BA.png'><img class=\"lazyload lazyload-style-1\" src=\"data:image\/svg+xml;base64,PCEtLUFyZ29uTG9hZGluZy0tPgo8c3ZnIHdpZHRoPSIxIiBoZWlnaHQ9IjEiIHhtbG5zPSJodHRwOi8vd3d3LnczLm9yZy8yMDAwL3N2ZyIgc3Ryb2tlPSIjZmZmZmZmMDAiPjxnPjwvZz4KPC9zdmc+\"  loading=\"lazy\" decoding=\"async\" class=\"size-full wp-image-731 aligncenter\" data-original=\"https:\/\/www.linuxprobe.com\/wp-content\/uploads\/2015\/03\/%E7%AC%AC5%E6%AD%A5%EF%BC%9A%E6%95%B2%E5%87%BB%E2%80%9C%EF%BC%9Awq%E2%80%9D%EF%BC%8C%E4%BF%9D%E5%AD%98%E5%B9%B6%E9%80%80%E5%87%BA.png\" src=\"data:image\/png;base64,iVBORw0KGgoAAAANSUhEUgAAAAEAAAABCAYAAAAfFcSJAAAAAXNSR0IArs4c6QAAAARnQU1BAACxjwv8YQUAAAAJcEhZcwAADsQAAA7EAZUrDhsAAAANSURBVBhXYzh8+PB\/AAffA0nNPuCLAAAAAElFTkSuQmCC\" alt=\"\u7b2c4\u7ae0 Vim\u7f16\u8f91\u5668\u4e0eShell\u547d\u4ee4\u811a\u672c\u3002\u7b2c4\u7ae0 Vim\u7f16\u8f91\u5668\u4e0eShell\u547d\u4ee4\u811a\u672c\u3002\" width=\"737\" height=\"495\"  sizes=\"auto, (max-width: 737px) 100vw, 737px\" title=\"\u7b2c4\u7ae0 Vim\u7f16\u8f91\u5668\u4e0eShell\u547d\u4ee4\u811a\u672c\u3002\u7b2c4\u7ae0 Vim\u7f16\u8f91\u5668\u4e0eShell\u547d\u4ee4\u811a\u672c\u3002\" style=\"box-sizing: border-box; max-width: 100%; border-radius: 4px; vertical-align: middle; height: auto; margin: 10px auto; display: block;\"\/><\/div><\/p>\n<p style=\"box-sizing: border-box; margin-top: 0px; margin-bottom: 10px; line-height: 23px; text-indent: 1em; text-align: center; color: rgb(61, 68, 80); font-family: &quot;Microsoft Yahei&quot;, Helvetica, Arial, sans-serif; font-size: 12px; white-space: normal; background-color: rgb(255, 255, 255);\">\u56fe4-6&nbsp; Vim\u7f16\u8f91\u5668\u7684\u672b\u884c\u6a21\u5f0f<\/p>\n<p style=\"box-sizing: border-box; margin-top: 0px; margin-bottom: 10px; line-height: 23px; text-indent: 1em; text-align: justify; color: rgb(61, 68, 80); font-family: &quot;Microsoft Yahei&quot;, Helvetica, Arial, sans-serif; font-size: 12px; white-space: normal; background-color: rgb(255, 255, 255);\">\u5f53\u5728\u672b\u884c\u6a21\u5f0f\u4e2d\u8f93\u5165:wq!\u547d\u4ee4\u65f6\uff0c\u5c31\u610f\u5473\u7740\u5f3a\u5236\u4fdd\u5b58\u5e76\u9000\u51fa\u6587\u6863\u3002\u7136\u540e\u4fbf\u53ef\u4ee5\u7528cat\u547d\u4ee4\u67e5\u770b\u4fdd\u5b58\u540e\u7684\u6587\u6863\u5185\u5bb9\u4e86\uff0c\u5982\u56fe4-7\u6240\u793a\u3002<\/p>\n<p style=\"box-sizing: border-box; margin-top: 0px; margin-bottom: 10px; line-height: 23px; text-indent: 1em; text-align: justify; color: rgb(61, 68, 80); font-family: &quot;Microsoft Yahei&quot;, Helvetica, Arial, sans-serif; font-size: 12px; white-space: normal; background-color: rgb(255, 255, 255);\"><div class='fancybox-wrapper lazyload-container-unload' data-fancybox='post-images' href='https:\/\/www.linuxprobe.com\/wp-content\/uploads\/2015\/03\/%E7%AC%AC6%E6%AD%A5%EF%BC%9A%E6%9F%A5%E7%9C%8B%E6%96%87%E6%A1%A3%E7%9A%84%E5%86%85%E5%AE%B9.png'><img class=\"lazyload lazyload-style-1\" src=\"data:image\/svg+xml;base64,PCEtLUFyZ29uTG9hZGluZy0tPgo8c3ZnIHdpZHRoPSIxIiBoZWlnaHQ9IjEiIHhtbG5zPSJodHRwOi8vd3d3LnczLm9yZy8yMDAwL3N2ZyIgc3Ryb2tlPSIjZmZmZmZmMDAiPjxnPjwvZz4KPC9zdmc+\"  loading=\"lazy\" decoding=\"async\" class=\"size-full wp-image-732 aligncenter\" data-original=\"https:\/\/www.linuxprobe.com\/wp-content\/uploads\/2015\/03\/%E7%AC%AC6%E6%AD%A5%EF%BC%9A%E6%9F%A5%E7%9C%8B%E6%96%87%E6%A1%A3%E7%9A%84%E5%86%85%E5%AE%B9.png\" src=\"data:image\/png;base64,iVBORw0KGgoAAAANSUhEUgAAAAEAAAABCAYAAAAfFcSJAAAAAXNSR0IArs4c6QAAAARnQU1BAACxjwv8YQUAAAAJcEhZcwAADsQAAA7EAZUrDhsAAAANSURBVBhXYzh8+PB\/AAffA0nNPuCLAAAAAElFTkSuQmCC\" alt=\"\u7b2c4\u7ae0 Vim\u7f16\u8f91\u5668\u4e0eShell\u547d\u4ee4\u811a\u672c\u3002\u7b2c4\u7ae0 Vim\u7f16\u8f91\u5668\u4e0eShell\u547d\u4ee4\u811a\u672c\u3002\" width=\"736\" height=\"494\"  sizes=\"auto, (max-width: 736px) 100vw, 736px\" title=\"\u7b2c4\u7ae0 Vim\u7f16\u8f91\u5668\u4e0eShell\u547d\u4ee4\u811a\u672c\u3002\u7b2c4\u7ae0 Vim\u7f16\u8f91\u5668\u4e0eShell\u547d\u4ee4\u811a\u672c\u3002\" style=\"box-sizing: border-box; max-width: 100%; border-radius: 4px; vertical-align: middle; height: auto; margin: 10px auto; display: block;\"\/><\/div><\/p>\n<p style=\"box-sizing: border-box; margin-top: 0px; margin-bottom: 10px; line-height: 23px; text-indent: 1em; text-align: center; color: rgb(61, 68, 80); font-family: &quot;Microsoft Yahei&quot;, Helvetica, Arial, sans-serif; font-size: 12px; white-space: normal; background-color: rgb(255, 255, 255);\">\u56fe4-7 \u67e5\u770b\u6587\u6863\u7684\u5185\u5bb9<\/p>\n<p style=\"box-sizing: border-box; margin-top: 0px; margin-bottom: 10px; line-height: 23px; text-indent: 1em; text-align: justify; color: rgb(61, 68, 80); font-family: &quot;Microsoft Yahei&quot;, Helvetica, Arial, sans-serif; font-size: 12px; white-space: normal; background-color: rgb(255, 255, 255);\">\u662f\u4e0d\u662f\u5f88\u7b80\u5355\uff1f\uff01\u7ee7\u7eed\u7f16\u8f91\u8fd9\u4e2a\u6587\u6863\u3002\u56e0\u4e3a\u8981\u5728\u539f\u6709\u6587\u672c\u5185\u5bb9\u7684\u4e0b\u9762\u8ffd\u52a0\u5185\u5bb9\uff0c\u6240\u4ee5\u5728\u547d\u4ee4\u6a21\u5f0f\u4e2d\u6572\u51fbo\u952e\u8fdb\u5165\u8f93\u5165\u6a21\u5f0f\u66f4\u4f1a\u9ad8\u6548\uff0c\u64cd\u4f5c\u5982\u56fe4-8\u3001\u56fe4-9\u4e0e\u56fe4-10\u6240\u793a\u3002<\/p>\n<p style=\"box-sizing: border-box; margin-top: 0px; margin-bottom: 10px; line-height: 23px; text-indent: 1em; text-align: justify; color: rgb(61, 68, 80); font-family: &quot;Microsoft Yahei&quot;, Helvetica, Arial, sans-serif; font-size: 12px; white-space: normal; background-color: rgb(255, 255, 255);\"><div class='fancybox-wrapper lazyload-container-unload' data-fancybox='post-images' href='https:\/\/www.linuxprobe.com\/wp-content\/uploads\/2015\/03\/%E7%AC%AC7%E6%AD%A5%EF%BC%9A%E7%BC%96%E8%BE%91%E6%96%87%E4%BB%B6.png'><img class=\"lazyload lazyload-style-1\" src=\"data:image\/svg+xml;base64,PCEtLUFyZ29uTG9hZGluZy0tPgo8c3ZnIHdpZHRoPSIxIiBoZWlnaHQ9IjEiIHhtbG5zPSJodHRwOi8vd3d3LnczLm9yZy8yMDAwL3N2ZyIgc3Ryb2tlPSIjZmZmZmZmMDAiPjxnPjwvZz4KPC9zdmc+\"  loading=\"lazy\" decoding=\"async\" class=\"size-full wp-image-733 aligncenter\" data-original=\"https:\/\/www.linuxprobe.com\/wp-content\/uploads\/2015\/03\/%E7%AC%AC7%E6%AD%A5%EF%BC%9A%E7%BC%96%E8%BE%91%E6%96%87%E4%BB%B6.png\" src=\"data:image\/png;base64,iVBORw0KGgoAAAANSUhEUgAAAAEAAAABCAYAAAAfFcSJAAAAAXNSR0IArs4c6QAAAARnQU1BAACxjwv8YQUAAAAJcEhZcwAADsQAAA7EAZUrDhsAAAANSURBVBhXYzh8+PB\/AAffA0nNPuCLAAAAAElFTkSuQmCC\" alt=\"\u7b2c4\u7ae0 Vim\u7f16\u8f91\u5668\u4e0eShell\u547d\u4ee4\u811a\u672c\u3002\u7b2c4\u7ae0 Vim\u7f16\u8f91\u5668\u4e0eShell\u547d\u4ee4\u811a\u672c\u3002\" width=\"737\" height=\"493\"  sizes=\"auto, (max-width: 737px) 100vw, 737px\" title=\"\u7b2c4\u7ae0 Vim\u7f16\u8f91\u5668\u4e0eShell\u547d\u4ee4\u811a\u672c\u3002\u7b2c4\u7ae0 Vim\u7f16\u8f91\u5668\u4e0eShell\u547d\u4ee4\u811a\u672c\u3002\" style=\"box-sizing: border-box; max-width: 100%; border-radius: 4px; vertical-align: middle; height: auto; margin: 10px auto; display: block;\"\/><\/div><\/p>\n<p style=\"box-sizing: border-box; margin-top: 0px; margin-bottom: 10px; line-height: 23px; text-indent: 1em; text-align: center; color: rgb(61, 68, 80); font-family: &quot;Microsoft Yahei&quot;, Helvetica, Arial, sans-serif; font-size: 12px; white-space: normal; background-color: rgb(255, 255, 255);\">\u56fe4-8&nbsp; \u518d\u6b21\u901a\u8fc7Vim\u7f16\u8f91\u5668\u7f16\u5199\u6587\u6863<\/p>\n<p style=\"box-sizing: border-box; margin-top: 0px; margin-bottom: 10px; line-height: 23px; text-indent: 1em; text-align: justify; color: rgb(61, 68, 80); font-family: &quot;Microsoft Yahei&quot;, Helvetica, Arial, sans-serif; font-size: 12px; white-space: normal; background-color: rgb(255, 255, 255);\"><div class='fancybox-wrapper lazyload-container-unload' data-fancybox='post-images' href='https:\/\/www.linuxprobe.com\/wp-content\/uploads\/2015\/03\/%E7%AC%AC8%E6%AD%A5%EF%BC%9A%E6%95%B2%E5%87%BB%E5%AD%97%E6%AF%8D%E2%80%9Co%E2%80%9D%EF%BC%8C%E8%BF%9B%E5%85%A5%E5%88%B0%E8%BE%93%E5%85%A5%E6%A8%A1%E5%BC%8F.png'><img class=\"lazyload lazyload-style-1\" src=\"data:image\/svg+xml;base64,PCEtLUFyZ29uTG9hZGluZy0tPgo8c3ZnIHdpZHRoPSIxIiBoZWlnaHQ9IjEiIHhtbG5zPSJodHRwOi8vd3d3LnczLm9yZy8yMDAwL3N2ZyIgc3Ryb2tlPSIjZmZmZmZmMDAiPjxnPjwvZz4KPC9zdmc+\"  loading=\"lazy\" decoding=\"async\" class=\"size-full wp-image-734 aligncenter\" data-original=\"https:\/\/www.linuxprobe.com\/wp-content\/uploads\/2015\/03\/%E7%AC%AC8%E6%AD%A5%EF%BC%9A%E6%95%B2%E5%87%BB%E5%AD%97%E6%AF%8D%E2%80%9Co%E2%80%9D%EF%BC%8C%E8%BF%9B%E5%85%A5%E5%88%B0%E8%BE%93%E5%85%A5%E6%A8%A1%E5%BC%8F.png\" src=\"data:image\/png;base64,iVBORw0KGgoAAAANSUhEUgAAAAEAAAABCAYAAAAfFcSJAAAAAXNSR0IArs4c6QAAAARnQU1BAACxjwv8YQUAAAAJcEhZcwAADsQAAA7EAZUrDhsAAAANSURBVBhXYzh8+PB\/AAffA0nNPuCLAAAAAElFTkSuQmCC\" alt=\"\u7b2c4\u7ae0 Vim\u7f16\u8f91\u5668\u4e0eShell\u547d\u4ee4\u811a\u672c\u3002\u7b2c4\u7ae0 Vim\u7f16\u8f91\u5668\u4e0eShell\u547d\u4ee4\u811a\u672c\u3002\" width=\"736\" height=\"494\"  sizes=\"auto, (max-width: 736px) 100vw, 736px\" title=\"\u7b2c4\u7ae0 Vim\u7f16\u8f91\u5668\u4e0eShell\u547d\u4ee4\u811a\u672c\u3002\u7b2c4\u7ae0 Vim\u7f16\u8f91\u5668\u4e0eShell\u547d\u4ee4\u811a\u672c\u3002\" style=\"box-sizing: border-box; max-width: 100%; border-radius: 4px; vertical-align: middle; height: auto; margin: 10px auto; display: block;\"\/><\/div><\/p>\n<p style=\"box-sizing: border-box; margin-top: 0px; margin-bottom: 10px; line-height: 23px; text-indent: 1em; text-align: center; color: rgb(61, 68, 80); font-family: &quot;Microsoft Yahei&quot;, Helvetica, Arial, sans-serif; font-size: 12px; white-space: normal; background-color: rgb(255, 255, 255);\">\u56fe4-9&nbsp; \u8fdb\u5165Vim\u7f16\u8f91\u5668\u7684\u8f93\u5165\u6a21\u5f0f<\/p>\n<p style=\"box-sizing: border-box; margin-top: 0px; margin-bottom: 10px; line-height: 23px; text-indent: 1em; text-align: justify; color: rgb(61, 68, 80); font-family: &quot;Microsoft Yahei&quot;, Helvetica, Arial, sans-serif; font-size: 12px; white-space: normal; background-color: rgb(255, 255, 255);\"><div class='fancybox-wrapper lazyload-container-unload' data-fancybox='post-images' href='https:\/\/www.linuxprobe.com\/wp-content\/uploads\/2015\/03\/%E7%AC%AC9%E6%AD%A5%EF%BC%9A%E8%BE%93%E5%85%A5%E4%B8%80%E8%A1%8C%E5%AD%97%E7%AC%A6.png'><img class=\"lazyload lazyload-style-1\" src=\"data:image\/svg+xml;base64,PCEtLUFyZ29uTG9hZGluZy0tPgo8c3ZnIHdpZHRoPSIxIiBoZWlnaHQ9IjEiIHhtbG5zPSJodHRwOi8vd3d3LnczLm9yZy8yMDAwL3N2ZyIgc3Ryb2tlPSIjZmZmZmZmMDAiPjxnPjwvZz4KPC9zdmc+\"  loading=\"lazy\" decoding=\"async\" class=\"size-full wp-image-735 aligncenter\" data-original=\"https:\/\/www.linuxprobe.com\/wp-content\/uploads\/2015\/03\/%E7%AC%AC9%E6%AD%A5%EF%BC%9A%E8%BE%93%E5%85%A5%E4%B8%80%E8%A1%8C%E5%AD%97%E7%AC%A6.png\" src=\"data:image\/png;base64,iVBORw0KGgoAAAANSUhEUgAAAAEAAAABCAYAAAAfFcSJAAAAAXNSR0IArs4c6QAAAARnQU1BAACxjwv8YQUAAAAJcEhZcwAADsQAAA7EAZUrDhsAAAANSURBVBhXYzh8+PB\/AAffA0nNPuCLAAAAAElFTkSuQmCC\" alt=\"\u7b2c4\u7ae0 Vim\u7f16\u8f91\u5668\u4e0eShell\u547d\u4ee4\u811a\u672c\u3002\u7b2c4\u7ae0 Vim\u7f16\u8f91\u5668\u4e0eShell\u547d\u4ee4\u811a\u672c\u3002\" width=\"736\" height=\"493\"  sizes=\"auto, (max-width: 736px) 100vw, 736px\" title=\"\u7b2c4\u7ae0 Vim\u7f16\u8f91\u5668\u4e0eShell\u547d\u4ee4\u811a\u672c\u3002\u7b2c4\u7ae0 Vim\u7f16\u8f91\u5668\u4e0eShell\u547d\u4ee4\u811a\u672c\u3002\" style=\"box-sizing: border-box; max-width: 100%; border-radius: 4px; vertical-align: middle; height: auto; margin: 10px auto; display: block;\"\/><\/div><\/p>\n<p style=\"box-sizing: border-box; margin-top: 0px; margin-bottom: 10px; line-height: 23px; text-indent: 1em; text-align: center; color: rgb(61, 68, 80); font-family: &quot;Microsoft Yahei&quot;, Helvetica, Arial, sans-serif; font-size: 12px; white-space: normal; background-color: rgb(255, 255, 255);\">\u56fe4-10&nbsp; \u8ffd\u52a0\u5199\u5165\u4e00\u884c\u6587\u672c\u5185\u5bb9<\/p>\n<p style=\"box-sizing: border-box; margin-top: 0px; margin-bottom: 10px; line-height: 23px; text-indent: 1em; text-align: justify; color: rgb(61, 68, 80); font-family: &quot;Microsoft Yahei&quot;, Helvetica, Arial, sans-serif; font-size: 12px; white-space: normal; background-color: rgb(255, 255, 255);\">\u56e0\u4e3a\u6b64\u65f6\u5df2\u7ecf\u4fee\u6539\u4e86\u6587\u672c\u5185\u5bb9\uff0c\u6240\u4ee5Vim\u7f16\u8f91\u5668\u5728\u6211\u4eec\u5c1d\u8bd5\u76f4\u63a5\u9000\u51fa\u6587\u6863\u800c\u4e0d\u4fdd\u5b58\u7684\u65f6\u5019\u5c31\u4f1a\u62d2\u7edd\u6211\u4eec\u7684\u64cd\u4f5c\u4e86\u3002\u6b64\u65f6\u53ea\u80fd\u5f3a\u5236\u9000\u51fa\u624d\u53ef\u4ee5\u7ed3\u675f\u672c\u6b21\u8f93\u5165\u64cd\u4f5c\uff0c\u5982\u56fe4-11\u3001\u56fe4-12\u548c\u56fe4-13\u6240\u793a\u3002<\/p>\n<p style=\"box-sizing: border-box; margin-top: 0px; margin-bottom: 10px; line-height: 23px; text-indent: 1em; text-align: justify; color: rgb(61, 68, 80); font-family: &quot;Microsoft Yahei&quot;, Helvetica, Arial, sans-serif; font-size: 12px; white-space: normal; background-color: rgb(255, 255, 255);\"><div class='fancybox-wrapper lazyload-container-unload' data-fancybox='post-images' href='https:\/\/www.linuxprobe.com\/wp-content\/uploads\/2015\/03\/%E7%AC%AC10%E6%AD%A5%EF%BC%9A%E8%BF%94%E5%9B%9E%E5%91%BD%E4%BB%A4%E6%A8%A1%E5%BC%8F%E5%90%8E%E5%B0%9D%E8%AF%95%E2%80%9C%EF%BC%9Aq%E2%80%9D%E9%80%80%E5%87%BA%E4%B8%8D%E4%BF%9D%E5%AD%98.png'><img class=\"lazyload lazyload-style-1\" src=\"data:image\/svg+xml;base64,PCEtLUFyZ29uTG9hZGluZy0tPgo8c3ZnIHdpZHRoPSIxIiBoZWlnaHQ9IjEiIHhtbG5zPSJodHRwOi8vd3d3LnczLm9yZy8yMDAwL3N2ZyIgc3Ryb2tlPSIjZmZmZmZmMDAiPjxnPjwvZz4KPC9zdmc+\"  loading=\"lazy\" decoding=\"async\" class=\"size-full wp-image-736 aligncenter\" data-original=\"https:\/\/www.linuxprobe.com\/wp-content\/uploads\/2015\/03\/%E7%AC%AC10%E6%AD%A5%EF%BC%9A%E8%BF%94%E5%9B%9E%E5%91%BD%E4%BB%A4%E6%A8%A1%E5%BC%8F%E5%90%8E%E5%B0%9D%E8%AF%95%E2%80%9C%EF%BC%9Aq%E2%80%9D%E9%80%80%E5%87%BA%E4%B8%8D%E4%BF%9D%E5%AD%98.png\" src=\"data:image\/png;base64,iVBORw0KGgoAAAANSUhEUgAAAAEAAAABCAYAAAAfFcSJAAAAAXNSR0IArs4c6QAAAARnQU1BAACxjwv8YQUAAAAJcEhZcwAADsQAAA7EAZUrDhsAAAANSURBVBhXYzh8+PB\/AAffA0nNPuCLAAAAAElFTkSuQmCC\" alt=\"\u7b2c4\u7ae0 Vim\u7f16\u8f91\u5668\u4e0eShell\u547d\u4ee4\u811a\u672c\u3002\u7b2c4\u7ae0 Vim\u7f16\u8f91\u5668\u4e0eShell\u547d\u4ee4\u811a\u672c\u3002\" width=\"735\" height=\"494\"  sizes=\"auto, (max-width: 735px) 100vw, 735px\" title=\"\u7b2c4\u7ae0 Vim\u7f16\u8f91\u5668\u4e0eShell\u547d\u4ee4\u811a\u672c\u3002\u7b2c4\u7ae0 Vim\u7f16\u8f91\u5668\u4e0eShell\u547d\u4ee4\u811a\u672c\u3002\" style=\"box-sizing: border-box; max-width: 100%; border-radius: 4px; vertical-align: middle; height: auto; margin: 10px auto; display: block;\"\/><\/div><\/p>\n<p style=\"box-sizing: border-box; margin-top: 0px; margin-bottom: 10px; line-height: 23px; text-indent: 1em; text-align: center; color: rgb(61, 68, 80); font-family: &quot;Microsoft Yahei&quot;, Helvetica, Arial, sans-serif; font-size: 12px; white-space: normal; background-color: rgb(255, 255, 255);\">\u56fe4-11&nbsp; \u5c1d\u8bd5\u9000\u51fa\u6587\u672c\u7f16\u8f91\u5668<\/p>\n<p style=\"box-sizing: border-box; margin-top: 0px; margin-bottom: 10px; line-height: 23px; text-indent: 1em; text-align: justify; color: rgb(61, 68, 80); font-family: &quot;Microsoft Yahei&quot;, Helvetica, Arial, sans-serif; font-size: 12px; white-space: normal; background-color: rgb(255, 255, 255);\"><div class='fancybox-wrapper lazyload-container-unload' data-fancybox='post-images' href='https:\/\/www.linuxprobe.com\/wp-content\/uploads\/2015\/03\/%E7%AC%AC11%E6%AD%A5%EF%BC%9A%E6%8F%90%E7%A4%BA%E5%86%85%E5%AE%B9%E5%B7%B2%E8%A2%AB%E4%BF%AE%E6%94%B9%EF%BC%8C%E4%B8%8D%E8%83%BD%E9%80%80%E5%87%BA%E3%80%82.png'><img class=\"lazyload lazyload-style-1\" src=\"data:image\/svg+xml;base64,PCEtLUFyZ29uTG9hZGluZy0tPgo8c3ZnIHdpZHRoPSIxIiBoZWlnaHQ9IjEiIHhtbG5zPSJodHRwOi8vd3d3LnczLm9yZy8yMDAwL3N2ZyIgc3Ryb2tlPSIjZmZmZmZmMDAiPjxnPjwvZz4KPC9zdmc+\"  loading=\"lazy\" decoding=\"async\" class=\"size-full wp-image-737 aligncenter\" data-original=\"https:\/\/www.linuxprobe.com\/wp-content\/uploads\/2015\/03\/%E7%AC%AC11%E6%AD%A5%EF%BC%9A%E6%8F%90%E7%A4%BA%E5%86%85%E5%AE%B9%E5%B7%B2%E8%A2%AB%E4%BF%AE%E6%94%B9%EF%BC%8C%E4%B8%8D%E8%83%BD%E9%80%80%E5%87%BA%E3%80%82.png\" src=\"data:image\/png;base64,iVBORw0KGgoAAAANSUhEUgAAAAEAAAABCAYAAAAfFcSJAAAAAXNSR0IArs4c6QAAAARnQU1BAACxjwv8YQUAAAAJcEhZcwAADsQAAA7EAZUrDhsAAAANSURBVBhXYzh8+PB\/AAffA0nNPuCLAAAAAElFTkSuQmCC\" alt=\"\u7b2c4\u7ae0 Vim\u7f16\u8f91\u5668\u4e0eShell\u547d\u4ee4\u811a\u672c\u3002\u7b2c4\u7ae0 Vim\u7f16\u8f91\u5668\u4e0eShell\u547d\u4ee4\u811a\u672c\u3002\" width=\"736\" height=\"494\"  sizes=\"auto, (max-width: 736px) 100vw, 736px\" title=\"\u7b2c4\u7ae0 Vim\u7f16\u8f91\u5668\u4e0eShell\u547d\u4ee4\u811a\u672c\u3002\u7b2c4\u7ae0 Vim\u7f16\u8f91\u5668\u4e0eShell\u547d\u4ee4\u811a\u672c\u3002\" style=\"box-sizing: border-box; max-width: 100%; border-radius: 4px; vertical-align: middle; height: auto; margin: 10px auto; display: block;\"\/><\/div><\/p>\n<p style=\"box-sizing: border-box; margin-top: 0px; margin-bottom: 10px; line-height: 23px; text-indent: 1em; text-align: center; color: rgb(61, 68, 80); font-family: &quot;Microsoft Yahei&quot;, Helvetica, Arial, sans-serif; font-size: 12px; white-space: normal; background-color: rgb(255, 255, 255);\">\u56fe4-12&nbsp; \u56e0\u6587\u4ef6\u5df2\u88ab\u4fee\u6539\u800c\u62d2\u7edd\u9000\u51fa\u64cd\u4f5c<\/p>\n<p style=\"box-sizing: border-box; margin-top: 0px; margin-bottom: 10px; line-height: 23px; text-indent: 1em; text-align: justify; color: rgb(61, 68, 80); font-family: &quot;Microsoft Yahei&quot;, Helvetica, Arial, sans-serif; font-size: 12px; white-space: normal; background-color: rgb(255, 255, 255);\">\u73b0\u5728\u5927\u5bb6\u4e5f\u7b97\u662f\u5177\u6709\u4e86\u4e00\u4e9bVim\u7f16\u8f91\u5668\u7684\u5b9e\u6218\u7ecf\u9a8c\u4e86\uff0c\u5e94\u8be5\u4e5f\u611f\u89c9\u6ca1\u6709\u60f3\u8c61\u4e2d\u90a3\u4e48\u96be\u5427\u3002\u73b0\u5728\u67e5\u770b\u6587\u672c\u7684\u5185\u5bb9\uff0c\u679c\u7136\u53d1\u73b0\u8ffd\u52a0\u8f93\u5165\u7684\u5185\u5bb9\u5e76\u6ca1\u6709\u88ab\u4fdd\u5b58\u4e0b\u6765\uff0c\u5982\u56fe4-14\u6240\u793a\u3002<\/p>\n<p style=\"box-sizing: border-box; margin-top: 0px; margin-bottom: 10px; line-height: 23px; text-indent: 1em; text-align: justify; color: rgb(61, 68, 80); font-family: &quot;Microsoft Yahei&quot;, Helvetica, Arial, sans-serif; font-size: 12px; white-space: normal; background-color: rgb(255, 255, 255);\">\u5927\u5bb6\u5728\u5b66\u5b8c\u4e86\u7406\u8bba\u77e5\u8bc6\u4e4b\u540e\u53c8\u81ea\u5df1\u52a8\u624b\u7f16\u5199\u4e86\u4e00\u4e2a\u6587\u672c\uff0c\u73b0\u5728\u662f\u5426\u611f\u89c9\u6210\u5c31\u6ee1\u6ee1\u5462\uff1f\u63a5\u4e0b\u6765\u5c06\u4f1a\u7531\u6d45\u5165\u6df1\u4e3a\u8bfb\u8005\u5b89\u6392\u4e09\u4e2a\u5c0f\u4efb\u52a1\u3002\u4e3a\u4e86\u5f7b\u5e95\u638c\u63e1Vim\u7f16\u8f91\u5668\u7684\u4f7f\u7528\uff0c\u5927\u5bb6\u4e00\u5b9a\u8981\u9010\u4e2a\u5b8c\u6210\u4e0d\u8bb8\u5077\u61d2\uff0c\u5982\u679c\u5728\u5b8c\u6210\u8fd9\u4e09\u4e2a\u4efb\u52a1\u671f\u95f4\u5fd8\u8bb0\u4e86\u76f8\u5173\u547d\u4ee4\uff0c\u53ef\u8fd4\u56de\u524d\u6587\u8fdb\u4e00\u6b65\u590d\u4e60\u638c\u63e1\u3002<\/p>\n<p style=\"box-sizing: border-box; margin-top: 0px; margin-bottom: 10px; line-height: 23px; text-indent: 1em; text-align: justify; color: rgb(61, 68, 80); font-family: &quot;Microsoft Yahei&quot;, Helvetica, Arial, sans-serif; font-size: 12px; white-space: normal; background-color: rgb(255, 255, 255);\"><div class='fancybox-wrapper lazyload-container-unload' data-fancybox='post-images' href='https:\/\/www.linuxprobe.com\/wp-content\/uploads\/2015\/03\/%E7%AC%AC12%E6%AD%A5%EF%BC%9A%E6%95%B2%E5%87%BB%E2%80%9C%EF%BC%9Aq%E2%80%9D%E5%90%8E%E5%BC%BA%E5%88%B6%E9%80%80%E5%87%BA%E4%B8%8D%E4%BF%9D%E5%AD%98.png'><img class=\"lazyload lazyload-style-1\" src=\"data:image\/svg+xml;base64,PCEtLUFyZ29uTG9hZGluZy0tPgo8c3ZnIHdpZHRoPSIxIiBoZWlnaHQ9IjEiIHhtbG5zPSJodHRwOi8vd3d3LnczLm9yZy8yMDAwL3N2ZyIgc3Ryb2tlPSIjZmZmZmZmMDAiPjxnPjwvZz4KPC9zdmc+\"  loading=\"lazy\" decoding=\"async\" class=\"size-full wp-image-738 aligncenter\" data-original=\"https:\/\/www.linuxprobe.com\/wp-content\/uploads\/2015\/03\/%E7%AC%AC12%E6%AD%A5%EF%BC%9A%E6%95%B2%E5%87%BB%E2%80%9C%EF%BC%9Aq%E2%80%9D%E5%90%8E%E5%BC%BA%E5%88%B6%E9%80%80%E5%87%BA%E4%B8%8D%E4%BF%9D%E5%AD%98.png\" src=\"data:image\/png;base64,iVBORw0KGgoAAAANSUhEUgAAAAEAAAABCAYAAAAfFcSJAAAAAXNSR0IArs4c6QAAAARnQU1BAACxjwv8YQUAAAAJcEhZcwAADsQAAA7EAZUrDhsAAAANSURBVBhXYzh8+PB\/AAffA0nNPuCLAAAAAElFTkSuQmCC\" alt=\"\u7b2c4\u7ae0 Vim\u7f16\u8f91\u5668\u4e0eShell\u547d\u4ee4\u811a\u672c\u3002\u7b2c4\u7ae0 Vim\u7f16\u8f91\u5668\u4e0eShell\u547d\u4ee4\u811a\u672c\u3002\" width=\"734\" height=\"495\"  sizes=\"auto, (max-width: 734px) 100vw, 734px\" title=\"\u7b2c4\u7ae0 Vim\u7f16\u8f91\u5668\u4e0eShell\u547d\u4ee4\u811a\u672c\u3002\u7b2c4\u7ae0 Vim\u7f16\u8f91\u5668\u4e0eShell\u547d\u4ee4\u811a\u672c\u3002\" style=\"box-sizing: border-box; max-width: 100%; border-radius: 4px; vertical-align: middle; height: auto; margin: 10px auto; display: block;\"\/><\/div><\/p>\n<p style=\"box-sizing: border-box; margin-top: 0px; margin-bottom: 10px; line-height: 23px; text-indent: 1em; text-align: center; color: rgb(61, 68, 80); font-family: &quot;Microsoft Yahei&quot;, Helvetica, Arial, sans-serif; font-size: 12px; white-space: normal; background-color: rgb(255, 255, 255);\">\u56fe4-13 &nbsp;\u5f3a\u5236\u9000\u51fa\u6587\u672c\u7f16\u8f91\u5668<\/p>\n<p style=\"box-sizing: border-box; margin-top: 0px; margin-bottom: 10px; line-height: 23px; text-indent: 1em; text-align: justify; color: rgb(61, 68, 80); font-family: &quot;Microsoft Yahei&quot;, Helvetica, Arial, sans-serif; font-size: 12px; white-space: normal; background-color: rgb(255, 255, 255);\"><div class='fancybox-wrapper lazyload-container-unload' data-fancybox='post-images' href='https:\/\/www.linuxprobe.com\/wp-content\/uploads\/2015\/03\/%E7%AC%AC13%E6%AD%A5%EF%BC%9A%E6%9F%A5%E7%9C%8B%E6%96%87%E6%A1%A3%EF%BC%8C%E5%8F%91%E7%8E%B0%E7%AC%AC%E4%BA%8C%E5%8F%A5%E7%A1%AE%E5%AE%9E%E6%B2%A1%E4%BF%9D%E5%AD%98.png'><img class=\"lazyload lazyload-style-1\" src=\"data:image\/svg+xml;base64,PCEtLUFyZ29uTG9hZGluZy0tPgo8c3ZnIHdpZHRoPSIxIiBoZWlnaHQ9IjEiIHhtbG5zPSJodHRwOi8vd3d3LnczLm9yZy8yMDAwL3N2ZyIgc3Ryb2tlPSIjZmZmZmZmMDAiPjxnPjwvZz4KPC9zdmc+\"  loading=\"lazy\" decoding=\"async\" class=\"size-full wp-image-739 aligncenter\" data-original=\"https:\/\/www.linuxprobe.com\/wp-content\/uploads\/2015\/03\/%E7%AC%AC13%E6%AD%A5%EF%BC%9A%E6%9F%A5%E7%9C%8B%E6%96%87%E6%A1%A3%EF%BC%8C%E5%8F%91%E7%8E%B0%E7%AC%AC%E4%BA%8C%E5%8F%A5%E7%A1%AE%E5%AE%9E%E6%B2%A1%E4%BF%9D%E5%AD%98.png\" src=\"data:image\/png;base64,iVBORw0KGgoAAAANSUhEUgAAAAEAAAABCAYAAAAfFcSJAAAAAXNSR0IArs4c6QAAAARnQU1BAACxjwv8YQUAAAAJcEhZcwAADsQAAA7EAZUrDhsAAAANSURBVBhXYzh8+PB\/AAffA0nNPuCLAAAAAElFTkSuQmCC\" alt=\"\u7b2c4\u7ae0 Vim\u7f16\u8f91\u5668\u4e0eShell\u547d\u4ee4\u811a\u672c\u3002\u7b2c4\u7ae0 Vim\u7f16\u8f91\u5668\u4e0eShell\u547d\u4ee4\u811a\u672c\u3002\" width=\"737\" height=\"493\"  sizes=\"auto, (max-width: 737px) 100vw, 737px\" title=\"\u7b2c4\u7ae0 Vim\u7f16\u8f91\u5668\u4e0eShell\u547d\u4ee4\u811a\u672c\u3002\u7b2c4\u7ae0 Vim\u7f16\u8f91\u5668\u4e0eShell\u547d\u4ee4\u811a\u672c\u3002\" style=\"box-sizing: border-box; max-width: 100%; border-radius: 4px; vertical-align: middle; height: auto; margin: 10px auto; display: block;\"\/><\/div><\/p>\n<p style=\"box-sizing: border-box; margin-top: 0px; margin-bottom: 10px; line-height: 23px; text-indent: 1em; text-align: center; color: rgb(61, 68, 80); font-family: &quot;Microsoft Yahei&quot;, Helvetica, Arial, sans-serif; font-size: 12px; white-space: normal; background-color: rgb(255, 255, 255);\">\u56fe4-14 &nbsp;\u67e5\u770b\u6700\u7ec8\u7f16\u5199\u6210\u7684\u6587\u672c\u5185\u5bb9<\/p>\n<h6 style=\"box-sizing: border-box; font-family: &quot;Helvetica Neue&quot;, Helvetica, Arial, sans-serif; font-weight: 500; line-height: 1.1; margin-top: 10px; margin-bottom: 10px; font-size: 12px; color: rgb(61, 68, 80); white-space: normal; background-color: rgb(255, 255, 255);\"><span id=\"412\" style=\"box-sizing: border-box;\"><strong style=\"box-sizing: border-box;\"><span style=\"box-sizing: border-box; color: #008000;\">4.1.2 \u914d\u7f6e\u4e3b\u673a\u540d\u79f0<\/span><\/strong><\/span><\/h6>\n<p style=\"box-sizing: border-box; margin-top: 0px; margin-bottom: 10px; line-height: 23px; text-indent: 1em; text-align: justify; color: rgb(61, 68, 80); font-family: &quot;Microsoft Yahei&quot;, Helvetica, Arial, sans-serif; font-size: 12px; white-space: normal; background-color: rgb(255, 255, 255);\">\u4e3a\u4e86\u4fbf\u4e8e\u5728\u5c40\u57df\u7f51\u4e2d\u67e5\u627e\u67d0\u53f0\u7279\u5b9a\u7684\u4e3b\u673a\uff0c\u6216\u8005\u5bf9\u4e3b\u673a\u8fdb\u884c\u533a\u5206\uff0c\u9664\u4e86\u8981\u6709IP\u5730\u5740\u5916\uff0c\u8fd8\u8981\u4e3a\u4e3b\u673a\u914d\u7f6e\u4e00\u4e2a\u4e3b\u673a\u540d\uff0c\u4e3b\u673a\u4e4b\u95f4\u53ef\u4ee5\u901a\u8fc7\u8fd9\u4e2a\u7c7b\u4f3c\u4e8e\u57df\u540d\u7684\u540d\u79f0\u6765\u76f8\u4e92\u8bbf\u95ee\u3002\u5728Linux\u7cfb\u7edf\u4e2d\uff0c\u4e3b\u673a\u540d\u5927\u591a\u4fdd\u5b58\u5728\/etc\/hostname\u6587\u4ef6\u4e2d\uff0c\u63a5\u4e0b\u6765\u5c06\/etc\/hostname\u6587\u4ef6\u7684\u5185\u5bb9\u4fee\u6539\u4e3a\u201clinuxprobe.com\u201d\uff0c\u6b65\u9aa4\u5982\u4e0b\u3002<\/p>\n<blockquote style=\"box-sizing: border-box; padding: 10px 20px; margin: 0px 0px 20px; border-left-width: 5px; border-left-style: solid; border-color: rgba(0, 0, 0, 0.14902); color: rgb(61, 68, 80); font-family: &quot;Microsoft Yahei&quot;, Helvetica, Arial, sans-serif; font-size: 12px; line-height: 17.1429px; white-space: normal; background-color: rgb(255, 255, 255);\">\n<p style=\"box-sizing: border-box; margin-top: 0px; margin-bottom: 10px; font-size: 14px; line-height: 23px; text-indent: 1em; text-align: justify;\"><strong style=\"box-sizing: border-box;\">\u7b2c1\u6b65<\/strong>\uff1a\u4f7f\u7528Vim\u7f16\u8f91\u5668\u4fee\u6539\u201c\/etc\/hostname\u201d\u4e3b\u673a\u540d\u79f0\u6587\u4ef6\u3002<\/p>\n<p style=\"box-sizing: border-box; margin-top: 0px; margin-bottom: 10px; font-size: 14px; line-height: 23px; text-indent: 1em; text-align: justify;\"><strong style=\"box-sizing: border-box;\">\u7b2c2\u6b65<\/strong>\uff1a\u628a\u539f\u59cb\u4e3b\u673a\u540d\u79f0\u5220\u9664\u540e\u8ffd\u52a0\u201clinuxprobe.com\u201d\u3002\u6ce8\u610f\uff0c\u4f7f\u7528Vim\u7f16\u8f91\u5668\u4fee\u6539\u4e3b\u673a\u540d\u79f0\u6587\u4ef6\u540e\uff0c\u8981\u5728\u672b\u884c\u6a21\u5f0f\u4e0b\u6267\u884c:wq!\u547d\u4ee4\u624d\u80fd\u4fdd\u5b58\u5e76\u9000\u51fa\u6587\u6863\u3002<\/p>\n<p style=\"box-sizing: border-box; margin-top: 0px; margin-bottom: 0px; font-size: 14px; line-height: 23px; text-indent: 1em; text-align: justify;\"><strong style=\"box-sizing: border-box;\">\u7b2c3\u6b65<\/strong>\uff1a\u4fdd\u5b58\u5e76\u9000\u51fa\u6587\u6863\uff0c\u7136\u540e\u4f7f\u7528hostname\u547d\u4ee4\u68c0\u67e5\u662f\u5426\u4fee\u6539\u6210\u529f\u3002<\/p>\n<\/blockquote>\n<pre style=\"box-sizing: border-box; font-family: Monaco, Menlo, Consolas, &quot;Courier New&quot;, monospace; font-size: 13px; white-space: pre-wrap; padding: 9.5px; margin-top: 0px; margin-bottom: 10px; line-height: 1.42857; color: rgb(51, 51, 51); word-break: break-all; word-wrap: break-word; border: 1px solid rgb(204, 204, 204); border-radius: 4px; background-color: rgb(245, 245, 245);\">[root@linuxprobe&nbsp;~]#&nbsp;vim&nbsp;\/etc\/hostname\r\nlinuxprobe.com<\/pre>\n<p style=\"box-sizing: border-box; margin-top: 0px; margin-bottom: 10px; line-height: 23px; text-indent: 1em; text-align: justify; color: rgb(61, 68, 80); font-family: &quot;Microsoft Yahei&quot;, Helvetica, Arial, sans-serif; font-size: 12px; white-space: normal; background-color: rgb(255, 255, 255);\">hostname\u547d\u4ee4\u7528\u4e8e\u67e5\u770b\u5f53\u524d\u7684\u4e3b\u673a\u540d\u79f0\uff0c\u4f46\u6709\u65f6\u4e3b\u673a\u540d\u79f0\u7684\u6539\u53d8\u4e0d\u4f1a\u7acb\u5373\u540c\u6b65\u5230\u7cfb\u7edf\u4e2d\uff0c\u6240\u4ee5\u5982\u679c\u53d1\u73b0\u4fee\u6539\u5b8c\u6210\u540e\u8fd8\u663e\u793a\u539f\u6765\u7684\u4e3b\u673a\u540d\u79f0\uff0c\u53ef\u91cd\u542f\u865a\u62df\u673a\u540e\u518d\u884c\u67e5\u770b\uff1a<\/p>\n<pre style=\"box-sizing: border-box; font-family: Monaco, Menlo, Consolas, &quot;Courier New&quot;, monospace; font-size: 13px; white-space: pre-wrap; padding: 9.5px; margin-top: 0px; margin-bottom: 10px; line-height: 1.42857; color: rgb(51, 51, 51); word-break: break-all; word-wrap: break-word; border: 1px solid rgb(204, 204, 204); border-radius: 4px; background-color: rgb(245, 245, 245);\">[root@linuxprobe&nbsp;~]#&nbsp;hostname\r\nlinuxprobe.com<\/pre>\n<h6 style=\"box-sizing: border-box; font-family: &quot;Helvetica Neue&quot;, Helvetica, Arial, sans-serif; font-weight: 500; line-height: 1.1; margin-top: 10px; margin-bottom: 10px; font-size: 12px; color: rgb(61, 68, 80); white-space: normal; background-color: rgb(255, 255, 255);\"><span id=\"413\" style=\"box-sizing: border-box;\"><span style=\"box-sizing: border-box; color: #008000;\"><strong style=\"box-sizing: border-box;\">4.1.3 \u914d\u7f6e\u7f51\u5361\u4fe1\u606f<\/strong><\/span><\/span><\/h6>\n<p style=\"box-sizing: border-box; margin-top: 0px; margin-bottom: 10px; line-height: 23px; text-indent: 1em; text-align: justify; color: rgb(61, 68, 80); font-family: &quot;Microsoft Yahei&quot;, Helvetica, Arial, sans-serif; font-size: 12px; white-space: normal; background-color: rgb(255, 255, 255);\">\u7f51\u5361IP\u5730\u5740\u914d\u7f6e\u7684\u662f\u5426\u6b63\u786e\u662f\u4e24\u53f0\u670d\u52a1\u5668\u662f\u5426\u53ef\u4ee5\u76f8\u4e92\u901a\u4fe1\u7684\u524d\u63d0\u3002\u5728Linux\u7cfb\u7edf\u4e2d\uff0c\u4e00\u5207\u90fd\u662f\u6587\u4ef6\uff0c\u56e0\u6b64\u914d\u7f6e\u7f51\u7edc\u670d\u52a1\u7684\u5de5\u4f5c\u5176\u5b9e\u5c31\u662f\u5728\u7f16\u8f91\u7f51\u5361\u914d\u7f6e\u6587\u4ef6\uff0c\u56e0\u6b64\u8fd9\u4e2a\u5c0f\u4efb\u52a1\u4e0d\u4ec5\u53ef\u4ee5\u5e2e\u52a9\u60a8\u7ec3\u4e60\u4f7f\u7528Vim\u7f16\u8f91\u5668\uff0c\u800c\u4e14\u4e5f\u4e3a\u60a8\u540e\u9762\u5b66\u4e60Linux\u4e2d\u7684\u5404\u79cd\u670d\u52a1\u914d\u7f6e\u6253\u4e0b\u4e86\u575a\u5b9e\u7684\u57fa\u7840\u3002\u5f53\u60a8\u8ba4\u771f\u5b66\u4e60\u5b8c\u672c\u4e66\u540e\uff0c\u4e00\u5b9a\u4f1a\u7279\u522b\u6709\u6210\u5c31\u611f\uff0c\u56e0\u4e3a\u672c\u4e66\u524d\u9762\u7684\u57fa\u7840\u90e8\u5206\u975e\u5e38\u624e\u5b9e\uff0c\u800c\u540e\u9762\u5185\u5bb9\u5219\u5177\u6709\u51e0\u4e4e\u4e00\u81f4\u7684\u7f51\u5361IP\u5730\u5740\u548c\u8fd0\u884c\u73af\u5883\uff0c\u4ece\u800c\u786e\u4fdd\u60a8\u5168\u8eab\u5fc3\u5730\u6295\u5165\u5230\u5404\u7c7b\u670d\u52a1\u7a0b\u5e8f\u7684\u5b66\u4e60\u4e0a\uff0c\u800c\u4e0d\u7528\u64cd\u5fc3\u7cfb\u7edf\u73af\u5883\u7684\u95ee\u9898\u3002<\/p>\n<p style=\"box-sizing: border-box; margin-top: 0px; margin-bottom: 10px; line-height: 23px; text-indent: 1em; text-align: justify; color: rgb(61, 68, 80); font-family: &quot;Microsoft Yahei&quot;, Helvetica, Arial, sans-serif; font-size: 12px; white-space: normal; background-color: rgb(255, 255, 255);\">\u5982\u679c\u60a8\u5177\u5907\u4e00\u5b9a\u7684\u8fd0\u7ef4\u7ecf\u9a8c\u6216\u8005\u719f\u6089\u65e9\u671f\u7684Linux\u7cfb\u7edf\uff0c\u5219\u5728\u5b66\u4e60\u672c\u4e66\u65f6\u4f1a\u9047\u5230\u4e00\u4e9b\u4e0d\u5bb9\u6613\u63a5\u53d7\u7684\u5dee\u5f02\u53d8\u5316\u3002\u5728RHEL 5\u3001RHEL 6\u4e2d\uff0c\u7f51\u5361\u914d\u7f6e\u6587\u4ef6\u7684\u524d\u7f00\u4e3aeth\uff0c\u7b2c1\u5757\u7f51\u5361\u4e3aeth0\uff0c\u7b2c2\u5757\u7f51\u5361\u4e3aeth1\uff1b\u4ee5\u6b64\u7c7b\u63a8\u3002\u800c\u5728RHEL 7\u4e2d\uff0c\u7f51\u5361\u914d\u7f6e\u6587\u4ef6\u7684\u524d\u7f00\u5219\u4ee5ifcfg\u5f00\u59cb\uff0c\u52a0\u4e0a\u7f51\u5361\u540d\u79f0\u5171\u540c\u7ec4\u6210\u4e86\u7f51\u5361\u914d\u7f6e\u6587\u4ef6\u7684\u540d\u5b57\uff0c\u4f8b\u5982ifcfg-eno16777736\uff1b\u597d\u5728\u9664\u4e86\u6587\u4ef6\u540d\u53d8\u5316\u5916\u4e5f\u6ca1\u6709\u5176\u4ed6\u5927\u7684\u533a\u522b\u3002<\/p>\n<p style=\"box-sizing: border-box; margin-top: 0px; margin-bottom: 10px; line-height: 23px; text-indent: 1em; text-align: justify; color: rgb(61, 68, 80); font-family: &quot;Microsoft Yahei&quot;, Helvetica, Arial, sans-serif; font-size: 12px; white-space: normal; background-color: rgb(255, 255, 255);\">\u73b0\u5728\u6709\u4e00\u4e2a\u540d\u79f0\u4e3aifcfg-eno16777736\u7684\u7f51\u5361\u8bbe\u5907\uff0c\u6211\u4eec\u5c06\u5176\u914d\u7f6e\u4e3a\u5f00\u673a\u81ea\u542f\u52a8\uff0c\u5e76\u4e14IP\u5730\u5740\u3001\u5b50\u7f51\u3001\u7f51\u5173\u7b49\u4fe1\u606f\u7531\u4eba\u5de5\u6307\u5b9a\uff0c\u5176\u6b65\u9aa4\u5e94\u8be5\u5982\u4e0b\u6240\u793a\u3002<\/p>\n<p style=\"box-sizing: border-box; margin-top: 0px; margin-bottom: 10px; line-height: 23px; text-indent: 1em; text-align: justify; color: rgb(61, 68, 80); font-family: &quot;Microsoft Yahei&quot;, Helvetica, Arial, sans-serif; font-size: 12px; white-space: normal; background-color: rgb(255, 255, 255);\"><strong style=\"box-sizing: border-box;\">\u7b2c1\u6b65<\/strong>\uff1a\u9996\u5148\u5207\u6362\u5230\/etc\/sysconfig\/network-scripts\u76ee\u5f55\u4e2d\uff08\u5b58\u653e\u7740\u7f51\u5361\u7684\u914d\u7f6e\u6587\u4ef6\uff09\u3002<\/p>\n<p style=\"box-sizing: border-box; margin-top: 0px; margin-bottom: 10px; line-height: 23px; text-indent: 1em; text-align: justify; color: rgb(61, 68, 80); font-family: &quot;Microsoft Yahei&quot;, Helvetica, Arial, sans-serif; font-size: 12px; white-space: normal; background-color: rgb(255, 255, 255);\"><strong style=\"box-sizing: border-box;\">\u7b2c2\u6b65<\/strong>\uff1a\u4f7f\u7528Vim\u7f16\u8f91\u5668\u4fee\u6539\u7f51\u5361\u6587\u4ef6ifcfg-eno16777736\uff0c\u9010\u9879\u5199\u5165\u4e0b\u9762\u7684\u914d\u7f6e\u53c2\u6570\u5e76\u4fdd\u5b58\u9000\u51fa\u3002\u7531\u4e8e\u6bcf\u53f0\u8bbe\u5907\u7684\u786c\u4ef6\u53ca\u67b6\u6784\u662f\u4e0d\u4e00\u6837\u7684\uff0c\u56e0\u6b64\u8bf7\u8bfb\u8005\u4f7f\u7528ifconfig\u547d\u4ee4\u81ea\u884c\u786e\u8ba4\u5404\u81ea\u7f51\u5361\u7684\u9ed8\u8ba4\u540d\u79f0\u3002<\/p>\n<blockquote style=\"box-sizing: border-box; padding: 10px 20px; margin: 0px 0px 20px; border-left-width: 5px; border-left-style: solid; border-color: rgba(0, 0, 0, 0.14902); color: rgb(61, 68, 80); font-family: &quot;Microsoft Yahei&quot;, Helvetica, Arial, sans-serif; font-size: 12px; line-height: 17.1429px; white-space: normal; background-color: rgb(255, 255, 255);\">\n<p style=\"box-sizing: border-box; margin-top: 0px; margin-bottom: 10px; font-size: 14px; line-height: 23px; text-indent: 1em; text-align: justify;\">\u8bbe\u5907\u7c7b\u578b\uff1aTYPE=Ethernet<\/p>\n<p style=\"box-sizing: border-box; margin-top: 0px; margin-bottom: 10px; font-size: 14px; line-height: 23px; text-indent: 1em; text-align: justify;\">\u5730\u5740\u5206\u914d\u6a21\u5f0f\uff1aBOOTPROTO=static<\/p>\n<p style=\"box-sizing: border-box; margin-top: 0px; margin-bottom: 10px; font-size: 14px; line-height: 23px; text-indent: 1em; text-align: justify;\">\u7f51\u5361\u540d\u79f0\uff1aNAME=eno16777736<\/p>\n<p style=\"box-sizing: border-box; margin-top: 0px; margin-bottom: 10px; font-size: 14px; line-height: 23px; text-indent: 1em; text-align: justify;\">\u662f\u5426\u542f\u52a8\uff1aONBOOT=yes<\/p>\n<p style=\"box-sizing: border-box; margin-top: 0px; margin-bottom: 10px; font-size: 14px; line-height: 23px; text-indent: 1em; text-align: justify;\">IP\u5730\u5740\uff1aIPADDR=192.168.10.10<\/p>\n<p style=\"box-sizing: border-box; margin-top: 0px; margin-bottom: 10px; font-size: 14px; line-height: 23px; text-indent: 1em; text-align: justify;\">\u5b50\u7f51\u63a9\u7801\uff1aNETMASK=255.255.255.0<\/p>\n<p style=\"box-sizing: border-box; margin-top: 0px; margin-bottom: 10px; font-size: 14px; line-height: 23px; text-indent: 1em; text-align: justify;\">\u7f51\u5173\u5730\u5740\uff1aGATEWAY=192.168.10.1<\/p>\n<p style=\"box-sizing: border-box; margin-top: 0px; margin-bottom: 0px; font-size: 14px; line-height: 23px; text-indent: 1em; text-align: justify;\">DNS\u5730\u5740\uff1aDNS1=192.168.10.1<\/p>\n<\/blockquote>\n<p style=\"box-sizing: border-box; margin-top: 0px; margin-bottom: 10px; line-height: 23px; text-indent: 1em; text-align: justify; color: rgb(61, 68, 80); font-family: &quot;Microsoft Yahei&quot;, Helvetica, Arial, sans-serif; font-size: 12px; white-space: normal; background-color: rgb(255, 255, 255);\"><strong style=\"box-sizing: border-box;\">\u7b2c3\u6b65<\/strong>\uff1a\u91cd\u542f\u7f51\u7edc\u670d\u52a1\u5e76\u6d4b\u8bd5\u7f51\u7edc\u662f\u5426\u8054\u901a\u3002<\/p>\n<p style=\"box-sizing: border-box; margin-top: 0px; margin-bottom: 10px; line-height: 23px; text-indent: 1em; text-align: justify; color: rgb(61, 68, 80); font-family: &quot;Microsoft Yahei&quot;, Helvetica, Arial, sans-serif; font-size: 12px; white-space: normal; background-color: rgb(255, 255, 255);\">\u8fdb\u5165\u5230\u7f51\u5361\u914d\u7f6e\u6587\u4ef6\u6240\u5728\u7684\u76ee\u5f55\uff0c\u7136\u540e\u7f16\u8f91\u7f51\u5361\u914d\u7f6e\u6587\u4ef6\uff0c\u5728\u5176\u4e2d\u586b\u5165\u4e0b\u9762\u7684\u4fe1\u606f\uff1a<\/p>\n<pre style=\"box-sizing: border-box; font-family: Monaco, Menlo, Consolas, &quot;Courier New&quot;, monospace; font-size: 13px; white-space: pre-wrap; padding: 9.5px; margin-top: 0px; margin-bottom: 10px; line-height: 1.42857; color: rgb(51, 51, 51); word-break: break-all; word-wrap: break-word; border: 1px solid rgb(204, 204, 204); border-radius: 4px; background-color: rgb(245, 245, 245);\">[root@linuxprobe&nbsp;~]#&nbsp;cd&nbsp;\/etc\/sysconfig\/network-scripts\/\r\n[root@linuxprobe&nbsp;network-scripts]#&nbsp;vim&nbsp;ifcfg-eno16777736\r\nTYPE=Ethernet\r\nBOOTPROTO=static\r\nNAME=eno16777736\r\nONBOOT=yes\r\nIPADDR=192.168.10.10\r\nNETMASK=255.255.255.0\r\nGATEWAY=192.168.10.1\r\nDNS1=192.168.10.1<\/pre>\n<p style=\"box-sizing: border-box; margin-top: 0px; margin-bottom: 10px; line-height: 23px; text-indent: 1em; text-align: justify; color: rgb(61, 68, 80); font-family: &quot;Microsoft Yahei&quot;, Helvetica, Arial, sans-serif; font-size: 12px; white-space: normal; background-color: rgb(255, 255, 255);\">\u6267\u884c\u91cd\u542f\u7f51\u5361\u8bbe\u5907\u7684\u547d\u4ee4\uff08\u5728\u6b63\u5e38\u60c5\u51b5\u4e0b\u4e0d\u4f1a\u6709\u63d0\u793a\u4fe1\u606f\uff09\uff0c\u7136\u540e\u901a\u8fc7ping\u547d\u4ee4\u6d4b\u8bd5\u7f51\u7edc\u80fd\u5426\u8054\u901a\u3002\u7531\u4e8e\u5728Linux\u7cfb\u7edf\u4e2dping\u547d\u4ee4\u4e0d\u4f1a\u81ea\u52a8\u7ec8\u6b62\uff0c\u56e0\u6b64\u9700\u8981\u624b\u52a8\u6309\u4e0bCtrl-c\u952e\u6765\u5f3a\u884c\u7ed3\u675f\u8fdb\u7a0b\u3002<\/p>\n<pre style=\"box-sizing: border-box; font-family: Monaco, Menlo, Consolas, &quot;Courier New&quot;, monospace; font-size: 13px; white-space: pre-wrap; padding: 9.5px; margin-top: 0px; margin-bottom: 10px; line-height: 1.42857; color: rgb(51, 51, 51); word-break: break-all; word-wrap: break-word; border: 1px solid rgb(204, 204, 204); border-radius: 4px; background-color: rgb(245, 245, 245);\">[root@linuxprobe&nbsp;network-scripts]#&nbsp;systemctl&nbsp;restart&nbsp;network\r\n[root@linuxprobe&nbsp;network-scripts]#&nbsp;ping&nbsp;192.168.10.10\r\nPING&nbsp;192.168.10.10&nbsp;(192.168.10.10)&nbsp;56(84)&nbsp;bytes&nbsp;of&nbsp;data.\r\n64&nbsp;bytes&nbsp;from&nbsp;192.168.10.10:&nbsp;icmp_seq=1&nbsp;ttl=64&nbsp;time=0.081&nbsp;ms\r\n64&nbsp;bytes&nbsp;from&nbsp;192.168.10.10:&nbsp;icmp_seq=2&nbsp;ttl=64&nbsp;time=0.083&nbsp;ms\r\n64&nbsp;bytes&nbsp;from&nbsp;192.168.10.10:&nbsp;icmp_seq=3&nbsp;ttl=64&nbsp;time=0.059&nbsp;ms\r\n64&nbsp;bytes&nbsp;from&nbsp;192.168.10.10:&nbsp;icmp_seq=4&nbsp;ttl=64&nbsp;time=0.097&nbsp;ms\r\n^C\r\n---&nbsp;192.168.10.10&nbsp;ping&nbsp;statistics&nbsp;---\r\n4&nbsp;packets&nbsp;transmitted,&nbsp;4&nbsp;received,&nbsp;0%&nbsp;packet&nbsp;loss,&nbsp;time&nbsp;2999ms\r\nrtt&nbsp;min\/avg\/max\/mdev&nbsp;=&nbsp;0.059\/0.080\/0.097\/0.013&nbsp;ms<\/pre>\n<h6 style=\"box-sizing: border-box; font-family: &quot;Helvetica Neue&quot;, Helvetica, Arial, sans-serif; font-weight: 500; line-height: 1.1; margin-top: 10px; margin-bottom: 10px; font-size: 12px; color: rgb(61, 68, 80); white-space: normal; background-color: rgb(255, 255, 255);\"><span id=\"414_Yum\" style=\"box-sizing: border-box;\"><span style=\"box-sizing: border-box; color: #008000;\"><strong style=\"box-sizing: border-box;\">4.1.4 \u914d\u7f6eYum\u4ed3\u5e93<\/strong><\/span><\/span><\/h6>\n<p style=\"box-sizing: border-box; margin-top: 0px; margin-bottom: 10px; line-height: 23px; text-indent: 1em; text-align: justify; color: rgb(61, 68, 80); font-family: &quot;Microsoft Yahei&quot;, Helvetica, Arial, sans-serif; font-size: 12px; white-space: normal; background-color: rgb(255, 255, 255);\">\u672c\u4e66\u524d\u9762\u8bb2\u5230\uff0cYum\u8f6f\u4ef6\u4ed3\u5e93\u7684\u4f5c\u7528\u662f\u4e3a\u4e86\u8fdb\u4e00\u6b65\u7b80\u5316RPM\u7ba1\u7406\u8f6f\u4ef6\u7684\u96be\u5ea6\u4ee5\u53ca\u81ea\u52a8\u5206\u6790\u6240\u9700\u8f6f\u4ef6\u5305\u53ca\u5176\u4f9d\u8d56\u5173\u7cfb\u7684\u6280\u672f\u3002\u53ef\u4ee5\u628aYum\u60f3\u8c61\u6210\u662f\u4e00\u4e2a\u7855\u5927\u7684\u8f6f\u4ef6\u4ed3\u5e93\uff0c\u91cc\u9762\u4fdd\u5b58\u6709\u51e0\u4e4e\u6240\u6709\u5e38\u7528\u7684\u5de5\u5177\uff0c\u800c\u4e14\u53ea\u9700\u8981\u8bf4\u51fa\u6240\u9700\u7684\u8f6f\u4ef6\u5305\u540d\u79f0\uff0c\u7cfb\u7edf\u5c31\u4f1a\u81ea\u52a8\u4e3a\u60a8\u641e\u5b9a\u4e00\u5207\u3002<\/p>\n<p style=\"box-sizing: border-box; margin-top: 0px; margin-bottom: 10px; line-height: 23px; text-indent: 1em; text-align: justify; color: rgb(61, 68, 80); font-family: &quot;Microsoft Yahei&quot;, Helvetica, Arial, sans-serif; font-size: 12px; white-space: normal; background-color: rgb(255, 255, 255);\">\u65e2\u7136\u8981\u4f7f\u7528Yum\u8f6f\u4ef6\u4ed3\u5e93\uff0c\u5c31\u8981\u5148\u628a\u5b83\u642d\u5efa\u8d77\u6765\uff0c\u7136\u540e\u5c06\u5176\u914d\u7f6e\u89c4\u5219\u786e\u5b9a\u597d\u624d\u884c\u3002\u9274\u4e8e\u7b2c6\u7ae0\u624d\u4f1a\u8bb2\u89e3Linux\u7684\u5b58\u50a8\u7ed3\u6784\u548c\u8bbe\u5907\u6302\u8f7d\u64cd\u4f5c\uff0c\u6240\u4ee5\u6211\u4eec\u5f53\u524d\u8fd8\u662f\u5c06\u91cd\u5fc3\u653e\u5230Vim\u7f16\u8f91\u5668\u7684\u5b66\u4e60\u4e0a\u3002\u5982\u679c\u9047\u5230\u770b\u4e0d\u61c2\u7684\u53c2\u6570\u4e5f\u4e0d\u8981\u7d27\uff0c\u540e\u9762\u7ae0\u8282\u4f1a\u5355\u72ec\u8bb2\u89e3\u3002\u642d\u5efa\u5e76\u914d\u7f6eYum\u8f6f\u4ef6\u4ed3\u5e93\u7684\u5927\u81f4\u6b65\u9aa4\u5982\u4e0b\u6240\u793a\u3002<\/p>\n<p style=\"box-sizing: border-box; margin-top: 0px; margin-bottom: 10px; line-height: 23px; text-indent: 1em; text-align: justify; color: rgb(61, 68, 80); font-family: &quot;Microsoft Yahei&quot;, Helvetica, Arial, sans-serif; font-size: 12px; white-space: normal; background-color: rgb(255, 255, 255);\"><strong style=\"box-sizing: border-box;\">\u7b2c1\u6b65<\/strong>\uff1a\u8fdb\u5165\u5230\/etc\/yum.repos.d\/\u76ee\u5f55\u4e2d\uff08\u56e0\u4e3a\u8be5\u76ee\u5f55\u5b58\u653e\u7740Yum\u8f6f\u4ef6\u4ed3\u5e93\u7684\u914d\u7f6e\u6587\u4ef6\uff09\u3002<\/p>\n<p style=\"box-sizing: border-box; margin-top: 0px; margin-bottom: 10px; line-height: 23px; text-indent: 1em; text-align: justify; color: rgb(61, 68, 80); font-family: &quot;Microsoft Yahei&quot;, Helvetica, Arial, sans-serif; font-size: 12px; white-space: normal; background-color: rgb(255, 255, 255);\"><strong style=\"box-sizing: border-box;\">\u7b2c2\u6b65<\/strong>\uff1a\u4f7f\u7528Vim\u7f16\u8f91\u5668\u521b\u5efa\u4e00\u4e2a\u540d\u4e3arhel7.repo\u7684\u65b0\u914d\u7f6e\u6587\u4ef6\uff08\u6587\u4ef6\u540d\u79f0\u53ef\u968f\u610f\uff0c\u4f46\u540e\u7f00\u5fc5\u987b\u4e3a.repo\uff09\uff0c\u9010\u9879\u5199\u5165\u4e0b\u9762\u52a0\u7c97\u7684\u914d\u7f6e\u53c2\u6570\u5e76\u4fdd\u5b58\u9000\u51fa\uff08\u4e0d\u8981\u5199\u540e\u9762\u7684\u4e2d\u6587\u6ce8\u91ca\uff09\u3002<\/p>\n<blockquote style=\"box-sizing: border-box; padding: 10px 20px; margin: 0px 0px 20px; border-left-width: 5px; border-left-style: solid; border-color: rgba(0, 0, 0, 0.14902); color: rgb(61, 68, 80); font-family: &quot;Microsoft Yahei&quot;, Helvetica, Arial, sans-serif; font-size: 12px; line-height: 17.1429px; white-space: normal; background-color: rgb(255, 255, 255);\">\n<p style=\"box-sizing: border-box; margin-top: 0px; margin-bottom: 10px; font-size: 14px; line-height: 23px; text-indent: 1em; text-align: justify;\"><strong style=\"box-sizing: border-box;\">[rhel-media]&nbsp;<\/strong>\uff1aYum\u8f6f\u4ef6\u4ed3\u5e93\u552f\u4e00\u6807\u8bc6\u7b26\uff0c\u907f\u514d\u4e0e\u5176\u4ed6\u4ed3\u5e93\u51b2\u7a81\u3002<\/p>\n<p style=\"box-sizing: border-box; margin-top: 0px; margin-bottom: 10px; font-size: 14px; line-height: 23px; text-indent: 1em; text-align: justify;\"><strong style=\"box-sizing: border-box;\">name=linuxprobe<\/strong>\uff1aYum\u8f6f\u4ef6\u4ed3\u5e93\u7684\u540d\u79f0\u63cf\u8ff0\uff0c\u6613\u4e8e\u8bc6\u522b\u4ed3\u5e93\u7528\u5904\u3002<\/p>\n<p style=\"box-sizing: border-box; margin-top: 0px; margin-bottom: 10px; font-size: 14px; line-height: 23px; text-indent: 1em; text-align: justify;\"><strong style=\"box-sizing: border-box;\">baseurl=file:\/\/\/media\/cdrom<\/strong>\uff1a\u63d0\u4f9b\u7684\u65b9\u5f0f\u5305\u62ecFTP\uff08ftp:\/\/..\uff09\u3001HTTP\uff08http:\/\/..\uff09\u3001\u672c\u5730\uff08file:\/\/\/..\uff09\u3002<\/p>\n<p style=\"box-sizing: border-box; margin-top: 0px; margin-bottom: 10px; font-size: 14px; line-height: 23px; text-indent: 1em; text-align: justify;\"><strong style=\"box-sizing: border-box;\">enabled=1<\/strong>\uff1a\u8bbe\u7f6e\u6b64\u6e90\u662f\u5426\u53ef\u7528\uff1b1\u4e3a\u53ef\u7528\uff0c0\u4e3a\u7981\u7528\u3002<\/p>\n<p style=\"box-sizing: border-box; margin-top: 0px; margin-bottom: 10px; font-size: 14px; line-height: 23px; text-indent: 1em; text-align: justify;\"><strong style=\"box-sizing: border-box;\">gpgcheck=1<\/strong>\uff1a\u8bbe\u7f6e\u6b64\u6e90\u662f\u5426\u6821\u9a8c\u6587\u4ef6\uff1b1\u4e3a\u6821\u9a8c\uff0c0\u4e3a\u4e0d\u6821\u9a8c\u3002<\/p>\n<p style=\"box-sizing: border-box; margin-top: 0px; margin-bottom: 0px; font-size: 14px; line-height: 23px; text-indent: 1em; text-align: justify;\"><strong style=\"box-sizing: border-box;\">gpgkey=file:\/\/\/media\/cdrom\/RPM-GPG-KEY-redhat-release<\/strong>\uff1a\u82e5\u4e0a\u9762\u53c2\u6570\u5f00\u542f\u6821\u9a8c\uff0c\u90a3\u4e48\u8bf7\u6307\u5b9a\u516c\u94a5\u6587\u4ef6\u5730\u5740\u3002<\/p>\n<\/blockquote>\n<p style=\"box-sizing: border-box; margin-top: 0px; margin-bottom: 10px; line-height: 23px; text-indent: 1em; text-align: justify; color: rgb(61, 68, 80); font-family: &quot;Microsoft Yahei&quot;, Helvetica, Arial, sans-serif; font-size: 12px; white-space: normal; background-color: rgb(255, 255, 255);\"><strong style=\"box-sizing: border-box;\">\u7b2c3\u6b65<\/strong>\uff1a\u6309\u914d\u7f6e\u53c2\u6570\u7684\u8def\u5f84\u6302\u8f7d\u5149\u76d8\uff0c\u5e76\u628a\u5149\u76d8\u6302\u8f7d\u4fe1\u606f\u5199\u5165\u5230\/etc\/fstab\u6587\u4ef6\u4e2d\u3002<\/p>\n<p style=\"box-sizing: border-box; margin-top: 0px; margin-bottom: 10px; line-height: 23px; text-indent: 1em; text-align: justify; color: rgb(61, 68, 80); font-family: &quot;Microsoft Yahei&quot;, Helvetica, Arial, sans-serif; font-size: 12px; white-space: normal; background-color: rgb(255, 255, 255);\"><strong style=\"box-sizing: border-box;\">\u7b2c4\u6b65<\/strong>\uff1a\u4f7f\u7528\u201cyum install httpd -y\u201d\u547d\u4ee4\u68c0\u67e5Yum\u8f6f\u4ef6\u4ed3\u5e93\u662f\u5426\u5df2\u7ecf\u53ef\u7528\u3002<\/p>\n<p style=\"box-sizing: border-box; margin-top: 0px; margin-bottom: 10px; line-height: 23px; text-indent: 1em; text-align: justify; color: rgb(61, 68, 80); font-family: &quot;Microsoft Yahei&quot;, Helvetica, Arial, sans-serif; font-size: 12px; white-space: normal; background-color: rgb(255, 255, 255);\">\u8fdb\u5165\/etc\/yum.repos.d\u76ee\u5f55\u4e2d\u540e\u521b\u5efaYum\u914d\u7f6e\u6587\u4ef6\uff1a<\/p>\n<pre style=\"box-sizing: border-box; font-family: Monaco, Menlo, Consolas, &quot;Courier New&quot;, monospace; font-size: 13px; white-space: pre-wrap; padding: 9.5px; margin-top: 0px; margin-bottom: 10px; line-height: 1.42857; color: rgb(51, 51, 51); word-break: break-all; word-wrap: break-word; border: 1px solid rgb(204, 204, 204); border-radius: 4px; background-color: rgb(245, 245, 245);\">[root@linuxprobe&nbsp;~]#&nbsp;cd&nbsp;\/etc\/yum.repos.d\/\r\n[root@linuxprobe&nbsp;yum.repos.d]#&nbsp;vim&nbsp;rhel7.repo\r\n[rhel7]\r\nname=rhel7\r\nbaseurl=file:\/\/\/media\/cdrom\r\nenabled=1\r\ngpgcheck=0<\/pre>\n<p style=\"box-sizing: border-box; margin-top: 0px; margin-bottom: 10px; line-height: 23px; text-indent: 1em; text-align: justify; color: rgb(61, 68, 80); font-family: &quot;Microsoft Yahei&quot;, Helvetica, Arial, sans-serif; font-size: 12px; white-space: normal; background-color: rgb(255, 255, 255);\">\u521b\u5efa\u6302\u8f7d\u70b9\u540e\u8fdb\u884c\u6302\u8f7d\u64cd\u4f5c\uff0c\u5e76\u8bbe\u7f6e\u6210\u5f00\u673a\u81ea\u52a8\u6302\u8f7d\uff08\u8be6\u89c1\u7b2c6\u7ae0\uff09\u3002\u5c1d\u8bd5\u4f7f\u7528Yum\u8f6f\u4ef6\u4ed3\u5e93\u6765\u5b89\u88c5Web\u670d\u52a1\uff0c\u51fa\u73b0<strong style=\"box-sizing: border-box;\">Complete<\/strong>\uff01\u5219\u4ee3\u8868\u914d\u7f6e\u6b63\u786e\uff1a<\/p>\n<pre style=\"box-sizing: border-box; font-family: Monaco, Menlo, Consolas, &quot;Courier New&quot;, monospace; font-size: 13px; white-space: pre-wrap; padding: 9.5px; margin-top: 0px; margin-bottom: 10px; line-height: 1.42857; color: rgb(51, 51, 51); word-break: break-all; word-wrap: break-word; border: 1px solid rgb(204, 204, 204); border-radius: 4px; background-color: rgb(245, 245, 245);\">[root@linuxprobe&nbsp;yum.repos.d]#&nbsp;mkdir&nbsp;-p&nbsp;\/media\/cdrom\r\n[root@linuxprobe&nbsp;yum.repos.d]#&nbsp;mount&nbsp;\/dev\/cdrom&nbsp;\/media\/cdrom\r\nmount:&nbsp;\/dev\/sr0&nbsp;is&nbsp;write-protected,&nbsp;mounting&nbsp;read-only\r\n[root@linuxprobe&nbsp;yum.repos.d]#&nbsp;vim&nbsp;\/etc\/fstab\r\n\/dev\/cdrom&nbsp;\/media\/cdrom&nbsp;iso9660&nbsp;defaults&nbsp;0&nbsp;0\r\n[root@linuxprobe&nbsp;~]#&nbsp;yum&nbsp;install&nbsp;httpd\r\nLoaded&nbsp;plugins:&nbsp;langpacks,&nbsp;product-id,&nbsp;subscription-manager\r\n\u2026\u2026\u2026\u2026\u2026\u2026\u7701\u7565\u90e8\u5206\u8f93\u51fa\u4fe1\u606f\u2026\u2026\u2026\u2026\u2026\u2026\r\nDependencies&nbsp;Resolved\r\n================================================================================\r\n&nbsp;Package&nbsp;Arch&nbsp;Version&nbsp;Repository&nbsp;Size\r\n================================================================================\r\nInstalling:\r\n&nbsp;httpd&nbsp;x86_64&nbsp;2.4.6-17.el7&nbsp;rhel&nbsp;1.2&nbsp;M\r\nInstalling&nbsp;for&nbsp;dependencies:\r\n&nbsp;apr&nbsp;x86_64&nbsp;1.4.8-3.el7&nbsp;rhel&nbsp;103&nbsp;k\r\n&nbsp;apr-util&nbsp;x86_64&nbsp;1.5.2-6.el7&nbsp;rhel&nbsp;92&nbsp;k\r\n&nbsp;httpd-tools&nbsp;x86_64&nbsp;2.4.6-17.el7&nbsp;rhel&nbsp;77&nbsp;k\r\n&nbsp;mailcap&nbsp;noarch&nbsp;2.1.41-2.el7&nbsp;rhel&nbsp;31&nbsp;k\r\nTransaction&nbsp;Summary\r\n================================================================================\r\nInstall&nbsp;1&nbsp;Package&nbsp;(+4&nbsp;Dependent&nbsp;packages)\r\nTotal&nbsp;download&nbsp;size:&nbsp;1.5&nbsp;M\r\nInstalled&nbsp;size:&nbsp;4.3&nbsp;M\r\nIs&nbsp;this&nbsp;ok&nbsp;[y\/d\/N]:&nbsp;yDownloading&nbsp;packages:\r\n--------------------------------------------------------------------------------\r\n\u2026\u2026\u2026\u2026\u2026\u2026\u7701\u7565\u90e8\u5206\u8f93\u51fa\u4fe1\u606f\u2026\u2026\u2026\u2026\u2026\u2026Complete!<\/pre>\n<p style=\"box-sizing: border-box; margin-top: 0px; margin-bottom: 10px; line-height: 23px; text-indent: 1em; text-align: justify; color: rgb(61, 68, 80); font-family: &quot;Microsoft Yahei&quot;, Helvetica, Arial, sans-serif; font-size: 12px; white-space: normal; background-color: rgb(255, 255, 255);\"><span style=\"box-sizing: border-box; color: #800080;\"><strong style=\"box-sizing: border-box;\">\u51fa\u73b0\u95ee\u9898?\u5927\u80c6\u63d0\u95ee!<\/strong><\/span><\/p>\n<blockquote style=\"box-sizing: border-box; padding: 10px 20px; margin: 0px 0px 20px; border-left-width: 5px; border-left-style: solid; border-color: rgba(0, 0, 0, 0.14902); color: rgb(61, 68, 80); font-family: &quot;Microsoft Yahei&quot;, Helvetica, Arial, sans-serif; font-size: 12px; line-height: 17.1429px; white-space: normal; background-color: rgb(255, 255, 255);\">\n<p style=\"box-sizing: border-box; margin-top: 0px; margin-bottom: 10px; font-size: 14px; line-height: 23px; text-indent: 1em; text-align: justify;\">\u56e0\u8bfb\u8005\u4eec\u786c\u4ef6\u4e0d\u540c\u6216\u64cd\u4f5c\u9519\u8bef\u90fd\u53ef\u80fd\u5bfc\u81f4\u5b9e\u9a8c\u914d\u7f6e\u51fa\u9519\uff0c\u8bf7\u8010\u5fc3\u518d\u4ed4\u7ec6\u770b\u770b\u64cd\u4f5c\u6b65\u9aa4\u5427\uff0c\u4e0d\u8981\u6c14\u9981~<\/p>\n<p style=\"box-sizing: border-box; margin-top: 0px; margin-bottom: 10px; font-size: 14px; line-height: 23px; text-indent: 1em; text-align: justify;\">Linux\u6280\u672f\u4ea4\u6d41\u8bf7\u52a0A\u7fa4\uff1a560843(<strong style=\"box-sizing: border-box;\"><span style=\"box-sizing: border-box; color: #008000;\">\u6ee1<\/span><\/strong>)\uff0cB\u7fa4\uff1a340829(<span style=\"box-sizing: border-box; color: #008000;\">\u63a8\u8350<\/span>)\uff0cC\u7fa4\uff1a463590\uff08<strong style=\"box-sizing: border-box;\"><span style=\"box-sizing: border-box; color: #008000;\">\u63a8\u8350<\/span><\/strong>\uff09\uff0c<a href=\"https:\/\/www.linuxprobe.com\/club\" style=\"box-sizing: border-box; color: rgb(210, 50, 45); text-decoration: none;\">\u70b9\u6b64\u67e5\u770b\u5168\u56fd\u7fa4<\/a>\u3002<\/p>\n<p style=\"box-sizing: border-box; margin-top: 0px; margin-bottom: 0px; font-size: 14px; line-height: 23px; text-indent: 1em; text-align: justify;\">*\u672c\u7fa4\u7279\u8272\uff1a\u901a\u8fc7\u53e3\u4ee4\u9a8c\u8bc1\u786e\u4fdd\u6bcf\u4e00\u4e2a\u7fa4\u5458\u90fd\u662f\u300aLinux\u5c31\u8be5\u8fd9\u4e48\u5b66\u300b\u7684\u8bfb\u8005\uff0c\u7b54\u7591\u66f4\u6709\u9488\u5bf9\u6027\uff0c\u4e0d\u5b9a\u671f\u514d\u8d39\u9886\u53d6\u5b9a\u5236\u793c\u54c1\u3002<\/p>\n<\/blockquote>\n<h5 style=\"box-sizing: border-box; font-family: &quot;Helvetica Neue&quot;, Helvetica, Arial, sans-serif; font-weight: 100; line-height: 1.1; margin-top: 10px; margin-bottom: 10px; font-size: 14px; color: rgb(61, 68, 80); white-space: normal; background-color: rgb(255, 255, 255);\"><span id=\"42_Shell\" style=\"box-sizing: border-box;\"><span style=\"box-sizing: border-box; color: #008000;\"><strong style=\"box-sizing: border-box;\">4.2 \u7f16\u5199Shell\u811a\u672c<\/strong><\/span><\/span><\/h5>\n<p style=\"box-sizing: border-box; margin-top: 0px; margin-bottom: 10px; line-height: 23px; text-indent: 1em; text-align: justify; color: rgb(61, 68, 80); font-family: &quot;Microsoft Yahei&quot;, Helvetica, Arial, sans-serif; font-size: 12px; white-space: normal; background-color: rgb(255, 255, 255);\">\u53ef\u4ee5\u5c06Shell\u7ec8\u7aef\u89e3\u91ca\u5668\u5f53\u4f5c\u4eba\u4e0e\u8ba1\u7b97\u673a\u786c\u4ef6\u4e4b\u95f4\u7684\u201c\u7ffb\u8bd1\u5b98\u201d\uff0c\u5b83\u4f5c\u4e3a\u7528\u6237\u4e0eLinux\u7cfb\u7edf\u5185\u90e8\u7684\u901a\u4fe1\u5a92\u4ecb\uff0c\u9664\u4e86\u80fd\u591f\u652f\u6301\u5404\u79cd\u53d8\u91cf\u4e0e\u53c2\u6570\u5916\uff0c\u8fd8\u63d0\u4f9b\u4e86\u8bf8\u5982\u5faa\u73af\u3001\u5206\u652f\u7b49\u9ad8\u7ea7\u7f16\u7a0b\u8bed\u8a00\u624d\u6709\u7684\u63a7\u5236\u7ed3\u6784\u7279\u6027\u3002\u8981\u60f3\u6b63\u786e\u4f7f\u7528Shell\u4e2d\u7684\u8fd9\u4e9b\u529f\u80fd\u7279\u6027\uff0c\u51c6\u786e\u4e0b\u8fbe\u547d\u4ee4\u5c24\u4e3a\u91cd\u8981\u3002Shell\u811a\u672c\u547d\u4ee4\u7684\u5de5\u4f5c\u65b9\u5f0f\u6709\u4e24\u79cd\uff1a\u4ea4\u4e92\u5f0f\u548c\u6279\u5904\u7406\u3002<\/p>\n<blockquote style=\"box-sizing: border-box; padding: 10px 20px; margin: 0px 0px 20px; border-left-width: 5px; border-left-style: solid; border-color: rgba(0, 0, 0, 0.14902); color: rgb(61, 68, 80); font-family: &quot;Microsoft Yahei&quot;, Helvetica, Arial, sans-serif; font-size: 12px; line-height: 17.1429px; white-space: normal; background-color: rgb(255, 255, 255);\">\n<p style=\"box-sizing: border-box; margin-top: 0px; margin-bottom: 10px; font-size: 14px; line-height: 23px; text-indent: 1em; text-align: justify;\">\u4ea4\u4e92\u5f0f\uff08Interactive\uff09\uff1a\u7528\u6237\u6bcf\u8f93\u5165\u4e00\u6761\u547d\u4ee4\u5c31\u7acb\u5373\u6267\u884c\u3002<\/p>\n<p style=\"box-sizing: border-box; margin-top: 0px; margin-bottom: 0px; font-size: 14px; line-height: 23px; text-indent: 1em; text-align: justify;\">\u6279\u5904\u7406\uff08Batch\uff09\uff1a\u7531\u7528\u6237\u4e8b\u5148\u7f16\u5199\u597d\u4e00\u4e2a\u5b8c\u6574\u7684Shell\u811a\u672c\uff0cShell\u4f1a\u4e00\u6b21\u6027\u6267\u884c\u811a\u672c\u4e2d\u8bf8\u591a\u7684\u547d\u4ee4\u3002<\/p>\n<\/blockquote>\n<p style=\"box-sizing: border-box; margin-top: 0px; margin-bottom: 10px; line-height: 23px; text-indent: 1em; text-align: justify; color: rgb(61, 68, 80); font-family: &quot;Microsoft Yahei&quot;, Helvetica, Arial, sans-serif; font-size: 12px; white-space: normal; background-color: rgb(255, 255, 255);\">\u5728Shell\u811a\u672c\u4e2d\u4e0d\u4ec5\u4f1a\u7528\u5230\u524d\u9762\u5b66\u4e60\u8fc7\u7684\u5f88\u591a<a href=\"https:\/\/www.linuxprobe.com\/\" title=\"linux\u547d\u4ee4\" target=\"_blank\" style=\"box-sizing: border-box; color: rgb(210, 50, 45); text-decoration: none;\" rel=\"noopener noreferrer\">Linux\u547d\u4ee4<\/a>\u4ee5\u53ca\u6b63\u5219\u8868\u8fbe\u5f0f\u3001\u7ba1\u9053\u7b26\u3001\u6570\u636e\u6d41\u91cd\u5b9a\u5411\u7b49\u8bed\u6cd5\u89c4\u5219\uff0c\u8fd8\u9700\u8981\u628a\u5185\u90e8\u529f\u80fd\u6a21\u5757\u5316\u540e\u901a\u8fc7\u903b\u8f91\u8bed\u53e5\u8fdb\u884c\u5904\u7406\uff0c\u6700\u7ec8\u5f62\u6210\u65e5\u5e38\u6240\u89c1\u7684Shell\u811a\u672c\u3002<\/p>\n<p style=\"box-sizing: border-box; margin-top: 0px; margin-bottom: 10px; line-height: 23px; text-indent: 1em; text-align: justify; color: rgb(61, 68, 80); font-family: &quot;Microsoft Yahei&quot;, Helvetica, Arial, sans-serif; font-size: 12px; white-space: normal; background-color: rgb(255, 255, 255);\">\u67e5\u770bSHELL\u53d8\u91cf\u53ef\u4ee5\u53d1\u73b0\u5f53\u524d\u7cfb\u7edf\u5df2\u7ecf\u9ed8\u8ba4\u4f7f\u7528Bash\u4f5c\u4e3a\u547d\u4ee4\u884c\u7ec8\u7aef\u89e3\u91ca\u5668\u4e86\uff1a<\/p>\n<pre style=\"box-sizing: border-box; font-family: Monaco, Menlo, Consolas, &quot;Courier New&quot;, monospace; font-size: 13px; white-space: pre-wrap; padding: 9.5px; margin-top: 0px; margin-bottom: 10px; line-height: 1.42857; color: rgb(51, 51, 51); word-break: break-all; word-wrap: break-word; border: 1px solid rgb(204, 204, 204); border-radius: 4px; background-color: rgb(245, 245, 245);\">[root@linuxprobe&nbsp;~]#&nbsp;echo&nbsp;$SHELL\r\n\/bin\/bash<\/pre>\n<h6 style=\"box-sizing: border-box; font-family: &quot;Helvetica Neue&quot;, Helvetica, Arial, sans-serif; font-weight: 500; line-height: 1.1; margin-top: 10px; margin-bottom: 10px; font-size: 12px; color: rgb(61, 68, 80); white-space: normal; background-color: rgb(255, 255, 255);\"><span id=\"421\" style=\"box-sizing: border-box;\"><span style=\"box-sizing: border-box; color: #008000;\"><strong style=\"box-sizing: border-box;\">4.2.1 \u7f16\u5199\u7b80\u5355\u7684\u811a\u672c<\/strong><\/span><\/span><\/h6>\n<p style=\"box-sizing: border-box; margin-top: 0px; margin-bottom: 10px; line-height: 23px; text-indent: 1em; text-align: justify; color: rgb(61, 68, 80); font-family: &quot;Microsoft Yahei&quot;, Helvetica, Arial, sans-serif; font-size: 12px; white-space: normal; background-color: rgb(255, 255, 255);\">\u4f30\u8ba1\u8bfb\u8005\u5728\u770b\u5b8c\u4e0a\u6587\u4e2d\u6709\u5173Shell\u811a\u672c\u7684\u590d\u6742\u63cf\u8ff0\u540e\uff0c\u4f1a\u7d2f\u89c9\u4e0d\u7231\u5427\u3002\u4f46\u662f\uff0c\u4e0a\u6587\u6307\u7684\u662f\u4e00\u4e2a\u9ad8\u7ea7Shell\u811a\u672c\u7684\u7f16\u5199\u539f\u5219\uff0c\u5176\u5b9e\u4f7f\u7528Vim\u7f16\u8f91\u5668\u628a<a href=\"https:\/\/www.linuxprobe.com\/\" title=\"linux\u547d\u4ee4\" target=\"_blank\" style=\"box-sizing: border-box; color: rgb(210, 50, 45); text-decoration: none;\" rel=\"noopener noreferrer\">Linux\u547d\u4ee4<\/a>\u6309\u7167\u987a\u5e8f\u4f9d\u6b21\u5199\u5165\u5230\u4e00\u4e2a\u6587\u4ef6\u4e2d\uff0c\u8fd9\u5c31\u662f\u4e00\u4e2a\u7b80\u5355\u7684\u811a\u672c\u4e86\u3002<\/p>\n<p style=\"box-sizing: border-box; margin-top: 0px; margin-bottom: 10px; line-height: 23px; text-indent: 1em; text-align: justify; color: rgb(61, 68, 80); font-family: &quot;Microsoft Yahei&quot;, Helvetica, Arial, sans-serif; font-size: 12px; white-space: normal; background-color: rgb(255, 255, 255);\">\u4f8b\u5982\uff0c\u5982\u679c\u60f3\u67e5\u770b\u5f53\u524d\u6240\u5728\u5de5\u4f5c\u8def\u5f84\u5e76\u5217\u51fa\u5f53\u524d\u76ee\u5f55\u4e0b\u6240\u6709\u7684\u6587\u4ef6\u53ca\u5c5e\u6027\u4fe1\u606f\uff0c\u5b9e\u73b0\u8fd9\u4e2a\u529f\u80fd\u7684\u811a\u672c\u5e94\u8be5\u7c7b\u4f3c\u4e8e\u4e0b\u9762\u8fd9\u6837\uff1a<\/p>\n<pre style=\"box-sizing: border-box; font-family: Monaco, Menlo, Consolas, &quot;Courier New&quot;, monospace; font-size: 13px; white-space: pre-wrap; padding: 9.5px; margin-top: 0px; margin-bottom: 10px; line-height: 1.42857; color: rgb(51, 51, 51); word-break: break-all; word-wrap: break-word; border: 1px solid rgb(204, 204, 204); border-radius: 4px; background-color: rgb(245, 245, 245);\">[root@linuxprobe&nbsp;~]#&nbsp;vim&nbsp;example.sh\r\n#!\/bin\/bash&nbsp;\r\n#For&nbsp;Example&nbsp;BY&nbsp;linuxprobe.com&nbsp;\r\npwd&nbsp;\r\nls&nbsp;-al<\/pre>\n<p style=\"box-sizing: border-box; margin-top: 0px; margin-bottom: 10px; line-height: 23px; text-indent: 1em; text-align: justify; color: rgb(61, 68, 80); font-family: &quot;Microsoft Yahei&quot;, Helvetica, Arial, sans-serif; font-size: 12px; white-space: normal; background-color: rgb(255, 255, 255);\">Shell\u811a\u672c\u6587\u4ef6\u7684\u540d\u79f0\u53ef\u4ee5\u4efb\u610f\uff0c\u4f46\u4e3a\u4e86\u907f\u514d\u88ab\u8bef\u4ee5\u4e3a\u662f\u666e\u901a\u6587\u4ef6\uff0c\u5efa\u8bae\u5c06.sh\u540e\u7f00\u52a0\u4e0a\uff0c\u4ee5\u8868\u793a\u662f\u4e00\u4e2a\u811a\u672c\u6587\u4ef6\u3002\u5728\u4e0a\u9762\u7684\u8fd9\u4e2aexample.sh\u811a\u672c\u4e2d\u5b9e\u9645\u4e0a\u51fa\u73b0\u4e86\u4e09\u79cd\u4e0d\u540c\u7684\u5143\u7d20\uff1a\u7b2c\u4e00\u884c\u7684\u811a\u672c\u58f0\u660e\uff08#!\uff09\u7528\u6765\u544a\u8bc9\u7cfb\u7edf\u4f7f\u7528\u54ea\u79cdShell\u89e3\u91ca\u5668\u6765\u6267\u884c\u8be5\u811a\u672c\uff1b\u7b2c\u4e8c\u884c\u7684\u6ce8\u91ca\u4fe1\u606f\uff08#\uff09\u662f\u5bf9\u811a\u672c\u529f\u80fd\u548c\u67d0\u4e9b\u547d\u4ee4\u7684\u4ecb\u7ecd\u4fe1\u606f\uff0c\u4f7f\u5f97\u81ea\u5df1\u6216\u4ed6\u4eba\u5728\u65e5\u540e\u770b\u5230\u8fd9\u4e2a\u811a\u672c\u5185\u5bb9\u65f6\uff0c\u53ef\u4ee5\u5feb\u901f\u77e5\u9053\u8be5\u811a\u672c\u7684\u4f5c\u7528\u6216\u4e00\u4e9b\u8b66\u544a\u4fe1\u606f\uff1b\u7b2c\u4e09\u3001\u56db\u884c\u7684\u53ef\u6267\u884c\u8bed\u53e5\u4e5f\u5c31\u662f\u6211\u4eec\u5e73\u65f6\u6267\u884c\u7684Linux\u547d\u4ee4\u4e86\u3002\u4ec0\u4e48\uff1f\uff01\u4f60\u4eec\u4e0d\u76f8\u4fe1\u8fd9\u4e48\u7b80\u5355\u5c31\u7f16\u5199\u51fa\u6765\u4e86\u4e00\u4e2a\u811a\u672c\u7a0b\u5e8f\uff0c\u90a3\u6211\u4eec\u6765\u6267\u884c\u4e00\u4e0b\u770b\u770b\u7ed3\u679c\uff1a<\/p>\n<pre style=\"box-sizing: border-box; font-family: Monaco, Menlo, Consolas, &quot;Courier New&quot;, monospace; font-size: 13px; white-space: pre-wrap; padding: 9.5px; margin-top: 0px; margin-bottom: 10px; line-height: 1.42857; color: rgb(51, 51, 51); word-break: break-all; word-wrap: break-word; border: 1px solid rgb(204, 204, 204); border-radius: 4px; background-color: rgb(245, 245, 245);\">[root@linuxprobe&nbsp;~]#&nbsp;bash&nbsp;example.sh\r\n\/root\/Desktop\r\ntotal&nbsp;8\r\ndrwxr-xr-x.&nbsp;2&nbsp;root&nbsp;root&nbsp;23&nbsp;Jul&nbsp;23&nbsp;17:31&nbsp;.\r\ndr-xr-x---.&nbsp;14&nbsp;root&nbsp;root&nbsp;4096&nbsp;Jul&nbsp;23&nbsp;17:31&nbsp;..\r\n-rwxr--r--.&nbsp;1&nbsp;root&nbsp;root&nbsp;55&nbsp;Jul&nbsp;23&nbsp;17:31&nbsp;example.sh<\/pre>\n<p style=\"box-sizing: border-box; margin-top: 0px; margin-bottom: 10px; line-height: 23px; text-indent: 1em; text-align: justify; color: rgb(61, 68, 80); font-family: &quot;Microsoft Yahei&quot;, Helvetica, Arial, sans-serif; font-size: 12px; white-space: normal; background-color: rgb(255, 255, 255);\">\u9664\u4e86\u4e0a\u9762\u7528bash\u89e3\u91ca\u5668\u547d\u4ee4\u76f4\u63a5\u8fd0\u884cShell\u811a\u672c\u6587\u4ef6\u5916\uff0c\u7b2c\u4e8c\u79cd\u8fd0\u884c\u811a\u672c\u7a0b\u5e8f\u7684\u65b9\u6cd5\u662f\u901a\u8fc7\u8f93\u5165\u5b8c\u6574\u8def\u5f84\u7684\u65b9\u5f0f\u6765\u6267\u884c\u3002\u4f46\u9ed8\u8ba4\u4f1a\u56e0\u4e3a\u6743\u9650\u4e0d\u8db3\u800c\u63d0\u793a\u62a5\u9519\u4fe1\u606f\uff0c\u6b64\u65f6\u53ea\u9700\u8981\u4e3a\u811a\u672c\u6587\u4ef6\u589e\u52a0\u6267\u884c\u6743\u9650\u5373\u53ef\uff08\u8be6\u89c1\u7b2c5\u7ae0\uff09\u3002\u521d\u6b21\u5b66\u4e60Linux\u7cfb\u7edf\u7684\u8bfb\u8005\u4e0d\u7528\u5fc3\u6025\uff0c\u7b49\u4e0b\u4e00\u7ae0\u5b66\u5b8c\u7528\u6237\u8eab\u4efd\u548c\u6743\u9650\u540e\u518d\u6765\u505a\u8fd9\u4e2a\u5b9e\u9a8c\u4e5f\u4e0d\u8fdf\uff1a<\/p>\n<pre style=\"box-sizing: border-box; font-family: Monaco, Menlo, Consolas, &quot;Courier New&quot;, monospace; font-size: 13px; white-space: pre-wrap; padding: 9.5px; margin-top: 0px; margin-bottom: 10px; line-height: 1.42857; color: rgb(51, 51, 51); word-break: break-all; word-wrap: break-word; border: 1px solid rgb(204, 204, 204); border-radius: 4px; background-color: rgb(245, 245, 245);\">[root@linuxprobe&nbsp;~]#&nbsp;.\/example.sh\r\nbash:&nbsp;.\/Example.sh:&nbsp;Permission&nbsp;denied\r\n[root@linuxprobe&nbsp;~]#&nbsp;chmod&nbsp;u+x&nbsp;example.sh\r\n[root@linuxprobe&nbsp;~]#&nbsp;.\/example.sh\r\n\/root\/Desktop\r\ntotal&nbsp;8\r\ndrwxr-xr-x.&nbsp;2&nbsp;root&nbsp;root&nbsp;23&nbsp;Jul&nbsp;23&nbsp;17:31&nbsp;.\r\ndr-xr-x---.&nbsp;14&nbsp;root&nbsp;root&nbsp;4096&nbsp;Jul&nbsp;23&nbsp;17:31&nbsp;..\r\n-rwxr--r--.&nbsp;1&nbsp;root&nbsp;root&nbsp;55&nbsp;Jul&nbsp;23&nbsp;17:31&nbsp;example.sh<\/pre>\n<h6 style=\"box-sizing: border-box; font-family: &quot;Helvetica Neue&quot;, Helvetica, Arial, sans-serif; font-weight: 500; line-height: 1.1; margin-top: 10px; margin-bottom: 10px; font-size: 12px; color: rgb(61, 68, 80); white-space: normal; background-color: rgb(255, 255, 255);\"><span id=\"422\" style=\"box-sizing: border-box;\"><span style=\"box-sizing: border-box; color: #008000;\"><strong style=\"box-sizing: border-box;\">4.2.2 \u63a5\u6536\u7528\u6237\u7684\u53c2\u6570<\/strong><\/span><\/span><\/h6>\n<p style=\"box-sizing: border-box; margin-top: 0px; margin-bottom: 10px; line-height: 23px; text-indent: 1em; text-align: justify; color: rgb(61, 68, 80); font-family: &quot;Microsoft Yahei&quot;, Helvetica, Arial, sans-serif; font-size: 12px; white-space: normal; background-color: rgb(255, 255, 255);\">\u4f46\u662f\uff0c\u50cf\u4e0a\u9762\u8fd9\u6837\u7684\u811a\u672c\u7a0b\u5e8f\u53ea\u80fd\u6267\u884c\u4e00\u4e9b\u9884\u5148\u5b9a\u4e49\u597d\u7684\u529f\u80fd\uff0c\u672a\u514d\u592a\u8fc7\u6b7b\u677f\u4e86\u3002\u4e3a\u4e86\u8ba9Shell\u811a\u672c\u7a0b\u5e8f\u66f4\u597d\u5730\u6ee1\u8db3\u7528\u6237\u7684\u4e00\u4e9b\u5b9e\u65f6\u9700\u6c42\uff0c\u4ee5\u4fbf\u7075\u6d3b\u5b8c\u6210\u5de5\u4f5c\uff0c\u5fc5\u987b\u8981\u8ba9\u811a\u672c\u7a0b\u5e8f\u80fd\u591f\u50cf\u4e4b\u524d\u6267\u884c\u547d\u4ee4\u65f6\u90a3\u6837\uff0c\u63a5\u6536\u7528\u6237\u8f93\u5165\u7684\u53c2\u6570\u3002<\/p>\n<p style=\"box-sizing: border-box; margin-top: 0px; margin-bottom: 10px; line-height: 23px; text-indent: 1em; text-align: justify; color: rgb(61, 68, 80); font-family: &quot;Microsoft Yahei&quot;, Helvetica, Arial, sans-serif; font-size: 12px; white-space: normal; background-color: rgb(255, 255, 255);\">\u5176\u5b9e\uff0cLinux\u7cfb\u7edf\u4e2d\u7684Shell\u811a\u672c\u8bed\u8a00\u65e9\u5c31\u8003\u8651\u5230\u4e86\u8fd9\u4e9b\uff0c\u5df2\u7ecf\u5185\u8bbe\u4e86\u7528\u4e8e\u63a5\u6536\u53c2\u6570\u7684\u53d8\u91cf\uff0c\u53d8\u91cf\u4e4b\u95f4\u53ef\u4ee5\u4f7f\u7528\u7a7a\u683c\u95f4\u9694\u3002\u4f8b\u5982$0\u5bf9\u5e94\u7684\u662f\u5f53\u524dShell\u811a\u672c\u7a0b\u5e8f\u7684\u540d\u79f0\uff0c$#\u5bf9\u5e94\u7684\u662f\u603b\u5171\u6709\u51e0\u4e2a\u53c2\u6570\uff0c$*\u5bf9\u5e94\u7684\u662f\u6240\u6709\u4f4d\u7f6e\u7684\u53c2\u6570\u503c\uff0c$?\u5bf9\u5e94\u7684\u662f\u663e\u793a\u4e0a\u4e00\u6b21\u547d\u4ee4\u7684\u6267\u884c\u8fd4\u56de\u503c\uff0c\u800c$1\u3001$2\u3001$3\u2026\u2026\u5219\u5206\u522b\u5bf9\u5e94\u7740\u7b2cN\u4e2a\u4f4d\u7f6e\u7684\u53c2\u6570\u503c\uff0c\u5982\u56fe4-15\u6240\u793a\u3002<\/p>\n<p style=\"box-sizing: border-box; margin-top: 0px; margin-bottom: 10px; line-height: 23px; text-indent: 1em; text-align: justify; color: rgb(61, 68, 80); font-family: &quot;Microsoft Yahei&quot;, Helvetica, Arial, sans-serif; font-size: 12px; white-space: normal; background-color: rgb(255, 255, 255);\"><div class='fancybox-wrapper lazyload-container-unload' data-fancybox='post-images' href='https:\/\/www.linuxprobe.com\/wp-content\/uploads\/2015\/07\/Shell%E8%84%9A%E6%9C%AC%E7%A8%8B%E5%BA%8F%E4%B8%AD%E7%9A%84%E5%8F%82%E6%95%B0%E4%BD%8D%E7%BD%AE%E5%8F%98%E9%87%8F.png'><img class=\"lazyload lazyload-style-1\" src=\"data:image\/svg+xml;base64,PCEtLUFyZ29uTG9hZGluZy0tPgo8c3ZnIHdpZHRoPSIxIiBoZWlnaHQ9IjEiIHhtbG5zPSJodHRwOi8vd3d3LnczLm9yZy8yMDAwL3N2ZyIgc3Ryb2tlPSIjZmZmZmZmMDAiPjxnPjwvZz4KPC9zdmc+\"  loading=\"lazy\" decoding=\"async\" class=\"size-full wp-image-88945 aligncenter\" data-original=\"https:\/\/www.linuxprobe.com\/wp-content\/uploads\/2015\/07\/Shell%E8%84%9A%E6%9C%AC%E7%A8%8B%E5%BA%8F%E4%B8%AD%E7%9A%84%E5%8F%82%E6%95%B0%E4%BD%8D%E7%BD%AE%E5%8F%98%E9%87%8F.png\" src=\"data:image\/png;base64,iVBORw0KGgoAAAANSUhEUgAAAAEAAAABCAYAAAAfFcSJAAAAAXNSR0IArs4c6QAAAARnQU1BAACxjwv8YQUAAAAJcEhZcwAADsQAAA7EAZUrDhsAAAANSURBVBhXYzh8+PB\/AAffA0nNPuCLAAAAAElFTkSuQmCC\" alt=\"\u7b2c4\u7ae0 Vim\u7f16\u8f91\u5668\u4e0eShell\u547d\u4ee4\u811a\u672c\u3002\u7b2c4\u7ae0 Vim\u7f16\u8f91\u5668\u4e0eShell\u547d\u4ee4\u811a\u672c\u3002\" width=\"2540\" height=\"464\"  sizes=\"auto, (max-width: 2540px) 100vw, 2540px\" title=\"\u7b2c4\u7ae0 Vim\u7f16\u8f91\u5668\u4e0eShell\u547d\u4ee4\u811a\u672c\u3002\u7b2c4\u7ae0 Vim\u7f16\u8f91\u5668\u4e0eShell\u547d\u4ee4\u811a\u672c\u3002\" style=\"box-sizing: border-box; max-width: 100%; border-radius: 4px; vertical-align: middle; height: auto; margin: 10px auto; display: block;\"\/><\/div><\/p>\n<p style=\"box-sizing: border-box; margin-top: 0px; margin-bottom: 10px; line-height: 23px; text-indent: 1em; text-align: center; color: rgb(61, 68, 80); font-family: &quot;Microsoft Yahei&quot;, Helvetica, Arial, sans-serif; font-size: 12px; white-space: normal; background-color: rgb(255, 255, 255);\">\u56fe4-15&nbsp; Shell\u811a\u672c\u7a0b\u5e8f\u4e2d\u7684\u53c2\u6570\u4f4d\u7f6e\u53d8\u91cf<\/p>\n<p style=\"box-sizing: border-box; margin-top: 0px; margin-bottom: 10px; line-height: 23px; text-indent: 1em; text-align: justify; color: rgb(61, 68, 80); font-family: &quot;Microsoft Yahei&quot;, Helvetica, Arial, sans-serif; font-size: 12px; white-space: normal; background-color: rgb(255, 255, 255);\">\u7406\u8bba\u8fc7\u540e\u6211\u4eec\u6765\u7ec3\u4e60\u4e00\u4e0b\u3002\u5c1d\u8bd5\u7f16\u5199\u4e00\u4e2a\u811a\u672c\u7a0b\u5e8f\u793a\u4f8b\uff0c\u901a\u8fc7\u5f15\u7528\u4e0a\u9762\u7684\u53d8\u91cf\u53c2\u6570\u6765\u770b\u4e0b\u771f\u5b9e\u6548\u679c\uff1a<\/p>\n<pre style=\"box-sizing: border-box; font-family: Monaco, Menlo, Consolas, &quot;Courier New&quot;, monospace; font-size: 13px; white-space: pre-wrap; padding: 9.5px; margin-top: 0px; margin-bottom: 10px; line-height: 1.42857; color: rgb(51, 51, 51); word-break: break-all; word-wrap: break-word; border: 1px solid rgb(204, 204, 204); border-radius: 4px; background-color: rgb(245, 245, 245);\">[root@linuxprobe&nbsp;~]#&nbsp;vim&nbsp;example.sh\r\n#!\/bin\/bash\r\necho&nbsp;&quot;\u5f53\u524d\u811a\u672c\u540d\u79f0\u4e3a$0&quot;\r\necho&nbsp;&quot;\u603b\u5171\u6709$#\u4e2a\u53c2\u6570\uff0c\u5206\u522b\u662f$*\u3002&quot;\r\necho&nbsp;&quot;\u7b2c1\u4e2a\u53c2\u6570\u4e3a$1\uff0c\u7b2c5\u4e2a\u4e3a$5\u3002&quot;\r\n[root@linuxprobe&nbsp;~]#&nbsp;sh&nbsp;example.sh&nbsp;one&nbsp;two&nbsp;three&nbsp;four&nbsp;five&nbsp;six\r\n\u5f53\u524d\u811a\u672c\u540d\u79f0\u4e3aexample.sh\r\n\u603b\u5171\u67096\u4e2a\u53c2\u6570\uff0c\u5206\u522b\u662fone&nbsp;two&nbsp;three&nbsp;four&nbsp;five&nbsp;six\u3002\r\n\u7b2c1\u4e2a\u53c2\u6570\u4e3aone\uff0c\u7b2c5\u4e2a\u4e3afive\u3002<\/pre>\n<h6 style=\"box-sizing: border-box; font-family: &quot;Helvetica Neue&quot;, Helvetica, Arial, sans-serif; font-weight: 500; line-height: 1.1; margin-top: 10px; margin-bottom: 10px; font-size: 12px; color: rgb(61, 68, 80); white-space: normal; background-color: rgb(255, 255, 255);\"><span id=\"423\" style=\"box-sizing: border-box;\"><span style=\"box-sizing: border-box; color: #008000;\"><strong style=\"box-sizing: border-box;\">4.2.3 \u5224\u65ad\u7528\u6237\u7684\u53c2\u6570<\/strong><\/span><\/span><\/h6>\n<p style=\"box-sizing: border-box; margin-top: 0px; margin-bottom: 10px; line-height: 23px; text-indent: 1em; text-align: justify; color: rgb(61, 68, 80); font-family: &quot;Microsoft Yahei&quot;, Helvetica, Arial, sans-serif; font-size: 12px; white-space: normal; background-color: rgb(255, 255, 255);\">\u5b66\u4e60\u662f\u4e00\u4e2a\u767b\u5802\u5165\u5ba4\u3001\u7531\u6d45\u5165\u6df1\u7684\u8fc7\u7a0b\u3002\u5728\u5b66\u4e60\u5b8cLinux\u547d\u4ee4\u3001\u638c\u63e1Shell\u811a\u672c\u8bed\u6cd5\u53d8\u91cf\u548c\u63a5\u6536\u7528\u6237\u8f93\u5165\u7684\u4fe1\u606f\u4e4b\u540e\uff0c\u5c31\u8981\u8e0f\u4e0a\u65b0\u7684\u9ad8\u5ea6\u2014\u80fd\u591f\u8fdb\u4e00\u6b65\u5904\u7406\u63a5\u6536\u5230\u7684\u7528\u6237\u53c2\u6570\u3002<\/p>\n<p style=\"box-sizing: border-box; margin-top: 0px; margin-bottom: 10px; line-height: 23px; text-indent: 1em; text-align: justify; color: rgb(61, 68, 80); font-family: &quot;Microsoft Yahei&quot;, Helvetica, Arial, sans-serif; font-size: 12px; white-space: normal; background-color: rgb(255, 255, 255);\">\u5728\u672c\u4e66\u524d\u9762\u7ae0\u8282\u4e2d\u8bb2\u5230\uff0c\u7cfb\u7edf\u5728\u6267\u884cmkdir\u547d\u4ee4\u65f6\u4f1a\u5224\u65ad\u7528\u6237\u8f93\u5165\u7684\u4fe1\u606f\uff0c\u5373\u5224\u65ad\u7528\u6237\u6307\u5b9a\u7684\u6587\u4ef6\u5939\u540d\u79f0\u662f\u5426\u5df2\u7ecf\u5b58\u5728\uff0c\u5982\u679c\u5b58\u5728\u5219\u63d0\u793a\u62a5\u9519\uff1b\u53cd\u4e4b\u5219\u81ea\u52a8\u521b\u5efa\u3002Shell\u811a\u672c\u4e2d\u7684\u6761\u4ef6\u6d4b\u8bd5\u8bed\u6cd5\u53ef\u4ee5\u5224\u65ad\u8868\u8fbe\u5f0f\u662f\u5426\u6210\u7acb\uff0c\u82e5\u6761\u4ef6\u6210\u7acb\u5219\u8fd4\u56de\u6570\u5b570\uff0c\u5426\u5219\u4fbf\u8fd4\u56de\u5176\u4ed6\u968f\u673a\u6570\u503c\u3002\u6761\u4ef6\u6d4b\u8bd5\u8bed\u6cd5\u7684\u6267\u884c\u683c\u5f0f\u5982\u56fe4-16\u6240\u793a\u3002\u5207\u8bb0\uff0c\u6761\u4ef6\u8868\u8fbe\u5f0f\u4e24\u8fb9\u5747\u5e94\u6709\u4e00\u4e2a\u7a7a\u683c\u3002<\/p>\n<p style=\"box-sizing: border-box; margin-top: 0px; margin-bottom: 10px; line-height: 23px; text-indent: 1em; text-align: justify; color: rgb(61, 68, 80); font-family: &quot;Microsoft Yahei&quot;, Helvetica, Arial, sans-serif; font-size: 12px; white-space: normal; background-color: rgb(255, 255, 255);\"><div class='fancybox-wrapper lazyload-container-unload' data-fancybox='post-images' href='https:\/\/www.linuxprobe.com\/wp-content\/uploads\/2015\/07\/%E6%B5%8B%E8%AF%95%E8%AF%AD%E5%8F%A5%E6%A0%BC%E5%BC%8F.png'><img class=\"lazyload lazyload-style-1\" src=\"data:image\/svg+xml;base64,PCEtLUFyZ29uTG9hZGluZy0tPgo8c3ZnIHdpZHRoPSIxIiBoZWlnaHQ9IjEiIHhtbG5zPSJodHRwOi8vd3d3LnczLm9yZy8yMDAwL3N2ZyIgc3Ryb2tlPSIjZmZmZmZmMDAiPjxnPjwvZz4KPC9zdmc+\"  loading=\"lazy\" decoding=\"async\" class=\" size-full wp-image-1578 aligncenter\" data-original=\"https:\/\/www.linuxprobe.com\/wp-content\/uploads\/2015\/07\/%E6%B5%8B%E8%AF%95%E8%AF%AD%E5%8F%A5%E6%A0%BC%E5%BC%8F.png\" src=\"data:image\/png;base64,iVBORw0KGgoAAAANSUhEUgAAAAEAAAABCAYAAAAfFcSJAAAAAXNSR0IArs4c6QAAAARnQU1BAACxjwv8YQUAAAAJcEhZcwAADsQAAA7EAZUrDhsAAAANSURBVBhXYzh8+PB\/AAffA0nNPuCLAAAAAElFTkSuQmCC\" alt=\"\u7b2c4\u7ae0 Vim\u7f16\u8f91\u5668\u4e0eShell\u547d\u4ee4\u811a\u672c\u3002\u7b2c4\u7ae0 Vim\u7f16\u8f91\u5668\u4e0eShell\u547d\u4ee4\u811a\u672c\u3002\" width=\"334\" height=\"74\"  sizes=\"auto, (max-width: 334px) 100vw, 334px\" title=\"\u7b2c4\u7ae0 Vim\u7f16\u8f91\u5668\u4e0eShell\u547d\u4ee4\u811a\u672c\u3002\u7b2c4\u7ae0 Vim\u7f16\u8f91\u5668\u4e0eShell\u547d\u4ee4\u811a\u672c\u3002\" style=\"box-sizing: border-box; max-width: 100%; border-radius: 4px; vertical-align: middle; height: auto; margin: 10px auto; display: block;\"\/><\/div><\/p>\n<p style=\"box-sizing: border-box; margin-top: 0px; margin-bottom: 10px; line-height: 23px; text-indent: 1em; text-align: center; color: rgb(61, 68, 80); font-family: &quot;Microsoft Yahei&quot;, Helvetica, Arial, sans-serif; font-size: 12px; white-space: normal; background-color: rgb(255, 255, 255);\">\u56fe4-16&nbsp; \u6761\u4ef6\u6d4b\u8bd5\u8bed\u53e5\u7684\u6267\u884c\u683c\u5f0f<\/p>\n<hr style=\"box-sizing: content-box; height: 0px; margin-top: 20px; margin-bottom: 20px; border-right-width: 0px; border-bottom-width: 0px; border-left-width: 0px; border-top-style: solid; border-top-color: rgb(238, 238, 238); color: rgb(61, 68, 80); font-family: &quot;Microsoft Yahei&quot;, Helvetica, Arial, sans-serif; font-size: 12px; line-height: 17.1429px; white-space: normal; background-color: rgb(255, 255, 255);\"\/>\n<p style=\"box-sizing: border-box; margin-top: 0px; margin-bottom: 10px; line-height: 23px; text-indent: 1em; text-align: justify; color: rgb(61, 68, 80); font-family: &quot;Microsoft Yahei&quot;, Helvetica, Arial, sans-serif; font-size: 12px; white-space: normal; background-color: rgb(255, 255, 255);\">\u6309\u7167\u6d4b\u8bd5\u5bf9\u8c61\u6765\u5212\u5206\uff0c\u6761\u4ef6\u6d4b\u8bd5\u8bed\u53e5\u53ef\u4ee5\u5206\u4e3a4\u79cd\uff1a<\/p>\n<blockquote style=\"box-sizing: border-box; padding: 10px 20px; margin: 0px 0px 20px; border-left-width: 5px; border-left-style: solid; border-color: rgba(0, 0, 0, 0.14902); color: rgb(61, 68, 80); font-family: &quot;Microsoft Yahei&quot;, Helvetica, Arial, sans-serif; font-size: 12px; line-height: 17.1429px; white-space: normal; background-color: rgb(255, 255, 255);\">\n<p style=\"box-sizing: border-box; margin-top: 0px; margin-bottom: 10px; font-size: 14px; line-height: 23px; text-indent: 1em; text-align: justify;\">\u6587\u4ef6\u6d4b\u8bd5\u8bed\u53e5\uff1b<\/p>\n<p style=\"box-sizing: border-box; margin-top: 0px; margin-bottom: 10px; font-size: 14px; line-height: 23px; text-indent: 1em; text-align: justify;\">\u903b\u8f91\u6d4b\u8bd5\u8bed\u53e5\uff1b<\/p>\n<p style=\"box-sizing: border-box; margin-top: 0px; margin-bottom: 10px; font-size: 14px; line-height: 23px; text-indent: 1em; text-align: justify;\">\u6574\u6570\u503c\u6bd4\u8f83\u8bed\u53e5\uff1b<\/p>\n<p style=\"box-sizing: border-box; margin-top: 0px; margin-bottom: 0px; font-size: 14px; line-height: 23px; text-indent: 1em; text-align: justify;\">\u5b57\u7b26\u4e32\u6bd4\u8f83\u8bed\u53e5\u3002<\/p>\n<\/blockquote>\n<p style=\"box-sizing: border-box; margin-top: 0px; margin-bottom: 10px; line-height: 23px; text-indent: 1em; text-align: justify; color: rgb(61, 68, 80); font-family: &quot;Microsoft Yahei&quot;, Helvetica, Arial, sans-serif; font-size: 12px; white-space: normal; background-color: rgb(255, 255, 255);\">\u6587\u4ef6\u6d4b\u8bd5\u5373\u4f7f\u7528\u6307\u5b9a\u6761\u4ef6\u6765\u5224\u65ad\u6587\u4ef6\u662f\u5426\u5b58\u5728\u6216\u6743\u9650\u662f\u5426\u6ee1\u8db3\u7b49\u60c5\u51b5\u7684\u8fd0\u7b97\u7b26\uff0c\u5177\u4f53\u7684\u53c2\u6570\u5982\u88684-3\u6240\u793a\u3002<\/p>\n<p style=\"box-sizing: border-box; margin-top: 0px; margin-bottom: 10px; line-height: 23px; text-indent: 1em; text-align: justify; color: rgb(61, 68, 80); font-family: &quot;Microsoft Yahei&quot;, Helvetica, Arial, sans-serif; font-size: 12px; white-space: normal; background-color: rgb(255, 255, 255);\">\u88684-3&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp; \u6587\u4ef6\u6d4b\u8bd5\u6240\u7528\u7684\u53c2\u6570<\/p>\n<table id=\"tablepress-90\" class=\"tablepress tablepress-id-90\" width=\"712\">\n<tbody class=\"row-hover\" style=\"box-sizing: border-box;\">\n<tr class=\"row-1 odd firstRow\" style=\"box-sizing: border-box;\">\n<td class=\"column-1\" style=\"box-sizing: border-box; padding: 8px; border-top-width: 0px; border-right-style: none; border-bottom-style: none; border-left-style: none; border-color: initial; vertical-align: top; float: none !important; background: 0px 0px rgb(249, 249, 249);\">\u64cd\u4f5c\u7b26<\/td>\n<td class=\"column-2\" style=\"box-sizing: border-box; padding: 8px; border-top-width: 0px; border-right-style: none; border-bottom-style: none; border-left-style: none; border-color: initial; vertical-align: top; float: none !important; background: 0px 0px rgb(249, 249, 249);\">\u4f5c\u7528<\/td>\n<\/tr>\n<tr class=\"row-2 even\" style=\"box-sizing: border-box;\">\n<td class=\"column-1\" style=\"box-sizing: border-box; padding: 8px; border-right-style: none; border-bottom-style: none; border-left-style: none; vertical-align: top; float: none !important; background-image: initial; background-attachment: initial; background-size: initial; background-origin: initial; background-clip: initial; background-position: 0px 0px; background-repeat: initial;\">-d<\/td>\n<td class=\"column-2\" style=\"box-sizing: border-box; padding: 8px; border-right-style: none; border-bottom-style: none; border-left-style: none; vertical-align: top; float: none !important; background-image: initial; background-attachment: initial; background-size: initial; background-origin: initial; background-clip: initial; background-position: 0px 0px; background-repeat: initial;\">\u6d4b\u8bd5\u6587\u4ef6\u662f\u5426\u4e3a\u76ee\u5f55\u7c7b\u578b<\/td>\n<\/tr>\n<tr class=\"row-3 odd\" style=\"box-sizing: border-box;\">\n<td class=\"column-1\" style=\"box-sizing: border-box; padding: 8px; border-right-style: none; border-bottom-style: none; border-left-style: none; vertical-align: top; float: none !important; background: 0px 0px rgb(249, 249, 249);\">-e<\/td>\n<td class=\"column-2\" style=\"box-sizing: border-box; padding: 8px; border-right-style: none; border-bottom-style: none; border-left-style: none; vertical-align: top; float: none !important; background: 0px 0px rgb(249, 249, 249);\">\u6d4b\u8bd5\u6587\u4ef6\u662f\u5426\u5b58\u5728<\/td>\n<\/tr>\n<tr class=\"row-4 even\" style=\"box-sizing: border-box;\">\n<td class=\"column-1\" style=\"box-sizing: border-box; padding: 8px; border-right-style: none; border-bottom-style: none; border-left-style: none; vertical-align: top; float: none !important; background-image: initial; background-attachment: initial; background-size: initial; background-origin: initial; background-clip: initial; background-position: 0px 0px; background-repeat: initial;\">-f<\/td>\n<td class=\"column-2\" style=\"box-sizing: border-box; padding: 8px; border-right-style: none; border-bottom-style: none; border-left-style: none; vertical-align: top; float: none !important; background-image: initial; background-attachment: initial; background-size: initial; background-origin: initial; background-clip: initial; background-position: 0px 0px; background-repeat: initial;\">\u5224\u65ad\u662f\u5426\u4e3a\u4e00\u822c\u6587\u4ef6<\/td>\n<\/tr>\n<tr class=\"row-5 odd\" style=\"box-sizing: border-box;\">\n<td class=\"column-1\" style=\"box-sizing: border-box; padding: 8px; border-right-style: none; border-bottom-style: none; border-left-style: none; vertical-align: top; float: none !important; background: 0px 0px rgb(249, 249, 249);\">-r<\/td>\n<td class=\"column-2\" style=\"box-sizing: border-box; padding: 8px; border-right-style: none; border-bottom-style: none; border-left-style: none; vertical-align: top; float: none !important; background: 0px 0px rgb(249, 249, 249);\">\u6d4b\u8bd5\u5f53\u524d\u7528\u6237\u662f\u5426\u6709\u6743\u9650\u8bfb\u53d6<\/td>\n<\/tr>\n<tr class=\"row-6 even\" style=\"box-sizing: border-box;\">\n<td class=\"column-1\" style=\"box-sizing: border-box; padding: 8px; border-right-style: none; border-bottom-style: none; border-left-style: none; vertical-align: top; float: none !important; background-image: initial; background-attachment: initial; background-size: initial; background-origin: initial; background-clip: initial; background-position: 0px 0px; background-repeat: initial;\">-w<\/td>\n<td class=\"column-2\" style=\"box-sizing: border-box; padding: 8px; border-right-style: none; border-bottom-style: none; border-left-style: none; vertical-align: top; float: none !important; background-image: initial; background-attachment: initial; background-size: initial; background-origin: initial; background-clip: initial; background-position: 0px 0px; background-repeat: initial;\">\u6d4b\u8bd5\u5f53\u524d\u7528\u6237\u662f\u5426\u6709\u6743\u9650\u5199\u5165<\/td>\n<\/tr>\n<tr class=\"row-7 odd\" style=\"box-sizing: border-box;\">\n<td class=\"column-1\" style=\"box-sizing: border-box; padding: 8px; border-right-style: none; border-bottom-style: none; border-left-style: none; vertical-align: top; float: none !important; background: 0px 0px rgb(249, 249, 249);\">-x<\/td>\n<td class=\"column-2\" style=\"box-sizing: border-box; padding: 8px; border-right-style: none; border-bottom-style: none; border-left-style: none; vertical-align: top; float: none !important; background: 0px 0px rgb(249, 249, 249);\">\u6d4b\u8bd5\u5f53\u524d\u7528\u6237\u662f\u5426\u6709\u6743\u9650\u6267\u884c<\/td>\n<\/tr>\n<\/tbody>\n<\/table>\n<p style=\"box-sizing: border-box; margin-top: 0px; margin-bottom: 10px; line-height: 23px; text-indent: 1em; text-align: justify; color: rgb(61, 68, 80); font-family: &quot;Microsoft Yahei&quot;, Helvetica, Arial, sans-serif; font-size: 12px; white-space: normal; background-color: rgb(255, 255, 255);\"><\/p>\n<p style=\"box-sizing: border-box; margin-top: 0px; margin-bottom: 10px; line-height: 23px; text-indent: 1em; text-align: justify; color: rgb(61, 68, 80); font-family: &quot;Microsoft Yahei&quot;, Helvetica, Arial, sans-serif; font-size: 12px; white-space: normal; background-color: rgb(255, 255, 255);\">\u4e0b\u9762\u4f7f\u7528\u6587\u4ef6\u6d4b\u8bd5\u8bed\u53e5\u6765\u5224\u65ad\/etc\/fstab\u662f\u5426\u4e3a\u4e00\u4e2a\u76ee\u5f55\u7c7b\u578b\u7684\u6587\u4ef6\uff0c\u7136\u540e\u901a\u8fc7Shell\u89e3\u91ca\u5668\u7684\u5185\u8bbe$?\u53d8\u91cf\u663e\u793a\u4e0a\u4e00\u6761\u547d\u4ee4\u6267\u884c\u540e\u7684\u8fd4\u56de\u503c\u3002\u5982\u679c\u8fd4\u56de\u503c\u4e3a0\uff0c\u5219\u76ee\u5f55\u5b58\u5728\uff1b\u5982\u679c\u8fd4\u56de\u503c\u4e3a\u975e\u96f6\u7684\u503c\uff0c\u5219\u610f\u5473\u7740\u76ee\u5f55\u4e0d\u5b58\u5728\uff1a<\/p>\n<pre style=\"box-sizing: border-box; font-family: Monaco, Menlo, Consolas, &quot;Courier New&quot;, monospace; font-size: 13px; white-space: pre-wrap; padding: 9.5px; margin-top: 0px; margin-bottom: 10px; line-height: 1.42857; color: rgb(51, 51, 51); word-break: break-all; word-wrap: break-word; border: 1px solid rgb(204, 204, 204); border-radius: 4px; background-color: rgb(245, 245, 245);\">[root@linuxprobe&nbsp;~]#&nbsp;[&nbsp;-d&nbsp;\/etc\/fstab&nbsp;]\r\n[root@linuxprobe&nbsp;~]#&nbsp;echo&nbsp;$?\r\n1<\/pre>\n<p style=\"box-sizing: border-box; margin-top: 0px; margin-bottom: 10px; line-height: 23px; text-indent: 1em; text-align: justify; color: rgb(61, 68, 80); font-family: &quot;Microsoft Yahei&quot;, Helvetica, Arial, sans-serif; font-size: 12px; white-space: normal; background-color: rgb(255, 255, 255);\">\u518d\u4f7f\u7528\u6587\u4ef6\u6d4b\u8bd5\u8bed\u53e5\u6765\u5224\u65ad\/etc\/fstab\u662f\u5426\u4e3a\u4e00\u822c\u6587\u4ef6\uff0c\u5982\u679c\u8fd4\u56de\u503c\u4e3a0\uff0c\u5219\u4ee3\u8868\u6587\u4ef6\u5b58\u5728\uff0c\u4e14\u4e3a\u4e00\u822c\u6587\u4ef6\uff1a<\/p>\n<pre style=\"box-sizing: border-box; font-family: Monaco, Menlo, Consolas, &quot;Courier New&quot;, monospace; font-size: 13px; white-space: pre-wrap; padding: 9.5px; margin-top: 0px; margin-bottom: 10px; line-height: 1.42857; color: rgb(51, 51, 51); word-break: break-all; word-wrap: break-word; border: 1px solid rgb(204, 204, 204); border-radius: 4px; background-color: rgb(245, 245, 245);\">[root@linuxprobe&nbsp;~]#&nbsp;[&nbsp;-f&nbsp;\/etc\/fstab&nbsp;]\r\n[root@linuxprobe&nbsp;~]#&nbsp;echo&nbsp;$?\r\n0<\/pre>\n<p style=\"box-sizing: border-box; margin-top: 0px; margin-bottom: 10px; line-height: 23px; text-indent: 1em; text-align: justify; color: rgb(61, 68, 80); font-family: &quot;Microsoft Yahei&quot;, Helvetica, Arial, sans-serif; font-size: 12px; white-space: normal; background-color: rgb(255, 255, 255);\">\u903b\u8f91\u8bed\u53e5\u7528\u4e8e\u5bf9\u6d4b\u8bd5\u7ed3\u679c\u8fdb\u884c\u903b\u8f91\u5206\u6790\uff0c\u6839\u636e\u6d4b\u8bd5\u7ed3\u679c\u53ef\u5b9e\u73b0\u4e0d\u540c\u7684\u6548\u679c\u3002\u4f8b\u5982\u5728Shell\u7ec8\u7aef\u4e2d\u903b\u8f91\u201c\u4e0e\u201d\u7684\u8fd0\u7b97\u7b26\u53f7\u662f&amp;&amp;\uff0c\u5b83\u8868\u793a\u5f53\u524d\u9762\u7684\u547d\u4ee4\u6267\u884c\u6210\u529f\u540e\u624d\u4f1a\u6267\u884c\u5b83\u540e\u9762\u7684\u547d\u4ee4\uff0c\u56e0\u6b64\u53ef\u4ee5\u7528\u6765\u5224\u65ad\/dev\/cdrom\u6587\u4ef6\u662f\u5426\u5b58\u5728\uff0c\u82e5\u5b58\u5728\u5219\u8f93\u51faExist\u5b57\u6837\u3002<\/p>\n<pre style=\"box-sizing: border-box; font-family: Monaco, Menlo, Consolas, &quot;Courier New&quot;, monospace; font-size: 13px; white-space: pre-wrap; padding: 9.5px; margin-top: 0px; margin-bottom: 10px; line-height: 1.42857; color: rgb(51, 51, 51); word-break: break-all; word-wrap: break-word; border: 1px solid rgb(204, 204, 204); border-radius: 4px; background-color: rgb(245, 245, 245);\">[root@linuxprobe&nbsp;~]#&nbsp;[&nbsp;-e&nbsp;\/dev\/cdrom&nbsp;]&nbsp;&amp;&amp;&nbsp;echo&nbsp;&quot;Exist&quot;\r\nExist<\/pre>\n<p style=\"box-sizing: border-box; margin-top: 0px; margin-bottom: 10px; line-height: 23px; text-indent: 1em; text-align: justify; color: rgb(61, 68, 80); font-family: &quot;Microsoft Yahei&quot;, Helvetica, Arial, sans-serif; font-size: 12px; white-space: normal; background-color: rgb(255, 255, 255);\">\u9664\u4e86\u903b\u8f91\u201c\u4e0e\u201d\u5916\uff0c\u8fd8\u6709\u903b\u8f91\u201c\u6216\u201d\uff0c\u5b83\u5728Linux\u7cfb\u7edf\u4e2d\u7684\u8fd0\u7b97\u7b26\u53f7\u4e3a||\uff0c\u8868\u793a\u5f53\u524d\u9762\u7684\u547d\u4ee4\u6267\u884c\u5931\u8d25\u540e\u624d\u4f1a\u6267\u884c\u5b83\u540e\u9762\u7684\u547d\u4ee4\uff0c\u56e0\u6b64\u53ef\u4ee5\u7528\u6765\u7ed3\u5408\u7cfb\u7edf\u73af\u5883\u53d8\u91cfUSER\u6765\u5224\u65ad\u5f53\u524d\u767b\u5f55\u7684\u7528\u6237\u662f\u5426\u4e3a\u975e\u7ba1\u7406\u5458\u8eab\u4efd\uff1a<\/p>\n<pre style=\"box-sizing: border-box; font-family: Monaco, Menlo, Consolas, &quot;Courier New&quot;, monospace; font-size: 13px; white-space: pre-wrap; padding: 9.5px; margin-top: 0px; margin-bottom: 10px; line-height: 1.42857; color: rgb(51, 51, 51); word-break: break-all; word-wrap: break-word; border: 1px solid rgb(204, 204, 204); border-radius: 4px; background-color: rgb(245, 245, 245);\">[root@linuxprobe&nbsp;~]#&nbsp;echo&nbsp;$USER\r\nroot\r\n[root@linuxprobe&nbsp;~]#&nbsp;[&nbsp;$USER&nbsp;=&nbsp;root&nbsp;]&nbsp;||&nbsp;echo&nbsp;&quot;user&quot;\r\n[root@linuxprobe&nbsp;~]#&nbsp;su&nbsp;-&nbsp;linuxprobe&nbsp;\r\n[linuxprobe@linuxprobe&nbsp;~]$&nbsp;[&nbsp;$USER&nbsp;=&nbsp;root&nbsp;]&nbsp;||&nbsp;echo&nbsp;&quot;user&quot;\r\nuser<\/pre>\n<p style=\"box-sizing: border-box; margin-top: 0px; margin-bottom: 10px; line-height: 23px; text-indent: 1em; text-align: justify; color: rgb(61, 68, 80); font-family: &quot;Microsoft Yahei&quot;, Helvetica, Arial, sans-serif; font-size: 12px; white-space: normal; background-color: rgb(255, 255, 255);\">\u7b2c\u4e09\u79cd\u903b\u8f91\u8bed\u53e5\u662f\u201c\u975e\u201d\uff0c\u5728Linux\u7cfb\u7edf\u4e2d\u7684\u8fd0\u7b97\u7b26\u53f7\u662f\u4e00\u4e2a\u53f9\u53f7\uff08\uff01\uff09\uff0c\u5b83\u8868\u793a\u628a\u6761\u4ef6\u6d4b\u8bd5\u4e2d\u7684\u5224\u65ad\u7ed3\u679c\u53d6\u76f8\u53cd\u503c\u3002\u4e5f\u5c31\u662f\u8bf4\uff0c\u5982\u679c\u539f\u672c\u6d4b\u8bd5\u7684\u7ed3\u679c\u662f\u6b63\u786e\u7684\uff0c\u5219\u5c06\u5176\u53d8\u6210\u9519\u8bef\u7684\uff1b\u539f\u672c\u6d4b\u8bd5\u9519\u8bef\u7684\u7ed3\u679c\u5219\u5c06\u5176\u53d8\u6210\u6b63\u786e\u7684\u3002<\/p>\n<p style=\"box-sizing: border-box; margin-top: 0px; margin-bottom: 10px; line-height: 23px; text-indent: 1em; text-align: justify; color: rgb(61, 68, 80); font-family: &quot;Microsoft Yahei&quot;, Helvetica, Arial, sans-serif; font-size: 12px; white-space: normal; background-color: rgb(255, 255, 255);\">\u6211\u4eec\u73b0\u5728\u5207\u6362\u56de\u5230root\u7ba1\u7406\u5458\u8eab\u4efd\uff0c\u518d\u5224\u65ad\u5f53\u524d\u7528\u6237\u662f\u5426\u4e3a\u4e00\u4e2a\u975e\u7ba1\u7406\u5458\u7684\u7528\u6237\u3002\u7531\u4e8e\u5224\u65ad\u7ed3\u679c\u56e0\u4e3a\u4e24\u6b21\u5426\u5b9a\u800c\u53d8\u6210\u6b63\u786e\uff0c\u56e0\u6b64\u4f1a\u6b63\u5e38\u5730\u8f93\u51fa\u9884\u8bbe\u4fe1\u606f\uff1a<\/p>\n<pre style=\"box-sizing: border-box; font-family: Monaco, Menlo, Consolas, &quot;Courier New&quot;, monospace; font-size: 13px; white-space: pre-wrap; padding: 9.5px; margin-top: 0px; margin-bottom: 10px; line-height: 1.42857; color: rgb(51, 51, 51); word-break: break-all; word-wrap: break-word; border: 1px solid rgb(204, 204, 204); border-radius: 4px; background-color: rgb(245, 245, 245);\">[linuxprobe@linuxprobe&nbsp;~]$&nbsp;exit\r\nlogout\r\n[root@linuxprobe&nbsp;root]#&nbsp;[&nbsp;$USER&nbsp;!=&nbsp;root&nbsp;]&nbsp;||&nbsp;echo&nbsp;&quot;administrator&quot;\r\nadministrator<\/pre>\n<p style=\"box-sizing: border-box; margin-top: 0px; margin-bottom: 10px; line-height: 23px; text-indent: 1em; text-align: justify; color: rgb(61, 68, 80); font-family: &quot;Microsoft Yahei&quot;, Helvetica, Arial, sans-serif; font-size: 12px; white-space: normal; background-color: rgb(255, 255, 255);\">\u5c31\u6280\u672f\u56fe\u4e66\u7684\u5199\u4f5c\u6765\u8bb2\uff0c\u4e00\u822c\u6709\u4e24\u79cd\u5957\u8def\uff1a\u8ba9\u8bfb\u8005\u771f\u6b63\u641e\u61c2\u6280\u672f\u4e86\uff1b\u8ba9\u8bfb\u8005\u89c9\u5f97\u81ea\u5df1\u641e\u61c2\u6280\u672f\u4e86\u3002\u56e0\u6b64\u5e02\u9762\u4e0a\u5f88\u591a\u6d45\u663e\u7684\u56fe\u4e66\u4f1a\u8ba9\u8bfb\u8005\u5728\u5b66\u5b8c\u4e4b\u540e\u611f\u89c9\u8fdb\u6b65\u7279\u522b\u5feb\uff0c\u8fd9\u57fa\u672c\u4e0a\u662f\u4f5c\u8005\u6709\u610f\u4e3a\u4e4b\uff0c\u76ee\u7684\u5c31\u662f\u8ba9\u60a8\u89c9\u5f97\u201c\u56fe\u4e66\u5f88\u6709\u6599\uff0c\u81ea\u5df1\u6536\u83b7\u5f88\u5927\u201d\uff0c\u4f46\u662f\u5728\u6b65\u5165\u5de5\u4f5c\u5c97\u4f4d\u540e\u5c31\u9732\u51fa\u77ed\u677f\u5403\u5927\u4e8f\u3002\u6240\u4ee5\u5218\u9044\u8001\u5e08\u51b3\u5b9a\u7ee7\u7eed\u63d0\u9ad8\u96be\u5ea6\uff0c\u4e3a\u8bfb\u8005\u589e\u52a0\u4e00\u4e2a\u7efc\u5408\u7684\u793a\u4f8b\uff0c\u4e00\u65b9\u9762\u4f5c\u4e3a\u524d\u8ff0\u77e5\u8bc6\u7684\u603b\u7ed3\uff0c\u53e6\u4e00\u65b9\u9762\u5e2e\u52a9\u8bfb\u8005\u592f\u5b9e\u57fa\u7840\uff0c\u80fd\u591f\u5728\u4eca\u540e\u5de5\u4f5c\u4e2d\u66f4\u7075\u6d3b\u5730\u4f7f\u7528\u903b\u8f91\u7b26\u53f7\u3002<\/p>\n<p style=\"box-sizing: border-box; margin-top: 0px; margin-bottom: 10px; line-height: 23px; text-indent: 1em; text-align: justify; color: rgb(61, 68, 80); font-family: &quot;Microsoft Yahei&quot;, Helvetica, Arial, sans-serif; font-size: 12px; white-space: normal; background-color: rgb(255, 255, 255);\">\u5f53\u524d\u6211\u4eec\u6b63\u5728\u767b\u5f55\u7684\u5373\u4e3a\u7ba1\u7406\u5458\u7528\u6237\u2014root\u3002\u4e0b\u9762\u8fd9\u4e2a\u793a\u4f8b\u7684\u6267\u884c\u987a\u5e8f\u662f\uff0c\u5148\u5224\u65ad\u5f53\u524d\u767b\u5f55\u7528\u6237\u7684USER\u53d8\u91cf\u540d\u79f0\u662f\u5426\u7b49\u4e8eroot\uff0c\u7136\u540e\u7528\u903b\u8f91\u8fd0\u7b97\u7b26\u201c\u975e\u201d\u8fdb\u884c\u53d6\u53cd\u64cd\u4f5c\uff0c\u6548\u679c\u5c31\u53d8\u6210\u4e86\u5224\u65ad\u5f53\u524d\u767b\u5f55\u7684\u7528\u6237\u662f\u5426\u4e3a\u975e\u7ba1\u7406\u5458\u7528\u6237\u4e86\u3002\u6700\u540e\u82e5\u6761\u4ef6\u6210\u7acb\u5219\u4f1a\u6839\u636e\u903b\u8f91\u201c\u4e0e\u201d\u8fd0\u7b97\u7b26\u8f93\u51fauser\u5b57\u6837\uff1b\u6216\u6761\u4ef6\u4e0d\u6ee1\u8db3\u5219\u4f1a\u901a\u8fc7\u903b\u8f91\u201c\u6216\u201d\u8fd0\u7b97\u7b26\u8f93\u51faroot\u5b57\u6837\uff0c\u800c\u5982\u679c\u524d\u9762\u7684&amp;&amp;\u4e0d\u6210\u7acb\u624d\u4f1a\u6267\u884c\u540e\u9762\u7684||\u7b26\u53f7\u3002<\/p>\n<pre style=\"box-sizing: border-box; font-family: Monaco, Menlo, Consolas, &quot;Courier New&quot;, monospace; font-size: 13px; white-space: pre-wrap; padding: 9.5px; margin-top: 0px; margin-bottom: 10px; line-height: 1.42857; color: rgb(51, 51, 51); word-break: break-all; word-wrap: break-word; border: 1px solid rgb(204, 204, 204); border-radius: 4px; background-color: rgb(245, 245, 245);\">[root@linuxprobe&nbsp;~]#&nbsp;[&nbsp;$USER&nbsp;!=&nbsp;root&nbsp;]&nbsp;&amp;&amp;&nbsp;echo&nbsp;&quot;user&quot;&nbsp;||&nbsp;echo&nbsp;&quot;root&quot;\r\nroot<\/pre>\n<hr style=\"box-sizing: content-box; height: 0px; margin-top: 20px; margin-bottom: 20px; border-right-width: 0px; border-bottom-width: 0px; border-left-width: 0px; border-top-style: solid; border-top-color: rgb(238, 238, 238); color: rgb(61, 68, 80); font-family: &quot;Microsoft Yahei&quot;, Helvetica, Arial, sans-serif; font-size: 12px; line-height: 17.1429px; white-space: normal; background-color: rgb(255, 255, 255);\"\/>\n<p style=\"box-sizing: border-box; margin-top: 0px; margin-bottom: 10px; line-height: 23px; text-indent: 1em; text-align: justify; color: rgb(61, 68, 80); font-family: &quot;Microsoft Yahei&quot;, Helvetica, Arial, sans-serif; font-size: 12px; white-space: normal; background-color: rgb(255, 255, 255);\">\u6574\u6570\u6bd4\u8f83\u8fd0\u7b97\u7b26\u4ec5\u662f\u5bf9\u6570\u5b57\u7684\u64cd\u4f5c\uff0c\u4e0d\u80fd\u5c06\u6570\u5b57\u4e0e\u5b57\u7b26\u4e32\u3001\u6587\u4ef6\u7b49\u5185\u5bb9\u4e00\u8d77\u64cd\u4f5c\uff0c\u800c\u4e14\u4e0d\u80fd\u60f3\u5f53\u7136\u5730\u4f7f\u7528\u65e5\u5e38\u751f\u6d3b\u4e2d\u7684\u7b49\u53f7\u3001\u5927\u4e8e\u53f7\u3001\u5c0f\u4e8e\u53f7\u7b49\u6765\u5224\u65ad\u3002\u56e0\u4e3a\u7b49\u53f7\u4e0e\u8d4b\u503c\u547d\u4ee4\u7b26\u51b2\u7a81\uff0c\u5927\u4e8e\u53f7\u548c\u5c0f\u4e8e\u53f7\u5206\u522b\u4e0e\u8f93\u51fa\u91cd\u5b9a\u5411\u547d\u4ee4\u7b26\u548c\u8f93\u5165\u91cd\u5b9a\u5411\u547d\u4ee4\u7b26\u51b2\u7a81\u3002\u56e0\u6b64\u4e00\u5b9a\u8981\u4f7f\u7528\u89c4\u8303\u7684\u6574\u6570\u6bd4\u8f83\u8fd0\u7b97\u7b26\u6765\u8fdb\u884c\u64cd\u4f5c\u3002\u53ef\u7528\u7684\u6574\u6570\u6bd4\u8f83\u8fd0\u7b97\u7b26\u5982\u88684-4\u6240\u793a\u3002<\/p>\n<p style=\"box-sizing: border-box; margin-top: 0px; margin-bottom: 10px; line-height: 23px; text-indent: 1em; text-align: justify; color: rgb(61, 68, 80); font-family: &quot;Microsoft Yahei&quot;, Helvetica, Arial, sans-serif; font-size: 12px; white-space: normal; background-color: rgb(255, 255, 255);\">\u88684-4&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp; \u53ef\u7528\u7684\u6574\u6570\u6bd4\u8f83\u8fd0\u7b97\u7b26<\/p>\n<table id=\"tablepress-91\" class=\"tablepress tablepress-id-91\" width=\"712\">\n<tbody class=\"row-hover\" style=\"box-sizing: border-box;\">\n<tr class=\"row-1 odd firstRow\" style=\"box-sizing: border-box;\">\n<td class=\"column-1\" style=\"box-sizing: border-box; padding: 8px; border-top-width: 0px; border-right-style: none; border-bottom-style: none; border-left-style: none; border-color: initial; vertical-align: top; float: none !important; background: 0px 0px rgb(249, 249, 249);\">\u64cd\u4f5c\u7b26<\/td>\n<td class=\"column-2\" style=\"box-sizing: border-box; padding: 8px; border-top-width: 0px; border-right-style: none; border-bottom-style: none; border-left-style: none; border-color: initial; vertical-align: top; float: none !important; background: 0px 0px rgb(249, 249, 249);\">\u4f5c\u7528<\/td>\n<\/tr>\n<tr class=\"row-2 even\" style=\"box-sizing: border-box;\">\n<td class=\"column-1\" style=\"box-sizing: border-box; padding: 8px; border-right-style: none; border-bottom-style: none; border-left-style: none; vertical-align: top; float: none !important; background-image: initial; background-attachment: initial; background-size: initial; background-origin: initial; background-clip: initial; background-position: 0px 0px; background-repeat: initial;\">-eq<\/td>\n<td class=\"column-2\" style=\"box-sizing: border-box; padding: 8px; border-right-style: none; border-bottom-style: none; border-left-style: none; vertical-align: top; float: none !important; background-image: initial; background-attachment: initial; background-size: initial; background-origin: initial; background-clip: initial; background-position: 0px 0px; background-repeat: initial;\">\u662f\u5426\u7b49\u4e8e<\/td>\n<\/tr>\n<tr class=\"row-3 odd\" style=\"box-sizing: border-box;\">\n<td class=\"column-1\" style=\"box-sizing: border-box; padding: 8px; border-right-style: none; border-bottom-style: none; border-left-style: none; vertical-align: top; float: none !important; background: 0px 0px rgb(249, 249, 249);\">-ne<\/td>\n<td class=\"column-2\" style=\"box-sizing: border-box; padding: 8px; border-right-style: none; border-bottom-style: none; border-left-style: none; vertical-align: top; float: none !important; background: 0px 0px rgb(249, 249, 249);\">\u662f\u5426\u4e0d\u7b49\u4e8e<\/td>\n<\/tr>\n<tr class=\"row-4 even\" style=\"box-sizing: border-box;\">\n<td class=\"column-1\" style=\"box-sizing: border-box; padding: 8px; border-right-style: none; border-bottom-style: none; border-left-style: none; vertical-align: top; float: none !important; background-image: initial; background-attachment: initial; background-size: initial; background-origin: initial; background-clip: initial; background-position: 0px 0px; background-repeat: initial;\">-gt<\/td>\n<td class=\"column-2\" style=\"box-sizing: border-box; padding: 8px; border-right-style: none; border-bottom-style: none; border-left-style: none; vertical-align: top; float: none !important; background-image: initial; background-attachment: initial; background-size: initial; background-origin: initial; background-clip: initial; background-position: 0px 0px; background-repeat: initial;\">\u662f\u5426\u5927\u4e8e<\/td>\n<\/tr>\n<tr class=\"row-5 odd\" style=\"box-sizing: border-box;\">\n<td class=\"column-1\" style=\"box-sizing: border-box; padding: 8px; border-right-style: none; border-bottom-style: none; border-left-style: none; vertical-align: top; float: none !important; background: 0px 0px rgb(249, 249, 249);\">-lt<\/td>\n<td class=\"column-2\" style=\"box-sizing: border-box; padding: 8px; border-right-style: none; border-bottom-style: none; border-left-style: none; vertical-align: top; float: none !important; background: 0px 0px rgb(249, 249, 249);\">\u662f\u5426\u5c0f\u4e8e<\/td>\n<\/tr>\n<tr class=\"row-6 even\" style=\"box-sizing: border-box;\">\n<td class=\"column-1\" style=\"box-sizing: border-box; padding: 8px; border-right-style: none; border-bottom-style: none; border-left-style: none; vertical-align: top; float: none !important; background-image: initial; background-attachment: initial; background-size: initial; background-origin: initial; background-clip: initial; background-position: 0px 0px; background-repeat: initial;\">-le<\/td>\n<td class=\"column-2\" style=\"box-sizing: border-box; padding: 8px; border-right-style: none; border-bottom-style: none; border-left-style: none; vertical-align: top; float: none !important; background-image: initial; background-attachment: initial; background-size: initial; background-origin: initial; background-clip: initial; background-position: 0px 0px; background-repeat: initial;\">\u662f\u5426\u7b49\u4e8e\u6216\u5c0f\u4e8e<\/td>\n<\/tr>\n<tr class=\"row-7 odd\" style=\"box-sizing: border-box;\">\n<td class=\"column-1\" style=\"box-sizing: border-box; padding: 8px; border-right-style: none; border-bottom-style: none; border-left-style: none; vertical-align: top; float: none !important; background: 0px 0px rgb(249, 249, 249);\">-ge<\/td>\n<td class=\"column-2\" style=\"box-sizing: border-box; padding: 8px; border-right-style: none; border-bottom-style: none; border-left-style: none; vertical-align: top; float: none !important; background: 0px 0px rgb(249, 249, 249);\">\u662f\u5426\u5927\u4e8e\u6216\u7b49\u4e8e<\/td>\n<\/tr>\n<\/tbody>\n<\/table>\n<p style=\"box-sizing: border-box; margin-top: 0px; margin-bottom: 10px; line-height: 23px; text-indent: 1em; text-align: justify; color: rgb(61, 68, 80); font-family: &quot;Microsoft Yahei&quot;, Helvetica, Arial, sans-serif; font-size: 12px; white-space: normal; background-color: rgb(255, 255, 255);\"><\/p>\n<p style=\"box-sizing: border-box; margin-top: 0px; margin-bottom: 10px; line-height: 23px; text-indent: 1em; text-align: justify; color: rgb(61, 68, 80); font-family: &quot;Microsoft Yahei&quot;, Helvetica, Arial, sans-serif; font-size: 12px; white-space: normal; background-color: rgb(255, 255, 255);\">\u63a5\u4e0b\u6765\u5c0f\u8bd5\u725b\u5200\u3002\u6211\u4eec\u5148\u6d4b\u8bd5\u4e00\u4e0b10\u662f\u5426\u5927\u4e8e10\u4ee5\u53ca10\u662f\u5426\u7b49\u4e8e10\uff08\u901a\u8fc7\u8f93\u51fa\u7684\u8fd4\u56de\u503c\u5185\u5bb9\u6765\u5224\u65ad\uff09\uff1a<\/p>\n<pre style=\"box-sizing: border-box; font-family: Monaco, Menlo, Consolas, &quot;Courier New&quot;, monospace; font-size: 13px; white-space: pre-wrap; padding: 9.5px; margin-top: 0px; margin-bottom: 10px; line-height: 1.42857; color: rgb(51, 51, 51); word-break: break-all; word-wrap: break-word; border: 1px solid rgb(204, 204, 204); border-radius: 4px; background-color: rgb(245, 245, 245);\">[root@linuxprobe&nbsp;~]#&nbsp;[&nbsp;10&nbsp;-gt&nbsp;10&nbsp;]\r\n[root@linuxprobe&nbsp;~]#&nbsp;echo&nbsp;$?1[root@linuxprobe&nbsp;~]#&nbsp;[&nbsp;10&nbsp;-eq&nbsp;10&nbsp;]\r\n[root@linuxprobe&nbsp;~]#&nbsp;echo&nbsp;$?0<\/pre>\n<p style=\"box-sizing: border-box; margin-top: 0px; margin-bottom: 10px; line-height: 23px; text-indent: 1em; text-align: justify; color: rgb(61, 68, 80); font-family: &quot;Microsoft Yahei&quot;, Helvetica, Arial, sans-serif; font-size: 12px; white-space: normal; background-color: rgb(255, 255, 255);\">\u57282.4\u8282\u66fe\u7ecf\u8bb2\u8fc7free\u547d\u4ee4\uff0c\u5b83\u53ef\u4ee5\u7528\u6765\u83b7\u53d6\u5f53\u524d\u7cfb\u7edf\u6b63\u5728\u4f7f\u7528\u53ca\u53ef\u7528\u7684\u5185\u5b58\u91cf\u4fe1\u606f\u3002\u63a5\u4e0b\u6765\u5148\u4f7f\u7528free -m\u547d\u4ee4\u67e5\u770b\u5185\u5b58\u4f7f\u7528\u91cf\u60c5\u51b5\uff08\u5355\u4f4d\u4e3aMB\uff09\uff0c\u7136\u540e\u901a\u8fc7grep Mem:\u547d\u4ee4\u8fc7\u6ee4\u51fa\u5269\u4f59\u5185\u5b58\u91cf\u7684\u884c\uff0c\u518d\u7528awk &#39;{print $4}&#39;\u547d\u4ee4\u53ea\u4fdd\u7559\u7b2c\u56db\u5217\uff0c\u6700\u540e\u7528FreeMem=`\u8bed\u53e5`\u7684\u65b9\u5f0f\u628a\u8bed\u53e5\u5185\u6267\u884c\u7684\u7ed3\u679c\u8d4b\u503c\u7ed9\u53d8\u91cf\u3002<\/p>\n<p style=\"box-sizing: border-box; margin-top: 0px; margin-bottom: 10px; line-height: 23px; text-indent: 1em; text-align: justify; color: rgb(61, 68, 80); font-family: &quot;Microsoft Yahei&quot;, Helvetica, Arial, sans-serif; font-size: 12px; white-space: normal; background-color: rgb(255, 255, 255);\">\u8fd9\u4e2a\u6f14\u793a\u786e\u5b9e\u6709\u4e9b\u96be\u5ea6\uff0c\u4f46\u770b\u61c2\u540e\u4f1a\u89c9\u5f97\u5f88\u6709\u610f\u601d\uff0c\u6ca1\u51c6\u5728\u8fd0\u7ef4\u5de5\u4f5c\u4e2d\u4e5f\u4f1a\u7528\u5f97\u4e0a\u3002<\/p>\n<pre style=\"box-sizing: border-box; font-family: Monaco, Menlo, Consolas, &quot;Courier New&quot;, monospace; font-size: 13px; white-space: pre-wrap; padding: 9.5px; margin-top: 0px; margin-bottom: 10px; line-height: 1.42857; color: rgb(51, 51, 51); word-break: break-all; word-wrap: break-word; border: 1px solid rgb(204, 204, 204); border-radius: 4px; background-color: rgb(245, 245, 245);\">[root@linuxprobe&nbsp;~]#&nbsp;free&nbsp;-m\r\n&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;total&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;used&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;free&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;shared&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;buffers&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;cachedMem:&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;1826&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;1244&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;582&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;9&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;1&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;413\r\n-\/+&nbsp;buffers\/cache:&nbsp;&nbsp;&nbsp;&nbsp;830&nbsp;996\r\nSwap:&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;2047&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;0&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;2047\r\n[root@linuxprobe&nbsp;~]#&nbsp;free&nbsp;-m&nbsp;|&nbsp;grep&nbsp;Mem:\r\nMem:&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;1826&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;1244&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;582&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;9&nbsp;\r\n[root@linuxprobe&nbsp;~]#&nbsp;free&nbsp;-m&nbsp;|&nbsp;grep&nbsp;Mem:&nbsp;|&nbsp;awk&nbsp;&#39;{print&nbsp;$4}&#39;\r\n582\r\n[root@linuxprobe&nbsp;~]#&nbsp;FreeMem=`free&nbsp;-m&nbsp;|&nbsp;grep&nbsp;Mem:&nbsp;|&nbsp;awk&nbsp;&#39;{print&nbsp;$4}&#39;`\r\n[root@linuxprobe&nbsp;~]#&nbsp;echo&nbsp;$FreeMem&nbsp;\r\n582<\/pre>\n<p style=\"box-sizing: border-box; margin-top: 0px; margin-bottom: 10px; line-height: 23px; text-indent: 1em; text-align: justify; color: rgb(61, 68, 80); font-family: &quot;Microsoft Yahei&quot;, Helvetica, Arial, sans-serif; font-size: 12px; white-space: normal; background-color: rgb(255, 255, 255);\">\u4e0a\u9762\u7528\u4e8e\u83b7\u53d6\u5185\u5b58\u53ef\u7528\u91cf\u7684\u547d\u4ee4\u4ee5\u53ca\u6b65\u9aa4\u53ef\u80fd\u6709\u4e9b\u201c\u8d85\u7eb2\u201d\u4e86\uff0c\u5982\u679c\u4e0d\u80fd\u7406\u89e3\u9886\u4f1a\u4e5f\u4e0d\u7528\u62c5\u5fc3\uff0c\u63a5\u4e0b\u6765\u624d\u662f\u91cd\u70b9\u3002\u6211\u4eec\u4f7f\u7528\u6574\u6570\u8fd0\u7b97\u7b26\u6765\u5224\u65ad\u5185\u5b58\u53ef\u7528\u91cf\u7684\u503c\u662f\u5426\u5c0f\u4e8e1024\uff0c\u82e5\u5c0f\u4e8e\u5219\u4f1a\u63d0\u793a\u201cInsufficient Memory\u201d\uff08\u5185\u5b58\u4e0d\u8db3\uff09\u7684\u5b57\u6837\uff1a<\/p>\n<pre style=\"box-sizing: border-box; font-family: Monaco, Menlo, Consolas, &quot;Courier New&quot;, monospace; font-size: 13px; white-space: pre-wrap; padding: 9.5px; margin-top: 0px; margin-bottom: 10px; line-height: 1.42857; color: rgb(51, 51, 51); word-break: break-all; word-wrap: break-word; border: 1px solid rgb(204, 204, 204); border-radius: 4px; background-color: rgb(245, 245, 245);\">[root@linuxprobe&nbsp;~]#&nbsp;[&nbsp;$FreeMem&nbsp;-lt&nbsp;1024&nbsp;]&nbsp;&amp;&amp;&nbsp;echo&nbsp;&quot;Insufficient&nbsp;Memory&quot;\r\nInsufficient&nbsp;Memory<\/pre>\n<p style=\"box-sizing: border-box; margin-top: 0px; margin-bottom: 10px; line-height: 23px; text-indent: 1em; text-align: justify; color: rgb(61, 68, 80); font-family: &quot;Microsoft Yahei&quot;, Helvetica, Arial, sans-serif; font-size: 12px; white-space: normal; background-color: rgb(255, 255, 255);\">\u5b57\u7b26\u4e32\u6bd4\u8f83\u8bed\u53e5\u7528\u4e8e\u5224\u65ad\u6d4b\u8bd5\u5b57\u7b26\u4e32\u662f\u5426\u4e3a\u7a7a\u503c\uff0c\u6216\u4e24\u4e2a\u5b57\u7b26\u4e32\u662f\u5426\u76f8\u540c\u3002\u5b83\u7ecf\u5e38\u7528\u6765\u5224\u65ad\u67d0\u4e2a\u53d8\u91cf\u662f\u5426\u672a\u88ab\u5b9a\u4e49\uff08\u5373\u5185\u5bb9\u4e3a\u7a7a\u503c\uff09\uff0c\u7406\u89e3\u8d77\u6765\u4e5f\u6bd4\u8f83\u7b80\u5355\u3002\u5b57\u7b26\u4e32\u6bd4\u8f83\u4e2d\u5e38\u89c1\u7684\u8fd0\u7b97\u7b26\u5982\u88684-5\u6240\u793a\u3002<\/p>\n<p style=\"box-sizing: border-box; margin-top: 0px; margin-bottom: 10px; line-height: 23px; text-indent: 1em; text-align: justify; color: rgb(61, 68, 80); font-family: &quot;Microsoft Yahei&quot;, Helvetica, Arial, sans-serif; font-size: 12px; white-space: normal; background-color: rgb(255, 255, 255);\">\u88684-5&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp; \u5e38\u89c1\u7684\u5b57\u7b26\u4e32\u6bd4\u8f83\u8fd0\u7b97\u7b26<\/p>\n<table id=\"tablepress-92\" class=\"tablepress tablepress-id-92\" width=\"712\">\n<tbody class=\"row-hover\" style=\"box-sizing: border-box;\">\n<tr class=\"row-1 odd firstRow\" style=\"box-sizing: border-box;\">\n<td class=\"column-1\" style=\"box-sizing: border-box; padding: 8px; border-top-width: 0px; border-right-style: none; border-bottom-style: none; border-left-style: none; border-color: initial; vertical-align: top; float: none !important; background: 0px 0px rgb(249, 249, 249);\">\u64cd\u4f5c\u7b26<\/td>\n<td class=\"column-2\" style=\"box-sizing: border-box; padding: 8px; border-top-width: 0px; border-right-style: none; border-bottom-style: none; border-left-style: none; border-color: initial; vertical-align: top; float: none !important; background: 0px 0px rgb(249, 249, 249);\">\u4f5c\u7528<\/td>\n<\/tr>\n<tr class=\"row-2 even\" style=\"box-sizing: border-box;\">\n<td class=\"column-1\" style=\"box-sizing: border-box; padding: 8px; border-right-style: none; border-bottom-style: none; border-left-style: none; vertical-align: top; float: none !important; background-image: initial; background-attachment: initial; background-size: initial; background-origin: initial; background-clip: initial; background-position: 0px 0px; background-repeat: initial;\">=<\/td>\n<td class=\"column-2\" style=\"box-sizing: border-box; padding: 8px; border-right-style: none; border-bottom-style: none; border-left-style: none; vertical-align: top; float: none !important; background-image: initial; background-attachment: initial; background-size: initial; background-origin: initial; background-clip: initial; background-position: 0px 0px; background-repeat: initial;\">\u6bd4\u8f83\u5b57\u7b26\u4e32\u5185\u5bb9\u662f\u5426\u76f8\u540c<\/td>\n<\/tr>\n<tr class=\"row-3 odd\" style=\"box-sizing: border-box;\">\n<td class=\"column-1\" style=\"box-sizing: border-box; padding: 8px; border-right-style: none; border-bottom-style: none; border-left-style: none; vertical-align: top; float: none !important; background: 0px 0px rgb(249, 249, 249);\">!=<\/td>\n<td class=\"column-2\" style=\"box-sizing: border-box; padding: 8px; border-right-style: none; border-bottom-style: none; border-left-style: none; vertical-align: top; float: none !important; background: 0px 0px rgb(249, 249, 249);\">\u6bd4\u8f83\u5b57\u7b26\u4e32\u5185\u5bb9\u662f\u5426\u4e0d\u540c<\/td>\n<\/tr>\n<tr class=\"row-4 even\" style=\"box-sizing: border-box;\">\n<td class=\"column-1\" style=\"box-sizing: border-box; padding: 8px; border-right-style: none; border-bottom-style: none; border-left-style: none; vertical-align: top; float: none !important; background-image: initial; background-attachment: initial; background-size: initial; background-origin: initial; background-clip: initial; background-position: 0px 0px; background-repeat: initial;\">-z<\/td>\n<td class=\"column-2\" style=\"box-sizing: border-box; padding: 8px; border-right-style: none; border-bottom-style: none; border-left-style: none; vertical-align: top; float: none !important; background-image: initial; background-attachment: initial; background-size: initial; background-origin: initial; background-clip: initial; background-position: 0px 0px; background-repeat: initial;\">\u5224\u65ad\u5b57\u7b26\u4e32\u5185\u5bb9\u662f\u5426\u4e3a\u7a7a<\/td>\n<\/tr>\n<\/tbody>\n<\/table>\n<p style=\"box-sizing: border-box; margin-top: 0px; margin-bottom: 10px; line-height: 23px; text-indent: 1em; text-align: justify; color: rgb(61, 68, 80); font-family: &quot;Microsoft Yahei&quot;, Helvetica, Arial, sans-serif; font-size: 12px; white-space: normal; background-color: rgb(255, 255, 255);\"><\/p>\n<p style=\"box-sizing: border-box; margin-top: 0px; margin-bottom: 10px; line-height: 23px; text-indent: 1em; text-align: justify; color: rgb(61, 68, 80); font-family: &quot;Microsoft Yahei&quot;, Helvetica, Arial, sans-serif; font-size: 12px; white-space: normal; background-color: rgb(255, 255, 255);\">\u63a5\u4e0b\u6765\u901a\u8fc7\u5224\u65adString\u53d8\u91cf\u662f\u5426\u4e3a\u7a7a\u503c\uff0c\u8fdb\u800c\u5224\u65ad\u662f\u5426\u5b9a\u4e49\u4e86\u8fd9\u4e2a\u53d8\u91cf\uff1a<\/p>\n<pre style=\"box-sizing: border-box; font-family: Monaco, Menlo, Consolas, &quot;Courier New&quot;, monospace; font-size: 13px; white-space: pre-wrap; padding: 9.5px; margin-top: 0px; margin-bottom: 10px; line-height: 1.42857; color: rgb(51, 51, 51); word-break: break-all; word-wrap: break-word; border: 1px solid rgb(204, 204, 204); border-radius: 4px; background-color: rgb(245, 245, 245);\">[root@linuxprobe&nbsp;~]#&nbsp;[&nbsp;-z&nbsp;$String&nbsp;]\r\n[root@linuxprobe&nbsp;~]#&nbsp;echo&nbsp;$?\r\n0<\/pre>\n<p style=\"box-sizing: border-box; margin-top: 0px; margin-bottom: 10px; line-height: 23px; text-indent: 1em; text-align: justify; color: rgb(61, 68, 80); font-family: &quot;Microsoft Yahei&quot;, Helvetica, Arial, sans-serif; font-size: 12px; white-space: normal; background-color: rgb(255, 255, 255);\">\u518d\u5c1d\u8bd5\u5f15\u5165\u903b\u8f91\u8fd0\u7b97\u7b26\u6765\u8bd5\u4e00\u4e0b\u3002\u5f53\u7528\u4e8e\u4fdd\u5b58\u5f53\u524d\u8bed\u7cfb\u7684\u73af\u5883\u53d8\u91cf\u503cLANG\u4e0d\u662f\u82f1\u8bed\uff08en.US\uff09\u65f6\uff0c\u5219\u4f1a\u6ee1\u8db3\u903b\u8f91\u6d4b\u8bd5\u6761\u4ef6\u5e76\u8f93\u51fa\u201cNot en.US\u201d\uff08\u975e\u82f1\u8bed\uff09\u7684\u5b57\u6837\uff1a<\/p>\n<pre style=\"box-sizing: border-box; font-family: Monaco, Menlo, Consolas, &quot;Courier New&quot;, monospace; font-size: 13px; white-space: pre-wrap; padding: 9.5px; margin-top: 0px; margin-bottom: 10px; line-height: 1.42857; color: rgb(51, 51, 51); word-break: break-all; word-wrap: break-word; border: 1px solid rgb(204, 204, 204); border-radius: 4px; background-color: rgb(245, 245, 245);\">[root@linuxprobe&nbsp;~]#&nbsp;echo&nbsp;$LANG\r\nen_US.UTF-8\r\n[root@linuxprobe&nbsp;~]#&nbsp;[&nbsp;$LANG&nbsp;!=&nbsp;&quot;en.US&quot;&nbsp;]&nbsp;&amp;&amp;&nbsp;echo&nbsp;&quot;Not&nbsp;en.US&quot;\r\nNot&nbsp;en.US<\/pre>\n<p style=\"box-sizing: border-box; margin-top: 0px; margin-bottom: 10px; line-height: 23px; text-indent: 1em; text-align: justify; color: rgb(61, 68, 80); font-family: &quot;Microsoft Yahei&quot;, Helvetica, Arial, sans-serif; font-size: 12px; white-space: normal; background-color: rgb(255, 255, 255);\"><span style=\"box-sizing: border-box; color: #800080;\"><strong style=\"box-sizing: border-box;\">\u51fa\u73b0\u95ee\u9898?\u5927\u80c6\u63d0\u95ee!<\/strong><\/span><\/p>\n<blockquote style=\"box-sizing: border-box; padding: 10px 20px; margin: 0px 0px 20px; border-left-width: 5px; border-left-style: solid; border-color: rgba(0, 0, 0, 0.14902); color: rgb(61, 68, 80); font-family: &quot;Microsoft Yahei&quot;, Helvetica, Arial, sans-serif; font-size: 12px; line-height: 17.1429px; white-space: normal; background-color: rgb(255, 255, 255);\">\n<p style=\"box-sizing: border-box; margin-top: 0px; margin-bottom: 10px; font-size: 14px; line-height: 23px; text-indent: 1em; text-align: justify;\">\u56e0\u8bfb\u8005\u4eec\u786c\u4ef6\u4e0d\u540c\u6216\u64cd\u4f5c\u9519\u8bef\u90fd\u53ef\u80fd\u5bfc\u81f4\u5b9e\u9a8c\u914d\u7f6e\u51fa\u9519\uff0c\u8bf7\u8010\u5fc3\u518d\u4ed4\u7ec6\u770b\u770b\u64cd\u4f5c\u6b65\u9aa4\u5427\uff0c\u4e0d\u8981\u6c14\u9981~<\/p>\n<p style=\"box-sizing: border-box; margin-top: 0px; margin-bottom: 10px; font-size: 14px; line-height: 23px; text-indent: 1em; text-align: justify;\">Linux\u6280\u672f\u4ea4\u6d41\u8bf7\u52a0A\u7fa4\uff1a560843(<strong style=\"box-sizing: border-box;\"><span style=\"box-sizing: border-box; color: #008000;\">\u6ee1<\/span><\/strong>)\uff0cB\u7fa4\uff1a340829(<span style=\"box-sizing: border-box; color: #008000;\">\u63a8\u8350<\/span>)\uff0cC\u7fa4\uff1a463590\uff08<strong style=\"box-sizing: border-box;\"><span style=\"box-sizing: border-box; color: #008000;\">\u63a8\u8350<\/span><\/strong>\uff09\uff0c<a href=\"https:\/\/www.linuxprobe.com\/club\" style=\"box-sizing: border-box; color: rgb(210, 50, 45); text-decoration: none;\">\u70b9\u6b64\u67e5\u770b\u5168\u56fd\u7fa4<\/a>\u3002<\/p>\n<p style=\"box-sizing: border-box; margin-top: 0px; margin-bottom: 0px; font-size: 14px; line-height: 23px; text-indent: 1em; text-align: justify;\">*\u672c\u7fa4\u7279\u8272\uff1a\u901a\u8fc7\u53e3\u4ee4\u9a8c\u8bc1\u786e\u4fdd\u6bcf\u4e00\u4e2a\u7fa4\u5458\u90fd\u662f\u300aLinux\u5c31\u8be5\u8fd9\u4e48\u5b66\u300b\u7684\u8bfb\u8005\uff0c\u7b54\u7591\u66f4\u6709\u9488\u5bf9\u6027\uff0c\u4e0d\u5b9a\u671f\u514d\u8d39\u9886\u53d6\u5b9a\u5236\u793c\u54c1\u3002<\/p>\n<\/blockquote>\n<h5 style=\"box-sizing: border-box; font-family: &quot;Helvetica Neue&quot;, Helvetica, Arial, sans-serif; font-weight: 100; line-height: 1.1; margin-top: 10px; margin-bottom: 10px; font-size: 14px; color: rgb(61, 68, 80); white-space: normal; background-color: rgb(255, 255, 255);\"><span id=\"43\" style=\"box-sizing: border-box;\"><span style=\"box-sizing: border-box; color: #008000;\"><strong style=\"box-sizing: border-box;\">4.3 \u6d41\u7a0b\u63a7\u5236\u8bed\u53e5<\/strong><\/span><\/span><\/h5>\n<p style=\"box-sizing: border-box; margin-top: 0px; margin-bottom: 10px; line-height: 23px; text-indent: 1em; text-align: justify; color: rgb(61, 68, 80); font-family: &quot;Microsoft Yahei&quot;, Helvetica, Arial, sans-serif; font-size: 12px; white-space: normal; background-color: rgb(255, 255, 255);\">\u5c3d\u7ba1\u6b64\u65f6\u53ef\u4ee5\u901a\u8fc7\u4f7f\u7528Linux\u547d\u4ee4\u3001\u7ba1\u9053\u7b26\u3001\u91cd\u5b9a\u5411\u4ee5\u53ca\u6761\u4ef6\u6d4b\u8bd5\u8bed\u53e5\u6765\u7f16\u5199\u6700\u57fa\u672c\u7684Shell\u811a\u672c\uff0c\u4f46\u662f\u8fd9\u79cd\u811a\u672c\u5e76\u4e0d\u9002\u7528\u4e8e\u751f\u4ea7\u73af\u5883\u3002\u539f\u56e0\u662f\u5b83\u4e0d\u80fd\u6839\u636e\u771f\u5b9e\u7684\u5de5\u4f5c\u9700\u6c42\u6765\u8c03\u6574\u5177\u4f53\u7684\u6267\u884c\u547d\u4ee4\uff0c\u4e5f\u4e0d\u80fd\u6839\u636e\u67d0\u4e9b\u6761\u4ef6\u5b9e\u73b0\u81ea\u52a8\u5faa\u73af\u6267\u884c\u3002\u4f8b\u5982\uff0c\u6211\u4eec\u9700\u8981\u6279\u91cf\u521b\u5efa1000\u4f4d\u7528\u6237\uff0c\u9996\u5148\u8981\u5224\u65ad\u8fd9\u4e9b\u7528\u6237\u662f\u5426\u5df2\u7ecf\u5b58\u5728\uff1b\u82e5\u4e0d\u5b58\u5728\uff0c\u5219\u901a\u8fc7\u5faa\u73af\u8bed\u53e5\u8ba9\u811a\u672c\u81ea\u52a8\u4e14\u4f9d\u6b21\u521b\u5efa\u4ed6\u4eec\u3002<\/p>\n<p style=\"box-sizing: border-box; margin-top: 0px; margin-bottom: 10px; line-height: 23px; text-indent: 1em; text-align: justify; color: rgb(61, 68, 80); font-family: &quot;Microsoft Yahei&quot;, Helvetica, Arial, sans-serif; font-size: 12px; white-space: normal; background-color: rgb(255, 255, 255);\">\u63a5\u4e0b\u6765\u6211\u4eec\u901a\u8fc7if\u3001for\u3001while\u3001case\u8fd94\u79cd\u6d41\u7a0b\u63a7\u5236\u8bed\u53e5\u6765\u5b66\u4e60\u7f16\u5199\u96be\u5ea6\u66f4\u5927\u3001\u529f\u80fd\u66f4\u5f3a\u7684Shell\u811a\u672c\u3002\u4e3a\u4e86\u4fdd\u8bc1\u4e0b\u6587\u7684\u5b9e\u7528\u6027\u548c\u8da3\u5473\u6027\uff0c\u505a\u5230\u5bd3\u6559\u4e8e\u4e50\uff0c\u6211\u4f1a\u5c3d\u53ef\u80fd\u591a\u5730\u8bb2\u89e3\u5404\u79cd\u4e0d\u540c\u529f\u80fd\u7684Shell\u811a\u672c\u793a\u4f8b\uff0c\u800c\u4e0d\u662f\u902e\u4f4f\u4e00\u4e2a\u811a\u672c\u4e0d\u653e\uff0c\u5728\u5b83\u539f\u6709\u5185\u5bb9\u7684\u57fa\u7840\u4e0a\u4fee\u4fee\u8865\u8865\u3002\u5c3d\u7ba1\u8fd9\u79cd\u4fee\u8865\u5f0f\u7684\u793a\u4f8b\u6559\u5b66\u4e5f\u53ef\u4ee5\u8ba9\u8bfb\u8005\u660e\u767d\u7406\u8bba\u77e5\u8bc6\uff0c\u4f46\u662f\u5374\u65e0\u6cd5\u5f00\u653e\u601d\u8def\uff0c\u4e0d\u5229\u4e8e\u65e5\u540e\u7684\u5de5\u4f5c\u3002<\/p>\n<h6 style=\"box-sizing: border-box; font-family: &quot;Helvetica Neue&quot;, Helvetica, Arial, sans-serif; font-weight: 500; line-height: 1.1; margin-top: 10px; margin-bottom: 10px; font-size: 12px; color: rgb(61, 68, 80); white-space: normal; background-color: rgb(255, 255, 255);\"><span id=\"431_if\" style=\"box-sizing: border-box;\"><span style=\"box-sizing: border-box; color: #008000;\"><strong style=\"box-sizing: border-box;\">4.3.1 if\u6761\u4ef6\u6d4b\u8bd5\u8bed\u53e5<\/strong><\/span><\/span><\/h6>\n<p style=\"box-sizing: border-box; margin-top: 0px; margin-bottom: 10px; line-height: 23px; text-indent: 1em; text-align: justify; color: rgb(61, 68, 80); font-family: &quot;Microsoft Yahei&quot;, Helvetica, Arial, sans-serif; font-size: 12px; white-space: normal; background-color: rgb(255, 255, 255);\">if\u6761\u4ef6\u6d4b\u8bd5\u8bed\u53e5\u53ef\u4ee5\u8ba9\u811a\u672c\u6839\u636e\u5b9e\u9645\u60c5\u51b5\u81ea\u52a8\u6267\u884c\u76f8\u5e94\u7684\u547d\u4ee4\u3002\u4ece\u6280\u672f\u89d2\u5ea6\u6765\u8bb2\uff0cif\u8bed\u53e5\u5206\u4e3a\u5355\u5206\u652f\u7ed3\u6784\u3001\u53cc\u5206\u652f\u7ed3\u6784\u3001\u591a\u5206\u652f\u7ed3\u6784\uff1b\u5176\u590d\u6742\u5ea6\u968f\u7740\u7075\u6d3b\u5ea6\u4e00\u8d77\u9010\u7ea7\u4e0a\u5347\u3002<\/p>\n<p style=\"box-sizing: border-box; margin-top: 0px; margin-bottom: 10px; line-height: 23px; text-indent: 1em; text-align: justify; color: rgb(61, 68, 80); font-family: &quot;Microsoft Yahei&quot;, Helvetica, Arial, sans-serif; font-size: 12px; white-space: normal; background-color: rgb(255, 255, 255);\">if\u6761\u4ef6\u8bed\u53e5\u7684\u5355\u5206\u652f\u7ed3\u6784\u7531if\u3001then\u3001fi\u5173\u952e\u8bcd\u7ec4\u6210\uff0c\u800c\u4e14\u53ea\u5728\u6761\u4ef6\u6210\u7acb\u540e\u624d\u6267\u884c\u9884\u8bbe\u7684\u547d\u4ee4\uff0c\u76f8\u5f53\u4e8e\u53e3\u8bed\u7684\u201c\u5982\u679c\u2026\u2026\u90a3\u4e48\u2026\u2026\u201d\u3002\u5355\u5206\u652f\u7684if\u8bed\u53e5\u5c5e\u4e8e\u6700\u7b80\u5355\u7684\u4e00\u79cd\u6761\u4ef6\u5224\u65ad\u7ed3\u6784\uff0c\u8bed\u6cd5\u683c\u5f0f\u5982\u56fe4-17\u6240\u793a\u3002<br style=\"box-sizing: border-box;\"\/><div class='fancybox-wrapper lazyload-container-unload' data-fancybox='post-images' href='https:\/\/www.linuxprobe.com\/wp-content\/uploads\/2015\/07\/%E5%8D%95%E5%88%86%E6%94%AF%E7%BB%93%E6%9E%84-2.png'><img class=\"lazyload lazyload-style-1\" src=\"data:image\/svg+xml;base64,PCEtLUFyZ29uTG9hZGluZy0tPgo8c3ZnIHdpZHRoPSIxIiBoZWlnaHQ9IjEiIHhtbG5zPSJodHRwOi8vd3d3LnczLm9yZy8yMDAwL3N2ZyIgc3Ryb2tlPSIjZmZmZmZmMDAiPjxnPjwvZz4KPC9zdmc+\"  loading=\"lazy\" decoding=\"async\" class=\"size-full wp-image-40055 aligncenter\" data-original=\"https:\/\/www.linuxprobe.com\/wp-content\/uploads\/2015\/07\/%E5%8D%95%E5%88%86%E6%94%AF%E7%BB%93%E6%9E%84-2.png\" src=\"data:image\/png;base64,iVBORw0KGgoAAAANSUhEUgAAAAEAAAABCAYAAAAfFcSJAAAAAXNSR0IArs4c6QAAAARnQU1BAACxjwv8YQUAAAAJcEhZcwAADsQAAA7EAZUrDhsAAAANSURBVBhXYzh8+PB\/AAffA0nNPuCLAAAAAElFTkSuQmCC\" alt=\"\u7b2c4\u7ae0 Vim\u7f16\u8f91\u5668\u4e0eShell\u547d\u4ee4\u811a\u672c\u3002\u7b2c4\u7ae0 Vim\u7f16\u8f91\u5668\u4e0eShell\u547d\u4ee4\u811a\u672c\u3002\" width=\"464\" height=\"102\"  sizes=\"auto, (max-width: 464px) 100vw, 464px\" title=\"\u7b2c4\u7ae0 Vim\u7f16\u8f91\u5668\u4e0eShell\u547d\u4ee4\u811a\u672c\u3002\u7b2c4\u7ae0 Vim\u7f16\u8f91\u5668\u4e0eShell\u547d\u4ee4\u811a\u672c\u3002\" style=\"box-sizing: border-box; max-width: 100%; border-radius: 4px; vertical-align: middle; height: auto; margin: 10px auto; display: block;\"\/><\/div><\/p>\n<p style=\"box-sizing: border-box; margin-top: 0px; margin-bottom: 10px; line-height: 23px; text-indent: 1em; text-align: center; color: rgb(61, 68, 80); font-family: &quot;Microsoft Yahei&quot;, Helvetica, Arial, sans-serif; font-size: 12px; white-space: normal; background-color: rgb(255, 255, 255);\">\u56fe4-17&nbsp; \u5355\u5206\u652f\u7684if\u8bed\u53e5<\/p>\n<p style=\"box-sizing: border-box; margin-top: 0px; margin-bottom: 10px; line-height: 23px; text-indent: 1em; text-align: justify; color: rgb(61, 68, 80); font-family: &quot;Microsoft Yahei&quot;, Helvetica, Arial, sans-serif; font-size: 12px; white-space: normal; background-color: rgb(255, 255, 255);\">\u4e0b\u9762\u4f7f\u7528\u5355\u5206\u652f\u7684if\u6761\u4ef6\u8bed\u53e5\u6765\u5224\u65ad\/media\/cdrom\u6587\u4ef6\u662f\u5426\u5b58\u5728\uff0c\u82e5\u5b58\u5728\u5c31\u7ed3\u675f\u6761\u4ef6\u5224\u65ad\u548c\u6574\u4e2aShell\u811a\u672c\uff0c\u53cd\u4e4b\u5219\u53bb\u521b\u5efa\u8fd9\u4e2a\u76ee\u5f55\uff1a<\/p>\n<pre style=\"box-sizing: border-box; font-family: Monaco, Menlo, Consolas, &quot;Courier New&quot;, monospace; font-size: 13px; white-space: pre-wrap; padding: 9.5px; margin-top: 0px; margin-bottom: 10px; line-height: 1.42857; color: rgb(51, 51, 51); word-break: break-all; word-wrap: break-word; border: 1px solid rgb(204, 204, 204); border-radius: 4px; background-color: rgb(245, 245, 245);\">[root@linuxprobe&nbsp;~]#&nbsp;vim&nbsp;mkcdrom.sh\r\n#!\/bin\/bash\r\nDIR=&quot;\/media\/cdrom&quot;\r\nif&nbsp;[&nbsp;!&nbsp;-e&nbsp;$DIR&nbsp;]\r\nthen\r\nmkdir&nbsp;-p&nbsp;$DIR\r\nfi<\/pre>\n<p style=\"box-sizing: border-box; margin-top: 0px; margin-bottom: 10px; line-height: 23px; text-indent: 1em; text-align: justify; color: rgb(61, 68, 80); font-family: &quot;Microsoft Yahei&quot;, Helvetica, Arial, sans-serif; font-size: 12px; white-space: normal; background-color: rgb(255, 255, 255);\">\u7531\u4e8e\u7b2c5\u7ae0\u624d\u8bb2\u89e3\u7528\u6237\u8eab\u4efd\u4e0e\u6743\u9650\uff0c\u56e0\u6b64\u8fd9\u91cc\u7ee7\u7eed\u7528\u201cbash \u811a\u672c\u540d\u79f0\u201d\u7684\u65b9\u5f0f\u6765\u6267\u884c\u811a\u672c\u3002\u5728\u6b63\u5e38\u60c5\u51b5\u4e0b\uff0c\u987a\u5229\u6267\u884c\u5b8c\u811a\u672c\u6587\u4ef6\u540e\u6ca1\u6709\u4efb\u4f55\u8f93\u51fa\u4fe1\u606f\uff0c\u4f46\u662f\u53ef\u4ee5\u4f7f\u7528ls\u547d\u4ee4\u9a8c\u8bc1\/media\/cdrom\u76ee\u5f55\u662f\u5426\u5df2\u7ecf\u6210\u529f\u521b\u5efa\uff1a<\/p>\n<pre style=\"box-sizing: border-box; font-family: Monaco, Menlo, Consolas, &quot;Courier New&quot;, monospace; font-size: 13px; white-space: pre-wrap; padding: 9.5px; margin-top: 0px; margin-bottom: 10px; line-height: 1.42857; color: rgb(51, 51, 51); word-break: break-all; word-wrap: break-word; border: 1px solid rgb(204, 204, 204); border-radius: 4px; background-color: rgb(245, 245, 245);\">[root@linuxprobe&nbsp;~]#&nbsp;bash&nbsp;mkcdrom.sh\r\n[root@linuxprobe&nbsp;~]#&nbsp;ls&nbsp;-d&nbsp;\/media\/cdrom\r\n\/media\/cdrom<\/pre>\n<hr style=\"box-sizing: content-box; height: 0px; margin-top: 20px; margin-bottom: 20px; border-right-width: 0px; border-bottom-width: 0px; border-left-width: 0px; border-top-style: solid; border-top-color: rgb(238, 238, 238); color: rgb(61, 68, 80); font-family: &quot;Microsoft Yahei&quot;, Helvetica, Arial, sans-serif; font-size: 12px; line-height: 17.1429px; white-space: normal; background-color: rgb(255, 255, 255);\"\/>\n<p style=\"box-sizing: border-box; margin-top: 0px; margin-bottom: 10px; line-height: 23px; text-indent: 1em; text-align: justify; color: rgb(61, 68, 80); font-family: &quot;Microsoft Yahei&quot;, Helvetica, Arial, sans-serif; font-size: 12px; white-space: normal; background-color: rgb(255, 255, 255);\">if\u6761\u4ef6\u8bed\u53e5\u7684\u53cc\u5206\u652f\u7ed3\u6784\u7531if\u3001then\u3001else\u3001fi\u5173\u952e\u8bcd\u7ec4\u6210\uff0c\u5b83\u8fdb\u884c\u4e00\u6b21\u6761\u4ef6\u5339\u914d\u5224\u65ad\uff0c\u5982\u679c\u4e0e\u6761\u4ef6\u5339\u914d\uff0c\u5219\u53bb\u6267\u884c\u76f8\u5e94\u7684\u9884\u8bbe\u547d\u4ee4\uff1b\u53cd\u4e4b\u5219\u53bb\u6267\u884c\u4e0d\u5339\u914d\u65f6\u7684\u9884\u8bbe\u547d\u4ee4\uff0c\u76f8\u5f53\u4e8e\u53e3\u8bed\u7684\u201c\u5982\u679c\u2026\u2026\u90a3\u4e48\u2026\u2026\u6216\u8005\u2026\u2026\u90a3\u4e48\u2026\u2026\u201d\u3002if\u6761\u4ef6\u8bed\u53e5\u7684\u53cc\u5206\u652f\u7ed3\u6784\u4e5f\u662f\u4e00\u79cd\u5f88\u7b80\u5355\u7684\u5224\u65ad\u7ed3\u6784\uff0c\u8bed\u6cd5\u683c\u5f0f\u5982\u56fe4-18\u6240\u793a\u3002<\/p>\n<p style=\"box-sizing: border-box; margin-top: 0px; margin-bottom: 10px; line-height: 23px; text-indent: 1em; text-align: justify; color: rgb(61, 68, 80); font-family: &quot;Microsoft Yahei&quot;, Helvetica, Arial, sans-serif; font-size: 12px; white-space: normal; background-color: rgb(255, 255, 255);\"><div class='fancybox-wrapper lazyload-container-unload' data-fancybox='post-images' href='https:\/\/www.linuxprobe.com\/wp-content\/uploads\/2015\/07\/%E5%8F%8C%E5%88%86%E6%94%AF%E7%BB%93%E6%9E%84-1.png'><img class=\"lazyload lazyload-style-1\" src=\"data:image\/svg+xml;base64,PCEtLUFyZ29uTG9hZGluZy0tPgo8c3ZnIHdpZHRoPSIxIiBoZWlnaHQ9IjEiIHhtbG5zPSJodHRwOi8vd3d3LnczLm9yZy8yMDAwL3N2ZyIgc3Ryb2tlPSIjZmZmZmZmMDAiPjxnPjwvZz4KPC9zdmc+\"  loading=\"lazy\" decoding=\"async\" class=\"size-full wp-image-40057 aligncenter\" data-original=\"https:\/\/www.linuxprobe.com\/wp-content\/uploads\/2015\/07\/%E5%8F%8C%E5%88%86%E6%94%AF%E7%BB%93%E6%9E%84-1.png\" src=\"data:image\/png;base64,iVBORw0KGgoAAAANSUhEUgAAAAEAAAABCAYAAAAfFcSJAAAAAXNSR0IArs4c6QAAAARnQU1BAACxjwv8YQUAAAAJcEhZcwAADsQAAA7EAZUrDhsAAAANSURBVBhXYzh8+PB\/AAffA0nNPuCLAAAAAElFTkSuQmCC\" alt=\"\u7b2c4\u7ae0 Vim\u7f16\u8f91\u5668\u4e0eShell\u547d\u4ee4\u811a\u672c\u3002\u7b2c4\u7ae0 Vim\u7f16\u8f91\u5668\u4e0eShell\u547d\u4ee4\u811a\u672c\u3002\" width=\"465\" height=\"123\"  sizes=\"auto, (max-width: 465px) 100vw, 465px\" title=\"\u7b2c4\u7ae0 Vim\u7f16\u8f91\u5668\u4e0eShell\u547d\u4ee4\u811a\u672c\u3002\u7b2c4\u7ae0 Vim\u7f16\u8f91\u5668\u4e0eShell\u547d\u4ee4\u811a\u672c\u3002\" style=\"box-sizing: border-box; max-width: 100%; border-radius: 4px; vertical-align: middle; height: auto; margin: 10px auto; display: block;\"\/><\/div><\/p>\n<p style=\"box-sizing: border-box; margin-top: 0px; margin-bottom: 10px; line-height: 23px; text-indent: 1em; text-align: center; color: rgb(61, 68, 80); font-family: &quot;Microsoft Yahei&quot;, Helvetica, Arial, sans-serif; font-size: 12px; white-space: normal; background-color: rgb(255, 255, 255);\">\u56fe4-18&nbsp;\u53cc\u5206\u652f\u7684if\u6761\u4ef6\u8bed\u53e5<\/p>\n<p style=\"box-sizing: border-box; margin-top: 0px; margin-bottom: 10px; line-height: 23px; text-indent: 1em; text-align: justify; color: rgb(61, 68, 80); font-family: &quot;Microsoft Yahei&quot;, Helvetica, Arial, sans-serif; font-size: 12px; white-space: normal; background-color: rgb(255, 255, 255);\">\u4e0b\u9762\u4f7f\u7528\u53cc\u5206\u652f\u7684if\u6761\u4ef6\u8bed\u53e5\u6765\u9a8c\u8bc1\u67d0\u53f0\u4e3b\u673a\u662f\u5426\u5728\u7ebf\uff0c\u7136\u540e\u6839\u636e\u8fd4\u56de\u503c\u7684\u7ed3\u679c\uff0c\u8981\u4e48\u663e\u793a\u4e3b\u673a\u5728\u7ebf\u4fe1\u606f\uff0c\u8981\u4e48\u663e\u793a\u4e3b\u673a\u4e0d\u5728\u7ebf\u4fe1\u606f\u3002\u8fd9\u91cc\u7684\u811a\u672c\u4e3b\u8981\u4f7f\u7528ping\u547d\u4ee4\u6765\u6d4b\u8bd5\u4e0e\u5bf9\u65b9\u4e3b\u673a\u7684\u7f51\u7edc\u8054\u901a\u6027\uff0c\u800cLinux\u7cfb\u7edf\u4e2d\u7684ping\u547d\u4ee4\u4e0d\u50cfWindows\u4e00\u6837\u5c1d\u8bd54\u6b21\u5c31\u7ed3\u675f\uff0c\u56e0\u6b64\u4e3a\u4e86\u907f\u514d\u7528\u6237\u7b49\u5f85\u65f6\u95f4\u8fc7\u957f\uff0c\u9700\u8981\u901a\u8fc7-c\u53c2\u6570\u6765\u89c4\u5b9a\u5c1d\u8bd5\u7684\u6b21\u6570\uff0c\u5e76\u4f7f\u7528-i\u53c2\u6570\u5b9a\u4e49\u6bcf\u4e2a\u6570\u636e\u5305\u7684\u53d1\u9001\u95f4\u9694\uff0c\u4ee5\u53ca\u4f7f\u7528-W\u53c2\u6570\u5b9a\u4e49\u7b49\u5f85\u8d85\u65f6\u65f6\u95f4\u3002<\/p>\n<pre style=\"box-sizing: border-box; font-family: Monaco, Menlo, Consolas, &quot;Courier New&quot;, monospace; font-size: 13px; white-space: pre-wrap; padding: 9.5px; margin-top: 0px; margin-bottom: 10px; line-height: 1.42857; color: rgb(51, 51, 51); word-break: break-all; word-wrap: break-word; border: 1px solid rgb(204, 204, 204); border-radius: 4px; background-color: rgb(245, 245, 245);\">[root@linuxprobe&nbsp;~]#&nbsp;vim&nbsp;chkhost.sh\r\n#!\/bin\/bash\r\nping&nbsp;-c&nbsp;3&nbsp;-i&nbsp;0.2&nbsp;-W&nbsp;3&nbsp;$1&nbsp;&amp;&gt;&nbsp;\/dev\/null\r\nif&nbsp;[&nbsp;$?&nbsp;-eq&nbsp;0&nbsp;]\r\nthen\r\necho&nbsp;&quot;Host&nbsp;$1&nbsp;is&nbsp;On-line.&quot;\r\nelse\r\necho&nbsp;&quot;Host&nbsp;$1&nbsp;is&nbsp;Off-line.&quot;\r\nfi<\/pre>\n<p style=\"box-sizing: border-box; margin-top: 0px; margin-bottom: 10px; line-height: 23px; text-indent: 1em; text-align: justify; color: rgb(61, 68, 80); font-family: &quot;Microsoft Yahei&quot;, Helvetica, Arial, sans-serif; font-size: 12px; white-space: normal; background-color: rgb(255, 255, 255);\">\u6211\u4eec\u57284.2.3\u5c0f\u8282\u4e2d\u7528\u8fc7$?\u53d8\u91cf\uff0c\u4f5c\u7528\u662f\u663e\u793a\u4e0a\u4e00\u6b21\u547d\u4ee4\u7684\u6267\u884c\u8fd4\u56de\u503c\u3002\u82e5\u524d\u9762\u7684\u90a3\u6761\u8bed\u53e5\u6210\u529f\u6267\u884c\uff0c\u5219$?\u53d8\u91cf\u4f1a\u663e\u793a\u6570\u5b570\uff0c\u53cd\u4e4b\u5219\u663e\u793a\u4e00\u4e2a\u975e\u96f6\u7684\u6570\u5b57\uff08\u53ef\u80fd\u4e3a1\uff0c\u4e5f\u53ef\u80fd\u4e3a2\uff0c\u53d6\u51b3\u4e8e\u7cfb\u7edf\u7248\u672c\uff09\u3002\u56e0\u6b64\u53ef\u4ee5\u4f7f\u7528\u6574\u6570\u6bd4\u8f83\u8fd0\u7b97\u7b26\u6765\u5224\u65ad$?\u53d8\u91cf\u662f\u5426\u4e3a0\uff0c\u4ece\u800c\u83b7\u77e5\u90a3\u6761\u8bed\u53e5\u7684\u6700\u7ec8\u5224\u65ad\u60c5\u51b5\u3002\u8fd9\u91cc\u7684\u670d\u52a1\u5668IP\u5730\u5740\u4e3a192.168.10.10\uff0c\u6211\u4eec\u6765\u9a8c\u8bc1\u4e00\u4e0b\u811a\u672c\u7684\u6548\u679c\uff1a<\/p>\n<pre style=\"box-sizing: border-box; font-family: Monaco, Menlo, Consolas, &quot;Courier New&quot;, monospace; font-size: 13px; white-space: pre-wrap; padding: 9.5px; margin-top: 0px; margin-bottom: 10px; line-height: 1.42857; color: rgb(51, 51, 51); word-break: break-all; word-wrap: break-word; border: 1px solid rgb(204, 204, 204); border-radius: 4px; background-color: rgb(245, 245, 245);\">[root@linuxprobe&nbsp;~]#&nbsp;bash&nbsp;chkhost.sh&nbsp;192.168.10.10\r\nHost&nbsp;192.168.10.10&nbsp;is&nbsp;On-line.\r\n[root@linuxprobe&nbsp;~]#&nbsp;bash&nbsp;chkhost.sh&nbsp;192.168.10.20\r\nHost&nbsp;192.168.10.20&nbsp;is&nbsp;Off-line.<\/pre>\n<p style=\"box-sizing: border-box; margin-top: 0px; margin-bottom: 10px; line-height: 23px; text-indent: 1em; text-align: justify; color: rgb(61, 68, 80); font-family: &quot;Microsoft Yahei&quot;, Helvetica, Arial, sans-serif; font-size: 12px; white-space: normal; background-color: rgb(255, 255, 255);\">if\u6761\u4ef6\u8bed\u53e5\u7684\u591a\u5206\u652f\u7ed3\u6784\u7531if\u3001then\u3001else\u3001elif\u3001fi\u5173\u952e\u8bcd\u7ec4\u6210\uff0c\u5b83\u8fdb\u884c\u591a\u6b21\u6761\u4ef6\u5339\u914d\u5224\u65ad\uff0c\u8fd9\u591a\u6b21\u5224\u65ad\u4e2d\u7684\u4efb\u4f55\u4e00\u9879\u5728\u5339\u914d\u6210\u529f\u540e\u90fd\u4f1a\u6267\u884c\u76f8\u5e94\u7684\u9884\u8bbe\u547d\u4ee4\uff0c\u76f8\u5f53\u4e8e\u53e3\u8bed\u7684\u201c\u5982\u679c\u2026\u2026\u90a3\u4e48\u2026\u2026\u5982\u679c\u2026\u2026\u90a3\u4e48\u2026\u2026\u201d\u3002if\u6761\u4ef6\u8bed\u53e5\u7684\u591a\u5206\u652f\u7ed3\u6784\u662f\u5de5\u4f5c\u4e2d\u6700\u5e38\u4f7f\u7528\u7684\u4e00\u79cd\u6761\u4ef6\u5224\u65ad\u7ed3\u6784\uff0c\u5c3d\u7ba1\u76f8\u5bf9\u590d\u6742\u4f46\u662f\u66f4\u52a0\u7075\u6d3b\uff0c\u8bed\u6cd5\u683c\u5f0f\u5982\u56fe4-19\u6240\u793a\u3002<div class='fancybox-wrapper lazyload-container-unload' data-fancybox='post-images' href='https:\/\/www.linuxprobe.com\/wp-content\/uploads\/2015\/07\/%E5%A4%9A%E5%88%86%E6%94%AF%E7%BB%93%E6%9E%84-2.png'><img class=\"lazyload lazyload-style-1\" src=\"data:image\/svg+xml;base64,PCEtLUFyZ29uTG9hZGluZy0tPgo8c3ZnIHdpZHRoPSIxIiBoZWlnaHQ9IjEiIHhtbG5zPSJodHRwOi8vd3d3LnczLm9yZy8yMDAwL3N2ZyIgc3Ryb2tlPSIjZmZmZmZmMDAiPjxnPjwvZz4KPC9zdmc+\"  loading=\"lazy\" decoding=\"async\" class=\"size-full wp-image-40058 aligncenter\" data-original=\"https:\/\/www.linuxprobe.com\/wp-content\/uploads\/2015\/07\/%E5%A4%9A%E5%88%86%E6%94%AF%E7%BB%93%E6%9E%84-2.png\" src=\"data:image\/png;base64,iVBORw0KGgoAAAANSUhEUgAAAAEAAAABCAYAAAAfFcSJAAAAAXNSR0IArs4c6QAAAARnQU1BAACxjwv8YQUAAAAJcEhZcwAADsQAAA7EAZUrDhsAAAANSURBVBhXYzh8+PB\/AAffA0nNPuCLAAAAAElFTkSuQmCC\" alt=\"\u7b2c4\u7ae0 Vim\u7f16\u8f91\u5668\u4e0eShell\u547d\u4ee4\u811a\u672c\u3002\u7b2c4\u7ae0 Vim\u7f16\u8f91\u5668\u4e0eShell\u547d\u4ee4\u811a\u672c\u3002\" width=\"509\" height=\"212\"  sizes=\"auto, (max-width: 509px) 100vw, 509px\" title=\"\u7b2c4\u7ae0 Vim\u7f16\u8f91\u5668\u4e0eShell\u547d\u4ee4\u811a\u672c\u3002\u7b2c4\u7ae0 Vim\u7f16\u8f91\u5668\u4e0eShell\u547d\u4ee4\u811a\u672c\u3002\" style=\"box-sizing: border-box; max-width: 100%; border-radius: 4px; vertical-align: middle; height: auto; margin: 10px auto; display: block;\"\/><\/div><\/p>\n<p style=\"box-sizing: border-box; margin-top: 0px; margin-bottom: 10px; line-height: 23px; text-indent: 1em; text-align: center; color: rgb(61, 68, 80); font-family: &quot;Microsoft Yahei&quot;, Helvetica, Arial, sans-serif; font-size: 12px; white-space: normal; background-color: rgb(255, 255, 255);\">\u56fe 4-19 \u591a\u5206\u652f\u7684if\u6761\u4ef6\u8bed\u53e5<\/p>\n<p style=\"box-sizing: border-box; margin-top: 0px; margin-bottom: 10px; line-height: 23px; text-indent: 1em; text-align: justify; color: rgb(61, 68, 80); font-family: &quot;Microsoft Yahei&quot;, Helvetica, Arial, sans-serif; font-size: 12px; white-space: normal; background-color: rgb(255, 255, 255);\">\u4e0b\u9762\u4f7f\u7528\u591a\u5206\u652f\u7684if\u6761\u4ef6\u8bed\u53e5\u6765\u5224\u65ad\u7528\u6237\u8f93\u5165\u7684\u5206\u6570\u5728\u54ea\u4e2a\u6210\u7ee9\u533a\u95f4\u5185\uff0c\u7136\u540e\u8f93\u51fa\u5982Excellent\u3001Pass\u3001Fail\u7b49\u63d0\u793a\u4fe1\u606f\u3002\u5728Linux\u7cfb\u7edf\u4e2d\uff0cread\u662f\u7528\u6765\u8bfb\u53d6\u7528\u6237\u8f93\u5165\u4fe1\u606f\u7684\u547d\u4ee4\uff0c\u80fd\u591f\u628a\u63a5\u6536\u5230\u7684\u7528\u6237\u8f93\u5165\u4fe1\u606f\u8d4b\u503c\u7ed9\u540e\u9762\u7684\u6307\u5b9a\u53d8\u91cf\uff0c-p\u53c2\u6570\u7528\u4e8e\u5411\u7528\u6237\u663e\u793a\u4e00\u5b9a\u7684\u63d0\u793a\u4fe1\u606f\u3002\u5728\u4e0b\u9762\u7684\u811a\u672c\u793a\u4f8b\u4e2d\uff0c\u53ea\u6709\u5f53\u7528\u6237\u8f93\u5165\u7684\u5206\u6570\u5927\u4e8e\u7b49\u4e8e85\u5206\u4e14\u5c0f\u4e8e\u7b49\u4e8e100\u5206\uff0c\u624d\u8f93\u51faExcellent\u5b57\u6837\uff1b\u82e5\u5206\u6570\u4e0d\u6ee1\u8db3\u8be5\u6761\u4ef6\uff08\u5373\u5339\u914d\u4e0d\u6210\u529f\uff09\uff0c\u5219\u7ee7\u7eed\u5224\u65ad\u5206\u6570\u662f\u5426\u5927\u4e8e\u7b49\u4e8e70\u5206\u4e14\u5c0f\u4e8e\u7b49\u4e8e84\u5206\uff0c\u5982\u679c\u662f\uff0c\u5219\u8f93\u51faPass\u5b57\u6837\uff1b\u82e5\u4e24\u6b21\u90fd\u843d\u7a7a\uff08\u5373\u4e24\u6b21\u7684\u5339\u914d\u64cd\u4f5c\u90fd\u5931\u8d25\u4e86\uff09\uff0c\u5219\u8f93\u51faFail\u5b57\u6837\uff1a<\/p>\n<pre style=\"box-sizing: border-box; font-family: Monaco, Menlo, Consolas, &quot;Courier New&quot;, monospace; font-size: 13px; white-space: pre-wrap; padding: 9.5px; margin-top: 0px; margin-bottom: 10px; line-height: 1.42857; color: rgb(51, 51, 51); word-break: break-all; word-wrap: break-word; border: 1px solid rgb(204, 204, 204); border-radius: 4px; background-color: rgb(245, 245, 245);\">[root@linuxprobe&nbsp;~]#&nbsp;vim&nbsp;chkscore.sh\r\n#!\/bin\/bash\r\nread&nbsp;-p&nbsp;&quot;Enter&nbsp;your&nbsp;score\uff080-100\uff09\uff1a&quot;&nbsp;GRADE\r\nif&nbsp;[&nbsp;$GRADE&nbsp;-ge&nbsp;85&nbsp;]&nbsp;&amp;&amp;&nbsp;[&nbsp;$GRADE&nbsp;-le&nbsp;100&nbsp;]&nbsp;;&nbsp;then\r\necho&nbsp;&quot;$GRADE&nbsp;is&nbsp;Excellent&quot;\r\nelif&nbsp;[&nbsp;$GRADE&nbsp;-ge&nbsp;70&nbsp;]&nbsp;&amp;&amp;&nbsp;[&nbsp;$GRADE&nbsp;-le&nbsp;84&nbsp;]&nbsp;;&nbsp;then\r\necho&nbsp;&quot;$GRADE&nbsp;is&nbsp;Pass&quot;\r\nelse\r\necho&nbsp;&quot;$GRADE&nbsp;is&nbsp;Fail&quot;&nbsp;\r\nfi\r\n[root@linuxprobe&nbsp;~]#&nbsp;bash&nbsp;chkscore.sh\r\nEnter&nbsp;your&nbsp;score\uff080-100\uff09\uff1a88\r\n88&nbsp;is&nbsp;Excellent\r\n[root@linuxprobe&nbsp;~]#&nbsp;bash&nbsp;chkscore.sh&nbsp;\r\nEnter&nbsp;your&nbsp;score\uff080-100\uff09\uff1a80\r\n80&nbsp;is&nbsp;Pass<\/pre>\n<p style=\"box-sizing: border-box; margin-top: 0px; margin-bottom: 10px; line-height: 23px; text-indent: 1em; text-align: justify; color: rgb(61, 68, 80); font-family: &quot;Microsoft Yahei&quot;, Helvetica, Arial, sans-serif; font-size: 12px; white-space: normal; background-color: rgb(255, 255, 255);\">\u4e0b\u9762\u6267\u884c\u8be5\u811a\u672c\u3002\u5f53\u7528\u6237\u8f93\u5165\u7684\u5206\u6570\u5206\u522b\u4e3a30\u548c200\u65f6\uff0c\u5176\u7ed3\u679c\u5982\u4e0b\uff1a<\/p>\n<pre style=\"box-sizing: border-box; font-family: Monaco, Menlo, Consolas, &quot;Courier New&quot;, monospace; font-size: 13px; white-space: pre-wrap; padding: 9.5px; margin-top: 0px; margin-bottom: 10px; line-height: 1.42857; color: rgb(51, 51, 51); word-break: break-all; word-wrap: break-word; border: 1px solid rgb(204, 204, 204); border-radius: 4px; background-color: rgb(245, 245, 245);\">[root@linuxprobe&nbsp;~]#&nbsp;bash&nbsp;chkscore.sh&nbsp;&nbsp;\r\nEnter&nbsp;your&nbsp;score\uff080-100\uff09\uff1a30\r\n30&nbsp;is&nbsp;Fail\r\n[root@linuxprobe&nbsp;~]#&nbsp;bash&nbsp;chkscore.sh\r\nEnter&nbsp;your&nbsp;score\uff080-100\uff09\uff1a200&nbsp;\r\n200&nbsp;is&nbsp;Fail<\/pre>\n<p style=\"box-sizing: border-box; margin-top: 0px; margin-bottom: 10px; line-height: 23px; text-indent: 1em; text-align: justify; color: rgb(61, 68, 80); font-family: &quot;Microsoft Yahei&quot;, Helvetica, Arial, sans-serif; font-size: 12px; white-space: normal; background-color: rgb(255, 255, 255);\">\u4e3a\u4ec0\u4e48\u8f93\u5165\u7684\u5206\u6570\u4e3a200\u65f6\uff0c\u4f9d\u7136\u663e\u793aFail\u5462\uff1f\u539f\u56e0\u5f88\u7b80\u5355\u2014\u6ca1\u6709\u6210\u529f\u5339\u914d\u811a\u672c\u4e2d\u7684\u4e24\u4e2a\u6761\u4ef6\u5224\u65ad\u8bed\u53e5\uff0c\u56e0\u6b64\u81ea\u52a8\u6267\u884c\u4e86\u6700\u7ec8\u7684\u515c\u5e95\u7b56\u7565\u3002\u53ef\u89c1\uff0c\u8fd9\u4e2a\u811a\u672c\u8fd8\u4e0d\u662f\u5f88\u5b8c\u7f8e\uff0c\u5efa\u8bae\u8bfb\u8005\u81ea\u884c\u5b8c\u5584\u8fd9\u4e2a\u811a\u672c\uff0c\u4f7f\u5f97\u7528\u6237\u5728\u8f93\u5165\u5927\u4e8e100\u6216\u5c0f\u4e8e0\u7684\u5206\u6570\u65f6\uff0c\u7ed9\u4e88Error\u62a5\u9519\u5b57\u6837\u7684\u63d0\u793a\u3002<\/p>\n<h6 style=\"box-sizing: border-box; font-family: &quot;Helvetica Neue&quot;, Helvetica, Arial, sans-serif; font-weight: 500; line-height: 1.1; margin-top: 10px; margin-bottom: 10px; font-size: 12px; color: rgb(61, 68, 80); white-space: normal; background-color: rgb(255, 255, 255);\"><span id=\"432_for\" style=\"box-sizing: border-box;\"><strong style=\"box-sizing: border-box;\"><span style=\"box-sizing: border-box; color: #008000;\">4.3.2 for\u6761\u4ef6\u5faa\u73af\u8bed\u53e5<\/span><\/strong><\/span><\/h6>\n<p style=\"box-sizing: border-box; margin-top: 0px; margin-bottom: 10px; line-height: 23px; text-indent: 1em; text-align: justify; color: rgb(61, 68, 80); font-family: &quot;Microsoft Yahei&quot;, Helvetica, Arial, sans-serif; font-size: 12px; white-space: normal; background-color: rgb(255, 255, 255);\">for\u5faa\u73af\u8bed\u53e5\u5141\u8bb8\u811a\u672c\u4e00\u6b21\u6027\u8bfb\u53d6\u591a\u4e2a\u4fe1\u606f\uff0c\u7136\u540e\u9010\u4e00\u5bf9\u4fe1\u606f\u8fdb\u884c\u64cd\u4f5c\u5904\u7406\uff0c\u5f53\u8981\u5904\u7406\u7684\u6570\u636e\u6709\u8303\u56f4\u65f6\uff0c\u4f7f\u7528for\u5faa\u73af\u8bed\u53e5\u518d\u9002\u5408\u4e0d\u8fc7\u4e86\u3002for\u5faa\u73af\u8bed\u53e5\u7684\u8bed\u6cd5\u683c\u5f0f\u5982\u56fe4-20\u6240\u793a\u3002<\/p>\n<p style=\"box-sizing: border-box; margin-top: 0px; margin-bottom: 10px; line-height: 23px; text-indent: 1em; text-align: justify; color: rgb(61, 68, 80); font-family: &quot;Microsoft Yahei&quot;, Helvetica, Arial, sans-serif; font-size: 12px; white-space: normal; background-color: rgb(255, 255, 255);\"><div class='fancybox-wrapper lazyload-container-unload' data-fancybox='post-images' href='https:\/\/www.linuxprobe.com\/wp-content\/uploads\/2015\/07\/for%E6%9D%A1%E4%BB%B6%E8%AF%AD%E5%8F%A5-1.png'><img class=\"lazyload lazyload-style-1\" src=\"data:image\/svg+xml;base64,PCEtLUFyZ29uTG9hZGluZy0tPgo8c3ZnIHdpZHRoPSIxIiBoZWlnaHQ9IjEiIHhtbG5zPSJodHRwOi8vd3d3LnczLm9yZy8yMDAwL3N2ZyIgc3Ryb2tlPSIjZmZmZmZmMDAiPjxnPjwvZz4KPC9zdmc+\"  loading=\"lazy\" decoding=\"async\" class=\"size-full wp-image-40145 aligncenter\" data-original=\"https:\/\/www.linuxprobe.com\/wp-content\/uploads\/2015\/07\/for%E6%9D%A1%E4%BB%B6%E8%AF%AD%E5%8F%A5-1.png\" src=\"data:image\/png;base64,iVBORw0KGgoAAAANSUhEUgAAAAEAAAABCAYAAAAfFcSJAAAAAXNSR0IArs4c6QAAAARnQU1BAACxjwv8YQUAAAAJcEhZcwAADsQAAA7EAZUrDhsAAAANSURBVBhXYzh8+PB\/AAffA0nNPuCLAAAAAElFTkSuQmCC\" alt=\"\u7b2c4\u7ae0 Vim\u7f16\u8f91\u5668\u4e0eShell\u547d\u4ee4\u811a\u672c\u3002\u7b2c4\u7ae0 Vim\u7f16\u8f91\u5668\u4e0eShell\u547d\u4ee4\u811a\u672c\u3002\" width=\"473\" height=\"100\"  sizes=\"auto, (max-width: 473px) 100vw, 473px\" title=\"\u7b2c4\u7ae0 Vim\u7f16\u8f91\u5668\u4e0eShell\u547d\u4ee4\u811a\u672c\u3002\u7b2c4\u7ae0 Vim\u7f16\u8f91\u5668\u4e0eShell\u547d\u4ee4\u811a\u672c\u3002\" style=\"box-sizing: border-box; max-width: 100%; border-radius: 4px; vertical-align: middle; height: auto; margin: 10px auto; display: block;\"\/><\/div><\/p>\n<p style=\"box-sizing: border-box; margin-top: 0px; margin-bottom: 10px; line-height: 23px; text-indent: 1em; text-align: center; color: rgb(61, 68, 80); font-family: &quot;Microsoft Yahei&quot;, Helvetica, Arial, sans-serif; font-size: 12px; white-space: normal; background-color: rgb(255, 255, 255);\">\u56fe4-20&nbsp; for\u5faa\u73af\u8bed\u53e5\u7684\u8bed\u6cd5\u683c\u5f0f<\/p>\n<p style=\"box-sizing: border-box; margin-top: 0px; margin-bottom: 10px; line-height: 23px; text-indent: 1em; text-align: justify; color: rgb(61, 68, 80); font-family: &quot;Microsoft Yahei&quot;, Helvetica, Arial, sans-serif; font-size: 12px; white-space: normal; background-color: rgb(255, 255, 255);\">\u4e0b\u9762\u4f7f\u7528for\u5faa\u73af\u8bed\u53e5\u4ece\u5217\u8868\u6587\u4ef6\u4e2d\u8bfb\u53d6\u591a\u4e2a\u7528\u6237\u540d\uff0c\u7136\u540e\u4e3a\u5176\u9010\u4e00\u521b\u5efa\u7528\u6237\u8d26\u6237\u5e76\u8bbe\u7f6e\u5bc6\u7801\u3002\u9996\u5148\u521b\u5efa\u7528\u6237\u540d\u79f0\u7684\u5217\u8868\u6587\u4ef6users.txt\uff0c\u6bcf\u4e2a\u7528\u6237\u540d\u79f0\u5355\u72ec\u4e00\u884c\u3002\u8bfb\u8005\u53ef\u4ee5\u81ea\u884c\u51b3\u5b9a\u5177\u4f53\u7684\u7528\u6237\u540d\u79f0\u548c\u4e2a\u6570\uff1a<\/p>\n<pre style=\"box-sizing: border-box; font-family: Monaco, Menlo, Consolas, &quot;Courier New&quot;, monospace; font-size: 13px; white-space: pre-wrap; padding: 9.5px; margin-top: 0px; margin-bottom: 10px; line-height: 1.42857; color: rgb(51, 51, 51); word-break: break-all; word-wrap: break-word; border: 1px solid rgb(204, 204, 204); border-radius: 4px; background-color: rgb(245, 245, 245);\">[root@linuxprobe&nbsp;~]#&nbsp;vim&nbsp;users.txt\r\nandy\r\nbarry\r\ncarl\r\nduke\r\neric\r\ngeorge<\/pre>\n<p style=\"box-sizing: border-box; margin-top: 0px; margin-bottom: 10px; line-height: 23px; text-indent: 1em; text-align: justify; color: rgb(61, 68, 80); font-family: &quot;Microsoft Yahei&quot;, Helvetica, Arial, sans-serif; font-size: 12px; white-space: normal; background-color: rgb(255, 255, 255);\">\u63a5\u4e0b\u6765\u7f16\u5199Shell\u811a\u672cExample.sh\u3002\u5728\u811a\u672c\u4e2d\u4f7f\u7528read\u547d\u4ee4\u8bfb\u53d6\u7528\u6237\u8f93\u5165\u7684\u5bc6\u7801\u503c\uff0c\u7136\u540e\u8d4b\u503c\u7ed9PASSWD\u53d8\u91cf\uff0c\u5e76\u901a\u8fc7-p\u53c2\u6570\u5411\u7528\u6237\u663e\u793a\u4e00\u6bb5\u63d0\u793a\u4fe1\u606f\uff0c\u544a\u8bc9\u7528\u6237\u6b63\u5728\u8f93\u5165\u7684\u5185\u5bb9\u5373\u5c06\u4f5c\u4e3a\u8d26\u6237\u5bc6\u7801\u3002\u5728\u6267\u884c\u8be5\u811a\u672c\u540e\uff0c\u4f1a\u81ea\u52a8\u4f7f\u7528\u4ece\u5217\u8868\u6587\u4ef6users.txt\u4e2d\u83b7\u53d6\u5230\u6240\u6709\u7684\u7528\u6237\u540d\u79f0\uff0c\u7136\u540e\u9010\u4e00\u4f7f\u7528\u201cid \u7528\u6237\u540d\u201d\u547d\u4ee4\u67e5\u770b\u7528\u6237\u7684\u4fe1\u606f\uff0c\u5e76\u4f7f\u7528$?\u5224\u65ad\u8fd9\u6761\u547d\u4ee4\u662f\u5426\u6267\u884c\u6210\u529f\uff0c\u4e5f\u5c31\u662f\u5224\u65ad\u8be5\u7528\u6237\u662f\u5426\u5df2\u7ecf\u5b58\u5728\u3002<\/p>\n<p style=\"box-sizing: border-box; margin-top: 0px; margin-bottom: 10px; line-height: 23px; text-indent: 1em; text-align: justify; color: rgb(61, 68, 80); font-family: &quot;Microsoft Yahei&quot;, Helvetica, Arial, sans-serif; font-size: 12px; white-space: normal; background-color: rgb(255, 255, 255);\">\u9700\u8981\u591a\u8bf4\u4e00\u53e5\uff0c\/dev\/null\u662f\u4e00\u4e2a\u88ab\u79f0\u4f5cLinux\u9ed1\u6d1e\u7684\u6587\u4ef6\uff0c\u628a\u8f93\u51fa\u4fe1\u606f\u91cd\u5b9a\u5411\u5230\u8fd9\u4e2a\u6587\u4ef6\u7b49\u540c\u4e8e\u5220\u9664\u6570\u636e\uff08\u7c7b\u4f3c\u4e8e\u6ca1\u6709\u56de\u6536\u529f\u80fd\u7684\u5783\u573e\u7bb1\uff09\uff0c\u53ef\u4ee5\u8ba9\u7528\u6237\u7684\u5c4f\u5e55\u7a97\u53e3\u4fdd\u6301\u7b80\u6d01\u3002<\/p>\n<pre style=\"box-sizing: border-box; font-family: Monaco, Menlo, Consolas, &quot;Courier New&quot;, monospace; font-size: 13px; white-space: pre-wrap; padding: 9.5px; margin-top: 0px; margin-bottom: 10px; line-height: 1.42857; color: rgb(51, 51, 51); word-break: break-all; word-wrap: break-word; border: 1px solid rgb(204, 204, 204); border-radius: 4px; background-color: rgb(245, 245, 245);\">[root@linuxprobe&nbsp;~]#&nbsp;vim&nbsp;Example.sh\r\n#!\/bin\/bash\r\nread&nbsp;-p&nbsp;&quot;Enter&nbsp;The&nbsp;Users&nbsp;Password&nbsp;:&nbsp;&quot;&nbsp;PASSWD\r\nfor&nbsp;UNAME&nbsp;in&nbsp;`cat&nbsp;users.txt`\r\ndo\r\nid&nbsp;$UNAME&nbsp;&amp;&gt;&nbsp;\/dev\/null\r\nif&nbsp;[&nbsp;$?&nbsp;-eq&nbsp;0&nbsp;]\r\nthen\r\necho&nbsp;&quot;Already&nbsp;exists&quot;\r\nelse\r\nuseradd&nbsp;$UNAME&nbsp;&amp;&gt;&nbsp;\/dev\/null\r\necho&nbsp;&quot;$PASSWD&quot;&nbsp;|&nbsp;passwd&nbsp;--stdin&nbsp;$UNAME&nbsp;&amp;&gt;&nbsp;\/dev\/null\r\nif&nbsp;[&nbsp;$?&nbsp;-eq&nbsp;0&nbsp;]\r\nthen\r\necho&nbsp;&quot;$UNAME&nbsp;,&nbsp;Create&nbsp;success&quot;\r\nelse\r\necho&nbsp;&quot;$UNAME&nbsp;,&nbsp;Create&nbsp;failure&quot;\r\nfi\r\nfi\r\ndone<\/pre>\n<p style=\"box-sizing: border-box; margin-top: 0px; margin-bottom: 10px; line-height: 23px; text-indent: 1em; text-align: justify; color: rgb(61, 68, 80); font-family: &quot;Microsoft Yahei&quot;, Helvetica, Arial, sans-serif; font-size: 12px; white-space: normal; background-color: rgb(255, 255, 255);\">\u6267\u884c\u6279\u91cf\u521b\u5efa\u7528\u6237\u7684Shell\u811a\u672cExample.sh\uff0c\u5728\u8f93\u5165\u4e3a\u8d26\u6237\u8bbe\u5b9a\u7684\u5bc6\u7801\u540e\u5c06\u7531\u811a\u672c\u81ea\u52a8\u68c0\u67e5\u5e76\u521b\u5efa\u8fd9\u4e9b\u8d26\u6237\u3002\u7531\u4e8e\u5df2\u7ecf\u5c06\u591a\u4f59\u7684\u4fe1\u606f\u901a\u8fc7\u8f93\u51fa\u91cd\u5b9a\u5411\u7b26\u8f6c\u79fb\u5230\u4e86\/dev\/null\u9ed1\u6d1e\u6587\u4ef6\u4e2d\uff0c\u56e0\u6b64\u5728\u6b63\u5e38\u60c5\u51b5\u4e0b\u5c4f\u5e55\u7a97\u53e3\u9664\u4e86\u201c\u7528\u6237\u8d26\u6237\u521b\u5efa\u6210\u529f\u201d\uff08Create success\uff09\u7684\u63d0\u793a\u540e\u4e0d\u4f1a\u6709\u5176\u4ed6\u5185\u5bb9\u3002<\/p>\n<p style=\"box-sizing: border-box; margin-top: 0px; margin-bottom: 10px; line-height: 23px; text-indent: 1em; text-align: justify; color: rgb(61, 68, 80); font-family: &quot;Microsoft Yahei&quot;, Helvetica, Arial, sans-serif; font-size: 12px; white-space: normal; background-color: rgb(255, 255, 255);\">\u5728Linux\u7cfb\u7edf\u4e2d\uff0c\/etc\/passwd\u662f\u7528\u6765\u4fdd\u5b58\u7528\u6237\u8d26\u6237\u4fe1\u606f\u7684\u6587\u4ef6\u3002\u5982\u679c\u60f3\u786e\u8ba4\u8fd9\u4e2a\u811a\u672c\u662f\u5426\u6210\u529f\u521b\u5efa\u4e86\u7528\u6237\u8d26\u6237\uff0c\u53ef\u4ee5\u6253\u5f00\u8fd9\u4e2a\u6587\u4ef6\uff0c\u770b\u5176\u4e2d\u662f\u5426\u6709\u8fd9\u4e9b\u65b0\u521b\u5efa\u7684\u7528\u6237\u4fe1\u606f\u3002<\/p>\n<pre style=\"box-sizing: border-box; font-family: Monaco, Menlo, Consolas, &quot;Courier New&quot;, monospace; font-size: 13px; white-space: pre-wrap; padding: 9.5px; margin-top: 0px; margin-bottom: 10px; line-height: 1.42857; color: rgb(51, 51, 51); word-break: break-all; word-wrap: break-word; border: 1px solid rgb(204, 204, 204); border-radius: 4px; background-color: rgb(245, 245, 245);\">[root@linuxprobe&nbsp;~]#&nbsp;bash&nbsp;Example.sh\r\nEnter&nbsp;The&nbsp;Users&nbsp;Password&nbsp;:&nbsp;linuxprobe\r\nandy&nbsp;,&nbsp;Create&nbsp;success\r\nbarry&nbsp;,&nbsp;Create&nbsp;success\r\ncarl&nbsp;,&nbsp;Create&nbsp;success\r\nduke&nbsp;,&nbsp;Create&nbsp;success\r\neric&nbsp;,&nbsp;Create&nbsp;success\r\ngeorge&nbsp;,&nbsp;Create&nbsp;success\r\n[root@linuxprobe&nbsp;~]#&nbsp;tail&nbsp;-6&nbsp;\/etc\/passwd\r\nandy:x:1001:1001::\/home\/andy:\/bin\/bash\r\nbarry:x:1002:1002::\/home\/barry:\/bin\/bash\r\ncarl:x:1003:1003::\/home\/carl:\/bin\/bash\r\nduke:x:1004:1004::\/home\/duke:\/bin\/bash\r\neric:x:1005:1005::\/home\/eric:\/bin\/bash\r\ngeorge:x:1006:1006::\/home\/george:\/bin\/bash<\/pre>\n<p style=\"box-sizing: border-box; margin-top: 0px; margin-bottom: 10px; line-height: 23px; text-indent: 1em; text-align: justify; color: rgb(61, 68, 80); font-family: &quot;Microsoft Yahei&quot;, Helvetica, Arial, sans-serif; font-size: 12px; white-space: normal; background-color: rgb(255, 255, 255);\">\u60a8\u8fd8\u8bb0\u5f97\u5728\u5b66\u4e60\u53cc\u5206\u652fif\u6761\u4ef6\u8bed\u53e5\u65f6\uff0c\u7528\u5230\u7684\u90a3\u4e2a\u6d4b\u8bd5\u4e3b\u673a\u662f\u5426\u5728\u7ebf\u7684\u811a\u672c\u4e48\uff1f\u65e2\u7136\u6211\u4eec\u73b0\u5728\u5df2\u7ecf\u638c\u63e1\u4e86for\u5faa\u73af\u8bed\u53e5\uff0c\u4e0d\u59a8\u505a\u4e9b\u66f4\u9177\u7684\u4e8b\u60c5\uff0c\u6bd4\u5982\u5c1d\u8bd5\u8ba9\u811a\u672c\u4ece\u6587\u672c\u4e2d\u81ea\u52a8\u8bfb\u53d6\u4e3b\u673a\u5217\u8868\uff0c\u7136\u540e\u81ea\u52a8\u9010\u4e2a\u6d4b\u8bd5\u8fd9\u4e9b\u4e3b\u673a\u662f\u5426\u5728\u7ebf\u3002<\/p>\n<p style=\"box-sizing: border-box; margin-top: 0px; margin-bottom: 10px; line-height: 23px; text-indent: 1em; text-align: justify; color: rgb(61, 68, 80); font-family: &quot;Microsoft Yahei&quot;, Helvetica, Arial, sans-serif; font-size: 12px; white-space: normal; background-color: rgb(255, 255, 255);\">\u9996\u5148\u521b\u5efa\u4e00\u4e2a\u4e3b\u673a\u5217\u8868\u6587\u4ef6ipadds.txt\uff1a<\/p>\n<pre style=\"box-sizing: border-box; font-family: Monaco, Menlo, Consolas, &quot;Courier New&quot;, monospace; font-size: 13px; white-space: pre-wrap; padding: 9.5px; margin-top: 0px; margin-bottom: 10px; line-height: 1.42857; color: rgb(51, 51, 51); word-break: break-all; word-wrap: break-word; border: 1px solid rgb(204, 204, 204); border-radius: 4px; background-color: rgb(245, 245, 245);\">[root@linuxprobe&nbsp;~]#&nbsp;vim&nbsp;ipadds.txt\r\n192.168.10.10\r\n192.168.10.11\r\n192.168.10.12<\/pre>\n<p style=\"box-sizing: border-box; margin-top: 0px; margin-bottom: 10px; line-height: 23px; text-indent: 1em; text-align: justify; color: rgb(61, 68, 80); font-family: &quot;Microsoft Yahei&quot;, Helvetica, Arial, sans-serif; font-size: 12px; white-space: normal; background-color: rgb(255, 255, 255);\">\u7136\u540e\u524d\u9762\u7684\u53cc\u5206\u652fif\u6761\u4ef6\u8bed\u53e5\u4e0efor\u5faa\u73af\u8bed\u53e5\u76f8\u7ed3\u5408\uff0c\u8ba9\u811a\u672c\u4ece\u4e3b\u673a\u5217\u8868\u6587\u4ef6ipadds.txt\u4e2d\u81ea\u52a8\u8bfb\u53d6IP\u5730\u5740\uff08\u7528\u6765\u8868\u793a\u4e3b\u673a\uff09\u5e76\u5c06\u5176\u8d4b\u503c\u7ed9HLIST\u53d8\u91cf\uff0c\u4ece\u800c\u901a\u8fc7\u5224\u65adping\u547d\u4ee4\u6267\u884c\u540e\u7684\u8fd4\u56de\u503c\u6765\u9010\u4e2a\u6d4b\u8bd5\u4e3b\u673a\u662f\u5426\u5728\u7ebf\u3002\u811a\u672c\u4e2d\u51fa\u73b0\u7684$\uff08\u547d\u4ee4\uff09\u662f\u4e00\u79cd\u5b8c\u5168\u7c7b\u4f3c\u4e8e\u7b2c3\u7ae0\u7684\u8f6c\u4e49\u5b57\u7b26\u4e2d\u53cd\u5f15\u53f7`\u547d\u4ee4`\u7684Shell\u64cd\u4f5c\u7b26\uff0c\u6548\u679c\u540c\u6837\u662f\u6267\u884c\u62ec\u53f7\u6216\u53cc\u5f15\u53f7\u62ec\u8d77\u6765\u7684\u5b57\u7b26\u4e32\u4e2d\u7684\u547d\u4ee4\u3002\u5927\u5bb6\u5728\u7f16\u5199\u811a\u672c\u65f6\uff0c\u591a\u5b66\u4e60\u51e0\u79cd\u7c7b\u4f3c\u7684\u65b0\u65b9\u6cd5\uff0c\u53ef\u5728\u5de5\u4f5c\u4e2d\u5927\u663e\u8eab\u624b\uff1a<\/p>\n<pre style=\"box-sizing: border-box; font-family: Monaco, Menlo, Consolas, &quot;Courier New&quot;, monospace; font-size: 13px; white-space: pre-wrap; padding: 9.5px; margin-top: 0px; margin-bottom: 10px; line-height: 1.42857; color: rgb(51, 51, 51); word-break: break-all; word-wrap: break-word; border: 1px solid rgb(204, 204, 204); border-radius: 4px; background-color: rgb(245, 245, 245);\">[root@linuxprobe&nbsp;~]#&nbsp;vim&nbsp;CheckHosts.sh\r\n#!\/bin\/bash\r\nHLIST=$(cat&nbsp;~\/ipadds.txt)\r\nfor&nbsp;IP&nbsp;in&nbsp;$HLIST\r\ndo\r\nping&nbsp;-c&nbsp;3&nbsp;-i&nbsp;0.2&nbsp;-W&nbsp;3&nbsp;$IP&nbsp;&amp;&gt;&nbsp;\/dev\/null\r\nif&nbsp;[&nbsp;$?&nbsp;-eq&nbsp;0&nbsp;]&nbsp;;&nbsp;then\r\necho&nbsp;&quot;Host&nbsp;$IP&nbsp;is&nbsp;On-line.&quot;\r\nelse\r\necho&nbsp;&quot;Host&nbsp;$IP&nbsp;is&nbsp;Off-line.&quot;\r\nfi\r\ndone\r\n[root@linuxprobe&nbsp;~]#&nbsp;.\/CheckHosts.sh\r\nHost&nbsp;192.168.10.10&nbsp;is&nbsp;On-line.\r\nHost&nbsp;192.168.10.11&nbsp;is&nbsp;Off-line.\r\nHost&nbsp;192.168.10.12&nbsp;is&nbsp;Off-line.<\/pre>\n<h6 style=\"box-sizing: border-box; font-family: &quot;Helvetica Neue&quot;, Helvetica, Arial, sans-serif; font-weight: 500; line-height: 1.1; margin-top: 10px; margin-bottom: 10px; font-size: 12px; color: rgb(61, 68, 80); white-space: normal; background-color: rgb(255, 255, 255);\"><span id=\"433_while\" style=\"box-sizing: border-box;\"><span style=\"box-sizing: border-box; color: #008000;\"><strong style=\"box-sizing: border-box;\">4.3.3 while\u6761\u4ef6\u5faa\u73af\u8bed\u53e5<\/strong><\/span><\/span><\/h6>\n<p style=\"box-sizing: border-box; margin-top: 0px; margin-bottom: 10px; line-height: 23px; text-indent: 1em; text-align: justify; color: rgb(61, 68, 80); font-family: &quot;Microsoft Yahei&quot;, Helvetica, Arial, sans-serif; font-size: 12px; white-space: normal; background-color: rgb(255, 255, 255);\">while\u6761\u4ef6\u5faa\u73af\u8bed\u53e5\u662f\u4e00\u79cd\u8ba9\u811a\u672c\u6839\u636e\u67d0\u4e9b\u6761\u4ef6\u6765\u91cd\u590d\u6267\u884c\u547d\u4ee4\u7684\u8bed\u53e5\uff0c\u5b83\u7684\u5faa\u73af\u7ed3\u6784\u5f80\u5f80\u5728\u6267\u884c\u524d\u5e76\u4e0d\u786e\u5b9a\u6700\u7ec8\u6267\u884c\u7684\u6b21\u6570\uff0c\u5b8c\u5168\u4e0d\u540c\u4e8efor\u5faa\u73af\u8bed\u53e5\u4e2d\u6709\u76ee\u6807\u3001\u6709\u8303\u56f4\u7684\u4f7f\u7528\u573a\u666f\u3002while\u5faa\u73af\u8bed\u53e5\u901a\u8fc7\u5224\u65ad\u6761\u4ef6\u6d4b\u8bd5\u7684\u771f\u5047\u6765\u51b3\u5b9a\u662f\u5426\u7ee7\u7eed\u6267\u884c\u547d\u4ee4\uff0c\u82e5\u6761\u4ef6\u4e3a\u771f\u5c31\u7ee7\u7eed\u6267\u884c\uff0c\u4e3a\u5047\u5c31\u7ed3\u675f\u5faa\u73af\u3002while\u8bed\u53e5\u7684\u8bed\u6cd5\u683c\u5f0f\u5982\u56fe4-21\u6240\u793a\u3002<div class='fancybox-wrapper lazyload-container-unload' data-fancybox='post-images' href='https:\/\/www.linuxprobe.com\/wp-content\/uploads\/2015\/07\/while%E6%9D%A1%E4%BB%B6%E8%AF%AD%E5%8F%A5-1.png'><img class=\"lazyload lazyload-style-1\" src=\"data:image\/svg+xml;base64,PCEtLUFyZ29uTG9hZGluZy0tPgo8c3ZnIHdpZHRoPSIxIiBoZWlnaHQ9IjEiIHhtbG5zPSJodHRwOi8vd3d3LnczLm9yZy8yMDAwL3N2ZyIgc3Ryb2tlPSIjZmZmZmZmMDAiPjxnPjwvZz4KPC9zdmc+\"  loading=\"lazy\" decoding=\"async\" class=\"size-full wp-image-41454 aligncenter\" data-original=\"https:\/\/www.linuxprobe.com\/wp-content\/uploads\/2015\/07\/while%E6%9D%A1%E4%BB%B6%E8%AF%AD%E5%8F%A5-1.png\" src=\"data:image\/png;base64,iVBORw0KGgoAAAANSUhEUgAAAAEAAAABCAYAAAAfFcSJAAAAAXNSR0IArs4c6QAAAARnQU1BAACxjwv8YQUAAAAJcEhZcwAADsQAAA7EAZUrDhsAAAANSURBVBhXYzh8+PB\/AAffA0nNPuCLAAAAAElFTkSuQmCC\" alt=\"\u7b2c4\u7ae0 Vim\u7f16\u8f91\u5668\u4e0eShell\u547d\u4ee4\u811a\u672c\u3002\u7b2c4\u7ae0 Vim\u7f16\u8f91\u5668\u4e0eShell\u547d\u4ee4\u811a\u672c\u3002\" width=\"465\" height=\"96\"  sizes=\"auto, (max-width: 465px) 100vw, 465px\" title=\"\u7b2c4\u7ae0 Vim\u7f16\u8f91\u5668\u4e0eShell\u547d\u4ee4\u811a\u672c\u3002\u7b2c4\u7ae0 Vim\u7f16\u8f91\u5668\u4e0eShell\u547d\u4ee4\u811a\u672c\u3002\" style=\"box-sizing: border-box; max-width: 100%; border-radius: 4px; vertical-align: middle; height: auto; margin: 10px auto; display: block;\"\/><\/div><\/p>\n<p style=\"box-sizing: border-box; margin-top: 0px; margin-bottom: 10px; line-height: 23px; text-indent: 1em; text-align: center; color: rgb(61, 68, 80); font-family: &quot;Microsoft Yahei&quot;, Helvetica, Arial, sans-serif; font-size: 12px; white-space: normal; background-color: rgb(255, 255, 255);\">\u56fe4-21&nbsp; while\u5faa\u73af\u8bed\u53e5\u7684\u8bed\u6cd5\u683c\u5f0f<\/p>\n<p style=\"box-sizing: border-box; margin-top: 0px; margin-bottom: 10px; line-height: 23px; text-indent: 1em; text-align: justify; color: rgb(61, 68, 80); font-family: &quot;Microsoft Yahei&quot;, Helvetica, Arial, sans-serif; font-size: 12px; white-space: normal; background-color: rgb(255, 255, 255);\">\u63a5\u4e0b\u6765\u7ed3\u5408\u4f7f\u7528\u591a\u5206\u652f\u7684if\u6761\u4ef6\u6d4b\u8bd5\u8bed\u53e5\u4e0ewhile\u6761\u4ef6\u5faa\u73af\u8bed\u53e5\uff0c\u7f16\u5199\u4e00\u4e2a\u7528\u6765\u731c\u6d4b\u6570\u503c\u5927\u5c0f\u7684\u811a\u672cGuess.sh\u3002\u8be5\u811a\u672c\u4f7f\u7528$RANDOM\u53d8\u91cf\u6765\u8c03\u53d6\u51fa\u4e00\u4e2a\u968f\u673a\u7684\u6570\u503c\uff08\u8303\u56f4\u4e3a0\uff5e32767\uff09\uff0c\u5c06\u8fd9\u4e2a\u968f\u673a\u6570\u5bf91000\u8fdb\u884c\u53d6\u4f59\u64cd\u4f5c\uff0c\u5e76\u4f7f\u7528expr\u547d\u4ee4\u53d6\u5f97\u5176\u7ed3\u679c\uff0c\u518d\u7528\u8fd9\u4e2a\u6570\u503c\u4e0e\u7528\u6237\u901a\u8fc7read\u547d\u4ee4\u8f93\u5165\u7684\u6570\u503c\u8fdb\u884c\u6bd4\u8f83\u5224\u65ad\u3002\u8fd9\u4e2a\u5224\u65ad\u8bed\u53e5\u5206\u4e3a\u4e09\u79cd\u60c5\u51b5\uff0c\u5206\u522b\u662f\u5224\u65ad\u7528\u6237\u8f93\u5165\u7684\u6570\u503c\u662f\u7b49\u4e8e\u3001\u5927\u4e8e\u8fd8\u662f\u5c0f\u4e8e\u4f7f\u7528expr\u547d\u4ee4\u53d6\u5f97\u7684\u6570\u503c\u3002\u5f53\u524d\uff0c\u73b0\u5728\u8fd9\u4e9b\u5185\u5bb9\u4e0d\u662f\u91cd\u70b9\uff0c\u6211\u4eec\u5f53\u524d\u8981\u5173\u6ce8\u7684\u662fwhile\u6761\u4ef6\u5faa\u73af\u8bed\u53e5\u4e2d\u7684\u6761\u4ef6\u6d4b\u8bd5\u59cb\u7ec8\u4e3atrue\uff0c\u56e0\u6b64\u5224\u65ad\u8bed\u53e5\u4f1a\u65e0\u9650\u6267\u884c\u4e0b\u53bb\uff0c\u76f4\u5230\u7528\u6237\u8f93\u5165\u7684\u6570\u503c\u7b49\u4e8eexpr\u547d\u4ee4\u53d6\u5f97\u7684\u6570\u503c\u540e\uff0c\u8fd9\u4e24\u8005\u76f8\u7b49\u4e4b\u540e\u624d\u8fd0\u884cexit 0\u547d\u4ee4\uff0c\u7ec8\u6b62\u811a\u672c\u7684\u6267\u884c\u3002<\/p>\n<pre style=\"box-sizing: border-box; font-family: Monaco, Menlo, Consolas, &quot;Courier New&quot;, monospace; font-size: 13px; white-space: pre-wrap; padding: 9.5px; margin-top: 0px; margin-bottom: 10px; line-height: 1.42857; color: rgb(51, 51, 51); word-break: break-all; word-wrap: break-word; border: 1px solid rgb(204, 204, 204); border-radius: 4px; background-color: rgb(245, 245, 245);\">[root@linuxprobe&nbsp;~]#&nbsp;vim&nbsp;Guess.sh\r\n#!\/bin\/bash\r\nPRICE=$(expr&nbsp;$RANDOM&nbsp;%&nbsp;1000)\r\nTIMES=0\r\necho&nbsp;&quot;\u5546\u54c1\u5b9e\u9645\u4ef7\u683c\u4e3a0-999\u4e4b\u95f4\uff0c\u731c\u731c\u770b\u662f\u591a\u5c11\uff1f&quot;\r\nwhile&nbsp;truedo\r\nread&nbsp;-p&nbsp;&quot;\u8bf7\u8f93\u5165\u60a8\u731c\u6d4b\u7684\u4ef7\u683c\u6570\u76ee\uff1a&quot;&nbsp;INT\r\nlet&nbsp;TIMES++\r\nif&nbsp;[&nbsp;$INT&nbsp;-eq&nbsp;$PRICE&nbsp;]&nbsp;;&nbsp;then\r\necho&nbsp;&quot;\u606d\u559c\u60a8\u7b54\u5bf9\u4e86\uff0c\u5b9e\u9645\u4ef7\u683c\u662f&nbsp;$PRICE&quot;\r\necho&nbsp;&quot;\u60a8\u603b\u5171\u731c\u6d4b\u4e86&nbsp;$TIMES&nbsp;\u6b21&quot;\r\nexit&nbsp;0\r\nelif&nbsp;[&nbsp;$INT&nbsp;-gt&nbsp;$PRICE&nbsp;]&nbsp;;&nbsp;then\r\necho&nbsp;&quot;\u592a\u9ad8\u4e86\uff01&quot;\r\nelse\r\necho&nbsp;&quot;\u592a\u4f4e\u4e86\uff01&quot;\r\nfi\r\ndone<\/pre>\n<p style=\"box-sizing: border-box; margin-top: 0px; margin-bottom: 10px; line-height: 23px; text-indent: 1em; text-align: justify; color: rgb(61, 68, 80); font-family: &quot;Microsoft Yahei&quot;, Helvetica, Arial, sans-serif; font-size: 12px; white-space: normal; background-color: rgb(255, 255, 255);\">\u5728\u8fd9\u4e2aGuess.sh\u811a\u672c\u4e2d\uff0c\u6211\u4eec\u6dfb\u52a0\u4e86\u4e00\u4e9b\u4ea4\u4e92\u5f0f\u7684\u4fe1\u606f\uff0c\u4ece\u800c\u4f7f\u5f97\u7528\u6237\u4e0e\u7cfb\u7edf\u7684\u4e92\u52a8\u6027\u5f97\u4ee5\u589e\u5f3a\u3002\u800c\u4e14\u6bcf\u5f53\u5faa\u73af\u5230let TIMES++\u547d\u4ee4\u65f6\u90fd\u4f1a\u8ba9TIMES\u53d8\u91cf\u5185\u7684\u6570\u503c\u52a01\uff0c\u7528\u6765\u7edf\u8ba1\u5faa\u73af\u603b\u8ba1\u6267\u884c\u4e86\u591a\u5c11\u6b21\u3002\u8fd9\u53ef\u4ee5\u8ba9\u7528\u6237\u5f97\u77e5\u603b\u5171\u731c\u6d4b\u4e86\u591a\u5c11\u6b21\u4e4b\u540e\uff0c\u624d\u731c\u5bf9\u4ef7\u683c\u3002<\/p>\n<pre style=\"box-sizing: border-box; font-family: Monaco, Menlo, Consolas, &quot;Courier New&quot;, monospace; font-size: 13px; white-space: pre-wrap; padding: 9.5px; margin-top: 0px; margin-bottom: 10px; line-height: 1.42857; color: rgb(51, 51, 51); word-break: break-all; word-wrap: break-word; border: 1px solid rgb(204, 204, 204); border-radius: 4px; background-color: rgb(245, 245, 245);\">[root@linuxprobe&nbsp;~]#&nbsp;bash&nbsp;Guess.sh\r\n\u5546\u54c1\u5b9e\u9645\u4ef7\u683c\u4e3a0-999\u4e4b\u95f4\uff0c\u731c\u731c\u770b\u662f\u591a\u5c11\uff1f\r\n\u8bf7\u8f93\u5165\u60a8\u731c\u6d4b\u7684\u4ef7\u683c\u6570\u76ee\uff1a500\r\n\u592a\u4f4e\u4e86\uff01\r\n\u8bf7\u8f93\u5165\u60a8\u731c\u6d4b\u7684\u4ef7\u683c\u6570\u76ee\uff1a800\r\n\u592a\u9ad8\u4e86\uff01\r\n\u8bf7\u8f93\u5165\u60a8\u731c\u6d4b\u7684\u4ef7\u683c\u6570\u76ee\uff1a650\r\n\u592a\u4f4e\u4e86\uff01\r\n\u8bf7\u8f93\u5165\u60a8\u731c\u6d4b\u7684\u4ef7\u683c\u6570\u76ee\uff1a720\r\n\u592a\u9ad8\u4e86\uff01\r\n\u8bf7\u8f93\u5165\u60a8\u731c\u6d4b\u7684\u4ef7\u683c\u6570\u76ee\uff1a690\r\n\u592a\u4f4e\u4e86\uff01\r\n\u8bf7\u8f93\u5165\u60a8\u731c\u6d4b\u7684\u4ef7\u683c\u6570\u76ee\uff1a700\r\n\u592a\u9ad8\u4e86\uff01\r\n\u8bf7\u8f93\u5165\u60a8\u731c\u6d4b\u7684\u4ef7\u683c\u6570\u76ee\uff1a695\r\n\u592a\u9ad8\u4e86\uff01\r\n\u8bf7\u8f93\u5165\u60a8\u731c\u6d4b\u7684\u4ef7\u683c\u6570\u76ee\uff1a692\r\n\u592a\u9ad8\u4e86\uff01\r\n\u8bf7\u8f93\u5165\u60a8\u731c\u6d4b\u7684\u4ef7\u683c\u6570\u76ee\uff1a691\r\n\u606d\u559c\u60a8\u7b54\u5bf9\u4e86\uff0c\u5b9e\u9645\u4ef7\u683c\u662f&nbsp;691\r\n\u60a8\u603b\u5171\u731c\u6d4b\u4e86&nbsp;9&nbsp;\u6b21<\/pre>\n<h6 style=\"box-sizing: border-box; font-family: &quot;Helvetica Neue&quot;, Helvetica, Arial, sans-serif; font-weight: 500; line-height: 1.1; margin-top: 10px; margin-bottom: 10px; font-size: 12px; color: rgb(61, 68, 80); white-space: normal; background-color: rgb(255, 255, 255);\"><span id=\"434_case\" style=\"box-sizing: border-box;\"><span style=\"box-sizing: border-box; color: #008000;\"><strong style=\"box-sizing: border-box;\">4.3.4 case\u6761\u4ef6\u6d4b\u8bd5\u8bed\u53e5<\/strong><\/span><\/span><\/h6>\n<p style=\"box-sizing: border-box; margin-top: 0px; margin-bottom: 10px; line-height: 23px; text-indent: 1em; text-align: justify; color: rgb(61, 68, 80); font-family: &quot;Microsoft Yahei&quot;, Helvetica, Arial, sans-serif; font-size: 12px; white-space: normal; background-color: rgb(255, 255, 255);\">\u5982\u679c\u60a8\u4e4b\u524d\u5b66\u4e60\u8fc7C\u8bed\u8a00\uff0c\u770b\u5230\u8fd9\u4e00\u5c0f\u8282\u7684\u6807\u9898\u80af\u5b9a\u4f1a\u4f1a\u5fc3\u4e00\u7b11\u201c\u8fd9\u4e0d\u5c31\u662fswitch\u8bed\u53e5\u561b\uff01\u201d\u662f\u7684\uff0ccase\u6761\u4ef6\u6d4b\u8bd5\u8bed\u53e5\u548cswitch\u8bed\u53e5\u7684\u529f\u80fd\u975e\u5e38\u76f8\u4f3c\uff01case\u8bed\u53e5\u662f\u5728\u591a\u4e2a\u8303\u56f4\u5185\u5339\u914d\u6570\u636e\uff0c\u82e5\u5339\u914d\u6210\u529f\u5219\u6267\u884c\u76f8\u5173\u547d\u4ee4\u5e76\u7ed3\u675f\u6574\u4e2a\u6761\u4ef6\u6d4b\u8bd5\uff1b\u800c\u5982\u679c\u6570\u636e\u4e0d\u5728\u6240\u5217\u51fa\u7684\u8303\u56f4\u5185\uff0c\u5219\u4f1a\u53bb\u6267\u884c\u661f\u53f7\uff08*\uff09\u4e2d\u6240\u5b9a\u4e49\u7684\u9ed8\u8ba4\u547d\u4ee4\u3002case\u8bed\u53e5\u7684\u8bed\u6cd5\u7ed3\u6784\u5982\u56fe4-22\u6240\u793a\u3002<\/p>\n<p style=\"box-sizing: border-box; margin-top: 0px; margin-bottom: 10px; line-height: 23px; text-indent: 1em; text-align: justify; color: rgb(61, 68, 80); font-family: &quot;Microsoft Yahei&quot;, Helvetica, Arial, sans-serif; font-size: 12px; white-space: normal; background-color: rgb(255, 255, 255);\"><div class='fancybox-wrapper lazyload-container-unload' data-fancybox='post-images' href='https:\/\/www.linuxprobe.com\/wp-content\/uploads\/2015\/07\/case%E6%9D%A1%E4%BB%B6%E8%AF%AD%E5%8F%A5-1.png'><img class=\"lazyload lazyload-style-1\" src=\"data:image\/svg+xml;base64,PCEtLUFyZ29uTG9hZGluZy0tPgo8c3ZnIHdpZHRoPSIxIiBoZWlnaHQ9IjEiIHhtbG5zPSJodHRwOi8vd3d3LnczLm9yZy8yMDAwL3N2ZyIgc3Ryb2tlPSIjZmZmZmZmMDAiPjxnPjwvZz4KPC9zdmc+\"  loading=\"lazy\" decoding=\"async\" class=\"size-full wp-image-41458 aligncenter\" data-original=\"https:\/\/www.linuxprobe.com\/wp-content\/uploads\/2015\/07\/case%E6%9D%A1%E4%BB%B6%E8%AF%AD%E5%8F%A5-1.png\" src=\"data:image\/png;base64,iVBORw0KGgoAAAANSUhEUgAAAAEAAAABCAYAAAAfFcSJAAAAAXNSR0IArs4c6QAAAARnQU1BAACxjwv8YQUAAAAJcEhZcwAADsQAAA7EAZUrDhsAAAANSURBVBhXYzh8+PB\/AAffA0nNPuCLAAAAAElFTkSuQmCC\" alt=\"\u7b2c4\u7ae0 Vim\u7f16\u8f91\u5668\u4e0eShell\u547d\u4ee4\u811a\u672c\u3002\u7b2c4\u7ae0 Vim\u7f16\u8f91\u5668\u4e0eShell\u547d\u4ee4\u811a\u672c\u3002\" width=\"463\" height=\"230\"  sizes=\"auto, (max-width: 463px) 100vw, 463px\" title=\"\u7b2c4\u7ae0 Vim\u7f16\u8f91\u5668\u4e0eShell\u547d\u4ee4\u811a\u672c\u3002\u7b2c4\u7ae0 Vim\u7f16\u8f91\u5668\u4e0eShell\u547d\u4ee4\u811a\u672c\u3002\" style=\"box-sizing: border-box; max-width: 100%; border-radius: 4px; vertical-align: middle; height: auto; margin: 10px auto; display: block;\"\/><\/div><\/p>\n<p style=\"box-sizing: border-box; margin-top: 0px; margin-bottom: 10px; line-height: 23px; text-indent: 1em; text-align: center; color: rgb(61, 68, 80); font-family: &quot;Microsoft Yahei&quot;, Helvetica, Arial, sans-serif; font-size: 12px; white-space: normal; background-color: rgb(255, 255, 255);\">\u56fe4-22&nbsp; case\u6761\u4ef6\u6d4b\u8bd5\u8bed\u53e5\u7684\u8bed\u6cd5\u7ed3\u6784<\/p>\n<p style=\"box-sizing: border-box; margin-top: 0px; margin-bottom: 10px; line-height: 23px; text-indent: 1em; text-align: justify; color: rgb(61, 68, 80); font-family: &quot;Microsoft Yahei&quot;, Helvetica, Arial, sans-serif; font-size: 12px; white-space: normal; background-color: rgb(255, 255, 255);\">\u5728\u524d\u6587\u4ecb\u7ecd\u7684Guess.sh\u811a\u672c\u4e2d\u6709\u4e00\u4e2a\u81f4\u547d\u7684\u5f31\u70b9\u2014\u53ea\u80fd\u63a5\u53d7\u6570\u5b57\uff01\u60a8\u53ef\u4ee5\u5c1d\u8bd5\u8f93\u5165\u4e00\u4e2a\u5b57\u6bcd\uff0c\u4f1a\u53d1\u73b0\u811a\u672c\u7acb\u5373\u5c31\u5d29\u6e83\u4e86\u3002\u539f\u56e0\u662f\u5b57\u6bcd\u65e0\u6cd5\u4e0e\u6570\u5b57\u8fdb\u884c\u5927\u5c0f\u6bd4\u8f83\uff0c\u4f8b\u5982\uff0c\u201ca\u662f\u5426\u5927\u4e8e\u7b49\u4e8e3\u201d\u8fd9\u6837\u7684\u547d\u9898\u662f\u5b8c\u5168\u9519\u8bef\u7684\u3002\u6211\u4eec\u5fc5\u987b\u6709\u4e00\u5b9a\u7684\u63aa\u65bd\u6765\u5224\u65ad\u7528\u6237\u7684\u8f93\u5165\u5185\u5bb9\uff0c\u5f53\u7528\u6237\u8f93\u5165\u7684\u5185\u5bb9\u4e0d\u662f\u6570\u5b57\u65f6\uff0c\u811a\u672c\u80fd\u4e88\u4ee5\u63d0\u793a\uff0c\u4ece\u800c\u514d\u4e8e\u5d29\u6e83\u3002<\/p>\n<p style=\"box-sizing: border-box; margin-top: 0px; margin-bottom: 10px; line-height: 23px; text-indent: 1em; text-align: justify; color: rgb(61, 68, 80); font-family: &quot;Microsoft Yahei&quot;, Helvetica, Arial, sans-serif; font-size: 12px; white-space: normal; background-color: rgb(255, 255, 255);\">\u901a\u8fc7\u5728\u811a\u672c\u4e2d\u7ec4\u5408\u4f7f\u7528case\u6761\u4ef6\u6d4b\u8bd5\u8bed\u53e5\u548c\u901a\u914d\u7b26\uff08\u8be6\u89c1\u7b2c3\u7ae0\uff09\uff0c\u5b8c\u5168\u53ef\u4ee5\u6ee1\u8db3\u8fd9\u91cc\u7684\u9700\u6c42\u3002\u63a5\u4e0b\u6765\u6211\u4eec\u7f16\u5199\u811a\u672cCheckkeys.sh\uff0c\u63d0\u793a\u7528\u6237\u8f93\u5165\u4e00\u4e2a\u5b57\u7b26\u5e76\u5c06\u5176\u8d4b\u503c\u7ed9\u53d8\u91cfKEY\uff0c\u7136\u540e\u6839\u636e\u53d8\u91cfKEY\u7684\u503c\u5411\u7528\u6237\u663e\u793a\u5176\u503c\u662f\u5b57\u6bcd\u3001\u6570\u5b57\u8fd8\u662f\u5176\u4ed6\u5b57\u7b26\u3002<\/p>\n<pre style=\"box-sizing: border-box; font-family: Monaco, Menlo, Consolas, &quot;Courier New&quot;, monospace; font-size: 13px; white-space: pre-wrap; padding: 9.5px; margin-top: 0px; margin-bottom: 10px; line-height: 1.42857; color: rgb(51, 51, 51); word-break: break-all; word-wrap: break-word; border: 1px solid rgb(204, 204, 204); border-radius: 4px; background-color: rgb(245, 245, 245);\">[root@linuxprobe&nbsp;~]#&nbsp;vim&nbsp;Checkkeys.sh\r\n#!\/bin\/bash\r\nread&nbsp;-p&nbsp;&quot;\u8bf7\u8f93\u5165\u4e00\u4e2a\u5b57\u7b26\uff0c\u5e76\u6309Enter\u952e\u786e\u8ba4\uff1a&quot;&nbsp;KEY\r\ncase&nbsp;&quot;$KEY&quot;&nbsp;in\r\n[a-z]|[A-Z])\r\necho&nbsp;&quot;\u60a8\u8f93\u5165\u7684\u662f&nbsp;\u5b57\u6bcd\u3002&quot;\r\n;;\r\n[0-9])\r\necho&nbsp;&quot;\u60a8\u8f93\u5165\u7684\u662f&nbsp;\u6570\u5b57\u3002&quot;\r\n;;\r\n*)\r\necho&nbsp;&quot;\u60a8\u8f93\u5165\u7684\u662f&nbsp;\u7a7a\u683c\u3001\u529f\u80fd\u952e\u6216\u5176\u4ed6\u63a7\u5236\u5b57\u7b26\u3002&quot;\r\nesac\r\n[root@linuxprobe&nbsp;~]#&nbsp;bash&nbsp;Checkkeys.sh\r\n\u8bf7\u8f93\u5165\u4e00\u4e2a\u5b57\u7b26\uff0c\u5e76\u6309Enter\u952e\u786e\u8ba4\uff1a6\r\n\u60a8\u8f93\u5165\u7684\u662f&nbsp;\u6570\u5b57\u3002\r\n[root@linuxprobe&nbsp;~]#&nbsp;bash&nbsp;Checkkeys.sh\r\n\u8bf7\u8f93\u5165\u4e00\u4e2a\u5b57\u7b26\uff0c\u5e76\u6309Enter\u952e\u786e\u8ba4\uff1ap\r\n\u60a8\u8f93\u5165\u7684\u662f&nbsp;\u5b57\u6bcd\u3002\r\n[root@linuxprobe&nbsp;~]#&nbsp;bash&nbsp;Checkkeys.sh\r\n\u8bf7\u8f93\u5165\u4e00\u4e2a\u5b57\u7b26\uff0c\u5e76\u6309Enter\u952e\u786e\u8ba4\uff1a^[[15~\r\n\u60a8\u8f93\u5165\u7684\u662f&nbsp;\u7a7a\u683c\u3001\u529f\u80fd\u952e\u6216\u5176\u4ed6\u63a7\u5236\u5b57\u7b26\u3002<\/pre>\n<h5 style=\"box-sizing: border-box; font-family: &quot;Helvetica Neue&quot;, Helvetica, Arial, sans-serif; font-weight: 100; line-height: 1.1; margin-top: 10px; margin-bottom: 10px; font-size: 14px; color: rgb(61, 68, 80); white-space: normal; background-color: rgb(255, 255, 255);\"><span id=\"44\" style=\"box-sizing: border-box;\"><span style=\"box-sizing: border-box; color: #008000;\"><strong style=\"box-sizing: border-box;\">4.4&nbsp;\u8ba1\u5212\u4efb\u52a1\u670d\u52a1\u7a0b\u5e8f<\/strong><\/span><\/span><\/h5>\n<p style=\"box-sizing: border-box; margin-top: 0px; margin-bottom: 10px; line-height: 23px; text-indent: 1em; text-align: justify; color: rgb(61, 68, 80); font-family: &quot;Microsoft Yahei&quot;, Helvetica, Arial, sans-serif; font-size: 12px; white-space: normal; background-color: rgb(255, 255, 255);\">\u7ecf\u9a8c\u4e30\u5bcc\u7684\u7cfb\u7edf\u8fd0\u7ef4\u5de5\u7a0b\u5e08\u53ef\u4ee5\u4f7f\u5f97Linux\u5728\u65e0\u9700\u4eba\u4e3a\u4ecb\u5165\u7684\u60c5\u51b5\u4e0b\uff0c\u5728\u6307\u5b9a\u7684\u65f6\u95f4\u6bb5\u81ea\u52a8\u542f\u7528\u6216\u505c\u6b62\u67d0\u4e9b\u670d\u52a1\u6216\u547d\u4ee4\uff0c\u4ece\u800c\u5b9e\u73b0\u8fd0\u7ef4\u7684\u81ea\u52a8\u5316\u3002\u5c3d\u7ba1\u6211\u4eec\u73b0\u5728\u5df2\u7ecf\u6709\u4e86\u529f\u80fd\u5f6a\u608d\u7684\u811a\u672c\u7a0b\u5e8f\u6765\u6267\u884c\u4e00\u4e9b\u6279\u5904\u7406\u5de5\u4f5c\uff0c\u4f46\u662f\uff0c\u5982\u679c\u4ecd\u7136\u9700\u8981\u5728\u6bcf\u5929\u51cc\u6668\u4e24\u70b9\u6572\u51fb\u952e\u76d8\u56de\u8f66\u952e\u6765\u6267\u884c\u8fd9\u4e2a\u811a\u672c\u7a0b\u5e8f\uff0c\u8fd9\u7b80\u76f4\u592a\u75db\u82e6\u4e86\uff08\u5f53\u7136\uff0c\u4e5f\u53ef\u4ee5\u8bad\u7ec3\u60a8\u7684\u5c0f\u732b\u5728\u534a\u591c\u6309\u4e0b\u56de\u8f66\u952e\uff09\u3002\u63a5\u4e0b\u6765\uff0c\u5218\u9044\u8001\u5e08\u5c06\u5411\u5927\u5bb6\u8bb2\u89e3\u5982\u4f55\u8bbe\u7f6e\u670d\u52a1\u5668\u7684\u8ba1\u5212\u4efb\u52a1\u670d\u52a1\uff0c\u628a\u5468\u671f\u6027\u3001\u89c4\u5f8b\u6027\u7684\u5de5\u4f5c\u4ea4\u7ed9\u7cfb\u7edf\u81ea\u52a8\u5b8c\u6210\u3002<\/p>\n<p style=\"box-sizing: border-box; margin-top: 0px; margin-bottom: 10px; line-height: 23px; text-indent: 1em; text-align: justify; color: rgb(61, 68, 80); font-family: &quot;Microsoft Yahei&quot;, Helvetica, Arial, sans-serif; font-size: 12px; white-space: normal; background-color: rgb(255, 255, 255);\">\u8ba1\u5212\u4efb\u52a1\u5206\u4e3a\u4e00\u6b21\u6027\u8ba1\u5212\u4efb\u52a1\u4e0e\u957f\u671f\u6027\u8ba1\u5212\u4efb\u52a1\uff0c\u5927\u5bb6\u53ef\u4ee5\u6309\u7167\u5982\u4e0b\u65b9\u5f0f\u7406\u89e3\u3002<\/p>\n<blockquote style=\"box-sizing: border-box; padding: 10px 20px; margin: 0px 0px 20px; border-left-width: 5px; border-left-style: solid; border-color: rgba(0, 0, 0, 0.14902); color: rgb(61, 68, 80); font-family: &quot;Microsoft Yahei&quot;, Helvetica, Arial, sans-serif; font-size: 12px; line-height: 17.1429px; white-space: normal; background-color: rgb(255, 255, 255);\">\n<p style=\"box-sizing: border-box; margin-top: 0px; margin-bottom: 10px; font-size: 14px; line-height: 23px; text-indent: 1em; text-align: justify;\">\u4e00\u6b21\u6027\u8ba1\u5212\u4efb\u52a1\uff1a\u4eca\u665a11\u70b930\u5206\u5f00\u542f\u7f51\u7ad9\u670d\u52a1\u3002<\/p>\n<p style=\"box-sizing: border-box; margin-top: 0px; margin-bottom: 0px; font-size: 14px; line-height: 23px; text-indent: 1em; text-align: justify;\">\u957f\u671f\u6027\u8ba1\u5212\u4efb\u52a1\uff1a\u6bcf\u5468\u4e00\u7684\u51cc\u66683\u70b925\u5206\u628a\/home\/wwwroot\u76ee\u5f55\u6253\u5305\u5907\u4efd\u4e3abackup.tar.gz\u3002<\/p>\n<\/blockquote>\n<p style=\"box-sizing: border-box; margin-top: 0px; margin-bottom: 10px; line-height: 23px; text-indent: 1em; text-align: justify; color: rgb(61, 68, 80); font-family: &quot;Microsoft Yahei&quot;, Helvetica, Arial, sans-serif; font-size: 12px; white-space: normal; background-color: rgb(255, 255, 255);\">\u987e\u540d\u601d\u4e49\uff0c\u4e00\u6b21\u6027\u8ba1\u5212\u4efb\u52a1\u53ea\u6267\u884c\u4e00\u6b21\uff0c\u4e00\u822c\u7528\u4e8e\u6ee1\u8db3\u4e34\u65f6\u7684\u5de5\u4f5c\u9700\u6c42\u3002\u6211\u4eec\u53ef\u4ee5\u7528at\u547d\u4ee4\u5b9e\u73b0\u8fd9\u79cd\u529f\u80fd\uff0c\u53ea\u9700\u8981\u5199\u6210\u201cat \u65f6\u95f4\u201d\u7684\u5f62\u5f0f\u5c31\u53ef\u4ee5\u3002\u5982\u679c\u60f3\u8981\u67e5\u770b\u5df2\u8bbe\u7f6e\u597d\u4f46\u8fd8\u672a\u6267\u884c\u7684\u4e00\u6b21\u6027\u8ba1\u5212\u4efb\u52a1\uff0c\u53ef\u4ee5\u4f7f\u7528\u201cat -l\u201d\u547d\u4ee4\uff1b\u8981\u60f3\u5c06\u5176\u5220\u9664\uff0c\u53ef\u4ee5\u7528\u201catrm \u4efb\u52a1\u5e8f\u53f7\u201d\u3002\u5728\u4f7f\u7528at\u547d\u4ee4\u6765\u8bbe\u7f6e\u4e00\u6b21\u6027\u8ba1\u5212\u4efb\u52a1\u65f6\uff0c\u9ed8\u8ba4\u91c7\u7528\u7684\u662f\u4ea4\u4e92\u5f0f\u65b9\u6cd5\u3002\u4f8b\u5982\uff0c\u4f7f\u7528\u4e0b\u8ff0\u547d\u4ee4\u5c06\u7cfb\u7edf\u8bbe\u7f6e\u4e3a\u5728\u4eca\u665a23:30\u5206\u81ea\u52a8\u91cd\u542f\u7f51\u7ad9\u670d\u52a1\u3002<\/p>\n<pre style=\"box-sizing: border-box; font-family: Monaco, Menlo, Consolas, &quot;Courier New&quot;, monospace; font-size: 13px; white-space: pre-wrap; padding: 9.5px; margin-top: 0px; margin-bottom: 10px; line-height: 1.42857; color: rgb(51, 51, 51); word-break: break-all; word-wrap: break-word; border: 1px solid rgb(204, 204, 204); border-radius: 4px; background-color: rgb(245, 245, 245);\">[root@linuxprobe&nbsp;~]#&nbsp;at&nbsp;23:30\r\nat&nbsp;&gt;&nbsp;systemctl&nbsp;restart&nbsp;httpd\r\nat&nbsp;&gt;&nbsp;\u6b64\u5904\u8bf7\u540c\u65f6\u6309\u4e0bCtrl+d\u6765\u7ed3\u675f\u7f16\u5199\u8ba1\u5212\u4efb\u52a1\r\njob&nbsp;3&nbsp;at&nbsp;Mon&nbsp;Apr&nbsp;27&nbsp;23:30:00&nbsp;2015\r\n[root@linuxprobe&nbsp;~]#&nbsp;at&nbsp;-l\r\n3&nbsp;Mon&nbsp;Apr&nbsp;27&nbsp;23:30:00&nbsp;2016&nbsp;a&nbsp;root<\/pre>\n<p style=\"box-sizing: border-box; margin-top: 0px; margin-bottom: 10px; line-height: 23px; text-indent: 1em; text-align: justify; color: rgb(61, 68, 80); font-family: &quot;Microsoft Yahei&quot;, Helvetica, Arial, sans-serif; font-size: 12px; white-space: normal; background-color: rgb(255, 255, 255);\">\u5982\u679c\u8bfb\u8005\u60f3\u6311\u6218\u4e00\u4e0b\u96be\u5ea6\u66f4\u5927\u4f46\u7b80\u6377\u6027\u66f4\u9ad8\u7684\u65b9\u5f0f\uff0c\u53ef\u4ee5\u628a\u524d\u9762\u5b66\u4e60\u7684\u7ba1\u9053\u7b26\uff08\u4efb\u610f\u95e8\uff09\u653e\u5230\u4e24\u6761\u547d\u4ee4\u4e4b\u95f4\uff0c\u8ba9at\u547d\u4ee4\u63a5\u6536\u524d\u9762echo\u547d\u4ee4\u7684\u8f93\u51fa\u4fe1\u606f\uff0c\u4ee5\u8fbe\u5230\u901a\u8fc7\u975e\u4ea4\u4e92\u5f0f\u7684\u65b9\u5f0f\u521b\u5efa\u8ba1\u5212\u4e00\u6b21\u6027\u4efb\u52a1\u7684\u76ee\u7684\u3002<\/p>\n<pre style=\"box-sizing: border-box; font-family: Monaco, Menlo, Consolas, &quot;Courier New&quot;, monospace; font-size: 13px; white-space: pre-wrap; padding: 9.5px; margin-top: 0px; margin-bottom: 10px; line-height: 1.42857; color: rgb(51, 51, 51); word-break: break-all; word-wrap: break-word; border: 1px solid rgb(204, 204, 204); border-radius: 4px; background-color: rgb(245, 245, 245);\">[root@linuxprobe&nbsp;~]#&nbsp;echo&nbsp;&quot;systemctl&nbsp;restart&nbsp;httpd&quot;&nbsp;|&nbsp;at&nbsp;23:30\r\njob&nbsp;4&nbsp;at&nbsp;Mon&nbsp;Apr&nbsp;27&nbsp;23:30:00&nbsp;2015\r\n[root@linuxprobe&nbsp;~]#&nbsp;at&nbsp;-l\r\n3&nbsp;Mon&nbsp;Apr&nbsp;27&nbsp;23:30:00&nbsp;2016&nbsp;a&nbsp;root\r\n4&nbsp;Mon&nbsp;Apr&nbsp;27&nbsp;23:30:00&nbsp;2016&nbsp;a&nbsp;root<\/pre>\n<p style=\"box-sizing: border-box; margin-top: 0px; margin-bottom: 10px; line-height: 23px; text-indent: 1em; text-align: justify; color: rgb(61, 68, 80); font-family: &quot;Microsoft Yahei&quot;, Helvetica, Arial, sans-serif; font-size: 12px; white-space: normal; background-color: rgb(255, 255, 255);\">\u5982\u679c\u6211\u4eec\u4e0d\u5c0f\u5fc3\u8bbe\u7f6e\u4e86\u4e24\u4e2a\u4e00\u6b21\u6027\u8ba1\u5212\u4efb\u52a1\uff0c\u53ef\u4ee5\u4f7f\u7528\u4e0b\u9762\u7684\u547d\u4ee4\u8f7b\u677e\u5220\u9664\u5176\u4e2d\u4e00\u4e2a\uff1a<\/p>\n<pre style=\"box-sizing: border-box; font-family: Monaco, Menlo, Consolas, &quot;Courier New&quot;, monospace; font-size: 13px; white-space: pre-wrap; padding: 9.5px; margin-top: 0px; margin-bottom: 10px; line-height: 1.42857; color: rgb(51, 51, 51); word-break: break-all; word-wrap: break-word; border: 1px solid rgb(204, 204, 204); border-radius: 4px; background-color: rgb(245, 245, 245);\">[root@linuxprobe&nbsp;~]#&nbsp;atrm&nbsp;3\r\n[root@linuxprobe&nbsp;~]#&nbsp;at&nbsp;-l\r\n4&nbsp;Mon&nbsp;Apr&nbsp;27&nbsp;23:30:00&nbsp;2016&nbsp;a&nbsp;root<\/pre>\n<p style=\"box-sizing: border-box; margin-top: 0px; margin-bottom: 10px; line-height: 23px; text-indent: 1em; text-align: justify; color: rgb(61, 68, 80); font-family: &quot;Microsoft Yahei&quot;, Helvetica, Arial, sans-serif; font-size: 12px; white-space: normal; background-color: rgb(255, 255, 255);\">\u5982\u679c\u6211\u4eec\u5e0c\u671bLinux\u7cfb\u7edf\u80fd\u591f\u5468\u671f\u6027\u5730\u3001\u6709\u89c4\u5f8b\u5730\u6267\u884c\u67d0\u4e9b\u5177\u4f53\u7684\u4efb\u52a1\uff0c\u90a3\u4e48Linux\u7cfb\u7edf\u4e2d\u9ed8\u8ba4\u542f\u7528\u7684crond\u670d\u52a1\u7b80\u76f4\u518d\u9002\u5408\u4e0d\u8fc7\u4e86\u3002\u521b\u5efa\u3001\u7f16\u8f91\u8ba1\u5212\u4efb\u52a1\u7684\u547d\u4ee4\u4e3a\u201ccrontab -e\u201d\uff0c\u67e5\u770b\u5f53\u524d\u8ba1\u5212\u4efb\u52a1\u7684\u547d\u4ee4\u4e3a\u201ccrontab -l\u201d\uff0c\u5220\u9664\u67d0\u6761\u8ba1\u5212\u4efb\u52a1\u7684\u547d\u4ee4\u4e3a\u201ccrontab -r\u201d\u3002\u53e6\u5916\uff0c\u5982\u679c\u60a8\u662f\u4ee5\u7ba1\u7406\u5458\u7684\u8eab\u4efd\u767b\u5f55\u7684\u7cfb\u7edf\uff0c\u8fd8\u53ef\u4ee5\u5728crontab\u547d\u4ee4\u4e2d\u52a0\u4e0a-u\u53c2\u6570\u6765\u7f16\u8f91\u4ed6\u4eba\u7684\u8ba1\u5212\u4efb\u52a1\u3002<\/p>\n<p style=\"box-sizing: border-box; margin-top: 0px; margin-bottom: 10px; line-height: 23px; text-indent: 1em; text-align: justify; color: rgb(61, 68, 80); font-family: &quot;Microsoft Yahei&quot;, Helvetica, Arial, sans-serif; font-size: 12px; white-space: normal; background-color: rgb(255, 255, 255);\">\u5728\u6b63\u5f0f\u90e8\u7f72\u8ba1\u5212\u4efb\u52a1\u524d\uff0c\u8bf7\u5148\u8ddf\u5218\u9044\u8001\u5e08\u5ff5\u4e00\u4e0b\u53e3\u8bc0\u201c\u5206\u3001\u65f6\u3001\u65e5\u3001\u6708\u3001\u661f\u671f \u547d\u4ee4\u201d\u3002\u8fd9\u662f\u4f7f\u7528crond\u670d\u52a1\u8bbe\u7f6e\u4efb\u52a1\u7684\u53c2\u6570\u683c\u5f0f\uff08\u5176\u683c\u5f0f\u89c1\u88684-6\uff09\u3002\u9700\u8981\u6ce8\u610f\u7684\u662f\uff0c\u5982\u679c\u6709\u4e9b\u5b57\u6bb5\u6ca1\u6709\u8bbe\u7f6e\uff0c\u5219\u9700\u8981\u4f7f\u7528\u661f\u53f7\uff08<strong style=\"box-sizing: border-box;\">*<\/strong>\uff09\u5360\u4f4d\uff0c\u5982\u56fe4-23\u6240\u793a\u3002<div class='fancybox-wrapper lazyload-container-unload' data-fancybox='post-images' href='https:\/\/www.linuxprobe.com\/wp-content\/uploads\/2015\/02\/cron%E8%AE%A1%E5%88%92%E4%BB%BB%E5%8A%A1%E7%9A%84%E5%8F%82%E6%95%B0.png'><img class=\"lazyload lazyload-style-1\" src=\"data:image\/svg+xml;base64,PCEtLUFyZ29uTG9hZGluZy0tPgo8c3ZnIHdpZHRoPSIxIiBoZWlnaHQ9IjEiIHhtbG5zPSJodHRwOi8vd3d3LnczLm9yZy8yMDAwL3N2ZyIgc3Ryb2tlPSIjZmZmZmZmMDAiPjxnPjwvZz4KPC9zdmc+\"  loading=\"lazy\" decoding=\"async\" class=\"size-full wp-image-1003 aligncenter\" data-original=\"https:\/\/www.linuxprobe.com\/wp-content\/uploads\/2015\/02\/cron%E8%AE%A1%E5%88%92%E4%BB%BB%E5%8A%A1%E7%9A%84%E5%8F%82%E6%95%B0.png\" src=\"data:image\/png;base64,iVBORw0KGgoAAAANSUhEUgAAAAEAAAABCAYAAAAfFcSJAAAAAXNSR0IArs4c6QAAAARnQU1BAACxjwv8YQUAAAAJcEhZcwAADsQAAA7EAZUrDhsAAAANSURBVBhXYzh8+PB\/AAffA0nNPuCLAAAAAElFTkSuQmCC\" alt=\"\u7b2c4\u7ae0 Vim\u7f16\u8f91\u5668\u4e0eShell\u547d\u4ee4\u811a\u672c\u3002\u7b2c4\u7ae0 Vim\u7f16\u8f91\u5668\u4e0eShell\u547d\u4ee4\u811a\u672c\u3002\" width=\"962\" height=\"174\"  sizes=\"auto, (max-width: 962px) 100vw, 962px\" title=\"\u7b2c4\u7ae0 Vim\u7f16\u8f91\u5668\u4e0eShell\u547d\u4ee4\u811a\u672c\u3002\u7b2c4\u7ae0 Vim\u7f16\u8f91\u5668\u4e0eShell\u547d\u4ee4\u811a\u672c\u3002\" style=\"box-sizing: border-box; max-width: 100%; border-radius: 4px; vertical-align: middle; height: auto; margin: 10px auto; display: block;\"\/><\/div><\/p>\n<p style=\"box-sizing: border-box; margin-top: 0px; margin-bottom: 10px; line-height: 23px; text-indent: 1em; text-align: center; color: rgb(61, 68, 80); font-family: &quot;Microsoft Yahei&quot;, Helvetica, Arial, sans-serif; font-size: 12px; white-space: normal; background-color: rgb(255, 255, 255);\">\u56fe4-23&nbsp; \u4f7f\u7528crond\u8bbe\u7f6e\u4efb\u52a1\u7684\u53c2\u6570\u683c\u5f0f<\/p>\n<p style=\"box-sizing: border-box; margin-top: 0px; margin-bottom: 10px; line-height: 23px; text-indent: 1em; text-align: justify; color: rgb(61, 68, 80); font-family: &quot;Microsoft Yahei&quot;, Helvetica, Arial, sans-serif; font-size: 12px; white-space: normal; background-color: rgb(255, 255, 255);\">\u88684-6&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp; \u4f7f\u7528crond\u8bbe\u7f6e\u4efb\u52a1\u7684\u53c2\u6570\u5b57\u6bb5\u8bf4\u660e<\/p>\n<table id=\"tablepress-57\" class=\"tablepress tablepress-id-57\" width=\"712\">\n<tbody class=\"row-hover\" style=\"box-sizing: border-box;\">\n<tr class=\"row-1 odd firstRow\" style=\"box-sizing: border-box;\">\n<td class=\"column-1\" style=\"box-sizing: border-box; padding: 8px; border-top-width: 0px; border-right-style: none; border-bottom-style: none; border-left-style: none; border-color: initial; vertical-align: top; float: none !important; background: 0px 0px rgb(249, 249, 249);\">\u5b57\u6bb5<\/td>\n<td class=\"column-2\" style=\"box-sizing: border-box; padding: 8px; border-top-width: 0px; border-right-style: none; border-bottom-style: none; border-left-style: none; border-color: initial; vertical-align: top; float: none !important; background: 0px 0px rgb(249, 249, 249);\">\u8bf4\u660e<\/td>\n<\/tr>\n<tr class=\"row-2 even\" style=\"box-sizing: border-box;\">\n<td class=\"column-1\" style=\"box-sizing: border-box; padding: 8px; border-right-style: none; border-bottom-style: none; border-left-style: none; vertical-align: top; float: none !important; background-image: initial; background-attachment: initial; background-size: initial; background-origin: initial; background-clip: initial; background-position: 0px 0px; background-repeat: initial;\">\u5206\u949f<\/td>\n<td class=\"column-2\" style=\"box-sizing: border-box; padding: 8px; border-right-style: none; border-bottom-style: none; border-left-style: none; vertical-align: top; float: none !important; background-image: initial; background-attachment: initial; background-size: initial; background-origin: initial; background-clip: initial; background-position: 0px 0px; background-repeat: initial;\">\u53d6\u503c\u4e3a0\uff5e59\u7684\u6574\u6570<\/td>\n<\/tr>\n<tr class=\"row-3 odd\" style=\"box-sizing: border-box;\">\n<td class=\"column-1\" style=\"box-sizing: border-box; padding: 8px; border-right-style: none; border-bottom-style: none; border-left-style: none; vertical-align: top; float: none !important; background: 0px 0px rgb(249, 249, 249);\">\u5c0f\u65f6<\/td>\n<td class=\"column-2\" style=\"box-sizing: border-box; padding: 8px; border-right-style: none; border-bottom-style: none; border-left-style: none; vertical-align: top; float: none !important; background: 0px 0px rgb(249, 249, 249);\">\u53d6\u503c\u4e3a0\uff5e23\u7684\u4efb\u610f\u6574\u6570<\/td>\n<\/tr>\n<tr class=\"row-4 even\" style=\"box-sizing: border-box;\">\n<td class=\"column-1\" style=\"box-sizing: border-box; padding: 8px; border-right-style: none; border-bottom-style: none; border-left-style: none; vertical-align: top; float: none !important; background-image: initial; background-attachment: initial; background-size: initial; background-origin: initial; background-clip: initial; background-position: 0px 0px; background-repeat: initial;\">\u65e5\u671f<\/td>\n<td class=\"column-2\" style=\"box-sizing: border-box; padding: 8px; border-right-style: none; border-bottom-style: none; border-left-style: none; vertical-align: top; float: none !important; background-image: initial; background-attachment: initial; background-size: initial; background-origin: initial; background-clip: initial; background-position: 0px 0px; background-repeat: initial;\">\u53d6\u503c\u4e3a1\uff5e31\u7684\u4efb\u610f\u6574\u6570<\/td>\n<\/tr>\n<tr class=\"row-5 odd\" style=\"box-sizing: border-box;\">\n<td class=\"column-1\" style=\"box-sizing: border-box; padding: 8px; border-right-style: none; border-bottom-style: none; border-left-style: none; vertical-align: top; float: none !important; background: 0px 0px rgb(249, 249, 249);\">\u6708\u4efd<\/td>\n<td class=\"column-2\" style=\"box-sizing: border-box; padding: 8px; border-right-style: none; border-bottom-style: none; border-left-style: none; vertical-align: top; float: none !important; background: 0px 0px rgb(249, 249, 249);\">\u53d6\u503c\u4e3a1\uff5e12\u7684\u4efb\u610f\u6574\u6570<\/td>\n<\/tr>\n<tr class=\"row-6 even\" style=\"box-sizing: border-box;\">\n<td class=\"column-1\" style=\"box-sizing: border-box; padding: 8px; border-right-style: none; border-bottom-style: none; border-left-style: none; vertical-align: top; float: none !important; background-image: initial; background-attachment: initial; background-size: initial; background-origin: initial; background-clip: initial; background-position: 0px 0px; background-repeat: initial;\">\u661f\u671f<\/td>\n<td class=\"column-2\" style=\"box-sizing: border-box; padding: 8px; border-right-style: none; border-bottom-style: none; border-left-style: none; vertical-align: top; float: none !important; background-image: initial; background-attachment: initial; background-size: initial; background-origin: initial; background-clip: initial; background-position: 0px 0px; background-repeat: initial;\">\u53d6\u503c\u4e3a0\uff5e7\u7684\u4efb\u610f\u6574\u6570\uff0c\u5176\u4e2d0\u4e0e7\u5747\u4e3a\u661f\u671f\u65e5<\/td>\n<\/tr>\n<tr class=\"row-7 odd\" style=\"box-sizing: border-box;\">\n<td class=\"column-1\" style=\"box-sizing: border-box; padding: 8px; border-right-style: none; border-bottom-style: none; border-left-style: none; vertical-align: top; float: none !important; background: 0px 0px rgb(249, 249, 249);\">\u547d\u4ee4<\/td>\n<td class=\"column-2\" style=\"box-sizing: border-box; padding: 8px; border-right-style: none; border-bottom-style: none; border-left-style: none; vertical-align: top; float: none !important; background: 0px 0px rgb(249, 249, 249);\">\u8981\u6267\u884c\u7684\u547d\u4ee4\u6216\u7a0b\u5e8f\u811a\u672c<\/td>\n<\/tr>\n<\/tbody>\n<\/table>\n<p style=\"box-sizing: border-box; margin-top: 0px; margin-bottom: 10px; line-height: 23px; text-indent: 1em; text-align: justify; color: rgb(61, 68, 80); font-family: &quot;Microsoft Yahei&quot;, Helvetica, Arial, sans-serif; font-size: 12px; white-space: normal; background-color: rgb(255, 255, 255);\"><\/p>\n<p style=\"box-sizing: border-box; margin-top: 0px; margin-bottom: 10px; line-height: 23px; text-indent: 1em; text-align: justify; color: rgb(61, 68, 80); font-family: &quot;Microsoft Yahei&quot;, Helvetica, Arial, sans-serif; font-size: 12px; white-space: normal; background-color: rgb(255, 255, 255);\">\u5047\u8bbe\u5728\u6bcf\u5468\u4e00\u3001\u4e09\u3001\u4e94\u7684\u51cc\u66683\u70b925\u5206\uff0c\u90fd\u9700\u8981\u4f7f\u7528tar\u547d\u4ee4\u628a\u67d0\u4e2a\u7f51\u7ad9\u7684\u6570\u636e\u76ee\u5f55\u8fdb\u884c\u6253\u5305\u5904\u7406\uff0c\u4f7f\u5176\u4f5c\u4e3a\u4e00\u4e2a\u5907\u4efd\u6587\u4ef6\u3002\u6211\u4eec\u53ef\u4ee5\u4f7f\u7528crontab -e\u547d\u4ee4\u6765\u521b\u5efa\u8ba1\u5212\u4efb\u52a1\u3002\u4e3a\u81ea\u5df1\u521b\u5efa\u8ba1\u5212\u4efb\u52a1\u65e0\u9700\u4f7f\u7528-u\u53c2\u6570\uff0c\u5177\u4f53\u7684\u5b9e\u73b0\u6548\u679c\u7684\u53c2\u6570\u5982crontab -l\u547d\u4ee4\u7ed3\u679c\u6240\u793a\uff1a<\/p>\n<pre style=\"box-sizing: border-box; font-family: Monaco, Menlo, Consolas, &quot;Courier New&quot;, monospace; font-size: 13px; white-space: pre-wrap; padding: 9.5px; margin-top: 0px; margin-bottom: 10px; line-height: 1.42857; color: rgb(51, 51, 51); word-break: break-all; word-wrap: break-word; border: 1px solid rgb(204, 204, 204); border-radius: 4px; background-color: rgb(245, 245, 245);\">[root@linuxprobe&nbsp;~]#&nbsp;crontab&nbsp;-e\r\nno&nbsp;crontab&nbsp;for&nbsp;root&nbsp;-&nbsp;using&nbsp;an&nbsp;empty&nbsp;one\r\ncrontab:&nbsp;installing&nbsp;new&nbsp;crontab\r\n[root@linuxprobe&nbsp;~]#&nbsp;crontab&nbsp;-l25&nbsp;3&nbsp;*&nbsp;*&nbsp;1,3,5&nbsp;\/usr\/bin\/tar&nbsp;-czvf&nbsp;backup.tar.gz&nbsp;\/home\/wwwroot<\/pre>\n<p style=\"box-sizing: border-box; margin-top: 0px; margin-bottom: 10px; line-height: 23px; text-indent: 1em; text-align: justify; color: rgb(61, 68, 80); font-family: &quot;Microsoft Yahei&quot;, Helvetica, Arial, sans-serif; font-size: 12px; white-space: normal; background-color: rgb(255, 255, 255);\">\u9700\u8981\u8bf4\u660e\u7684\u662f\uff0c\u9664\u4e86\u7528\u9017\u53f7\uff08,\uff09\u6765\u5206\u522b\u8868\u793a\u591a\u4e2a\u65f6\u95f4\u6bb5\uff0c\u4f8b\u5982\u201c8,9,12\u201d\u8868\u793a8\u6708\u30019\u6708\u548c12\u6708\u3002\u8fd8\u53ef\u4ee5\u7528\u51cf\u53f7\uff08-\uff09\u6765\u8868\u793a\u4e00\u6bb5\u8fde\u7eed\u7684\u65f6\u95f4\u5468\u671f\uff08\u4f8b\u5982\u5b57\u6bb5\u201c\u65e5\u201d\u7684\u53d6\u503c\u4e3a\u201c12-15\u201d\uff0c\u5219\u8868\u793a\u6bcf\u6708\u768412\uff5e15\u65e5\uff09\u3002\u4ee5\u53ca\u7528\u9664\u53f7\uff08\/\uff09\u8868\u793a\u6267\u884c\u4efb\u52a1\u7684\u95f4\u9694\u65f6\u95f4\uff08\u4f8b\u5982\u201c*\/2\u201d\u8868\u793a\u6bcf\u96942\u5206\u949f\u6267\u884c\u4e00\u6b21\u4efb\u52a1\uff09\u3002<\/p>\n<p style=\"box-sizing: border-box; margin-top: 0px; margin-bottom: 10px; line-height: 23px; text-indent: 1em; text-align: justify; color: rgb(61, 68, 80); font-family: &quot;Microsoft Yahei&quot;, Helvetica, Arial, sans-serif; font-size: 12px; white-space: normal; background-color: rgb(255, 255, 255);\">\u5982\u679c\u5728crond\u670d\u52a1\u4e2d\u9700\u8981\u540c\u65f6\u5305\u542b\u591a\u6761\u8ba1\u5212\u4efb\u52a1\u7684\u547d\u4ee4\u8bed\u53e5\uff0c\u5e94\u6bcf\u884c\u4ec5\u5199\u4e00\u6761\u3002\u4f8b\u5982\u6211\u4eec\u518d\u6dfb\u52a0\u4e00\u6761\u8ba1\u5212\u4efb\u52a1\uff0c\u5b83\u7684\u529f\u80fd\u662f\u6bcf\u5468\u4e00\u81f3\u5468\u4e94\u7684\u51cc\u66681\u70b9\u949f\u81ea\u52a8\u6e05\u7a7a\/tmp\u76ee\u5f55\u5185\u7684\u6240\u6709\u6587\u4ef6\u3002\u5c24\u5176\u9700\u8981\u6ce8\u610f\u7684\u662f\uff0c\u5728crond\u670d\u52a1\u7684\u8ba1\u5212\u4efb\u52a1\u53c2\u6570\u4e2d\uff0c\u6240\u6709\u547d\u4ee4\u4e00\u5b9a\u8981\u7528\u7edd\u5bf9\u8def\u5f84\u7684\u65b9\u5f0f\u6765\u5199\uff0c\u5982\u679c\u4e0d\u77e5\u9053\u7edd\u5bf9\u8def\u5f84\uff0c\u8bf7\u7528whereis\u547d\u4ee4\u8fdb\u884c\u67e5\u8be2\uff0crm\u547d\u4ee4\u8def\u5f84\u4e3a\u4e0b\u9762\u8f93\u51fa\u4fe1\u606f\u4e2d\u52a0\u7c97\u90e8\u5206\u3002<\/p>\n<pre style=\"box-sizing: border-box; font-family: Monaco, Menlo, Consolas, &quot;Courier New&quot;, monospace; font-size: 13px; white-space: pre-wrap; padding: 9.5px; margin-top: 0px; margin-bottom: 10px; line-height: 1.42857; color: rgb(51, 51, 51); word-break: break-all; word-wrap: break-word; border: 1px solid rgb(204, 204, 204); border-radius: 4px; background-color: rgb(245, 245, 245);\">[root@linuxprobe&nbsp;~]#&nbsp;whereis&nbsp;rm\r\nrm:&nbsp;\/usr\/bin\/rm&nbsp;\/usr\/share\/man\/man1\/rm.1.gz&nbsp;\/usr\/share\/man\/man1p\/rm.1p.gz\r\n[root@linuxprobe&nbsp;~]#&nbsp;crontab&nbsp;-e\r\ncrontab:&nbsp;installing&nbsp;new&nbsp;crontab\r\n[root@linuxprobe&nbsp;~]#&nbsp;crontab&nbsp;-l\r\n25&nbsp;3&nbsp;*&nbsp;*&nbsp;1,3,5&nbsp;\/usr\/bin\/tar&nbsp;-czvf&nbsp;backup.tar.gz&nbsp;\/home\/wwwroot0&nbsp;1&nbsp;*&nbsp;*&nbsp;1-5&nbsp;\/usr\/bin\/rm&nbsp;-rf&nbsp;\/tmp\/*<\/pre>\n<p style=\"box-sizing: border-box; margin-top: 0px; margin-bottom: 10px; line-height: 23px; text-indent: 1em; text-align: justify; color: rgb(61, 68, 80); font-family: &quot;Microsoft Yahei&quot;, Helvetica, Arial, sans-serif; font-size: 12px; white-space: normal; background-color: rgb(255, 255, 255);\">\u5728\u672c\u8282\u6700\u540e\uff0c\u5218\u9044\u8001\u5e08\u518d\u6765\u5570\u55e6\u51e0\u53e5\u5728\u5de5\u4f5c\u4e2d\u4f7f\u7528\u8ba1\u5212\u670d\u52a1\u7684\u6ce8\u610f\u4e8b\u9879\u3002<\/p>\n<blockquote style=\"box-sizing: border-box; padding: 10px 20px; margin: 0px 0px 20px; border-left-width: 5px; border-left-style: solid; border-color: rgba(0, 0, 0, 0.14902); color: rgb(61, 68, 80); font-family: &quot;Microsoft Yahei&quot;, Helvetica, Arial, sans-serif; font-size: 12px; line-height: 17.1429px; white-space: normal; background-color: rgb(255, 255, 255);\">\n<p style=\"box-sizing: border-box; margin-top: 0px; margin-bottom: 10px; font-size: 14px; line-height: 23px; text-indent: 1em; text-align: justify;\">\u5728crond\u670d\u52a1\u7684\u914d\u7f6e\u53c2\u6570\u4e2d\uff0c\u53ef\u4ee5\u50cfShell\u811a\u672c\u90a3\u6837\u4ee5#\u53f7\u5f00\u5934\u5199\u4e0a\u6ce8\u91ca\u4fe1\u606f\uff0c\u8fd9\u6837\u5728\u65e5\u540e\u56de\u987e\u8fd9\u6bb5\u547d\u4ee4\u4ee3\u7801\u65f6\u53ef\u4ee5\u5feb\u901f\u4e86\u89e3\u5176\u529f\u80fd\u3001\u9700\u6c42\u4ee5\u53ca\u7f16\u5199\u4eba\u5458\u7b49\u91cd\u8981\u4fe1\u606f\u3002<\/p>\n<p style=\"box-sizing: border-box; margin-top: 0px; margin-bottom: 0px; font-size: 14px; line-height: 23px; text-indent: 1em; text-align: justify;\">\u8ba1\u5212\u4efb\u52a1\u4e2d\u7684\u201c\u5206\u201d\u5b57\u6bb5\u5fc5\u987b\u6709\u6570\u503c\uff0c\u7edd\u5bf9\u4e0d\u80fd\u4e3a\u7a7a\u6216\u662f*\u53f7\uff0c\u800c\u201c\u65e5\u201d\u548c\u201c\u661f\u671f\u201d\u5b57\u6bb5\u4e0d\u80fd\u540c\u65f6\u4f7f\u7528\uff0c\u5426\u5219\u5c31\u4f1a\u53d1\u751f\u51b2\u7a81\u3002<\/p>\n<\/blockquote>\n<p style=\"box-sizing: border-box; margin-top: 0px; margin-bottom: 10px; line-height: 23px; text-indent: 1em; text-align: justify; color: rgb(61, 68, 80); font-family: &quot;Microsoft Yahei&quot;, Helvetica, Arial, sans-serif; font-size: 12px; white-space: normal; background-color: rgb(255, 255, 255);\">\u6700\u540e\u518d\u5570\u55e6\u4e00\u53e5\uff0c\u60f3\u5fc5\u8bfb\u8005\u4e5f\u5df2\u7ecf\u53d1\u73b0\u4e86\uff0c\u8bf8\u5982crond\u5728\u5185\u7684\u5f88\u591a\u670d\u52a1\u9ed8\u8ba4\u8c03\u7528\u7684\u662fVim\u7f16\u8f91\u5668\uff0c\u76f8\u4fe1\u5927\u5bb6\u73b0\u5728\u80fd\u8fdb\u4e00\u6b65\u4f53\u4f1a\u5230\u5728Linux\u7cfb\u7edf\u4e2d\u638c\u63e1Vim\u6587\u672c\u7f16\u8f91\u5668\u7684\u597d\u5904\u4e86\u5427\u3002\u6240\u4ee5\u8bf7\u5927\u5bb6\u4e00\u5b9a\u8981\u5728\u5f7b\u5e95\u638c\u63e1Vim\u7f16\u7801\u5668\u4e4b\u540e\u518d\u5b66\u4e60\u4e0b\u4e00\u7ae0\u3002<\/p>\n<p style=\"box-sizing: border-box; margin-top: 0px; margin-bottom: 10px; line-height: 23px; text-indent: 1em; text-align: justify; color: rgb(61, 68, 80); font-family: &quot;Microsoft Yahei&quot;, Helvetica, Arial, sans-serif; font-size: 12px; white-space: normal; background-color: rgb(255, 255, 255);\"><span style=\"box-sizing: border-box; color: #800080;\"><strong style=\"box-sizing: border-box;\">\u51fa\u73b0\u95ee\u9898?\u5927\u80c6\u63d0\u95ee!<\/strong><\/span><\/p>\n<p style=\"box-sizing: border-box; margin-top: 0px; margin-bottom: 10px; line-height: 23px; text-indent: 1em; text-align: center; color: rgb(61, 68, 80); font-family: &quot;Microsoft Yahei&quot;, Helvetica, Arial, sans-serif; font-size: 12px; white-space: normal; background-color: rgb(255, 255, 255);\"><span style=\"box-sizing: border-box; color: #800080;\"><strong style=\"box-sizing: border-box;\"><span style=\"box-sizing: border-box; color: #008000;\">\u672c\u7ae0\u8282\u7684\u590d\u4e60\u4f5c\u4e1a<\/span><\/strong><\/span><\/p>\n<p style=\"box-sizing: border-box; margin-top: 0px; margin-bottom: 10px; line-height: 23px; text-indent: 1em; text-align: justify; color: rgb(61, 68, 80); font-family: &quot;Microsoft Yahei&quot;, Helvetica, Arial, sans-serif; font-size: 12px; white-space: normal; background-color: rgb(255, 255, 255);\">&nbsp;<\/p>\n<p style=\"box-sizing: border-box; margin-top: 0px; margin-bottom: 10px; line-height: 23px; text-indent: 1em; text-align: justify; color: rgb(61, 68, 80); font-family: &quot;Microsoft Yahei&quot;, Helvetica, Arial, sans-serif; font-size: 12px; white-space: normal; background-color: rgb(255, 255, 255);\">1\uff0eVim\u7f16\u8f91\u5668\u7684\u4e09\u79cd\u6a21\u5f0f\u5206\u522b\u662f\u4ec0\u4e48\uff1f<\/p>\n<p style=\"box-sizing: border-box; margin-top: 0px; margin-bottom: 10px; line-height: 23px; text-indent: 1em; text-align: justify; color: rgb(61, 68, 80); font-family: &quot;Microsoft Yahei&quot;, Helvetica, Arial, sans-serif; font-size: 12px; white-space: normal; background-color: rgb(255, 255, 255);\"><strong style=\"box-sizing: border-box;\">\u7b54\uff1a<\/strong><span style=\"box-sizing: border-box; color: #FF0000;\">\u547d\u4ee4\u6a21\u5f0f\u3001\u672b\u884c\u6a21\u5f0f\u4e0e\u8f93\u5165\u6a21\u5f0f\uff08\u4e5f\u53eb\u7f16\u8f91\u6a21\u5f0f\u6216\u63d2\u5165\u6a21\u5f0f\uff09\u3002<\/span><\/p>\n<p style=\"box-sizing: border-box; margin-top: 0px; margin-bottom: 10px; line-height: 23px; text-indent: 1em; text-align: justify; color: rgb(61, 68, 80); font-family: &quot;Microsoft Yahei&quot;, Helvetica, Arial, sans-serif; font-size: 12px; white-space: normal; background-color: rgb(255, 255, 255);\">2\uff0e\u600e\u4e48\u4ece\u8f93\u5165\u6a21\u5f0f\u5207\u6362\u5230\u672b\u884c\u6a21\u5f0f\uff1f<\/p>\n<p style=\"box-sizing: border-box; margin-top: 0px; margin-bottom: 10px; line-height: 23px; text-indent: 1em; text-align: justify; color: rgb(61, 68, 80); font-family: &quot;Microsoft Yahei&quot;, Helvetica, Arial, sans-serif; font-size: 12px; white-space: normal; background-color: rgb(255, 255, 255);\"><strong style=\"box-sizing: border-box;\">\u7b54\uff1a<\/strong><span style=\"box-sizing: border-box; color: #FF0000;\">\u9700\u8981\u5148\u6572\u51fbEsc\u952e\u9000\u56de\u5230\u547d\u4ee4\u6a21\u5f0f\uff0c\u7136\u540e\u6572\u51fb\u5192\u53f7\uff08:\uff09\u952e\u540e\u8fdb\u5165\u672b\u884c\u6a21\u5f0f\u3002<\/span><\/p>\n<p style=\"box-sizing: border-box; margin-top: 0px; margin-bottom: 10px; line-height: 23px; text-indent: 1em; text-align: justify; color: rgb(61, 68, 80); font-family: &quot;Microsoft Yahei&quot;, Helvetica, Arial, sans-serif; font-size: 12px; white-space: normal; background-color: rgb(255, 255, 255);\">3\uff0e\u4e00\u4e2a\u5b8c\u6574\u7684Shell\u811a\u672c\u5e94\u8be5\u54ea\u4e9b\u5185\u5bb9\uff1f<\/p>\n<p style=\"box-sizing: border-box; margin-top: 0px; margin-bottom: 10px; line-height: 23px; text-indent: 1em; text-align: justify; color: rgb(61, 68, 80); font-family: &quot;Microsoft Yahei&quot;, Helvetica, Arial, sans-serif; font-size: 12px; white-space: normal; background-color: rgb(255, 255, 255);\"><strong style=\"box-sizing: border-box;\">\u7b54\uff1a<\/strong><span style=\"box-sizing: border-box; color: #FF0000;\">\u5e94\u8be5\u5305\u62ec\u811a\u672c\u58f0\u660e\u3001\u6ce8\u91ca\u4fe1\u606f\u548c\u53ef\u6267\u884c\u8bed\u53e5\uff08\u5373\u547d\u4ee4\uff09\u3002<\/span><\/p>\n<p style=\"box-sizing: border-box; margin-top: 0px; margin-bottom: 10px; line-height: 23px; text-indent: 1em; text-align: justify; color: rgb(61, 68, 80); font-family: &quot;Microsoft Yahei&quot;, Helvetica, Arial, sans-serif; font-size: 12px; white-space: normal; background-color: rgb(255, 255, 255);\">4\uff0e\u5206\u522b\u89e3\u91caShell\u811a\u672c\u4e2d$0\u4e0e$3\u53d8\u91cf\u7684\u4f5c\u7528\u3002<\/p>\n<p style=\"box-sizing: border-box; margin-top: 0px; margin-bottom: 10px; line-height: 23px; text-indent: 1em; text-align: justify; color: rgb(61, 68, 80); font-family: &quot;Microsoft Yahei&quot;, Helvetica, Arial, sans-serif; font-size: 12px; white-space: normal; background-color: rgb(255, 255, 255);\"><strong style=\"box-sizing: border-box;\">\u7b54\uff1a<\/strong><span style=\"box-sizing: border-box; color: #FF0000;\">\u5728Shell\u811a\u672c\u4e2d\uff0c$0\u4ee3\u8868\u811a\u672c\u6587\u4ef6\u7684\u540d\u79f0\uff0c$3\u5219\u4ee3\u8868\u8be5\u811a\u672c\u5728\u6267\u884c\u65f6\u63a5\u6536\u7684\u7b2c\u4e09\u4e2a\u53c2\u6570\u3002<\/span><\/p>\n<p style=\"box-sizing: border-box; margin-top: 0px; margin-bottom: 10px; line-height: 23px; text-indent: 1em; text-align: justify; color: rgb(61, 68, 80); font-family: &quot;Microsoft Yahei&quot;, Helvetica, Arial, sans-serif; font-size: 12px; white-space: normal; background-color: rgb(255, 255, 255);\">5\uff0eif\u6761\u4ef6\u6d4b\u8bd5\u8bed\u53e5\u6709\u51e0\u79cd\u7ed3\u6784\uff0c\u6700\u7075\u6d3b\u4e14\u6700\u590d\u6742\u7684\u662f\u54ea\u79cd\u7ed3\u6784\uff1f<\/p>\n<p style=\"box-sizing: border-box; margin-top: 0px; margin-bottom: 10px; line-height: 23px; text-indent: 1em; text-align: justify; color: rgb(61, 68, 80); font-family: &quot;Microsoft Yahei&quot;, Helvetica, Arial, sans-serif; font-size: 12px; white-space: normal; background-color: rgb(255, 255, 255);\"><strong style=\"box-sizing: border-box;\">\u7b54\uff1a<\/strong><span style=\"box-sizing: border-box; color: #FF0000;\">if\u6761\u4ef6\u6d4b\u8bd5\u8bed\u53e5\u5305\u62ec\u5355\u5206\u652f\u3001\u53cc\u5206\u652f\u4e0e\u591a\u5206\u652f\u7b49\u4e09\u79cd\u7ed3\u6784\uff0c\u5176\u4e2d\u591a\u5206\u652f\u7ed3\u6784\u662f\u6700\u7075\u6d3b\u4e14\u6700\u590d\u6742\u7684\u7ed3\u6784\uff0c\u5176\u7ed3\u6784\u5f62\u5f0f\u4e3aif\u2026then\u2026elif\u2026then\u2026else\u2026fi\u3002<\/span><\/p>\n<p style=\"box-sizing: border-box; margin-top: 0px; margin-bottom: 10px; line-height: 23px; text-indent: 1em; text-align: justify; color: rgb(61, 68, 80); font-family: &quot;Microsoft Yahei&quot;, Helvetica, Arial, sans-serif; font-size: 12px; white-space: normal; background-color: rgb(255, 255, 255);\">6\uff0efor\u6761\u4ef6\u5faa\u73af\u8bed\u53e5\u7684\u5faa\u73af\u7ed3\u6784\u662f\u4ec0\u4e48\u6837\u5b50\u7684\uff1f<\/p>\n<p style=\"box-sizing: border-box; margin-top: 0px; margin-bottom: 10px; line-height: 23px; text-indent: 1em; text-align: justify; color: rgb(61, 68, 80); font-family: &quot;Microsoft Yahei&quot;, Helvetica, Arial, sans-serif; font-size: 12px; white-space: normal; background-color: rgb(255, 255, 255);\"><strong style=\"box-sizing: border-box;\">\u7b54\uff1a<\/strong><span style=\"box-sizing: border-box; color: #FF0000;\">for\u6761\u4ef6\u5faa\u73af\u8bed\u53e5\u7684\u7ed3\u6784\u4e3a\u201cfor \u53d8\u91cf\u540d in \u53d6\u503c\u5217\u8868 do \u547d\u4ee4\u5e8f\u5217 done\u201d\uff0c\u5982\u56fe4-20\u6240\u793a\u3002<\/span><\/p>\n<p style=\"box-sizing: border-box; margin-top: 0px; margin-bottom: 10px; line-height: 23px; text-indent: 1em; text-align: justify; color: rgb(61, 68, 80); font-family: &quot;Microsoft Yahei&quot;, Helvetica, Arial, sans-serif; font-size: 12px; white-space: normal; background-color: rgb(255, 255, 255);\">7\uff0e\u82e5\u5728while\u6761\u4ef6\u5faa\u73af\u8bed\u53e5\u4e2d\u4f7f\u7528true\u4f5c\u4e3a\u5faa\u73af\u6761\u4ef6\uff0c\u90a3\u4e48\u4f1a\u53d1\u751f\u4ec0\u4e48\u4e8b\u60c5\uff1f<\/p>\n<p style=\"box-sizing: border-box; margin-top: 0px; margin-bottom: 10px; line-height: 23px; text-indent: 1em; text-align: justify; color: rgb(61, 68, 80); font-family: &quot;Microsoft Yahei&quot;, Helvetica, Arial, sans-serif; font-size: 12px; white-space: normal; background-color: rgb(255, 255, 255);\"><strong style=\"box-sizing: border-box;\">\u7b54\uff1a<\/strong><span style=\"box-sizing: border-box; color: #FF0000;\">\u56e0\u6761\u4ef6\u6d4b\u8bd5\u503c\u6c38\u4e45\u4e3atrue\uff0c\u56e0\u6b64\u811a\u672c\u4e2d\u5faa\u73af\u90e8\u5206\u4f1a\u65e0\u9650\u5730\u91cd\u590d\u6267\u884c\u4e0b\u53bb\uff0c\u76f4\u5230\u78b0\u5230exit\u547d\u4ee4\u624d\u4f1a\u7ed3\u675f\u3002<\/span><\/p>\n<p style=\"box-sizing: border-box; margin-top: 0px; margin-bottom: 10px; line-height: 23px; text-indent: 1em; text-align: justify; color: rgb(61, 68, 80); font-family: &quot;Microsoft Yahei&quot;, Helvetica, Arial, sans-serif; font-size: 12px; white-space: normal; background-color: rgb(255, 255, 255);\">8\uff0e\u5982\u679c\u9700\u8981\u4f9d\u636e\u7528\u6237\u7684\u8f93\u5165\u53c2\u6570\u6267\u884c\u4e0d\u540c\u7684\u64cd\u4f5c\uff0c\u6700\u65b9\u4fbf\u7684\u6761\u4ef6\u6d4b\u8bd5\u8bed\u53e5\u662f\u4ec0\u4e48\uff1f<\/p>\n<p style=\"box-sizing: border-box; margin-top: 0px; margin-bottom: 10px; line-height: 23px; text-indent: 1em; text-align: justify; color: rgb(61, 68, 80); font-family: &quot;Microsoft Yahei&quot;, Helvetica, Arial, sans-serif; font-size: 12px; white-space: normal; background-color: rgb(255, 255, 255);\"><strong style=\"box-sizing: border-box;\">\u7b54\uff1a<\/strong><span style=\"box-sizing: border-box; color: #FF0000;\">case\u6761\u4ef6\u8bed\u53e5\u3002<\/span><\/p>\n<p style=\"box-sizing: border-box; margin-top: 0px; margin-bottom: 10px; line-height: 23px; text-indent: 1em; text-align: justify; color: rgb(61, 68, 80); font-family: &quot;Microsoft Yahei&quot;, Helvetica, Arial, sans-serif; font-size: 12px; white-space: normal; background-color: rgb(255, 255, 255);\">9\uff0eLinux\u7cfb\u7edf\u7684\u957f\u671f\u8ba1\u5212\u4efb\u52a1\u6240\u4f7f\u7528\u7684\u670d\u52a1\u662f\u4ec0\u4e48\uff0c\u5176\u53c2\u6570\u683c\u5f0f\u662f\u4ec0\u4e48\uff1f<\/p>\n<p style=\"box-sizing: border-box; margin-top: 0px; margin-bottom: 10px; line-height: 23px; text-indent: 1em; text-align: justify; color: rgb(61, 68, 80); font-family: &quot;Microsoft Yahei&quot;, Helvetica, Arial, sans-serif; font-size: 12px; white-space: normal; background-color: rgb(255, 255, 255);\"><strong style=\"box-sizing: border-box;\">\u7b54\uff1a<\/strong><span style=\"box-sizing: border-box; color: #FF0000;\">\u957f\u671f\u8ba1\u5212\u4efb\u52a1\u9700\u8981\u4f7f\u7528crond\u670d\u52a1\u7a0b\u5e8f\uff0c\u53c2\u6570\u683c\u5f0f\u662f\u201c\u5206\u3001\u65f6\u3001\u65e5\u3001\u6708\u3001\u661f\u671f \u547d\u4ee4\u201d\u3002<\/span><\/p>\n<p style=\"box-sizing: border-box; margin-top: 0px; margin-bottom: 10px; line-height: 23px; text-indent: 1em; font-family: &quot;Microsoft Yahei&quot;, Helvetica, Arial, sans-serif; font-size: 12px; white-space: normal; color: rgb(136, 166, 164); background-color: rgb(255, 255, 255);\">\u672c\u6587\u539f\u521b\u5730\u5740\uff1a<a href=\"https:\/\/www.linuxprobe.com\/chapter-04.html\" target=\"_blank\" style=\"box-sizing: border-box; color: rgb(210, 50, 45); text-decoration: none;\" rel=\"noopener noreferrer\">https:\/\/www.linuxprobe.com\/chapter-04.html<\/a><\/p>\n<p><\/p>\n<p><\/p>\n","protected":false},"excerpt":{"rendered":"<p>\u63a8\u8350\u7b80\u8ff0\uff1a \u8bf4\u5230Linux\u7cfb\u7edf\u4ece01\u5e74\u5f00\u59cb\u6211\u5c31\u4e00\u76f4\u5728\u63a5\u89e6\uff0c\u76f4\u523003\u5e74\u8fd8\u662f04\u5e74\u7684\u65f6\u5019\u5728\u60e0\u5dde\u65b0\u534e\u4e66\u5e97\u4e70\u4e86\u4e00\u672c\u300a\u9e1f [&hellip;]<\/p>\n","protected":false},"author":1,"featured_media":0,"comment_status":"open","ping_status":"open","sticky":false,"template":"","format":"standard","meta":{"footnotes":""},"categories":[1],"tags":[35,504,503,442],"class_list":["post-40","post","type-post","status-publish","format-standard","hentry","category-1","tag-linux","tag-shell","tag-vim","tag-442"],"_links":{"self":[{"href":"https:\/\/www.fatesky.com\/index.php?rest_route=\/wp\/v2\/posts\/40","targetHints":{"allow":["GET"]}}],"collection":[{"href":"https:\/\/www.fatesky.com\/index.php?rest_route=\/wp\/v2\/posts"}],"about":[{"href":"https:\/\/www.fatesky.com\/index.php?rest_route=\/wp\/v2\/types\/post"}],"author":[{"embeddable":true,"href":"https:\/\/www.fatesky.com\/index.php?rest_route=\/wp\/v2\/users\/1"}],"replies":[{"embeddable":true,"href":"https:\/\/www.fatesky.com\/index.php?rest_route=%2Fwp%2Fv2%2Fcomments&post=40"}],"version-history":[{"count":1,"href":"https:\/\/www.fatesky.com\/index.php?rest_route=\/wp\/v2\/posts\/40\/revisions"}],"predecessor-version":[{"id":3444,"href":"https:\/\/www.fatesky.com\/index.php?rest_route=\/wp\/v2\/posts\/40\/revisions\/3444"}],"wp:attachment":[{"href":"https:\/\/www.fatesky.com\/index.php?rest_route=%2Fwp%2Fv2%2Fmedia&parent=40"}],"wp:term":[{"taxonomy":"category","embeddable":true,"href":"https:\/\/www.fatesky.com\/index.php?rest_route=%2Fwp%2Fv2%2Fcategories&post=40"},{"taxonomy":"post_tag","embeddable":true,"href":"https:\/\/www.fatesky.com\/index.php?rest_route=%2Fwp%2Fv2%2Ftags&post=40"}],"curies":[{"name":"wp","href":"https:\/\/api.w.org\/{rel}","templated":true}]}}