
Hello! When I installed Debian on my current computer, I (foolishly) let the install script partition my disk. Now I have a /boot partition that is too small. The system is using lvm, and I have enough free space on /home that I can reduce the size of /home by a couple of Gb, and then in theory allocate that to my ridiculously undersized /boot partition. Back in the old days I knew how to do this, but with lvm I don't know how, and of the (many) questions and answers that I have found I haven't seen one that inspires confidence. So... 1) Do I need to make a boot drive? 2) Does anyone know a nice set of instructions? Thanks!

On 2021-10-07 10:45 p.m., William Witteman via talk wrote:
When I installed Debian on my current computer, I (foolishly) let the install script partition my disk. Now I have a /boot partition that is too small.
How small is your /boot partition? Are you using it for more than just the kernel files needed to boot your system? I have a /boot that is way bigger than I really need but I wanted room to keep multiple kernels so I can test out different distros that may require different kernels. Allowing 100M per kernel should be more than enough space. I currently have two kernels and they only use 153M of disk space.
The system is using lvm
I don't use lvm so I can't help with that. All I can say is that when I have needed to adjust partition sizes I use gparted. That might not help you. -- Cheers! Kevin. http://www.ve3syb.ca/ | "Nerds make the shiny things that https://www.patreon.com/KevinCozens | distract the mouth-breathers, and | that's why we're powerful" Owner of Elecraft K2 #2172 | #include <disclaimer/favourite> | --Chris Hardwick

Thanks for the response! My /boot partition is 239Mb, which is just small enough that a particularly chunky kernel and an upgrade to it is too much. I am not in a big hurry to delete the kernel image I am actively using to make space for the upgraded one - 'cause every 5 years or so I need to boot from an old kernel, and I'd like to be able to. On Fri, 8 Oct 2021 at 11:37, Kevin Cozens via talk <talk@gtalug.org> wrote:
On 2021-10-07 10:45 p.m., William Witteman via talk wrote:
When I installed Debian on my current computer, I (foolishly) let the install script partition my disk. Now I have a /boot partition that is too small.
How small is your /boot partition? Are you using it for more than just the kernel files needed to boot your system?
I have a /boot that is way bigger than I really need but I wanted room to keep multiple kernels so I can test out different distros that may require different kernels. Allowing 100M per kernel should be more than enough space. I currently have two kernels and they only use 153M of disk space.
The system is using lvm
I don't use lvm so I can't help with that. All I can say is that when I have needed to adjust partition sizes I use gparted. That might not help you.
-- Cheers!
Kevin.
http://www.ve3syb.ca/ | "Nerds make the shiny things that https://www.patreon.com/KevinCozens | distract the mouth-breathers, and | that's why we're powerful" Owner of Elecraft K2 #2172 | #include <disclaimer/favourite> | --Chris Hardwick --- Post to this mailing list talk@gtalug.org Unsubscribe from this mailing list https://gtalug.org/mailman/listinfo/talk

| From: William Witteman via talk <talk@gtalug.org> | When I installed Debian on my current computer, I (foolishly) let the | install script partition my disk. Now I have a /boot partition that is too | small. Useless advice: I've never felt the need for a /boot partition. I just have it as part of /. Start up the time machine. Turning this into useful advice: you could change your setup to do this, abandoning the /boot partition. I assume you are using UEFI booting. In particular, grub and its bits are living in /boot/efi (a mount point for the ESP). You need to have the grub.cfg refer to /boot inside / rather than /boot the (obsolete) partition. Off the top of my head, UNTESTED, here's what I'd try. Do have a live Linux USB stick standing by in case your surgery results in a broken system. 1. unmount /boot/efi 2. cp -a /boot /boot-new 3. mount /boot/efi 4. change things (mostly grub.cfg) ain /boot/efi/ so that they refer to the relocated /boot (a new GUUID, the one for /; a new path, including /boot). 5. umount /boot/efi 6. umount /boot 7, mv /boot /boot-old 8. mv /boot-new /boot 9, remove /boot from /etc/fstab 10, reboot. The tricky bit is getting step 4 just right.

On Thu, Oct 07, 2021 at 10:45:57PM -0400, William Witteman via talk wrote:
When I installed Debian on my current computer, I (foolishly) let the install script partition my disk. Now I have a /boot partition that is too small.
The system is using lvm, and I have enough free space on /home that I can reduce the size of /home by a couple of Gb, and then in theory allocate that to my ridiculously undersized /boot partition.
Back in the old days I knew how to do this, but with lvm I don't know how, and of the (many) questions and answers that I have found I haven't seen one that inspires confidence.
So...
1) Do I need to make a boot drive? 2) Does anyone know a nice set of instructions?
Well you may in fact need a boot drive since you are using LVM for / and something has to boot the system to a ramdisk to start lvm to mount root. gparted livecd can definitely expand LVM PV, but not sure about shrinking them. What is the current partition table? -- Len Sorensen

Thanks to everyone who responded! As Lennart points out, /boot can't be an LVM, and the whole rest of the disk was an LVM partition. Those get bigger easily, but not smaller. It was easiest for me to copy my /home onto a backup drive and reinstall Debian. My experiment with LVM and "automatic" partitions was a failure - my workflow is better suited to a / and a /home. Thanks again! On Tue., Oct. 12, 2021, 10:57 Lennart Sorensen, < lsorense@csclub.uwaterloo.ca> wrote:
On Thu, Oct 07, 2021 at 10:45:57PM -0400, William Witteman via talk wrote:
When I installed Debian on my current computer, I (foolishly) let the install script partition my disk. Now I have a /boot partition that is too small.
The system is using lvm, and I have enough free space on /home that I can reduce the size of /home by a couple of Gb, and then in theory allocate that to my ridiculously undersized /boot partition.
Back in the old days I knew how to do this, but with lvm I don't know how, and of the (many) questions and answers that I have found I haven't seen one that inspires confidence.
So...
1) Do I need to make a boot drive? 2) Does anyone know a nice set of instructions?
Well you may in fact need a boot drive since you are using LVM for / and something has to boot the system to a ramdisk to start lvm to mount root.
gparted livecd can definitely expand LVM PV, but not sure about shrinking them.
What is the current partition table?
-- Len Sorensen

As Lennart points out, /boot can't be an LVM,
Hm. I have plenty of computers where the disks have one RAID partition, and the RAID volume has only LVM on it, with either a separate LV=boot or just booting from LV=/ This has worked since at least GRUB2 came out. I also have a single-disk (no RAID) computer where one of the partitions is LVM booting straight from the LVM with LILO. Another partition is WinXP. Yes, this is an old system, but shows that booting from an LV without a separate /boot partition has been possible for a long time. The only time I've found it necessary to have a separate /boot partition is when the rest of the drive is encrypted. There needs to be some unencrypted software to decrypt the drive, available in initramfs in the unencrypted /boot partition. But to address William's problem of an overfull /boot partition: I have sometimes rescued a system by just deleting the oldest kernel images to free up space in boot (or / ) with a rescue CD or USB stick, allowing the system to boot again to fix up the slightly broken repository (usually by re-installing the most recent kernel update that overflowed /boot in the first place). --Bob. On 2021-10-12 11:39, William Witteman via talk wrote:
Thanks to everyone who responded!
As Lennart points out, /boot can't be an LVM, and the whole rest of the disk was an LVM partition. Those get bigger easily, but not smaller.
It was easiest for me to copy my /home onto a backup drive and reinstall Debian. My experiment with LVM and "automatic" partitions was a failure - my workflow is better suited to a / and a /home.
Thanks again!
On Tue., Oct. 12, 2021, 10:57 Lennart Sorensen, < lsorense@csclub.uwaterloo.ca> wrote:
On Thu, Oct 07, 2021 at 10:45:57PM -0400, William Witteman via talk wrote:
When I installed Debian on my current computer, I (foolishly) let the install script partition my disk. Now I have a /boot partition that is too small.
The system is using lvm, and I have enough free space on /home that I can reduce the size of /home by a couple of Gb, and then in theory allocate that to my ridiculously undersized /boot partition.
Back in the old days I knew how to do this, but with lvm I don't know how, and of the (many) questions and answers that I have found I haven't seen one that inspires confidence.
So...
1) Do I need to make a boot drive? 2) Does anyone know a nice set of instructions?
Well you may in fact need a boot drive since you are using LVM for / and something has to boot the system to a ramdisk to start lvm to mount root.
gparted livecd can definitely expand LVM PV, but not sure about shrinking them.
What is the current partition table?
-- Len Sorensen
--- Post to this mailing list talk@gtalug.org Unsubscribe from this mailing list https://gtalug.org/mailman/listinfo/talk
-- Bob Jonkman <bjonkman@sobac.com> Phone: +1-519-635-9413 SOBAC Microcomputer Services http://sobac.com/sobac/ Software --- Office & Business Automation --- Consulting GnuPG Fngrprnt:04F7 742B 8F54 C40A E115 26C2 B912 89B0 D2CC E5EA

On Wed., Oct. 13, 2021, 18:08 Bob Jonkman via talk, <talk@gtalug.org> wrote:
As Lennart points out, /boot can't be an LVM,
... shows that booting from an LV without a separate /boot partition has been possible for a long time.
Oops. I misread something. Thanks! But to address William's problem of an overfull /boot partition: I have
sometimes rescued a system by just deleting the oldest kernel images to free up space in boot (or / ) with a rescue CD or USB stick, allowing the system to boot again to fix up the slightly broken repository (usually by re-installing the most recent kernel update that overflowed /boot in the first place).
Yeah, the problem was the comically, "full of clowns" tiny space that didn't allow two kernels (234 Mb), so I could either keep the known-good kernel, or the new one, but not both :-P I far prefer the way it's set up now, with / and /home, and I probably won't have to worry about this system until I replace it. Thanks!

On Wed, Oct 13, 2021 at 06:07:58PM -0400, Bob Jonkman via talk wrote:
Hm. I have plenty of computers where the disks have one RAID partition, and the RAID volume has only LVM on it, with either a separate LV=boot or just booting from LV=/ This has worked since at least GRUB2 came out.
I also have a single-disk (no RAID) computer where one of the partitions is LVM booting straight from the LVM with LILO. Another partition is WinXP. Yes, this is an old system, but shows that booting from an LV without a separate /boot partition has been possible for a long time.
The only time I've found it necessary to have a separate /boot partition is when the rest of the drive is encrypted. There needs to be some unencrypted software to decrypt the drive, available in initramfs in the unencrypted /boot partition.
But to address William's problem of an overfull /boot partition: I have sometimes rescued a system by just deleting the oldest kernel images to free up space in boot (or / ) with a rescue CD or USB stick, allowing the system to boot again to fix up the slightly broken repository (usually by re-installing the most recent kernel update that overflowed /boot in the first place).
Well lilo could boot from anything as long as it could learn the block locations of the files it needed. Of course sometimes those blocks changed and lilo broke. Quite fragile. grub2 does have lvm support so yes it should be able to boot without a /boot partition these days. I don't think grub2 had that initially, but has had it quite a while. I think any system I have with LVM still has a separate /boot though. -- Len Sorensen
participants (5)
-
Bob Jonkman
-
D. Hugh Redelmeier
-
Kevin Cozens
-
Lennart Sorensen
-
William Witteman