{"id":1829,"date":"2020-10-05T12:28:44","date_gmt":"2020-10-05T19:28:44","guid":{"rendered":"https:\/\/jim-zimmerman.com\/?p=1829"},"modified":"2020-10-05T12:28:44","modified_gmt":"2020-10-05T19:28:44","slug":"howto-extend-an-xfs-partition-in-aws","status":"publish","type":"post","link":"https:\/\/jim-zimmerman.com\/?p=1829","title":{"rendered":"Howto extend an XFS partition in AWS."},"content":{"rendered":"<p>Login to the EC2 Console.<br \/>\nGo down to Elastic Block Store.<br \/>\nSelect Volumes.<br \/>\nSelect the volume<br \/>\nClick Actions and then Modify Volume.<br \/>\nEnter the new size and click Modify.<\/p>\n<p>At this point, you will need to extend your volumes and partitions.<\/p>\n<p>In this case, I was not using LVM, so it was a pretty simple process.<\/p>\n<p>Check to see which partition you want to extend:<\/p>\n<blockquote><p>$ df -hT<br \/>\n\/dev\/xvda1     xfs        8G  8.7G   8G  97% \/<\/p><\/blockquote>\n<p>Determine the block device and the partition number:<\/p>\n<blockquote><p>$ lsblk<br \/>\nNAME    MAJ:MIN RM SIZE RO TYPE MOUNTPOINT<br \/>\nxvda    202:0    0  8G  0 disk<br \/>\n\u00e2\u201d\u201d\u00e2\u201d\u20acxvda1 202:1    0  8G  0 part \/<\/p><\/blockquote>\n<p>Expand to partition to all the available unallocated storage on the disk:<\/p>\n<blockquote><p>$ sudo growpart \/dev\/xvda 1<\/p><\/blockquote>\n<p>Verify to see if the partition has been extended.<\/p>\n<blockquote><p>$ lsblk<br \/>\nNAME    MAJ:MIN RM SIZE RO TYPE MOUNTPOINT<br \/>\nxvda    202:0    0  30G  0 disk<br \/>\n\u00e2\u201d\u201d\u00e2\u201d\u20acxvda1 202:1    0  30G  0 part \/<\/p><\/blockquote>\n<p>Extend the filesystem on the partition:<\/p>\n<blockquote><p>$ sudo xfs_growfs -d \/<\/p><\/blockquote>\n<p>Verify:<\/p>\n<blockquote><p>$ df -h<br \/>\nFilesystem     Type      Size  Used Avail Use% Mounted on<br \/>\n\/dev\/xvda1     xfs        30G  9.1G   21G  31% \/<\/p><\/blockquote>\n","protected":false},"excerpt":{"rendered":"<p>Login to the EC2 Console. Go down to Elastic Block Store. Select Volumes. Select the volume Click Actions and then Modify Volume. Enter the new size and click Modify. At this point, you will need to extend your volumes and partitions. In this case, I was not using LVM, so it was a pretty simple [&#038;hellip<\/p>\n","protected":false},"author":2,"featured_media":0,"comment_status":"open","ping_status":"open","sticky":false,"template":"","format":"standard","meta":{"footnotes":""},"categories":[3],"tags":[498,499],"class_list":["post-1829","post","type-post","status-publish","format-standard","hentry","category-documentation","tag-aws","tag-xfs"],"share_on_mastodon":{"url":"","error":""},"_links":{"self":[{"href":"https:\/\/jim-zimmerman.com\/index.php?rest_route=\/wp\/v2\/posts\/1829","targetHints":{"allow":["GET"]}}],"collection":[{"href":"https:\/\/jim-zimmerman.com\/index.php?rest_route=\/wp\/v2\/posts"}],"about":[{"href":"https:\/\/jim-zimmerman.com\/index.php?rest_route=\/wp\/v2\/types\/post"}],"author":[{"embeddable":true,"href":"https:\/\/jim-zimmerman.com\/index.php?rest_route=\/wp\/v2\/users\/2"}],"replies":[{"embeddable":true,"href":"https:\/\/jim-zimmerman.com\/index.php?rest_route=%2Fwp%2Fv2%2Fcomments&post=1829"}],"version-history":[{"count":2,"href":"https:\/\/jim-zimmerman.com\/index.php?rest_route=\/wp\/v2\/posts\/1829\/revisions"}],"predecessor-version":[{"id":1831,"href":"https:\/\/jim-zimmerman.com\/index.php?rest_route=\/wp\/v2\/posts\/1829\/revisions\/1831"}],"wp:attachment":[{"href":"https:\/\/jim-zimmerman.com\/index.php?rest_route=%2Fwp%2Fv2%2Fmedia&parent=1829"}],"wp:term":[{"taxonomy":"category","embeddable":true,"href":"https:\/\/jim-zimmerman.com\/index.php?rest_route=%2Fwp%2Fv2%2Fcategories&post=1829"},{"taxonomy":"post_tag","embeddable":true,"href":"https:\/\/jim-zimmerman.com\/index.php?rest_route=%2Fwp%2Fv2%2Ftags&post=1829"}],"curies":[{"name":"wp","href":"https:\/\/api.w.org\/{rel}","templated":true}]}}