{"id":1613,"date":"2024-07-18T13:50:11","date_gmt":"2024-07-18T13:50:11","guid":{"rendered":"\/blog\/?p=1613"},"modified":"2024-07-18T13:50:12","modified_gmt":"2024-07-18T13:50:12","slug":"create-vgslvsfs-for-single-disk-vg-to-fs-input","status":"publish","type":"post","link":"\/blog\/index.php\/create-vgslvsfs-for-single-disk-vg-to-fs-input\/","title":{"rendered":"create vgs,lvs,fs for single disk vg-to fs input"},"content":{"rendered":"\n<p>This is for when you have a 1to1 relation from disk to filesystem.<\/p>\n\n\n\n<p>\/u01  sdc<br>\/u02 sdd<br>\/u03 sde<br>\/u04  sdf<br>\/u05 sdg<br>\/u06  sdh<br>\/u07 sdi<\/p>\n\n\n\n<p><code>cat x | sed 's\/\\\/\/\/g' | awk '{ print \"vgcreate \"$1\"_vg \/dev\/\"$2 }'<br>cat x | sed 's\/\\\/\/\/g' | awk '{ print \"lvcreate -l 100%FREE -n \"$1\"_lv \"$1\"_vg\" }'<br>cat x | sed 's\/\\\/\/\/g' | awk '{ print \"mkfs.xfs \/dev\/\"$1\"_vg\/\"$1\"_lv\" }'<br>cat x | sed 's\/\\\/\/\/g' | awk '{ print \"\/dev\/\"$1\"_vg\/\"$1\"_lv \/\"$1\" xfs defaults 0 0\" }'<br>cat x | sed 's\/\\\/\/\/g' | awk '{ print \"mkdir \/\"$1 }'<\/code><\/p>\n","protected":false},"excerpt":{"rendered":"<p>This is for when you have a 1to1 relation from disk to filesystem. \/u01 sdc\/u02 sdd\/u03 sde\/u04 sdf\/u05 sdg\/u06 sdh\/u07 sdi cat x | sed &#8216;s\/\\\/\/\/g&#8217; | awk &#8216;{ print &#8220;vgcreate &#8220;$1&#8243;_vg \/dev\/&#8221;$2 }&#8217;cat x | sed &#8216;s\/\\\/\/\/g&#8217; | awk &#8216;{ print &#8220;lvcreate -l 100%FREE -n &#8220;$1&#8243;_lv &#8220;$1&#8243;_vg&#8221; }&#8217;cat x | sed &#8216;s\/\\\/\/\/g&#8217; | awk [&hellip;]<\/p>\n","protected":false},"author":1,"featured_media":0,"comment_status":"closed","ping_status":"open","sticky":false,"template":"","format":"standard","meta":{"footnotes":""},"categories":[1],"tags":[],"class_list":["post-1613","post","type-post","status-publish","format-standard","hentry","category-uncategorized"],"_links":{"self":[{"href":"\/blog\/index.php\/wp-json\/wp\/v2\/posts\/1613","targetHints":{"allow":["GET"]}}],"collection":[{"href":"\/blog\/index.php\/wp-json\/wp\/v2\/posts"}],"about":[{"href":"\/blog\/index.php\/wp-json\/wp\/v2\/types\/post"}],"author":[{"embeddable":true,"href":"\/blog\/index.php\/wp-json\/wp\/v2\/users\/1"}],"replies":[{"embeddable":true,"href":"\/blog\/index.php\/wp-json\/wp\/v2\/comments?post=1613"}],"version-history":[{"count":1,"href":"\/blog\/index.php\/wp-json\/wp\/v2\/posts\/1613\/revisions"}],"predecessor-version":[{"id":1614,"href":"\/blog\/index.php\/wp-json\/wp\/v2\/posts\/1613\/revisions\/1614"}],"wp:attachment":[{"href":"\/blog\/index.php\/wp-json\/wp\/v2\/media?parent=1613"}],"wp:term":[{"taxonomy":"category","embeddable":true,"href":"\/blog\/index.php\/wp-json\/wp\/v2\/categories?post=1613"},{"taxonomy":"post_tag","embeddable":true,"href":"\/blog\/index.php\/wp-json\/wp\/v2\/tags?post=1613"}],"curies":[{"name":"wp","href":"https:\/\/api.w.org\/{rel}","templated":true}]}}