{"id":215558,"date":"2021-04-16T09:50:23","date_gmt":"2021-04-16T01:50:23","guid":{"rendered":"https:\/\/lrxjmw.cn\/?p=215558"},"modified":"2021-04-02T08:53:35","modified_gmt":"2021-04-02T00:53:35","slug":"linux-cfdisk-usage","status":"publish","type":"post","link":"https:\/\/lrxjmw.cn\/linux-cfdisk-usage.html","title":{"rendered":"Linux\u4e0b\u78c1\u76d8\u5206\u533a\u5de5\u5177cfdisk\u7684\u4f7f\u7528"},"content":{"rendered":"\n\n\n
\u5bfc\u8bfb<\/td>\n\u5bf9\u4e8e\u65b0\u624b\u6765\u8bf4\uff0cLinux\u73af\u5883\u4e0b\u7684\u78c1\u76d8\u5206\u533a\u53ef\u80fd\u8fd8\u4f1a\u5b58\u5728\u4e00\u4e9b\u56f0\u96be\u3002\u5bf9\u4e8e\u719f\u6089Linux\u7684\u670b\u53cb\u6765\u8bf4\uff0c\u6211\u4eec\u8fd8\u6709fdisk\u3001parted\uff082TB\u4ee5\u4e0a\u7684\u78c1\u76d8\u5206\u533a\u4f7f\u7528\uff09\u7b49\u78c1\u76d8\u5206\u533a\u5de5\u5177\u53ef\u4ee5\u4f7f\u7528\u3002<\/strong><\/td>\n<\/tr>\n<\/tbody>\n<\/table>\n

\u5728\u6211\u4eec\u65b0\u589e\u78c1\u76d8\u6216\u8005\u5728\u539f\u6765\u78c1\u76d8\u4e0a\u8fdb\u884c\u6269\u5bb9\u65f6\u5c31\u4f1a\u4f7f\u7528\u5230\u78c1\u76d8\u5206\u533a\u5de5\u5177\uff0c\u78c1\u76d8\u5206\u533a\u5bf9\u4e8e\u6574\u4e2a\u7cfb\u7edf\u7684\u7ba1\u7406\u5341\u5206\u91cd\u8981\u3002<\/p>\n

1 . \u589e\u52a0\u4e00\u5757\u5bb9\u91cf\u4e3a2GB\u7684\u786c\u76d8\uff0c\u589e\u52a0\u6b65\u9aa4\u4e0d\u8d58\u8ff0\uff0c\u6839\u636e\u4e2a\u4eba\u60c5\u51b5\u8fdb\u884c\u64cd\u4f5c\u3002\u4f7f\u7528lsblk\u547d\u4ee4\u67e5\u770b\u4e00\u4e0b\u5f53\u524d\u5b58\u50a8\u8bbe\u5907\u60c5\u51b5\uff0c\u53ef\u4ee5\u770b\u51fa\u6211\u4eec\u65b0\u589e\u7684\u8bbe\u5907\u540d\u79f0\u4e3asdb\u3002<\/p>\n

lsblk\r\nNAME            MAJ:MIN RM  SIZE RO TYPE MOUNTPOINT\r\nsda              8:0    0  10G  0 disk\r\n\u251c\u2500sda1            8:1    0  250M  0 part \/boot\r\n\u2514\u2500sda2            8:2    0  9.8G  0 part\r\n  \u251c\u2500CentOS-root 253:0    0  8.3G  0 lvm  \/\r\n  \u2514\u2500centos-swap 253:1    0  1.5G  0 lvm  [SWAP]\r\nsdb              8:16  0    2G  0 disk\r\nsr0              11:0    1 1024M  0 rom<\/pre>\n

2 . \u4f7f\u7528cfdisk\u6765\u5bf9\u8bbe\u5907sdb\u6765\u8fdb\u884c\u5206\u533a\u64cd\u4f5c\u3002<\/p>\n

cfdisk \/dev\/sdb1<\/pre>\n

\u8f93\u5165\u4ee5\u4e0a\u547d\u4ee4\u540e\uff0c\u5c4f\u5e55\u51fa\u73b0\u4ee5\u4e0b\u754c\u9762\uff1a<\/p>\n

\"\"<\/p>\n

\u5149\u6807\u9ed8\u8ba4\u5728\u201c\u65b0\u5efa\u201d\u4e0a\uff0c\u6309\u4e0b\u56de\u8f66\u952e\u3002\u6309\u7167\u4ee5\u4e0b\u6b65\u9aa4\uff08\u6bcf\u4e00\u6b65\u90fd\u9700\u8981\u952e\u5165\u56de\u8f66\u952e\u786e\u8ba4\uff09\uff1a
\n\u4e3b\u5206\u533a\uff08\u903b\u8f91\u5206\u533a\uff09->\u5927\u5c0f\uff08MB\uff0c\u6b64\u5904\u9700\u8981\u8f93\u5165\u65b0\u5efa\u5206\u533a\u7684\u5927\u5c0f\uff0c\u8f93\u5b8c\u4e4b\u540e\u6309\u56de\u8f66\u952e\uff09->\u7c7b\u578b\uff08\u6839\u636e\u5b9e\u9645\u9700\u6c42\u8fdb\u884c\u9009\u62e9\uff09->\u5199\u5165\uff08\u56de\u8f66\u952e\u4e4b\u540e\u8f93\u5165\u201c\u662f\u201d\uff09\u3002<\/p>\n

\u4ee5\u4e0a\u6b65\u9aa4\u64cd\u4f5c\u5b8c\u6210\u4e4b\u540e\u5982\u4e0b\u56fe\u6240\u793a\uff1a <\/p>\n

\"\"<\/p>\n

\u518d\u4f7f\u7528lsblk\u770b\u4e00\u4e0b\uff1a<\/p>\n

lsblk\r\nNAME            MAJ:MIN RM  SIZE RO TYPE MOUNTPOINT\r\nsda              8:0    0  10G  0 disk\r\n\u251c\u2500sda1            8:1    0  250M  0 part \/boot\r\n\u2514\u2500sda2            8:2    0  9.8G  0 part\r\n  \u251c\u2500centos-root 253:0    0  8.3G  0 lvm  \/\r\n  \u2514\u2500centos-swap 253:1    0  1.5G  0 lvm  [SWAP]\r\nsdb              8:16  0    2G  0 disk\r\n\u2514\u2500sdb1            8:17  0    2G  0 part\r\nsr0              11:0    1 1024M  0 rom<\/pre>\n

3 . \u6839\u636e\u5b9e\u9645\u60c5\u51b5\u683c\u5f0f\u5316\u6302\u8f7d\u4f7f\u7528\u6216\u8005\u8fdb\u884cLVM\u64cd\u4f5c\u5373\u53ef<\/p>\n","protected":false},"excerpt":{"rendered":"

\u5728\u6211\u4eec\u65b0\u589e\u78c1\u76d8\u6216\u8005\u5728\u539f\u6765\u78c1\u76d8\u4e0a\u8fdb\u884c\u6269\u5bb9\u65f6\u5c31\u4f1a\u4f7f\u7528\u5230\u78c1\u76d8\u5206\u533a\u5de5\u5177\uff0c\u78c1\u76d8\u5206\u533a\u5bf9\u4e8e\u6574\u4e2a\u7cfb\u7edf\u7684\u7ba1\u7406\u5341\u5206\u91cd\u8981\u3002 1 . […]<\/p>\n","protected":false},"author":310,"featured_media":215564,"comment_status":"closed","ping_status":"closed","sticky":false,"template":"","format":"standard","meta":{"_acf_changed":false,"footnotes":""},"categories":[55],"tags":[],"class_list":["post-215558","post","type-post","status-publish","format-standard","has-post-thumbnail","hentry","category-thread"],"acf":[],"_links":{"self":[{"href":"https:\/\/lrxjmw.cn\/wp-json\/wp\/v2\/posts\/215558","targetHints":{"allow":["GET"]}}],"collection":[{"href":"https:\/\/lrxjmw.cn\/wp-json\/wp\/v2\/posts"}],"about":[{"href":"https:\/\/lrxjmw.cn\/wp-json\/wp\/v2\/types\/post"}],"author":[{"embeddable":true,"href":"https:\/\/lrxjmw.cn\/wp-json\/wp\/v2\/users\/310"}],"replies":[{"embeddable":true,"href":"https:\/\/lrxjmw.cn\/wp-json\/wp\/v2\/comments?post=215558"}],"version-history":[{"count":4,"href":"https:\/\/lrxjmw.cn\/wp-json\/wp\/v2\/posts\/215558\/revisions"}],"predecessor-version":[{"id":215653,"href":"https:\/\/lrxjmw.cn\/wp-json\/wp\/v2\/posts\/215558\/revisions\/215653"}],"wp:featuredmedia":[{"embeddable":true,"href":"https:\/\/lrxjmw.cn\/wp-json\/wp\/v2\/media\/215564"}],"wp:attachment":[{"href":"https:\/\/lrxjmw.cn\/wp-json\/wp\/v2\/media?parent=215558"}],"wp:term":[{"taxonomy":"category","embeddable":true,"href":"https:\/\/lrxjmw.cn\/wp-json\/wp\/v2\/categories?post=215558"},{"taxonomy":"post_tag","embeddable":true,"href":"https:\/\/lrxjmw.cn\/wp-json\/wp\/v2\/tags?post=215558"}],"curies":[{"name":"wp","href":"https:\/\/api.w.org\/{rel}","templated":true}]}}