{"id":1849,"date":"2021-11-11T11:56:20","date_gmt":"2021-11-11T03:56:20","guid":{"rendered":"http:\/\/cn.hostease.com\/blog\/?p=1849"},"modified":"2021-11-12T11:25:20","modified_gmt":"2021-11-12T03:25:20","slug":"%e5%a6%82%e4%bd%95%e5%9c%a8%e5%9f%ba%e4%ba%8e-redhat-%e7%9a%84%e7%b3%bb%e7%bb%9f%e4%b8%8a%e5%bf%ab%e9%80%9f%e7%bb%91%e5%ae%9a-ip","status":"publish","type":"post","link":"https:\/\/cn.hostease.com\/blog\/news\/%e5%a6%82%e4%bd%95%e5%9c%a8%e5%9f%ba%e4%ba%8e-redhat-%e7%9a%84%e7%b3%bb%e7%bb%9f%e4%b8%8a%e5%bf%ab%e9%80%9f%e7%bb%91%e5%ae%9a-ip\/","title":{"rendered":"\u5982\u4f55\u5728\u57fa\u4e8e RedHat \u7684\u7cfb\u7edf\u4e0a\u5feb\u901f\u7ed1\u5b9a IP"},"content":{"rendered":"<p>\u5728\u8fd9\u7bc7\u77ed\u6587\u4e2d\uff0c\u6211\u5c06\u5411\u60a8\u5c55\u793a\u5982\u4f55\u5728\u4efb\u4f55\u57fa\u4e8eRedHat\u7684\u7cfb\u7edf(Rhel\u3001Centos\u3001Fedora\u7b49)\u4e0a\u5feb\u901f\u6dfb\u52a0\u4e00\u6bb5IP\u3002\u5f53\u60a8\u9700\u8981\u5411\u7cfb\u7edf\u6dfb\u52a0\u8bb8\u591a IP \u65f6\uff0c\u8fd9\u4f1a\u975e\u5e38\u65b9\u4fbf\u5e76\u8282\u7701\u5927\u91cf\u65f6\u95f4\u3002\u901a\u5e38\uff0c\u5f53\u60a8\u5411\u57fa\u4e8e RedHat \u7684\u7cfb\u7edf\u4e2d\u7684\u7f51\u7edc\u63a5\u53e3\u6dfb\u52a0\u65b0 IP \u65f6\uff0c\u60a8\u4f1a\u5728\/etc\/sysconfig\/network-scripts\/ \u4e2d\u521b\u5efa\u4e00\u4e2a\u6587\u4ef6ifcfg-eth0:x\u3002\u63a8\u8350\u9605\u8bfb\uff1a<a href=\"https:\/\/cn.hostease.com\/blog\/server\/694.html\" target=\"_blank\" rel=\"noopener\">\u300a \u4e92\u8054\u7f51\u4e2d\u7684IP\u5230\u5e95\u6709\u591a\u91cd\u8981 \u300b<\/a>\u4f8b\u5982\uff1a<\/p>\n<p>\/etc\/sysconfig\/network-scripts\/ifcfg-eth0:0<\/p>\n<p>DEVICE=eth0:0<\/p>\n<p>ONBOOT=yes<\/p>\n<p>BOOTPROTO=static<\/p>\n<p>IPADDR=192.168.0.100<\/p>\n<p>NETMASK=255.255.255.0<\/p>\n<p>NETWORK=192.168.0.0<\/p>\n<p>BROADCAST=192.168.0.255<\/p>\n<p>TYPE=Ethernet<\/p>\n<p>\u4e0e\u4e0a\u9762\u7684\u793a\u4f8b\u7c7b\u4f3c\uff0c\u60a8\u53ef\u4ee5\u521b\u5efa\u591a\u4e2a\u522b\u540d\u3002\u4f46\u662f\uff0c\u5982\u679c\u60a8\u9700\u8981\u6dfb\u52a0\u5f88\u591a\u540c\u4e00\u4e2a\u6bb5\u7684IP\u5462?\u5047\u8bbe\u6211\u60f3\u4ee5\u8fd9\u79cd\u65b9\u5f0f\u6dfb\u52a0 100 \u4e2a IP\u2026\u2026 \u53ef\u4ee5\u8fd9\u6837\u64cd\u4f5c\uff0c\u4f46\u4e0d\u662f\u5f88\u6709\u6548\uff0c\u5bf9\u5427?\u57fa\u4e8e RedHat \u7684\u7cfb\u7edf\u63d0\u4f9b\u4e86\u4e00\u79cd\u4ee5\u5feb\u901f\u65b9\u5f0f\u7ed1\u5b9a\u4e00\u7cfb\u5217 IP \u7684\u65b9\u6cd5\uff0c\u4f7f\u6211\u4eec\u65e0\u9700\u521b\u5efa\u5927\u91cf\u6587\u4ef6\u5e76\u8282\u7701\u6211\u4eec\u7684\u65f6\u95f4\u3002\u63a8\u8350\u9605\u8bfb\uff1a<a href=\"https:\/\/cn.hostease.com\/blog\/shared-hosting\/1766.html\" target=\"_blank\" rel=\"noopener\">\u300a \u72ec\u7acbIP\u4e0e\u5171\u4eabIP\u865a\u62df\u4e3b\u673a\u54ea\u4e2a\u597d? \u300b<\/a>\u521b\u5efa\u4e00\u4e2a\u6587\u4ef6\/etc\/sysconfig\/network-scripts\/ifcfg-eth0-range0\uff0c\u6216\u8005\u5982\u679c\u4f60\u5df2\u7ecf\u521b\u5efa\u4e86\uff0c\u5c31\u7f16\u8f91\u6dfb\u52a0<\/p>\n<p>\/etc\/sysconfig\/network-scripts\/ifcfg-eth0-range0<\/p>\n<p>IPADDR_START=192.168.0.100<\/p>\n<p>IPADDR_END=192.168.0.200<\/p>\n<p>CLONENUM_START=0<\/p>\n<p>\u5176\u4e2d\uff1aIPADDR_START\u662f\u7b2c\u4e00\u4e2a IP\uff0cIPADDR_END\u662f\u8be5\u8303\u56f4\u5185\u7684\u6700\u540e\u4e00\u4e2a IP\u3002CLONENUM_START\u662f\u5c06\u5206\u914d\u7ed9\u7b2c\u4e00\u4e2a IP \u522b\u540d\u63a5\u53e3\u7684\u7f16\u53f7(\u5728\u672c\u4f8b\u4e2d\u4e3a eth0:0)\u3002<\/p>\n<p>\u5982\u679c\u60a8\u9700\u8981\u6dfb\u52a0\u66f4\u591a IP \u8303\u56f4\uff0c\u90a3\u4e48\u53ea\u9700\u4f7f\u7528\u4e0d\u540c\u7684\u6587\u4ef6\u5373\u53ef\u3002ifcfg-eth0-range1\uff0c\u5bf9\u4e8e\u6bcf\u4e2a\u8303\u56f4\u3002\u60a8\u9700\u8981\u5c0f\u5fc3\u5e76\u4f7f\u7528\u6b63\u786e\u7684CLONENUM_START\u4ee5\u514d\u8986\u76d6\u5176\u4ed6\u522b\u540d\u3002\u914d\u7f6e IP \u8303\u56f4\u540e\uff0c\u60a8\u53ea\u9700\u8981\u91cd\u65b0\u542f\u52a8\u7f51\u7edc\u670d\u52a1\u5373\u53ef\u6fc0\u6d3b\u5b83\uff1a<\/p>\n<p>service network restart<\/p>\n<p>\u4ee5\u4e0a\u5c31\u662f\u5982\u4f55\u5728\u57fa\u4e8e RedHat \u7684\u7cfb\u7edf\u4e0a\u5feb\u901f\u7ed1\u5b9a IP\u7684\u5168\u90e8\u5185\u5bb9\u3002\u63a8\u8350\u76f8\u5173\u9605\u8bfb\uff1a<a href=\"https:\/\/cn.hostease.com\/blog\/server\/692.html\">\u300a \u5728Linux\u670d\u52a1\u5668\u4e2d\u4f7f\u7528ip\u547d\u4ee4 \u300b<\/a><\/p>\n","protected":false},"excerpt":{"rendered":"<p>\u5728\u8fd9\u7bc7\u77ed\u6587\u4e2d\uff0c\u6211\u5c06\u5411\u60a8\u5c55\u793a\u5982\u4f55\u5728\u4efb\u4f55\u57fa\u4e8eRedHat\u7684\u7cfb\u7edf(Rhel\u3001Centos\u3001Fedora\u7b49)\u4e0a\u5feb\u901f\u6dfb\u52a0 &#8230; <a title=\"\u5982\u4f55\u5728\u57fa\u4e8e RedHat \u7684\u7cfb\u7edf\u4e0a\u5feb\u901f\u7ed1\u5b9a IP\" class=\"read-more\" href=\"https:\/\/cn.hostease.com\/blog\/news\/%e5%a6%82%e4%bd%95%e5%9c%a8%e5%9f%ba%e4%ba%8e-redhat-%e7%9a%84%e7%b3%bb%e7%bb%9f%e4%b8%8a%e5%bf%ab%e9%80%9f%e7%bb%91%e5%ae%9a-ip\/\" aria-label=\"\u9605\u8bfb \u5982\u4f55\u5728\u57fa\u4e8e RedHat \u7684\u7cfb\u7edf\u4e0a\u5feb\u901f\u7ed1\u5b9a IP\">\u9605\u8bfb\u66f4\u591a<\/a><\/p>\n","protected":false},"author":2,"featured_media":0,"comment_status":"open","ping_status":"open","sticky":false,"template":"","format":"standard","meta":{"_jetpack_memberships_contains_paid_content":false,"footnotes":""},"categories":[8],"tags":[177,299],"class_list":["post-1849","post","type-post","status-publish","format-standard","hentry","category-news","tag-ip","tag-redhat"],"aioseo_notices":[],"jetpack_featured_media_url":"","jetpack_sharing_enabled":true,"_links":{"self":[{"href":"https:\/\/cn.hostease.com\/blog\/wp-json\/wp\/v2\/posts\/1849","targetHints":{"allow":["GET"]}}],"collection":[{"href":"https:\/\/cn.hostease.com\/blog\/wp-json\/wp\/v2\/posts"}],"about":[{"href":"https:\/\/cn.hostease.com\/blog\/wp-json\/wp\/v2\/types\/post"}],"author":[{"embeddable":true,"href":"https:\/\/cn.hostease.com\/blog\/wp-json\/wp\/v2\/users\/2"}],"replies":[{"embeddable":true,"href":"https:\/\/cn.hostease.com\/blog\/wp-json\/wp\/v2\/comments?post=1849"}],"version-history":[{"count":2,"href":"https:\/\/cn.hostease.com\/blog\/wp-json\/wp\/v2\/posts\/1849\/revisions"}],"predecessor-version":[{"id":1853,"href":"https:\/\/cn.hostease.com\/blog\/wp-json\/wp\/v2\/posts\/1849\/revisions\/1853"}],"wp:attachment":[{"href":"https:\/\/cn.hostease.com\/blog\/wp-json\/wp\/v2\/media?parent=1849"}],"wp:term":[{"taxonomy":"category","embeddable":true,"href":"https:\/\/cn.hostease.com\/blog\/wp-json\/wp\/v2\/categories?post=1849"},{"taxonomy":"post_tag","embeddable":true,"href":"https:\/\/cn.hostease.com\/blog\/wp-json\/wp\/v2\/tags?post=1849"}],"curies":[{"name":"wp","href":"https:\/\/api.w.org\/{rel}","templated":true}]}}