{"id":206,"date":"2011-07-03T13:10:21","date_gmt":"2011-07-03T01:10:21","guid":{"rendered":"http:\/\/mdickinson.dnsalias.org\/php\/wordpress\/?p=206"},"modified":"2011-07-03T13:10:21","modified_gmt":"2011-07-03T01:10:21","slug":"lvm-note-for-my-reference","status":"publish","type":"post","link":"https:\/\/mdickinson.dyndns.org\/php\/wordpress\/?p=206","title":{"rendered":"lvm note for my reference"},"content":{"rendered":"<p>Still playing with iSCSI, so needed to enlarge the logical volume now I am actually using it.<\/p>\n<p>This post is just for my reference as for years I have been running resize2fs manually after resizing an LV, but I noticed in the man page the <b>-r<\/b> option will do it automatically now. So posted for my reference to try to override my habit of doing all the steps individually.<\/p>\n<pre>\r\n[root@falcon ~]# lvextend --size +10G -r \/dev\/VolGroup00\/iSCSI01\r\nfsck from util-linux 2.19.1\r\n\/dev\/mapper\/VolGroup00-iSCSI01: 17\/983040 files (0.0% non-contiguous), 104105\/3932160 blocks\r\n  Extending logical volume iSCSI01 to 25.00 GiB\r\n  Logical volume iSCSI01 successfully resized\r\nresize2fs 1.41.14 (22-Dec-2010)\r\nResizing the filesystem on \/dev\/mapper\/VolGroup00-iSCSI01 to 6553600 (4k) blocks.\r\nThe filesystem on \/dev\/mapper\/VolGroup00-iSCSI01 is now 6553600 blocks long.\r\n<\/pre>\n<p>Much easier than having to run resize2fs manually. Of course it always helps to know how to do it manually as some of the stuff I muck about with requires a lot of fiddling to fix once I break it :-).<\/p>\n<p>I guess it may also manage shrinking an LV automatically as well; but as I generally only shrink a LV if I&#8217;m about to do something nasty with the PV(s) it&#8217;s hosted on I&#8217;ll keep doing that manually.<\/p>\n","protected":false},"excerpt":{"rendered":"<p>Still playing with iSCSI, so needed to enlarge the logical volume now I am actually using it. This post is just for my reference as for years I have been running resize2fs manually after resizing an LV, but I noticed &hellip; <a href=\"https:\/\/mdickinson.dyndns.org\/php\/wordpress\/?p=206\">Continue reading <span class=\"meta-nav\">&rarr;<\/span><\/a><\/p>\n","protected":false},"author":2,"featured_media":0,"comment_status":"open","ping_status":"open","sticky":false,"template":"","format":"standard","meta":{"footnotes":""},"categories":[5],"tags":[],"class_list":["post-206","post","type-post","status-publish","format-standard","hentry","category-my-nux-thoughts-and-notes"],"_links":{"self":[{"href":"https:\/\/mdickinson.dyndns.org\/php\/wordpress\/index.php?rest_route=\/wp\/v2\/posts\/206","targetHints":{"allow":["GET"]}}],"collection":[{"href":"https:\/\/mdickinson.dyndns.org\/php\/wordpress\/index.php?rest_route=\/wp\/v2\/posts"}],"about":[{"href":"https:\/\/mdickinson.dyndns.org\/php\/wordpress\/index.php?rest_route=\/wp\/v2\/types\/post"}],"author":[{"embeddable":true,"href":"https:\/\/mdickinson.dyndns.org\/php\/wordpress\/index.php?rest_route=\/wp\/v2\/users\/2"}],"replies":[{"embeddable":true,"href":"https:\/\/mdickinson.dyndns.org\/php\/wordpress\/index.php?rest_route=%2Fwp%2Fv2%2Fcomments&post=206"}],"version-history":[{"count":1,"href":"https:\/\/mdickinson.dyndns.org\/php\/wordpress\/index.php?rest_route=\/wp\/v2\/posts\/206\/revisions"}],"predecessor-version":[{"id":207,"href":"https:\/\/mdickinson.dyndns.org\/php\/wordpress\/index.php?rest_route=\/wp\/v2\/posts\/206\/revisions\/207"}],"wp:attachment":[{"href":"https:\/\/mdickinson.dyndns.org\/php\/wordpress\/index.php?rest_route=%2Fwp%2Fv2%2Fmedia&parent=206"}],"wp:term":[{"taxonomy":"category","embeddable":true,"href":"https:\/\/mdickinson.dyndns.org\/php\/wordpress\/index.php?rest_route=%2Fwp%2Fv2%2Fcategories&post=206"},{"taxonomy":"post_tag","embeddable":true,"href":"https:\/\/mdickinson.dyndns.org\/php\/wordpress\/index.php?rest_route=%2Fwp%2Fv2%2Ftags&post=206"}],"curies":[{"name":"wp","href":"https:\/\/api.w.org\/{rel}","templated":true}]}}