{"id":866,"date":"2012-10-17T02:12:21","date_gmt":"2012-10-17T08:12:21","guid":{"rendered":"http:\/\/blog.supportpro.com\/?p=866"},"modified":"2026-03-27T01:08:58","modified_gmt":"2026-03-27T07:08:58","slug":"reducing-an-lvm-mounted-as-root-partition-partition","status":"publish","type":"post","link":"https:\/\/www.supportpro.com\/blog\/reducing-an-lvm-mounted-as-root-partition-partition\/","title":{"rendered":"How to Safely Reduce Root (\/) LVM Partition Size Using Rescue Mode ?"},"content":{"rendered":"\n<p>Resizing an <strong>LVM partition<\/strong>, especially reducing the <strong>root ( \/ ) partition<\/strong>, requires careful planning because the root filesystem cannot be unmounted while the system is running.<\/p>\n\n\n\n<p>To safely perform this operation, the server must be booted into a <strong>rescue environment<\/strong>, allowing administrators to modify disk partitions without risking data corruption.<\/p>\n\n\n\n<p>This guide explains how to safely reduce an LVM root partition using <strong>SystemRescueCd<\/strong>.<\/p>\n\n\n\n<h2 class=\"wp-block-heading\"><strong>Prerequisites<\/strong><\/h2>\n\n\n\n<p>Before starting:<\/p>\n\n\n\n<ul class=\"wp-block-list\">\n<li>Take a <strong>complete backup<\/strong> of your server.<\/li>\n\n\n\n<li>Ensure console or remote KVM access is available.<\/li>\n\n\n\n<li>Download SystemRescueCd from:<\/li>\n<\/ul>\n\n\n\n<p>\ud83d\udc49 <a href=\"http:\/\/www.sysresccd.org\/Download\">http:\/\/www.sysresccd.org\/Download<\/a><\/p>\n\n\n\n<h2 class=\"wp-block-heading\"><strong>Step 1: Boot the Server in Rescue Mode<\/strong><\/h2>\n\n\n\n<ol class=\"wp-block-list\">\n<li>Burn the <strong>SystemRescueCd ISO<\/strong> to a CD\/DVD<br><strong>or<\/strong><\/li>\n\n\n\n<li>Mount the ISO through:\n<ul class=\"wp-block-list\">\n<li>KVM<\/li>\n\n\n\n<li>IPMI<\/li>\n\n\n\n<li>Remote management console<\/li>\n<\/ul>\n<\/li>\n<\/ol>\n\n\n\n<p>Reboot the server and enter <strong>BIOS\/Boot Menu<\/strong>.<\/p>\n\n\n\n<ul class=\"wp-block-list\">\n<li>Set <strong>CD\/DVD or Virtual Media<\/strong> as the primary boot device.<\/li>\n\n\n\n<li>Save changes and boot into the rescue environment.<\/li>\n\n\n\n<li>Follow on-screen instructions to load SystemRescue.<\/li>\n<\/ul>\n\n\n\n<h2 class=\"wp-block-heading\"><strong>Step 2: Identify the Root LVM Partition<\/strong><\/h2>\n\n\n\n<p>Before resizing, identify which LVM partition is mounted as <code>\/<\/code>.<\/p>\n\n\n\n<p>You can verify this using:<\/p>\n\n\n\n<h3 class=\"wp-block-heading\">Check <code>\/etc\/fstab<\/code><\/h3>\n\n\n\n<pre class=\"wp-block-code\"><code>cat \/etc\/fstab<\/code><\/pre>\n\n\n\n<h3 class=\"wp-block-heading\">Or display logical volumes<\/h3>\n\n\n\n<pre class=\"wp-block-code\"><code>lvdisplay<\/code><\/pre>\n\n\n\n<p>Note the <strong>LV Path<\/strong>, which typically appears as:<\/p>\n\n\n\n<pre class=\"wp-block-code\"><code>\/dev\/&lt;volume-group&gt;\/&lt;logical-volume&gt;<\/code><\/pre>\n\n\n\n<h2 class=\"wp-block-heading\"><strong>Step 3: Activate LVM Volumes<\/strong><\/h2>\n\n\n\n<p>In rescue mode, LVM volumes are inactive by default.<\/p>\n\n\n\n<p>Activate all volume groups:<\/p>\n\n\n\n<pre class=\"wp-block-code\"><code>vgchange -a y<\/code><\/pre>\n\n\n\n<p>This makes the logical volumes accessible for maintenance.<\/p>\n\n\n\n<h2 class=\"wp-block-heading\"><strong>Step 4: Perform Filesystem Check<\/strong><\/h2>\n\n\n\n<p>Always check filesystem integrity before resizing.<\/p>\n\n\n\n<pre class=\"wp-block-code\"><code>e2fsck -f \/dev\/&lt;volume-group&gt;\/&lt;logical-volume&gt;<\/code><\/pre>\n\n\n\n<blockquote class=\"wp-block-quote is-layout-flow wp-block-quote-is-layout-flow\">\n<p>Wait for the check to finish completely before continuing.<\/p>\n<\/blockquote>\n\n\n\n<h2 class=\"wp-block-heading\"><strong>Step 5: Resize the Filesystem<\/strong><\/h2>\n\n\n\n<p>The filesystem must be reduced <strong>before<\/strong> shrinking the logical volume.<\/p>\n\n\n\n<p>Resize it slightly smaller than the final target size (about <strong>85\u201390%<\/strong>).<\/p>\n\n\n\n<pre class=\"wp-block-code\"><code>resize2fs \/dev\/&lt;volume-group&gt;\/&lt;logical-volume&gt; &lt;new-size&gt;<\/code><\/pre>\n\n\n\n<h3 class=\"wp-block-heading\">Example<\/h3>\n\n\n\n<p>To reduce the partition to <strong>300GB<\/strong>, resize filesystem to <strong>270GB<\/strong> first:<\/p>\n\n\n\n<pre class=\"wp-block-code\"><code>resize2fs \/dev\/&lt;volume-group&gt;\/&lt;logical-volume&gt; 270G<\/code><\/pre>\n\n\n\n<h2 class=\"wp-block-heading\"><strong>Step 6: Reduce the LVM Logical Volume<\/strong><\/h2>\n\n\n\n<p>After shrinking the filesystem, reduce the logical volume:<\/p>\n\n\n\n<pre class=\"wp-block-code\"><code>lvreduce -L 300G \/dev\/&lt;volume-group&gt;\/&lt;logical-volume&gt;<\/code><\/pre>\n\n\n\n<p>Confirm when prompted.<\/p>\n\n\n\n<h2 class=\"wp-block-heading\"><strong>Step 7: Verify the Changes<\/strong><\/h2>\n\n\n\n<p>Verify the updated LVM size:<\/p>\n\n\n\n<pre class=\"wp-block-code\"><code>lvdisplay<\/code><\/pre>\n\n\n\n<p>Ensure the logical volume reflects the new partition size correctly.<\/p>\n\n\n\n<h2 class=\"wp-block-heading\"><strong>Final Step: Reboot the Server<\/strong><\/h2>\n\n\n\n<p>Exit rescue mode and reboot normally:<\/p>\n\n\n\n<pre class=\"wp-block-code\"><code>reboot<\/code><\/pre>\n\n\n\n<p>The system should now boot with the resized root partition.<\/p>\n\n\n\n<h2 class=\"wp-block-heading\"><strong>Important Best Practices<\/strong><\/h2>\n\n\n\n<ul class=\"wp-block-list\">\n<li>Always <strong>backup data<\/strong> before modifying partitions.<\/li>\n\n\n\n<li>Never reduce LVM size before shrinking the filesystem.<\/li>\n\n\n\n<li>Perform operations only from <strong>rescue mode<\/strong>.<\/li>\n\n\n\n<li>Double-check volume names to avoid data loss.<\/li>\n<\/ul>\n\n\n\n<h2 class=\"wp-block-heading\"><strong>Conclusion<\/strong><\/h2>\n\n\n\n<p>Reducing an LVM root partition requires booting into rescue mode because the root filesystem cannot be unmounted during normal operation. By activating LVM volumes, checking the filesystem, resizing safely, and then reducing the logical volume, administrators can resize partitions without damaging system data.<\/p>\n\n\n\n<h3 class=\"wp-block-heading\">Need Assistance?<\/h3>\n\n\n\n<p>If you require any help during this process, contact the <a href=\"https:\/\/www.supportpro.com\/requestquote.php\">SupportPRO Server Admin<\/a>.<\/p>\n\n\n\n<p class=\"has-text-align-center\"><!--HubSpot Call-to-Action Code --><!-- [if lte IE 8]><\/p>\n\n\n\n\n<p><![endif]--><!-- end HubSpot Call-to-Action Code --><\/p>\n\n\n\n<div class=\"wp-block-media-text alignwide has-media-on-the-right is-stacked-on-mobile is-vertically-aligned-center has-white-background-color has-background\"><div class=\"wp-block-media-text__content\">\n<p class=\"has-large-font-size\">Partner with <strong>SupportPRO<\/strong> for 24\/7 proactive cloud support that keeps your business secure, scalable, and ahead of the curve.<\/p>\n\n\n\n<!--HubSpot Call-to-Action Code --><span class=\"hs-cta-wrapper\" id=\"hs-cta-wrapper-3350a795-db50-482f-9911-301930d1b1be\"><span class=\"hs-cta-node hs-cta-3350a795-db50-482f-9911-301930d1b1be\" id=\"hs-cta-3350a795-db50-482f-9911-301930d1b1be\"><!--[if lte IE 8]><div id=\"hs-cta-ie-element\"><\/div><![endif]--><a href=\"https:\/\/cta-redirect.hubspot.com\/cta\/redirect\/2725694\/3350a795-db50-482f-9911-301930d1b1be\" ><img decoding=\"async\" class=\"hs-cta-img\" id=\"hs-cta-img-3350a795-db50-482f-9911-301930d1b1be\" style=\"border-width:0px;\" src=\"https:\/\/no-cache.hubspot.com\/cta\/default\/2725694\/3350a795-db50-482f-9911-301930d1b1be.png\"  alt=\"Contact Us today!\"\/><\/a><\/span><script charset=\"utf-8\" src=\"https:\/\/js.hscta.net\/cta\/current.js\"><\/script><script type=\"text\/javascript\"> hbspt.cta.load(2725694, '3350a795-db50-482f-9911-301930d1b1be', {\"useNewLoader\":\"true\",\"region\":\"na1\"}); <\/script><\/span><!-- end HubSpot Call-to-Action Code -->\n<\/div><figure class=\"wp-block-media-text__media\"><img fetchpriority=\"high\" decoding=\"async\" width=\"904\" height=\"931\" src=\"https:\/\/www.supportpro.com\/blog\/wp-content\/uploads\/2022\/09\/Free-server-checkup.png\" alt=\"guy server checkup\" class=\"wp-image-12943 size-full\" srcset=\"https:\/\/www.supportpro.com\/blog\/wp-content\/uploads\/2022\/09\/Free-server-checkup.png 904w, https:\/\/www.supportpro.com\/blog\/wp-content\/uploads\/2022\/09\/Free-server-checkup-291x300.png 291w, https:\/\/www.supportpro.com\/blog\/wp-content\/uploads\/2022\/09\/Free-server-checkup-768x791.png 768w, https:\/\/www.supportpro.com\/blog\/wp-content\/uploads\/2022\/09\/Free-server-checkup-585x602.png 585w\" sizes=\"(max-width: 904px) 100vw, 904px\" \/><\/figure><\/div>\n","protected":false},"excerpt":{"rendered":"<p>Resizing an LVM partition, especially reducing the root ( \/ ) partition, requires careful planning because the root filesystem cannot be unmounted while the system is running. To safely perform&hellip;<\/p>\n","protected":false},"author":4,"featured_media":0,"comment_status":"open","ping_status":"open","sticky":false,"template":"","format":"standard","meta":{"_lmt_disableupdate":"","_lmt_disable":"","footnotes":""},"categories":[1],"tags":[],"class_list":["post-866","post","type-post","status-publish","format-standard","hentry","category-miscellaneous"],"aioseo_notices":[],"_links":{"self":[{"href":"https:\/\/www.supportpro.com\/blog\/wp-json\/wp\/v2\/posts\/866","targetHints":{"allow":["GET"]}}],"collection":[{"href":"https:\/\/www.supportpro.com\/blog\/wp-json\/wp\/v2\/posts"}],"about":[{"href":"https:\/\/www.supportpro.com\/blog\/wp-json\/wp\/v2\/types\/post"}],"author":[{"embeddable":true,"href":"https:\/\/www.supportpro.com\/blog\/wp-json\/wp\/v2\/users\/4"}],"replies":[{"embeddable":true,"href":"https:\/\/www.supportpro.com\/blog\/wp-json\/wp\/v2\/comments?post=866"}],"version-history":[{"count":16,"href":"https:\/\/www.supportpro.com\/blog\/wp-json\/wp\/v2\/posts\/866\/revisions"}],"predecessor-version":[{"id":16765,"href":"https:\/\/www.supportpro.com\/blog\/wp-json\/wp\/v2\/posts\/866\/revisions\/16765"}],"wp:attachment":[{"href":"https:\/\/www.supportpro.com\/blog\/wp-json\/wp\/v2\/media?parent=866"}],"wp:term":[{"taxonomy":"category","embeddable":true,"href":"https:\/\/www.supportpro.com\/blog\/wp-json\/wp\/v2\/categories?post=866"},{"taxonomy":"post_tag","embeddable":true,"href":"https:\/\/www.supportpro.com\/blog\/wp-json\/wp\/v2\/tags?post=866"}],"curies":[{"name":"wp","href":"https:\/\/api.w.org\/{rel}","templated":true}]}}