Groups | Search | Server Info | Keyboard shortcuts | Login | Register [http] [https] [nntp] [nntps]
Groups > linux.debian.user > #274087 > unrolled thread
| Started by | Jonathan Wiebe <jonathan.b.wiebe@proton.me> |
|---|---|
| First post | 2024-10-27 06:10 +0100 |
| Last post | 2024-10-28 13:40 +0100 |
| Articles | 11 — 6 participants |
Back to article view | Back to linux.debian.user
Trouble with lvreduce on Debian 12 Jonathan Wiebe <jonathan.b.wiebe@proton.me> - 2024-10-27 06:10 +0100
Re: Trouble with lvreduce and / read-only Geert Stappers <stappers@stappers.nl> - 2024-10-27 10:30 +0100
Re: Trouble with lvreduce and / read-only Dan Ritter <dsr@randomstring.org> - 2024-10-27 15:10 +0100
Re: Trouble with lvreduce and / read-only gene heskett <gheskett@shentel.net> - 2024-10-27 15:30 +0100
Re: Trouble with lvreduce and / read-only Dan Ritter <dsr@randomstring.org> - 2024-10-27 16:50 +0100
Re: Trouble with lvreduce and / read-only Jonathan Wiebe <jonathan.b.wiebe@proton.me> - 2024-10-27 19:20 +0100
Re: Trouble with lvreduce and / read-only Geert Stappers <stappers@stappers.nl> - 2024-10-27 19:30 +0100
Re: Trouble with lvreduce and / read-only Jonathan Wiebe <jonathan.b.wiebe@proton.me> - 2024-10-27 19:50 +0100
Re: Trouble with lvreduce and / read-only Geert Stappers <stappers@stappers.nl> - 2024-10-27 22:30 +0100
Re: Trouble with lvreduce and / read-only Andy Smith <andy@strugglers.net> - 2024-10-28 02:50 +0100
Re: Trouble with lvreduce on Debian 12 Anders Andersson <pipatron@gmail.com> - 2024-10-28 13:40 +0100
| From | Jonathan Wiebe <jonathan.b.wiebe@proton.me> |
|---|---|
| Date | 2024-10-27 06:10 +0100 |
| Subject | Trouble with lvreduce on Debian 12 |
| Message-ID | <JC3Hj-4v1x-1@gated-at.bofh.it> |
[Multipart message — attachments visible in raw view] — view raw
I ran into an issue with my root partition being too small. My plan was to reduce the size of my home partition and increase the size of my root partition. Here is what I have done: First, I rebooted in single user mode. Then I did the following: # mount / -rw -o remount # amount /home umount: /home: not mounted. # fsck -f /dev/mapper/debian --vg-home fsck from util-linux 2.38.1 e2fsck 1.47.0 (5-Feb-2023) Pass 1: Checking inodes, blocks, and sizes Inode 8803015 extent tree (at level 1) could be shorter. Optimize<y>? yes Inode 8919578 extent tree (at level 1) could be shorter. Optimize<y>? yes Inode 9328852 extent tree (at level 1) could be shorter. Optimize<y>? yes Inode 11273442 extent tree (at level 1) could be shorter. Optimize<y>? yes Pass 1E: Optimizing extent trees Pass 2: Checking directory structure Pass 3: Checking directory connectivity Pass 4: Checking reference counts Pass 5: Checking group summary information /dev/mapper/debian--vg-home: ***** FILE SYSTEM WAS MODIFIED ***** /dev/mapper/debian--vg-home: 329100/29302784 files (1.8% non-contiguous), 12560416/117196800 blocks # fsck -f /dev/mapper/debian--vg-home fsck from util-linux 2.38.1 e2fsck 1.47.0 (5-Feb-2023) Pass 1: Checking inodes, blocks, and sizes Pass 2: Checking directory structure Pass 3: Checking directory connectivity Pass 4: Checking reference counts Pass 5: Checking group summary information /dev/mapper/debian--vg-home: 329100/29302784 files (1.8% non-contiguous), 12560416/117196800 blocks # resize2fs /dev/mapper/debian--vg-home 400G resize2fs 1.47.0 (5-Feb-2023) Resizing the filesystem on /dev/mapper/debian--vg-home to 104857600 (4k) blocks. The filesystem on /dev/mapper/debian--vg-home is now 104857600 (4k) blocks long. # lvreduce -L -39G /dev/mapper/debian--vg-home WARNING: Reducing active logical volume to 408.07 GiB. THIS MAY DESTROY YOUR DATA (filesystem etc.) Do you really want to reduce debian--vg/home? [y/n]: y Size of logical volume debian--vg/home changed from 447.07 GiB (114450 extents) to 408.07 GiB (104466 extents). Logical volume debian--vg/home successfully resized. This is where I am stalled. The prompt has not come back and I have been waiting about 10.5 hours. Is it normal for this to take this long? Should I just be patient? Or has something gone wrong? I am not sure what to do at this point. Thanks in advance for your assistance. Jonathan -- Jonathan Wiebe Our passions are there to drive us to act, not to be the seasoning of our emotional stew. Sent from Proton Mail Android
[toc] | [next] | [standalone]
| From | Geert Stappers <stappers@stappers.nl> |
|---|---|
| Date | 2024-10-27 10:30 +0100 |
| Subject | Re: Trouble with lvreduce and / read-only |
| Message-ID | <JC7KV-4y2R-9@gated-at.bofh.it> |
| In reply to | #274087 |
On Sun, Oct 27, 2024 at 05:04:19AM +0000, Jonathan Wiebe wrote:
> I ran into an issue with my root partition being too small. My plan
> was to reduce the size of my home partition and increase the size of
> my root partition. Here is what I have done:
>
> First, I rebooted in single user mode.
> Then I did the following:
> # mount / -rw -o remount
I understand the '-o remount', not the '-rw'.
And I think "that command might be the culprit"
> # amount /home
Assuming an ugly typo.
> umount: /home: not mounted.
I think: That is strange.
And wonder: Why was /home not mounted?
> # fsck -f /dev/mapper/debian --vg-home
> fsck from util-linux 2.38.1
> e2fsck 1.47.0 (5-Feb-2023)
> Pass 1: Checking inodes, blocks, and sizes
> Inode 8803015 extent tree (at level 1) could be shorter. Optimize<y>? yes
> Inode 8919578 extent tree (at level 1) could be shorter. Optimize<y>? yes
> Inode 9328852 extent tree (at level 1) could be shorter. Optimize<y>? yes
> Inode 11273442 extent tree (at level 1) could be shorter. Optimize<y>? yes
> Pass 1E: Optimizing extent trees
> Pass 2: Checking directory structure
> Pass 3: Checking directory connectivity
> Pass 4: Checking reference counts
> Pass 5: Checking group summary information
>
> /dev/mapper/debian--vg-home: ***** FILE SYSTEM WAS MODIFIED *****
> /dev/mapper/debian--vg-home: 329100/29302784 files (1.8% non-contiguous), 12560416/117196800 blocks
Acknowledge on "/home had some burses"
> # fsck -f /dev/mapper/debian--vg-home
> fsck from util-linux 2.38.1
> e2fsck 1.47.0 (5-Feb-2023)
> Pass 1: Checking inodes, blocks, and sizes
> Pass 2: Checking directory structure
> Pass 3: Checking directory connectivity
> Pass 4: Checking reference counts
> Pass 5: Checking group summary information
> /dev/mapper/debian--vg-home: 329100/29302784 files (1.8% non-contiguous), 12560416/117196800 blocks
Acknowledge on "fsck is happy"
> # resize2fs /dev/mapper/debian--vg-home 400G
> resize2fs 1.47.0 (5-Feb-2023)
> Resizing the filesystem on /dev/mapper/debian--vg-home to 104857600 (4k) blocks.
> The filesystem on /dev/mapper/debian--vg-home is now 104857600 (4k) blocks long.
Assuming something as "home was and is 400G"
> # lvreduce -L -39G /dev/mapper/debian--vg-home
> WARNING: Reducing active logical volume to 408.07 GiB.
> THIS MAY DESTROY YOUR DATA (filesystem etc.)
> Do you really want to reduce debian--vg/home? [y/n]: y
> Size of logical volume debian--vg/home changed from 447.07 GiB (114450 extents) to 408.07 GiB (104466 extents).
> Logical volume debian--vg/home successfully resized.
Acknowledge
NOTE: Only the logical volume was resized. [1]
> This is where I am stalled. The prompt has not come back and I have
> been waiting about 10.5 hours. Is it normal for this to take this
> long? Should I just be patient? Or has something gone wrong? I am not
> sure what to do at this point.
Think "have shot my self in the foot", "learnt much today".
Even on slow hardware is ten hour response time an indicator for
"something is wrong".
My guess is root filesystem mounted readonly being the culprit.
> Thanks in advance for your assistance.
Oh, that is cheap. I do read it as:
You must spend time on my problem and report back to me!
Do not expect any follow-up from me, I have already said "Thanks"!!!
Input for follow-up:
* Powercycle the system.
* Continue with reaching the intended goal
* complete resizing of /home [1]
* resize / [1]
> Jonathan
Groeten
Geert Stappers
[1] Be aware of the command `resize2fs` and the flag `--resizefs` for
the command `lvresize`.
--
Silence is hard to parse
[toc] | [prev] | [next] | [standalone]
| From | Dan Ritter <dsr@randomstring.org> |
|---|---|
| Date | 2024-10-27 15:10 +0100 |
| Subject | Re: Trouble with lvreduce and / read-only |
| Message-ID | <JCc7T-4AYx-13@gated-at.bofh.it> |
| In reply to | #274090 |
Geert Stappers wrote: > On Sun, Oct 27, 2024 at 05:04:19AM +0000, Jonathan Wiebe wrote: > > I ran into an issue with my root partition being too small. My plan > > was to reduce the size of my home partition and increase the size of > > my root partition. Here is what I have done: > > > > First, I rebooted in single user mode. > > Then I did the following: > > # mount / -rw -o remount > > I understand the '-o remount', not the '-rw'. > And I think "that command might be the culprit" It should be mount / -o remount,rw -dsr-
[toc] | [prev] | [next] | [standalone]
| From | gene heskett <gheskett@shentel.net> |
|---|---|
| Date | 2024-10-27 15:30 +0100 |
| Subject | Re: Trouble with lvreduce and / read-only |
| Message-ID | <JCcrf-4B4F-5@gated-at.bofh.it> |
| In reply to | #274092 |
On 10/27/24 10:03, Dan Ritter wrote: > Geert Stappers wrote: >> On Sun, Oct 27, 2024 at 05:04:19AM +0000, Jonathan Wiebe wrote: >>> I ran into an issue with my root partition being too small. My plan >>> was to reduce the size of my home partition and increase the size of >>> my root partition. Here is what I have done: >>> >>> First, I rebooted in single user mode. >>> Then I did the following: >>> # mount / -rw -o remount >> >> I understand the '-o remount', not the '-rw'. >> And I think "that command might be the culprit" > > > It should be > > mount / -o remount,rw No, that is an endless loop Dan. The idea is to remount a file system with errors as read-only in order to prevent further damage from rw operations. From there, you can copy to a new location, like a new drive, rescueing the data that does survive. That drive made a mistake and that is sad. But limit the losses by putting in a new, bigger drive and remake the system to use it in place of the drive that upchucked. > > -dsr- > > . Cheers, Gene Heskett, CET. -- "There are four boxes to be used in defense of liberty: soap, ballot, jury, and ammo. Please use in that order." -Ed Howdershelt (Author, 1940) If we desire respect for the law, we must first make the law respectable. - Louis D. Brandeis
[toc] | [prev] | [next] | [standalone]
| From | Dan Ritter <dsr@randomstring.org> |
|---|---|
| Date | 2024-10-27 16:50 +0100 |
| Subject | Re: Trouble with lvreduce and / read-only |
| Message-ID | <JCdGF-4BJh-3@gated-at.bofh.it> |
| In reply to | #274093 |
gene heskett wrote: > On 10/27/24 10:03, Dan Ritter wrote: > > Geert Stappers wrote: > > > On Sun, Oct 27, 2024 at 05:04:19AM +0000, Jonathan Wiebe wrote: > > > > I ran into an issue with my root partition being too small. My plan > > > > was to reduce the size of my home partition and increase the size of > > > > my root partition. Here is what I have done: > > > > > > > > First, I rebooted in single user mode. > > > > Then I did the following: > > > > # mount / -rw -o remount > > > > > > I understand the '-o remount', not the '-rw'. > > > And I think "that command might be the culprit" > > > > > > It should be > > > > mount / -o remount,rw > No, that is an endless loop Dan. The idea is to remount a file system with > errors as read-only in order to prevent further damage from rw operations. > From there, you can copy to a new location, like a new drive, rescueing the > data that does survive. That drive made a mistake and that is sad. But limit > the losses by putting in a new, bigger drive and remake the system to use it > in place of the drive that upchucked. Then you want mount / -o remount,ro Neither one of these causes an endless loop. Specifying ro or rw without remount won't work on an already mounted filesystem. -dsr-
[toc] | [prev] | [next] | [standalone]
| From | Jonathan Wiebe <jonathan.b.wiebe@proton.me> |
|---|---|
| Date | 2024-10-27 19:20 +0100 |
| Subject | Re: Trouble with lvreduce and / read-only |
| Message-ID | <JCg1P-4Dip-11@gated-at.bofh.it> |
| In reply to | #274090 |
[Multipart message — attachments visible in raw view] — view raw
-- Jonathan Wiebe Our passions are there to drive us to act, not to be the seasoning of our emotional stew. Sent with Proton Mail secure email. On Sunday, October 27th, 2024 at 02:28, Geert Stappers <stappers@stappers.nl> wrote: > On Sun, Oct 27, 2024 at 05:04:19AM +0000, Jonathan Wiebe wrote: > > > I ran into an issue with my root partition being too small. My plan > > was to reduce the size of my home partition and increase the size of > > my root partition. Here is what I have done: > > > > First, I rebooted in single user mode. > > Then I did the following: > > # mount / -rw -o remount > > > I understand the '-o remount', not the '-rw'. > And I think "that command might be the culprit" > > > # amount /home > > > Assuming an ugly typo. > > > umount: /home: not mounted. > > > I think: That is strange. > And wonder: Why was /home not mounted? > > > # fsck -f /dev/mapper/debian --vg-home > > fsck from util-linux 2.38.1 > > e2fsck 1.47.0 (5-Feb-2023) > > Pass 1: Checking inodes, blocks, and sizes > > Inode 8803015 extent tree (at level 1) could be shorter. Optimize<y>? yes > > Inode 8919578 extent tree (at level 1) could be shorter. Optimize<y>? yes > > Inode 9328852 extent tree (at level 1) could be shorter. Optimize<y>? yes > > Inode 11273442 extent tree (at level 1) could be shorter. Optimize<y>? yes > > Pass 1E: Optimizing extent trees > > Pass 2: Checking directory structure > > Pass 3: Checking directory connectivity > > Pass 4: Checking reference counts > > Pass 5: Checking group summary information > > > > /dev/mapper/debian--vg-home: ***** FILE SYSTEM WAS MODIFIED ***** > > /dev/mapper/debian--vg-home: 329100/29302784 files (1.8% non-contiguous), 12560416/117196800 blocks > > > Acknowledge on "/home had some burses" > > > # fsck -f /dev/mapper/debian--vg-home > > fsck from util-linux 2.38.1 > > e2fsck 1.47.0 (5-Feb-2023) > > Pass 1: Checking inodes, blocks, and sizes > > Pass 2: Checking directory structure > > Pass 3: Checking directory connectivity > > Pass 4: Checking reference counts > > Pass 5: Checking group summary information > > /dev/mapper/debian--vg-home: 329100/29302784 files (1.8% non-contiguous), 12560416/117196800 blocks > > > Acknowledge on "fsck is happy" > > > # resize2fs /dev/mapper/debian--vg-home 400G > > resize2fs 1.47.0 (5-Feb-2023) > > Resizing the filesystem on /dev/mapper/debian--vg-home to 104857600 (4k) blocks. > > The filesystem on /dev/mapper/debian--vg-home is now 104857600 (4k) blocks long. > > > Assuming something as "home was and is 400G" > > > # lvreduce -L -39G /dev/mapper/debian--vg-home > > WARNING: Reducing active logical volume to 408.07 GiB. > > THIS MAY DESTROY YOUR DATA (filesystem etc.) > > Do you really want to reduce debian--vg/home? [y/n]: y > > Size of logical volume debian--vg/home changed from 447.07 GiB (114450 extents) to 408.07 GiB (104466 extents). > > Logical volume debian--vg/home successfully resized. > > > Acknowledge > NOTE: Only the logical volume was resized. [1] > > > This is where I am stalled. The prompt has not come back and I have > > been waiting about 10.5 hours. Is it normal for this to take this > > long? Should I just be patient? Or has something gone wrong? I am not > > sure what to do at this point. > > > Think "have shot my self in the foot", "learnt much today". > > Even on slow hardware is ten hour response time an indicator for > "something is wrong". > > My guess is root filesystem mounted readonly being the culprit. > > > > Thanks in advance for your assistance. > > > Oh, that is cheap. I do read it as: > > > You must spend time on my problem and report back to me! > Do not expect any follow-up from me, I have already said "Thanks"!!! > > > Input for follow-up: > * Powercycle the system. > * Continue with reaching the intended goal > * complete resizing of /home [1] > * resize / [1] > > > > > Jonathan > > > > > > Groeten > Geert Stappers > > [1] Be aware of the command `resize2fs` and the flag `--resizefs` for > the command `lvresize`. > -- > Silence is hard to parse Thank-you for your help Geert. After a power cycle the system came back up normally and I was able to continue. As to your last comment, I am sorry that you took it that way. :) I think we have a cultural translation issue. Here in Canada we often thank people in advance without any expectations. Then we follow up. And finally we say that we are sorry if we have caused any offense. :) Thank-you!
[toc] | [prev] | [next] | [standalone]
| From | Geert Stappers <stappers@stappers.nl> |
|---|---|
| Date | 2024-10-27 19:30 +0100 |
| Subject | Re: Trouble with lvreduce and / read-only |
| Message-ID | <JCgbv-4Dly-1@gated-at.bofh.it> |
| In reply to | #274098 |
On Sun, Oct 27, 2024 at 06:11:45PM +0000, Jonathan Wiebe wrote: > On Sunday, October 27th, 2024 at 02:28, Geert Stappers wrote: > > On Sun, Oct 27, 2024 at 05:04:19AM +0000, Jonathan Wiebe wrote: > > > > > I ran into an issue with my root partition being too small. My plan > > > was to reduce the size of my home partition and increase the size of > > > my root partition. Here is what I have done: > > > > > > First, I rebooted in single user mode. > > > Then I did the following: > > > # mount / -rw -o remount > > > > I understand the '-o remount', not the '-rw'. > > And I think "that command might be the culprit" > > > > > > > # amount /home > > > > Assuming an ugly typo. > > > > > > > umount: /home: not mounted. > > > > > > I think: That is strange. > > And wonder: Why was /home not mounted? > > > > > > > # fsck -f /dev/mapper/debian --vg-home > > > fsck from util-linux 2.38.1 > > > e2fsck 1.47.0 (5-Feb-2023) > > > Pass 1: Checking inodes, blocks, and sizes > > > Inode 8803015 extent tree (at level 1) could be shorter. Optimize<y>? yes > > > Inode 8919578 extent tree (at level 1) could be shorter. Optimize<y>? yes > > > Inode 9328852 extent tree (at level 1) could be shorter. Optimize<y>? yes > > > Inode 11273442 extent tree (at level 1) could be shorter. Optimize<y>? yes > > > Pass 1E: Optimizing extent trees > > > Pass 2: Checking directory structure > > > Pass 3: Checking directory connectivity > > > Pass 4: Checking reference counts > > > Pass 5: Checking group summary information > > > > > > /dev/mapper/debian--vg-home: ***** FILE SYSTEM WAS MODIFIED ***** > > > /dev/mapper/debian--vg-home: 329100/29302784 files (1.8% non-contiguous), 12560416/117196800 blocks > > > > Acknowledge on "/home had some burses" > > > > > > > # fsck -f /dev/mapper/debian--vg-home > > > fsck from util-linux 2.38.1 > > > e2fsck 1.47.0 (5-Feb-2023) > > > Pass 1: Checking inodes, blocks, and sizes > > > Pass 2: Checking directory structure > > > Pass 3: Checking directory connectivity > > > Pass 4: Checking reference counts > > > Pass 5: Checking group summary information > > > /dev/mapper/debian--vg-home: 329100/29302784 files (1.8% non-contiguous), 12560416/117196800 blocks > > > > Acknowledge on "fsck is happy" > > > > > > > # resize2fs /dev/mapper/debian--vg-home 400G > > > resize2fs 1.47.0 (5-Feb-2023) > > > Resizing the filesystem on /dev/mapper/debian--vg-home to 104857600 (4k) blocks. > > > The filesystem on /dev/mapper/debian--vg-home is now 104857600 (4k) blocks long. > > > > Assuming something as "home was and is 400G" > > > > > > > # lvreduce -L -39G /dev/mapper/debian--vg-home > > > WARNING: Reducing active logical volume to 408.07 GiB. > > > THIS MAY DESTROY YOUR DATA (filesystem etc.) > > > Do you really want to reduce debian--vg/home? [y/n]: y > > > Size of logical volume debian--vg/home changed from 447.07 GiB (114450 extents) to 408.07 GiB (104466 extents). > > > Logical volume debian--vg/home successfully resized. > > > > Acknowledge > > NOTE: Only the logical volume was resized. [1] > > > > > > > This is where I am stalled. The prompt has not come back and I have > > > been waiting about 10.5 hours. Is it normal for this to take this > > > long? Should I just be patient? Or has something gone wrong? I am not > > > sure what to do at this point. > > > > Think "have shot my self in the foot", "learnt much today". > > > > Even on slow hardware is ten hour response time an indicator for > > "something is wrong". > > > > My guess is root filesystem mounted readonly being the culprit. > > > > > > > Thanks in advance for your assistance. > > > > Oh, that is cheap. I do read it as: > > > > You must spend time on my problem and report back to me! > > Do not expect any follow-up from me, I have already said "Thanks"!!! > > > > > > Input for follow-up: > > * Powercycle the system. > > * Continue with reaching the intended goal > > * complete resizing of /home [1] > > * resize / [1] > > > > > > > > > Jonathan > > > > Groeten > > Geert Stappers > > > > [1] Be aware of the command `resize2fs` and the flag `--resizefs` for > > the command `lvresize`. > > Thank-you for your help Geert. > > After a power cycle the system came back up normally OK, nice. > and I was able to continue. And which notes will be shared with this mailinglist? Groeten Geert Stappers > As to your last comment, I am sorry that you took it that way. :) > > I think we have a cultural translation issue. Here in Canada we often > thank people in advance without any expectations. > > Then we follow up. Just do it -- Silence is hard to parse
[toc] | [prev] | [next] | [standalone]
| From | Jonathan Wiebe <jonathan.b.wiebe@proton.me> |
|---|---|
| Date | 2024-10-27 19:50 +0100 |
| Subject | Re: Trouble with lvreduce and / read-only |
| Message-ID | <JCguS-4Dse-9@gated-at.bofh.it> |
| In reply to | #274099 |
[Multipart message — attachments visible in raw view] — view raw
-- Jonathan Wiebe Our passions are there to drive us to act, not to be the seasoning of our emotional stew. Sent with Proton Mail secure email. On Sunday, October 27th, 2024 at 11:29, Geert Stappers <stappers@stappers.nl> wrote: > On Sun, Oct 27, 2024 at 06:11:45PM +0000, Jonathan Wiebe wrote: > > > On Sunday, October 27th, 2024 at 02:28, Geert Stappers wrote: > > > > > On Sun, Oct 27, 2024 at 05:04:19AM +0000, Jonathan Wiebe wrote: > > > > > > > I ran into an issue with my root partition being too small. My plan > > > > was to reduce the size of my home partition and increase the size of > > > > my root partition. Here is what I have done: > > > > > > > > First, I rebooted in single user mode. > > > > Then I did the following: > > > > # mount / -rw -o remount > > > > > > I understand the '-o remount', not the '-rw'. > > > And I think "that command might be the culprit" > > > > > > > # amount /home > > > > > > Assuming an ugly typo. > > > > > > > umount: /home: not mounted. > > > > > > I think: That is strange. > > > And wonder: Why was /home not mounted? > > > > > > > # fsck -f /dev/mapper/debian --vg-home > > > > fsck from util-linux 2.38.1 > > > > e2fsck 1.47.0 (5-Feb-2023) > > > > Pass 1: Checking inodes, blocks, and sizes > > > > Inode 8803015 extent tree (at level 1) could be shorter. Optimize<y>? yes > > > > Inode 8919578 extent tree (at level 1) could be shorter. Optimize<y>? yes > > > > Inode 9328852 extent tree (at level 1) could be shorter. Optimize<y>? yes > > > > Inode 11273442 extent tree (at level 1) could be shorter. Optimize<y>? yes > > > > Pass 1E: Optimizing extent trees > > > > Pass 2: Checking directory structure > > > > Pass 3: Checking directory connectivity > > > > Pass 4: Checking reference counts > > > > Pass 5: Checking group summary information > > > > > > > > /dev/mapper/debian--vg-home: ***** FILE SYSTEM WAS MODIFIED ***** > > > > /dev/mapper/debian--vg-home: 329100/29302784 files (1.8% non-contiguous), 12560416/117196800 blocks > > > > > > Acknowledge on "/home had some burses" > > > > > > > # fsck -f /dev/mapper/debian--vg-home > > > > fsck from util-linux 2.38.1 > > > > e2fsck 1.47.0 (5-Feb-2023) > > > > Pass 1: Checking inodes, blocks, and sizes > > > > Pass 2: Checking directory structure > > > > Pass 3: Checking directory connectivity > > > > Pass 4: Checking reference counts > > > > Pass 5: Checking group summary information > > > > /dev/mapper/debian--vg-home: 329100/29302784 files (1.8% non-contiguous), 12560416/117196800 blocks > > > > > > Acknowledge on "fsck is happy" > > > > > > > # resize2fs /dev/mapper/debian--vg-home 400G > > > > resize2fs 1.47.0 (5-Feb-2023) > > > > Resizing the filesystem on /dev/mapper/debian--vg-home to 104857600 (4k) blocks. > > > > The filesystem on /dev/mapper/debian--vg-home is now 104857600 (4k) blocks long. > > > > > > Assuming something as "home was and is 400G" > > > > > > > # lvreduce -L -39G /dev/mapper/debian--vg-home > > > > WARNING: Reducing active logical volume to 408.07 GiB. > > > > THIS MAY DESTROY YOUR DATA (filesystem etc.) > > > > Do you really want to reduce debian--vg/home? [y/n]: y > > > > Size of logical volume debian--vg/home changed from 447.07 GiB (114450 extents) to 408.07 GiB (104466 extents). > > > > Logical volume debian--vg/home successfully resized. > > > > > > Acknowledge > > > NOTE: Only the logical volume was resized. [1] > > > > > > > This is where I am stalled. The prompt has not come back and I have > > > > been waiting about 10.5 hours. Is it normal for this to take this > > > > long? Should I just be patient? Or has something gone wrong? I am not > > > > sure what to do at this point. > > > > > > Think "have shot my self in the foot", "learnt much today". > > > > > > Even on slow hardware is ten hour response time an indicator for > > > "something is wrong". > > > > > > My guess is root filesystem mounted readonly being the culprit. > > > > > > > Thanks in advance for your assistance. > > > > > > Oh, that is cheap. I do read it as: > > > > > > You must spend time on my problem and report back to me! > > > Do not expect any follow-up from me, I have already said "Thanks"!!! > > > > > > Input for follow-up: > > > * Powercycle the system. > > > * Continue with reaching the intended goal > > > * complete resizing of /home [1] > > > * resize / [1] > > > > > > > Jonathan > > > > > > Groeten > > > Geert Stappers > > > > > > [1] Be aware of the command `resize2fs` and the flag `--resizefs` for > > > the command `lvresize`. > > > > Thank-you for your help Geert. > > > > After a power cycle the system came back up normally > > > OK, nice. > > > and I was able to continue. > > > And which notes will be shared with this mailinglist? > > > > > Groeten > Geert Stappers > > > As to your last comment, I am sorry that you took it that way. :) > > > > I think we have a cultural translation issue. Here in Canada we often > > thank people in advance without any expectations. > > > > Then we follow up. > > > Just do it > > > -- > Silence is hard to parse After the reboot I continued with: # resize2fs /dev/mapper/debian--vg-home # lvextend -L +20G /dev/mapper/debian--vg-root (Saving some free space for future use.) At this point I rebooted and forced a fsck on the root partition by appending fsck.mode=force to the grub boot line starting with linux... After a successful fsck: # resize2fs /dev/mapper/debian--vg-root And finally rebooted the system and checked that all partitions were the expected sizes. Thanks all for your help!
[toc] | [prev] | [next] | [standalone]
| From | Geert Stappers <stappers@stappers.nl> |
|---|---|
| Date | 2024-10-27 22:30 +0100 |
| Subject | Re: Trouble with lvreduce and / read-only |
| Message-ID | <JCiZI-4F1u-7@gated-at.bofh.it> |
| In reply to | #274102 |
On Sun, Oct 27, 2024 at 06:46:44PM +0000, Jonathan Wiebe wrote: > On Sunday, October 27th, 2024 at 11:29, Geert Stappers wrote: > > On Sun, Oct 27, 2024 at 06:11:45PM +0000, Jonathan Wiebe wrote: > > > On Sunday, October 27th, 2024 at 02:28, Geert Stappers wrote: > > > > On Sun, Oct 27, 2024 at 05:04:19AM +0000, Jonathan Wiebe wrote: > > > > > > > > > I ran into an issue with my root partition being too small. My plan > > > > > was to reduce the size of my home partition and increase the size of > > > > > my root partition. Here is what I have done: > > > > > .... > > > > > Logical volume debian--vg/home successfully resized. > > > > > > > > Acknowledge > > > > NOTE: Only the logical volume was resized. [1] > > > > > > > > > This is where I am stalled. The prompt has not come back and I have > > > > > > > > Even on slow hardware is ten hour response time an indicator for > > > > "something is wrong". > > > > > > > > Input for follow-up: > > > > * Powercycle the system. > > > > * Continue with reaching the intended goal > > > > * complete resizing of /home [1] > > > > * resize / [1] > > > > > > > > > > > > [1] Be aware of the command `resize2fs` and the flag `--resizefs` for > > > > the command `lvresize`. > > > > > > After a power cycle the system came back up normally > > > > OK, nice. > > > > > and I was able to continue. > > > > And which notes will be shared with this mailinglist? > > > > After the reboot I continued with: > # resize2fs /dev/mapper/debian--vg-home > > # lvextend -L +20G /dev/mapper/debian--vg-root > (Saving some free space for future use.) > At this point I rebooted and forced a fsck on the root partition by > appending fsck.mode=force to the grub boot line starting with linux... > After a successful fsck: > # resize2fs /dev/mapper/debian--vg-root > And finally rebooted the system and checked that all partitions were the expected sizes. > Thanks all for your help! Thanks for reporting back. For those who read this for their resize adventure: These days can LV resize / LV reduce be done on the fly. No need for unmount and `fsck`. Just add --resizefs to the LV commands. Groeten Geert Stappers -- Silence is hard to parse
[toc] | [prev] | [next] | [standalone]
| From | Andy Smith <andy@strugglers.net> |
|---|---|
| Date | 2024-10-28 02:50 +0100 |
| Subject | Re: Trouble with lvreduce and / read-only |
| Message-ID | <JCn3j-4Hnh-1@gated-at.bofh.it> |
| In reply to | #274102 |
Hi Jonathan, By the way, for future reference, one can use the -r option to lvextend / lvreduce which will call the equivalent of resize2fs for you. For filesystems like ext* that don't allow online shrink it will ask you if you want to umount it first. I find it takes some of the guesswork and stress out of such operations. Thanks, Andy -- https://bitfolk.com/ -- No-nonsense VPS hosting
[toc] | [prev] | [next] | [standalone]
| From | Anders Andersson <pipatron@gmail.com> |
|---|---|
| Date | 2024-10-28 13:40 +0100 |
| Message-ID | <JCxcl-4RsL-9@gated-at.bofh.it> |
| In reply to | #274087 |
On Sun, Oct 27, 2024 at 9:48 AM Jonathan Wiebe <jonathan.b.wiebe@proton.me> wrote: > > # lvreduce -L -39G /dev/mapper/debian--vg-home > WARNING: Reducing active logical volume to 408.07 GiB. > THIS MAY DESTROY YOUR DATA (filesystem etc.) > Do you really want to reduce debian--vg/home? [y/n]: y > Size of logical volume debian--vg/home changed from 447.07 GiB (114450 extents) to 408.07 GiB (104466 extents). > Logical volume debian--vg/home successfully resized. > > This is where I am stalled. The prompt has not come back and I have been waiting about 10.5 hours. Is it normal for this to take this long? Should I just be patient? Or has something gone wrong? I am not sure what to do at this point. Shrinking a logical volume should be more or less instant, and it is already "successfully resized" as reported by the tool. If I were in your situation I would open a new terminal and run "lvs" or similar to check the status. If that works fine and returns the prompt, then I'd assume it's good and try to cancel the first operation with ctrl-c. If the second "lvs" doesn't respond or if the new terminal doesn't even open correctly, you're of course in more trouble, but I would personally still be reasonably sure that the operation was OK and there's just some temporary confusion. In my experience, the lvm subsystem is pretty solid but of course YMMV. Realistically unless you can cancel the initial operation there's not much you can do anyway except to reboot. For what it's worth, I always prefer to do these things from a live CD/USB because you know that the host is not actively using some part of the disk you're working on, and it's easier to do backups. As long as the lvm/kernel versions are not that far apart you'll be fine. // Anders
[toc] | [prev] | [standalone]
Back to top | Article view | linux.debian.user
csiph-web