{"id":279374,"date":"2023-08-02T20:08:12","date_gmt":"2023-08-02T12:08:12","guid":{"rendered":"https:\/\/gulass.cn\/jbwlcpgscpkr.html"},"modified":"2023-08-02T20:08:12","modified_gmt":"2023-08-02T12:08:12","slug":"jbwlcpgscpkr","status":"publish","type":"post","link":"https:\/\/gulass.cn\/jbwlcpgscpkr.html","title":{"rendered":"\u57fa\u672c\u7269\u7406\u78c1\u76d8\u683c\u5f0f\u78c1\u76d8\u6269\u5bb9\u7684\u6b65\u9aa4\u53ca\u6b65\u9aa4\u770b\u8fd9\u91cc\uff01"},"content":{"rendered":"

\u6458\u8981\uff1a\u57fa\u672c\u6570\u5b66c\u76d8\u662f\u6307\u7cfb\u7edf<\/a>\u7684\u5316\u5b66\u50a8\u5b58\u8bbe\u5907\uff0c\u5982\uff1a\/dev\/hda\u3001\/dev\/sda\u7b49\uff0c\u662f\u50a8\u5b58\u7cfb\u7edf\u6700\u5e95\u5c42\u7684\u50a8\u5b58\u5355\u5143\u3002\u975elvm\u683c\u5f0fc\u76d8\u6269\u5bb9\u53ea\u9002\u5b9c\u865a\u62df\u673a\uff0c\u540c\u65f6\u53ea\u9002\u5b9c\u540c\u4e00\u4e2ac\u76d8\u4ece\u67d0\u4e2a\u5927\u5c0f\u6269\u5bb9\u5230\u53e6\u4e00\u4e2a\u5927\u5c0f\uff0c\u4f8b\u5982c\u76d8A\u539f\u5148100G\uff0c\u6269\u5bb9c\u76d8A\u5230200Glinux\u67e5\u8be2\u5b58\u50a8\u5927\u5c0f<\/strong>\uff0c\u4e0d\u9002\u5b9c\u5316\u5b66\u670d\u52a1\u5668\uff0c\u540c\u65f6\u4e0d\u9002\u5b9c\u865a\u62df\u673a\u65b0\u6dfb\u52a0c\u76d8\u3002\u672c\u6587\u4e3b\u8981\u9488\u5bf9Debian\u7cfb\u7edf\u7684\u57fa\u7840c\u76d8\u51fa\u73b0\u6839\u76ee\u5f55\u501f\u52a9\u7387\u504f\u4f4e\uff0c\u987b\u8981\u5bf9\u6839\u76ee\u5f55\/\u8fdb\u884c\u6269\u5bb9\u7684\u8fc7\u7a0b\u3002\u5177\u4f53\u6b65\u9aa4\u770b\u4e0b\u6587\u3002<\/p>\n

\u4e00\u3001\u6269\u5bb9\u6253\u7b97<\/p>\n

1\u3001\u865a\u62df\u673a\u539f\u5148\u7684c\u76d8\u5bb9\u91cf\u4e3a100G\uff0c\u6269\u5145\u5230200G\u3002<\/p>\n

linux\u600e\u4e48\u770b\u5b58\u50a8_linux\u7cfb\u7edf\u67e5\u770b\u50a8\u5b58\u547d\u4ee4_linux\u67e5\u8be2\u5b58\u50a8\u5927\u5c0f<\/p>\n

2\u3001\u6267\u884creboot\u6307\u4ee4\u91cd\u542fDebian\u670d\u52a1\u5668\uff0c\u67e5\u770bc\u76d8\u7684\u6269\u5145\u60c5\u51b5\u3002<\/p>\n

\u4e8c\u3001\u975eLVMc\u76d8\u6269\u5bb9<\/p>\n

\u8bf4\u660e\uff1a\u4e00\u5b9a\u8981\u5148\u505a\u5907\u4efd\uff0c\u865a\u673a\u4e2d\u76f4\u63a5\u521b\u5efa\u4e00\u4e2a\u5feb\u7167\u5907\u4efd\u3002<\/p>\n

1\u3001\u67e5\u770b\u5f53\u524d\u5206\u533a\u60c5\u51b5<\/p>\n

linux\u67e5\u8be2\u5b58\u50a8\u5927\u5c0f_linux\u7cfb\u7edf\u67e5\u770b\u50a8\u5b58\u547d\u4ee4_linux\u600e\u4e48\u770b\u5b58\u50a8<\/p>\n

\u5907\u6ce8\uff1a\u770b\u89c1\/dev\/sda1\u662f97G\uff0c\u76ee\u6807\u5c31\u662f\u5c06\/dev\/sda1\u65e0\u635f\u6269\u5bb9\u3002<\/p>\n

2\u3001fdisk\u547d\u4ee4<\/a>\u5220\u6389\u65e7\u5206\u533a\u5e76\u521b\u5efa\u65b0\u5206\u533a<\/p>\n

\uff081\uff09\u3001\u5148\u5220\u6389\u539f\u672c\u7684swap\u5206\u533a\u548c\u4e3b\u5206\u533a<\/p>\n

\u6267\u884c\u6307\u4ee4#fdisk\/dev\/sda<\/p>\n

\u547d\u4ee4(\u8f93\u5165m\u83b7\u53d6\u5e2e\u52a9)\uff1ad<\/p>\n

\u5206\u533a\u53f7(1,2,5,\u9ed8\u8ba45):2<\/p>\n

\u5206\u533a2\u5df2\u5220\u6389\u3002<\/p>\n

\u547d\u4ee4(\u8f93\u5165m\u83b7\u53d6\u5e2e\u52a9)\uff1ad<\/p>\n

\u5df2\u9009\u62e9\u5206\u533a1<\/p>\n

\u5206\u533a1\u5df2\u5220\u6389\u3002<\/p>\n

linux\u67e5\u8be2\u5b58\u50a8\u5927\u5c0f_linux\u7cfb\u7edf\u67e5\u770b\u50a8\u5b58\u547d\u4ee4_linux\u600e\u4e48\u770b\u5b58\u50a8<\/p>\n

\u6ce8\u610f\uff1a\u6b64\u6b65\u9aa4\u6267\u884c\u5b8c\u6210\u540e\uff0c\u5343\u4e07\u4e0d\u8981\u4fdd\u5b58\uff0c\u5426\u5219sda1\u548csda2\u5c31\u771f\u7684\u88ab\u5220\u6389\u4e86\uff0csda1\u548csda2\u4e0a\u7684\u6570\u636e\u5c31\u88ab\u6e05\u7a7a\u3002<\/p>\n

\uff082\uff09\u3001\u91cd\u65b0\u521b\u5efa\u4e3b\u5206\u533a\u548cswap\u5206\u533a\uff0cswap\u5206\u533a\u7ed94G\uff0c\u4e3b\u5206\u533a96G\u3002\u521b\u5efa\u4e3b\u5206\u533a\u65f6linux\u67e5\u8be2\u5b58\u50a8\u5927\u5c0f<\/strong>linux\u547d\u4ee4\u884c\u548cshell\u811a\u672c\u7f16\u7a0b\u5b9d\u5178\uff0clastsector=sector\u6700\u5927\u503c-\uff08410241024*1024\/512\uff09\uff0c209715200-8,388,608=201,326,592<\/p>\n

\u547d\u4ee4(\u8f93\u5165m\u83b7\u53d6\u5e2e\u52a9)\uff1an<\/p>\n

\u5206\u533a\u7c7b\u578b<\/p>\n

p\u4e3b\u5206\u533a(0\u4e2a\u4e3b\u5206\u533a\uff0c0\u4e2a\u6269\u5145\u5206\u533a\uff0c4\u7a7a\u95f2)<\/p>\n

e\u6269\u5145\u5206\u533a(\u903b\u8f91\u5206\u533a\u5bb9\u5668)<\/p>\n

\u9009\u62e9(\u9ed8\u8ba4p)\uff1ap<\/p>\n

\u5206\u533a\u53f7(1-4,\u9ed8\u8ba41):<\/p>\n

\u7b2c\u4e00\u4e2a\u78c1\u9053(29,default2048):<\/p>\n

Lastsector,+\/-sectorsor+\/-size{K,M,G,T,P}(29,default419430399):411030391<\/p>\n

\u521b\u5efa\u4e86\u4e00\u4e2a\u65b0\u5206\u533a1\uff0c\u7c7b\u578b\u4e3a\u201cLinux<\/a>\u201d\uff0c\u5927\u5c0f\u4e3a196GiB\u3002<\/p>\n

\u5206\u533a#1\u5305\u542b\u4e00\u4e2aext4\u7b7e\u540d\u3002<\/p>\n

\u60a8\u60f3\u79fb\u9664\u8be5\u7b7e\u540d\u5417\uff1f\u662f[Y]\/\u5426[N]\uff1ay<\/p>\n

\u5199\u5165\u547d\u4ee4\u5c06\u79fb\u9664\u8be5\u7b7e\u540d\u3002<\/p>\n

\u547d\u4ee4(\u8f93\u5165m\u83b7\u53d6\u5e2e\u52a9)\uff1an<\/p>\n

\u5206\u533a\u7c7b\u578b<\/p>\n

p\u4e3b\u5206\u533a(1\u4e2a\u4e3b\u5206\u533a\uff0c0\u4e2a\u6269\u5145\u5206\u533alinux\u5b89\u88c5\u6559\u7a0b\uff0c3\u7a7a\u95f2)<\/p>\n

e\u6269\u5145\u5206\u533a(\u903b\u8f91\u5206\u533a\u5bb9\u5668)<\/p>\n

\u9009\u62e9(\u9ed8\u8ba4p)\uff1ap<\/p>\n

linux\u67e5\u8be2\u5b58\u50a8\u5927\u5c0f_linux\u600e\u4e48\u770b\u5b58\u50a8_linux\u7cfb\u7edf\u67e5\u770b\u50a8\u5b58\u547d\u4ee4<\/p>\n

\u5206\u533a\u53f7(2-4,\u9ed8\u8ba42):<\/p>\n

\u7b2c\u4e00\u4e2a\u78c1\u9053(4130399,default411031552):<\/p>\n

Lastsector,+\/-sectorsor+\/-size{K,M,G,T,P}(4130399,default419430399):<\/p>\n

\u521b\u5efa\u4e86\u4e00\u4e2a\u65b0\u5206\u533a2\uff0c\u7c7b\u578b\u4e3a\u201cLinux\u201d\uff0c\u5927\u5c0f\u4e3a4GiB\u3002<\/p>\n

\uff083\uff09\u3001\u8bbe\u7f6e\u542f\u52a8\u4fe1\u606f<\/p>\n

\u547d\u4ee4(\u8f93\u5165m\u83b7\u53d6\u5e2e\u52a9)\uff1at<\/p>\n

\u5206\u533a\u53f7(1,2,\u9ed8\u8ba42):<\/p>\n

Hex\u4ee3\u7801(\u8f93\u5165L\u5217\u4e3e\u6240\u6709\u4ee3\u7801)\uff1a82<\/p>\n

\u5df2\u5c06\u5206\u533a\u201cLinux\u201d\u7684\u7c7b\u578b\u4fee\u6539\u4e3a\u201cLinuxswap\/Solaris\u201d\u3002<\/p>\n

\u547d\u4ee4(\u8f93\u5165m\u83b7\u53d6\u5e2e\u52a9)\uff1aa<\/p>\n

\u5206\u533a\u53f7(1,2,\u9ed8\u8ba42):1<\/p>\n

linux\u67e5\u8be2\u5b58\u50a8\u5927\u5c0f_linux\u600e\u4e48\u770b\u5b58\u50a8_linux\u7cfb\u7edf\u67e5\u770b\u50a8\u5b58\u547d\u4ee4<\/p>\n

\u5206\u533a1\u7684\u53ef\u542f\u52a8\u6807\u5fd7\u5df2\u542f\u7528\u3002<\/p>\n

\uff084\uff09\u3001\u5199\u5165\u4fdd\u5b58<\/p>\n

\u547d\u4ee4(\u8f93\u5165m\u83b7\u53d6\u5e2e\u52a9)\uff1aw<\/p>\n

\u5206\u533a\u8868\u5df2\u8c03\u6574\u3002<\/p>\n

Failedtoremovepartition5fromsystem:\u8bbe\u5907\u6216\u8d44\u6e90\u5fd9<\/p>\n

Failedtoupdatesysteminformationaboutpartition1:\u8bbe\u5907\u6216\u8d44\u6e90\u5fd9<\/p>\n

Thekernelstillusestheoldpartitions.Thenewtablewillbeusedatthenextreboot.<\/p>\n

\u6b63\u5728\u540c\u6b65c\u76d8\u3002<\/p>\n

3\u3001resize2fs\u547d\u4ee4\u6269\u5927\u5206\u533a<\/p>\n

\uff081\uff09\u3001\u67e5\u770bc\u76d8\u5206\u533a\u60c5\u51b5<\/p>\n

\uff082\uff09\u3001\u6267\u884c\u6307\u4ee4#resize2fs\/dev\/sda1\u6269\u5bb9<\/p>\n

\uff083\uff09\u67e5\u770bc\u76d8\u6269\u5bb9\u60c5\u51b5<\/p>\n

linux\u7cfb\u7edf\u67e5\u770b\u50a8\u5b58\u547d\u4ee4_linux\u600e\u4e48\u770b\u5b58\u50a8_linux\u67e5\u8be2\u5b58\u50a8\u5927\u5c0f<\/p>\n

4\u3001\u91cd\u5efaswap\u5206\u533a\u4fe1\u606f<\/p>\n

\uff081\uff09\u3001blkid\u67e5\u770bswap\u5206\u533a\u4fe1\u606f\uff0c\u6ca1\u6709UUID\u3002<\/p>\n

(2)\u3001mkswap\/dev\/sda2\u91cd\u65b0\u521b\u5efaswap\u4fe1\u606f\uff0c\u4f1a\u5f62\u6210UUID\u3002<\/p>\n

\uff083\uff09\u3001\u4fee\u6539\/etc\/fstab\u6587\u4ef6\uff0c\u5c06\u4e0a\u9762\u7684swap\u5206\u533a\u4fe1\u606f\u7684uuid\u6362\u6210\u65b0\u751f\u6210\u7684uuid\u3002<\/p>\n

linux\u67e5\u8be2\u5b58\u50a8\u5927\u5c0f_linux\u7cfb\u7edf\u67e5\u770b\u50a8\u5b58\u547d\u4ee4_linux\u600e\u4e48\u770b\u5b58\u50a8<\/p>\n

\uff084\uff09\u3001\u6267\u884cswapon\/dev\/sda2\u542f\u7528swap\uff0c\u518d\u4f7f\u7528swapon-s\u6216\u5219free-m\uff0c\u67e5\u770b\u5230swap\u5206\u533a\u4fe1\u606f\u3002<\/p>\n

\u5907\u6ce8\uff1a\u81f3\u6b64\uff0c\u5df2\u5b8c\u6210c\u76d8\u7a7a\u95f4\u6269\u5bb9\u53ca\u91cd\u5efaswap\u5206\u533a\u4fe1\u606f\u3002<\/p>\n","protected":false},"excerpt":{"rendered":"

\u6458\u8981\uff1a\u57fa\u672c\u7269\u7406\u78c1\u76d8\u662f\u6307\u7cfb\u7edf\u7684\u7269\u7406\u5b58\u50a8\u8bbe\u5907\uff0c\u5982\uff1a\/dev\/hda\u3001\/dev\/sda\u7b49\uff0c\u662f\u5b58\u50a8\u7cfb\u7edf\u6700\u5e95\u5c42\u7684\u5b58\u50a8\u5355\u5143\u3002\u975elvm\u683c\u5f0f\u78c1\u76d8\u6269\u5bb9\u53ea\u9002\u5408\u865a\u62df\u673a\uff0c\u540c\u65f6\u53ea\u9002\u5408\u540c\u4e00\u4e2a\u78c1\u76d8\u4ece\u67d0\u4e2a\u5927\u5c0f\u6269\u5bb9\u5230\u53e6\u4e00\u4e2a\u5927\u5c0f\uff0c\u6bd4\u5982\u78c1\u76d8A\u539f\u6765100G\uff0c\u6269\u5bb9\u78c1\u76d8A\u5230200G\uff0c\u4e0d\u9002\u5408\u7269\u7406\u670d\u52a1\u5668\uff0c\u540c\u65f6\u4e0d\u9002\u5408\u865a\u62df\u673a\u65b0\u6dfb\u52a0\u78c1\u76d8\u30021\u3001\u865a\u62df\u673a\u539f\u6765\u7684\u78c1\u76d8\u5bb9\u91cf\u4e3a100G\uff0c\u6269\u5c55\u5230200G\u3002\u5907\u6ce8\uff1a\u81f3\u6b64\uff0c\u5df2\u5b8c\u6210\u78c1\u76d8\u7a7a\u95f4\u6269\u5bb9\u53ca\u91cd\u5efaswap\u5206\u533a\u4fe1\u606f\u3002<\/p>\n","protected":false},"author":1,"featured_media":279375,"comment_status":"open","ping_status":"open","sticky":false,"template":"","format":"standard","meta":{"_acf_changed":false,"footnotes":""},"categories":[988],"tags":[999],"class_list":["post-279374","post","type-post","status-publish","format-standard","has-post-thumbnail","hentry","category-tougao","tag-999"],"acf":[],"_links":{"self":[{"href":"https:\/\/gulass.cn\/wp-json\/wp\/v2\/posts\/279374","targetHints":{"allow":["GET"]}}],"collection":[{"href":"https:\/\/gulass.cn\/wp-json\/wp\/v2\/posts"}],"about":[{"href":"https:\/\/gulass.cn\/wp-json\/wp\/v2\/types\/post"}],"author":[{"embeddable":true,"href":"https:\/\/gulass.cn\/wp-json\/wp\/v2\/users\/1"}],"replies":[{"embeddable":true,"href":"https:\/\/gulass.cn\/wp-json\/wp\/v2\/comments?post=279374"}],"version-history":[{"count":0,"href":"https:\/\/gulass.cn\/wp-json\/wp\/v2\/posts\/279374\/revisions"}],"wp:featuredmedia":[{"embeddable":true,"href":"https:\/\/gulass.cn\/wp-json\/wp\/v2\/media\/279375"}],"wp:attachment":[{"href":"https:\/\/gulass.cn\/wp-json\/wp\/v2\/media?parent=279374"}],"wp:term":[{"taxonomy":"category","embeddable":true,"href":"https:\/\/gulass.cn\/wp-json\/wp\/v2\/categories?post=279374"},{"taxonomy":"post_tag","embeddable":true,"href":"https:\/\/gulass.cn\/wp-json\/wp\/v2\/tags?post=279374"}],"curies":[{"name":"wp","href":"https:\/\/api.w.org\/{rel}","templated":true}]}}