{"id":5818,"date":"2017-11-10T23:35:04","date_gmt":"2017-11-10T14:35:04","guid":{"rendered":"http:\/\/blog.kourin.org\/blog\/?p=5818"},"modified":"2017-11-11T12:49:49","modified_gmt":"2017-11-11T03:49:49","slug":"%e5%85%89%e8%bc%aa%e3%82%b5%e3%83%bc%e3%83%90%e3%83%bc-linux-lvm%e9%a0%98%e5%9f%9f%e3%81%ae%e3%82%aa%e3%83%b3%e3%83%a9%e3%82%a4%e3%83%b3%e6%8b%a1%e5%bc%b5","status":"publish","type":"post","link":"http:\/\/blog.kourin.org\/blog\/?p=5818","title":{"rendered":"\u5149\u8f2a\u30b5\u30fc\u30d0\u30fc Linux LVM\u9818\u57df\u306e\u30aa\u30f3\u30e9\u30a4\u30f3\u62e1\u5f35"},"content":{"rendered":"<p>\u4eca\u65e5\u306f\u8272\u3005\u306aPC\u306b\u6563\u3089\u3070\u3063\u3066\u308bISO\u3068\u304b\u30e1\u30e2<span style=\"color: #808080;\"><strong>\uff08\u7121\u984c.txt, \u7121\u984c2.txt, memo,txt&#8230; \u7b49\uff09<\/strong><\/span>\u3068\u304b\u3001\u30ea\u30f3\u30af\u5207\u308c\u306eWEB\u30b7\u30e7\u30fc\u30c8\u30ab\u30c3\u30c8\u3068\u304b\u53e4\u3044\u30c9\u30e9\u30a4\u30d0\u3068\u304b\u30d1\u30c3\u30c1\u3068\u304b&#8230;<br \/>\n\u524a\u9664\u3057\u305f\u308a\u3001\u4e00\u30ab\u6240\u306b\u7e8f\u3081\u305f\u308a\u30c7\u30fc\u30bf\u306e\u6574\u7406\u3092\u3057\u3066\u3044\u305f\u8a33\u3067\u3059\u3002<\/p>\n<p>\u8a55\u4fa1\u7248\u306eISO\u3068\u304b\u30d1\u30c3\u30c1\u3068\u304b\u306f\u5149\u8f2a\u30b5\u30fc\u30d0\u30fc\u306b\u653e\u308a\u8fbc\u3093\u3067\u3042\u3063\u305f\u308a\u3059\u308b\u306e\u3067\u3059\u304c&#8230;<br \/>\n<img loading=\"lazy\" decoding=\"async\" class=\"alignnone size-large wp-image-5817\" src=\"http:\/\/blog.kourin.org\/blog\/wp-content\/uploads\/2017\/11\/graph_245_1-470x177.png\" alt=\"\" width=\"470\" height=\"177\" srcset=\"http:\/\/blog.kourin.org\/blog\/wp-content\/uploads\/2017\/11\/graph_245_1-470x177.png 470w, http:\/\/blog.kourin.org\/blog\/wp-content\/uploads\/2017\/11\/graph_245_1-300x113.png 300w, http:\/\/blog.kourin.org\/blog\/wp-content\/uploads\/2017\/11\/graph_245_1.png 595w\" sizes=\"(max-width: 470px) 100vw, 470px\" \/><br \/>\n<span style=\"color: #ff6600; font-size: 14pt;\"><strong>\u7a7a\u304d\u304c5GB\u306b\u306a\u3063\u3066\u3057\u307e\u3044\u307e\u3057\u305f&#8230;<\/strong><\/span><br \/>\n\u3068\u8a00\u3046\u4e8b\u3067\u3001\/home\u9818\u57df\u306e\u30aa\u30f3\u30e9\u30a4\u30f3\u62e1\u5f35\u3092\u5b9f\u65bd\u3057\u307e\u3057\u305f\u3002<br \/>\n<span style=\"color: #808080;\"><strong>\uff08\u5b9f\u306f\u3001\u4ee5\u524d\u306b\u53e4\u3044\u5149\u8f2a\u30b5\u30fc\u30d0\u30fc\u3067\u3082\u3063\u3068<a href=\"http:\/\/blog.kourin.org\/blog\/?p=1857\">\u5927\u639b\u304b\u308a\u306a\u624b\u9806\u3067\u5b9f\u65bd<\/a>\u3057\u3066\u3044\u308b\u3082\u306e\u3068\u3084\u3063\u3066\u308b\u3053\u3068\u306f\u5909\u308f\u308a\u307e\u305b\u3093\uff09<\/strong><\/span><\/p>\n<p><strong>\u25cf \/home \u9818\u57df\u3068\u3057\u3066\u5229\u7528\u3057\u3066\u3044\u308b\u30dc\u30ea\u30e5\u30fc\u30e0\u3092\u78ba\u8a8d<\/strong><\/p>\n<pre><span style=\"font-size: 8pt;\">[root@Server ~]# <span style=\"background-color: #ffff00;\">df -k | grep home<\/span>\r\n\/dev\/mapper\/vg01-lvol1 206292968 190498856 5291968 98% \/home <span style=\"color: #ff0000;\"><strong>&lt;= \u4f7f\u7528\u738798%\uff01\r\n<\/strong><\/span><\/span><\/pre>\n<p><strong>\u25cf vg01\u306e\u5272\u308a\u5f53\u3066\u9818\u57df\u30b5\u30a4\u30ba\u3068\u672a\u4f7f\u7528\u9818\u57df\u30b5\u30a4\u30ba\u3092\u78ba\u8a8d<\/strong><\/p>\n<pre><span style=\"font-size: 8pt;\">[root@Server ~]# <span style=\"background-color: #ffff00;\">vgdisplay -v vg01<\/span>\r\n--- Volume group ---\r\nVG Name vg01\r\nSystem ID\r\nFormat lvm2\r\nMetadata Areas 1\r\nMetadata Sequence No 5\r\nVG Access read\/write\r\nVG Status resizable\r\nMAX LV 0\r\nCur LV 4\r\nOpen LV 4\r\nMax PV 0\r\nCur PV 1\r\nAct PV 1\r\nVG Size &lt;300.00 GiB\r\nPE Size 4.00 MiB\r\nTotal PE 76799\r\nAlloc PE \/ Size 65536 \/ 256.00 GiB\r\nFree PE \/ Size 11263 \/ &lt;44.00 GiB <span style=\"color: #ff0000;\"><strong>&lt;= \u672a\u4f7f\u752844GiB<\/strong><\/span>\r\nVG UUID otQhLv-SSPP-yfDi-2gpI-U2jF-BEf1-jTovcN\r\n\r\n--- Logical volume ---\r\nLV Path \/dev\/vg01\/lvol1\r\nLV Name lvol1\r\nVG Name vg01\r\nLV UUID owNriB-OYTm-GjOn-19Ph-dQqQ-Zirf-SFdJfB\r\nLV Write Access read\/write\r\nLV Creation host, time Server.kourin.org, 2015-10-24 22:34:46 +0900\r\nLV Status available\r\n# open 1\r\nLV Size 200.00 GiB <span style=\"color: #ff0000;\"><strong>&lt;= \/home\u9818\u57df\u5272\u5f53\u3066\u30b5\u30a4\u30ba200GiB<\/strong><\/span>\r\nCurrent LE 51200\r\nSegments 1\r\nAllocation inherit\r\nRead ahead sectors auto\r\n- currently set to 8192\r\nBlock device 253:0\r\n\r\n--- Logical volume ---\r\nLV Path \/dev\/vg01\/lvol2\r\nLV Name lvol2\r\nVG Name vg01\r\nLV UUID 5iZm1y-pQft-yNsC-D74h-UWK9-azee-5WFFml\r\nLV Write Access read\/write\r\nLV Creation host, time Server.kourin.org, 2015-10-24 22:36:46 +0900\r\nLV Status available\r\n# open 1\r\nLV Size 1.00 GiB\r\nCurrent LE 256\r\nSegments 1\r\nAllocation inherit\r\nRead ahead sectors auto\r\n- currently set to 8192\r\nBlock device 253:1\r\n\r\n--- Logical volume ---\r\nLV Path \/dev\/vg01\/lvol3\r\nLV Name lvol3\r\nVG Name vg01\r\nLV UUID fZsfJL-qmXl-X0tz-X4bC-iq9z-1WKr-aN3EP4\r\nLV Write Access read\/write\r\nLV Creation host, time Server.kourin.org, 2015-10-24 22:37:50 +0900\r\nLV Status available\r\n# open 1\r\nLV Size 25.00 GiB\r\nCurrent LE 6400\r\nSegments 1\r\nAllocation inherit\r\nRead ahead sectors auto\r\n- currently set to 8192\r\nBlock device 253:2\r\n\r\n--- Logical volume ---\r\nLV Path \/dev\/vg01\/lvol4\r\nLV Name lvol4\r\nVG Name vg01\r\nLV UUID iV85Vl-6uKj-K2OF-4gvn-dJKc-Be9b-UeDgOB\r\nLV Write Access read\/write\r\nLV Creation host, time Server.kourin.org, 2015-10-24 22:38:22 +0900\r\nLV Status available\r\n# open 1\r\nLV Size 30.00 GiB\r\nCurrent LE 7680\r\nSegments 1\r\nAllocation inherit\r\nRead ahead sectors auto\r\n- currently set to 8192\r\nBlock device 253:3\r\n\r\n--- Physical volumes ---\r\nPV Name \/dev\/sdb\r\nPV UUID gn2EvZ-lIP6-Nycm-EZlJ-0v7w-ZU8V-TLXKJj\r\nPV Status allocatable\r\nTotal PE \/ Free PE 76799 \/ 11263\r\n<\/span><\/pre>\n<p><strong>\u25cf \/home\u9818\u57df(\/dev\/vg01\/lvol1)\u306b\u672a\u4f7f\u7528\u306e40GiB\u3092\u8ffd\u52a0\u5272\u5f53\u3066<\/strong><\/p>\n<pre><span style=\"font-size: 8pt;\">[root@Server ~]# <span style=\"background-color: #ffff00;\">lvextend -L 240GiB \/dev\/vg01\/lvol1<\/span>\r\nSize of logical volume vg01\/lvol1 changed from 200.00 GiB (51200 extents) to 240.00 GiB (61440 extents).\r\nLogical volume vg01\/lvol1 successfully resized.\r\n<\/span><\/pre>\n<p><strong>\u25cf \/home\u9818\u57df(\/dev\/vg01\/lvol1)\u304c\u62e1\u5f35\u3055\u308c\u305f\u3053\u3068\u3092\u78ba\u8a8d<\/strong><\/p>\n<pre><span style=\"font-size: 8pt;\">[root@Server ~]# <span style=\"background-color: #ffff00;\">lvdisplay \/dev\/vg01\/lvol1<\/span>\r\n--- Logical volume ---\r\nLV Path \/dev\/vg01\/lvol1\r\nLV Name lvol1\r\nVG Name vg01\r\nLV UUID owNriB-OYTm-GjOn-19Ph-dQqQ-Zirf-SFdJfB\r\nLV Write Access read\/write\r\nLV Creation host, time Server.kourin.org, 2015-10-24 22:34:46 +0900\r\nLV Status available\r\n# open 1\r\nLV Size 240.00 GiB <span style=\"color: #ff0000;\"><strong>&lt;= 200GiB\u304b\u3089240GiB\u306b\u62e1\u5f35\u3055\u308c\u305f<\/strong><\/span>\r\nCurrent LE 61440\r\nSegments 2\r\nAllocation inherit\r\nRead ahead sectors auto\r\n- currently set to 8192\r\nBlock device 253:0\r\n[root@Server ~]#\r\n[root@Server ~]# <span style=\"background-color: #ffff00;\">df -k | grep home<\/span>\r\n\/dev\/mapper\/vg01-lvol1 206292968 190498856 5291968 98% \/home <span style=\"color: #ff0000;\"><strong>&lt;= \u30d5\u30a1\u30a4\u30eb\u30b7\u30b9\u30c6\u30e0\u306f200GiB\u306e\u307e\u307e<\/strong><\/span>\r\n<\/span><\/pre>\n<p><strong>\u25cf \/home\u9818\u57df\u306e\u30d5\u30a1\u30a4\u30eb\u30b7\u30b9\u30c6\u30e0\u3092\u62e1\u5f35<\/strong><\/p>\n<pre><span style=\"font-size: 8pt;\">[root@Server ~]# <span style=\"background-color: #ffff00;\">resize2fs \/dev\/vg01\/lvol1<\/span>\r\nresize2fs 1.42.9 (28-Dec-2013)\r\nFilesystem at \/dev\/vg01\/lvol1 is mounted on \/home; on-line resizing required\r\nold_desc_blocks = 25, new_desc_blocks = 30\r\nThe filesystem on \/dev\/vg01\/lvol1 is now 62914560 blocks long.\r\n<\/span><\/pre>\n<p><strong>\u25cf \/home\u9818\u57df\u304c\u62e1\u5f35\u3055\u308c\u305f\u3053\u3068\u3092\u78ba\u8a8d<\/strong><\/p>\n<pre><span style=\"font-size: 8pt;\">[root@Server ~]# <span style=\"background-color: #ffff00;\">df -k | grep home<\/span>\r\n\/dev\/mapper\/vg01-lvol1 247577788 190498556 44878436 81% \/home <span style=\"color: #ff0000;\"><strong>&lt;= \u4f7f\u7528\u7387\u304c\u4e0b\u304c\u3063\u305f\uff01<\/strong><\/span>\r\n[root@Server ~]#<\/span><\/pre>\n<p><span style=\"color: #ff0000;\"><strong>2017\/11\/11 \u8ffd\u8a18<br \/>\n<img loading=\"lazy\" decoding=\"async\" class=\"alignnone size-large wp-image-5821\" src=\"http:\/\/blog.kourin.org\/blog\/wp-content\/uploads\/2017\/11\/graph_245_1-1-470x177.png\" alt=\"\" width=\"470\" height=\"177\" srcset=\"http:\/\/blog.kourin.org\/blog\/wp-content\/uploads\/2017\/11\/graph_245_1-1-470x177.png 470w, http:\/\/blog.kourin.org\/blog\/wp-content\/uploads\/2017\/11\/graph_245_1-1-300x113.png 300w, http:\/\/blog.kourin.org\/blog\/wp-content\/uploads\/2017\/11\/graph_245_1-1.png 595w\" sizes=\"(max-width: 470px) 100vw, 470px\" \/><br \/>\n<\/strong><span style=\"color: #000000;\">\u30b0\u30e9\u30d5\u3067\u3059\u304c\u3001\u3053\u3093\u306a\u611f\u3058\u306b\u306a\u308a\u307e\u3057\u305f\u3002<\/span><\/span><br \/>\n<!-- Rakuten Widget FROM HERE --><script type=\"text\/javascript\">rakuten_design=\"slide\";rakuten_affiliateId=\"0f26729d.bc2972ea.0f26729e.557dde8c\";rakuten_items=\"ctsmatch\";rakuten_genreId=0;rakuten_size=\"468x160\";rakuten_target=\"_blank\";rakuten_theme=\"gray\";rakuten_border=\"off\";rakuten_auto_mode=\"on\";rakuten_genre_title=\"off\";rakuten_recommend=\"off\";<\/script><script type=\"text\/javascript\" src=\"http:\/\/xml.affiliate.rakuten.co.jp\/widget\/js\/rakuten_widget.js\"><\/script><!-- Rakuten Widget TO HERE --><\/p>\n","protected":false},"excerpt":{"rendered":"<p>\u4eca\u65e5\u306f\u8272\u3005\u306aPC\u306b\u6563\u3089\u3070\u3063\u3066\u308bISO\u3068\u304b\u30e1\u30e2\uff08\u7121\u984c.txt, \u7121\u984c2.txt, memo,txt&#8230; \u7b49\uff09\u3068\u304b\u3001\u30ea\u30f3\u30af\u5207\u308c\u306eWEB\u30b7\u30e7\u30fc\u30c8\u30ab\u30c3\u30c8\u3068\u304b\u53e4\u3044\u30c9\u30e9\u30a4\u30d0\u3068\u304b\u30d1\u30c3\u30c1\u3068\u304b&#8230; \u524a\u9664\u3057\u305f\u308a\u3001\u4e00\u30ab\u6240\u306b\u7e8f\u3081\u305f\u308a\u30c7\u30fc\u30bf\u306e\u6574\u7406\u3092\u3057\u3066\u3044\u305f\u8a33\u3067\u3059\u3002 \u8a55\u4fa1\u7248\u306eISO\u3068\u304b\u30d1\u30c3\u30c1\u3068\u304b\u306f\u5149\u8f2a\u30b5\u30fc\u30d0\u30fc\u306b\u653e\u308a\u8fbc\u3093\u3067\u3042\u3063\u305f\u308a\u3059\u308b\u306e\u3067\u3059\u304c&#8230; \u7a7a\u304d\u304c5GB\u306b\u306a\u3063\u3066\u3057\u307e\u3044\u307e\u3057\u305f&#8230; \u3068\u8a00\u3046\u4e8b\u3067\u3001\/home\u9818\u57df\u306e\u30aa\u30f3\u30e9\u30a4\u30f3\u62e1\u5f35\u3092\u5b9f\u65bd\u3057\u307e\u3057\u305f\u3002 \uff08\u5b9f\u306f\u3001\u4ee5\u524d\u306b\u53e4\u3044\u5149\u8f2a\u30b5\u30fc\u30d0\u30fc\u3067\u3082\u3063\u3068\u5927\u639b\u304b\u308a\u306a\u624b\u9806\u3067\u5b9f\u65bd\u3057\u3066\u3044\u308b\u3082\u306e\u3068\u3084\u3063\u3066\u308b\u3053\u3068\u306f\u5909\u308f\u308a\u307e\u305b\u3093\uff09 \u25cf \/home \u9818\u57df\u3068\u3057\u3066\u5229\u7528\u3057\u3066\u3044\u308b\u30dc\u30ea\u30e5\u30fc\u30e0\u3092\u78ba\u8a8d [root@Server ~]# df -k | grep home \/dev\/mapper\/vg01-lvol1 206292968 190498856 5291968 98% \/home &lt;= \u4f7f\u7528\u738798%\uff01 \u25cf vg01\u306e\u5272\u308a\u5f53\u3066\u9818\u57df\u30b5\u30a4\u30ba\u3068\u672a\u4f7f\u7528\u9818\u57df\u30b5\u30a4\u30ba\u3092\u78ba\u8a8d [root@Server ~]# vgdisplay -v vg01 &#8212; Volume group &#8212; VG Name vg01 System ID Format lvm2 Metadata Areas 1 Metadata Sequence No 5 VG Access read\/write [&#8230;]<\/p>\n","protected":false},"author":1,"featured_media":0,"comment_status":"open","ping_status":"open","sticky":false,"template":"","format":"standard","meta":{"footnotes":""},"categories":[5,16,9,3],"tags":[1413,129,2619,2620,715,2618,2621,2622,714],"class_list":["post-5818","post","type-post","status-publish","format-standard","hentry","category-linux","category-digital","category-trub","category-kourin","tag-linux","tag-lvm","tag-lvol","tag-pe","tag-vg","tag-volumegroup","tag-2621","tag-2622","tag-714"],"aioseo_notices":[],"_links":{"self":[{"href":"http:\/\/blog.kourin.org\/blog\/index.php?rest_route=\/wp\/v2\/posts\/5818"}],"collection":[{"href":"http:\/\/blog.kourin.org\/blog\/index.php?rest_route=\/wp\/v2\/posts"}],"about":[{"href":"http:\/\/blog.kourin.org\/blog\/index.php?rest_route=\/wp\/v2\/types\/post"}],"author":[{"embeddable":true,"href":"http:\/\/blog.kourin.org\/blog\/index.php?rest_route=\/wp\/v2\/users\/1"}],"replies":[{"embeddable":true,"href":"http:\/\/blog.kourin.org\/blog\/index.php?rest_route=%2Fwp%2Fv2%2Fcomments&post=5818"}],"version-history":[{"count":4,"href":"http:\/\/blog.kourin.org\/blog\/index.php?rest_route=\/wp\/v2\/posts\/5818\/revisions"}],"predecessor-version":[{"id":5823,"href":"http:\/\/blog.kourin.org\/blog\/index.php?rest_route=\/wp\/v2\/posts\/5818\/revisions\/5823"}],"wp:attachment":[{"href":"http:\/\/blog.kourin.org\/blog\/index.php?rest_route=%2Fwp%2Fv2%2Fmedia&parent=5818"}],"wp:term":[{"taxonomy":"category","embeddable":true,"href":"http:\/\/blog.kourin.org\/blog\/index.php?rest_route=%2Fwp%2Fv2%2Fcategories&post=5818"},{"taxonomy":"post_tag","embeddable":true,"href":"http:\/\/blog.kourin.org\/blog\/index.php?rest_route=%2Fwp%2Fv2%2Ftags&post=5818"}],"curies":[{"name":"wp","href":"https:\/\/api.w.org\/{rel}","templated":true}]}}