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
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"
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 beNo, that is an endless loop Dan. The idea is to remount a file system
mount / -o remount,rw
-dsr-
.
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,rwNo, 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.
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
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.
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
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
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!
| Sysop: | Keyop |
|---|---|
| Location: | Huddersfield, West Yorkshire, UK |
| Users: | 715 |
| Nodes: | 16 (2 / 14) |
| Uptime: | 146:13:18 |
| Calls: | 12,089 |
| Calls today: | 2 |
| Files: | 15,000 |
| Messages: | 6,517,501 |