From mboxrd@z Thu Jan 1 00:00:00 1970 Return-Path: Received: from lists.gentoo.org (pigeon.gentoo.org [208.92.234.80]) (using TLSv1.3 with cipher TLS_AES_256_GCM_SHA384 (256/256 bits) key-exchange X25519 server-signature RSA-PSS (2048 bits)) (No client certificate requested) by finch.gentoo.org (Postfix) with ESMTPS id CC748158041 for ; Wed, 3 Apr 2024 16:22:14 +0000 (UTC) Received: from pigeon.gentoo.org (localhost [127.0.0.1]) by pigeon.gentoo.org (Postfix) with SMTP id 4FE39E2A9B; Wed, 3 Apr 2024 16:22:10 +0000 (UTC) Received: from mail-pg1-x531.google.com (mail-pg1-x531.google.com [IPv6:2607:f8b0:4864:20::531]) (using TLSv1.3 with cipher TLS_AES_256_GCM_SHA384 (256/256 bits) key-exchange X25519 server-signature RSA-PSS (4096 bits) server-digest SHA256) (No client certificate requested) by pigeon.gentoo.org (Postfix) with ESMTPS id DBE65E2A76 for ; Wed, 3 Apr 2024 16:22:09 +0000 (UTC) Received: by mail-pg1-x531.google.com with SMTP id 41be03b00d2f7-5e42b4bbfa4so43372a12.1 for ; Wed, 03 Apr 2024 09:22:09 -0700 (PDT) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=gmail.com; s=20230601; t=1712161329; x=1712766129; darn=lists.gentoo.org; h=to:subject:message-id:date:from:in-reply-to:references:mime-version :from:to:cc:subject:date:message-id:reply-to; bh=xCnFddtHBTGdJZIMI1MlEIXrU98p0jInM9EJjCyifhg=; b=UJqVjkqG6bx/SZk2E38d2U3g7RtOJVgf8xGIp8hVbAoAenl3raw01IPC0OfmK5Ck5w m/KlstRBxBHrdIvLRKmpdqzd0ql13fdSK3qBwBxHe+qSqJUXpZ3gCIR1iSzebBHN50mn s9kLP30Cqbmtt6oiThvPWF1FEQOfkiPWMtlFZGRyJqSt+l/S/UsAthZeHodk0KibusA6 8lQtgy+xds6xZuS1IgDP25Xsi8MDojOmQnPzawZp6RFdQsBJRaLNMUmt+H60mpMMJLaP wOiHpRcAtuEX1oiSuMClUrWYennce8paWqGl1AmdffMsMaYBcys7UE7Cq08NXOCkOxIt yl7g== X-Google-DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=1e100.net; s=20230601; t=1712161329; x=1712766129; h=to:subject:message-id:date:from:in-reply-to:references:mime-version :x-gm-message-state:from:to:cc:subject:date:message-id:reply-to; bh=xCnFddtHBTGdJZIMI1MlEIXrU98p0jInM9EJjCyifhg=; b=pRLZLSN0p6WM/x6i1sbPd5PQ1Uw4TzN5JtUyn76uHLIhNCFW65WWHLOAan3r6LmV9E MI5Duzdy0UY2LYYa13nq2IfFqIaeUAgO+6P0b0lRZpEhQg1YoexEuDxFq2QB8wvQGg+m j8r0sgtmGdydnELM2b4yeFx5rjLfbHqdt/SOEo0zx8b4RplDzYUvwgdz7VL4Yah/RniM z1FHxfWdTAQyhRZQnQ6RDQCwJgMyhDOBFsIcJp3nYr1Fbhk6CjtAbQwUO9WGJhg2YyKq SYgKR2xxvF09RSjTie7uybYL22rIqmbMSR2HBxY8Yrm3ycvzx74/04tHews2V6jZs44Y rseQ== X-Gm-Message-State: AOJu0YzELOnsMqgwIUPS80kJcOXyJro2hIkzC7ngQi7J9V/KN/uo4TBv BbKbkifFFinhGu1DBYKYsPUvGD7PDJilL7XeptoLYVdf++0vKeDvEZbocIc7IvLHSjcFxhIDQO4 YcKDtc9f9A72hjL3m4LOZjI43oYyoAvvPj8M= X-Google-Smtp-Source: AGHT+IGjD+SWWWY9aJ6Df2icbiTfsYdqJle3MGhFe0jr6OBvY2/MSC7bg1BIp8qak5jHt+9gK03QCLRTALQfNyUBsS0= X-Received: by 2002:a17:90a:8a87:b0:2a2:898:f8b6 with SMTP id x7-20020a17090a8a8700b002a20898f8b6mr2987480pjn.46.1712161328684; Wed, 03 Apr 2024 09:22:08 -0700 (PDT) Precedence: bulk List-Post: List-Help: List-Unsubscribe: List-Subscribe: List-Id: Gentoo Linux mail X-BeenThere: gentoo-user@lists.gentoo.org Reply-to: gentoo-user@lists.gentoo.org X-Auto-Response-Suppress: DR, RN, NRN, OOF, AutoReply MIME-Version: 1.0 References: In-Reply-To: From: Waldo Lemmer Date: Wed, 3 Apr 2024 18:21:51 +0200 Message-ID: Subject: Re: [gentoo-user] Resizing boot partition while dual-booting To: gentoo-user@lists.gentoo.org Content-Type: multipart/alternative; boundary="000000000000cb68f70615339fcc" X-Archives-Salt: 078ec03f-30d6-4a29-be8a-85940e923ed3 X-Archives-Hash: 11766d90376253ec6fb589bec67780f9 --000000000000cb68f70615339fcc Content-Type: text/plain; charset="UTF-8" Content-Transfer-Encoding: quoted-printable Hi Vit I presume you plan to have a single boot partition that will contain your bootloader, kernel and initramfs. There are actually two kinds of boot partitions that are commonly used together: 1. The EFI system partition (ESP) contains Linux and Windows's bootloaders. It's formatted as FAT. 2. The extended boot (XBOOTLDR) partition contains kernels, initramfs's and microcode. It's formatted as anything the bootloader supports (GRUB supports FAT, ext4 and more). If you have a single boot partition, you're actually just combining the above two. If you want to create more room, you can split it: 1. Shrink your Linux partition to create space for the extended boot partition. You can GParted from another system or bootable USB. 2. Create and format the extended boot partition. 3. Modify /etc/fstab so the ESP gets mounted at /efi and the XBOOTLDR gets mounted at /boot. 4. Mount these two partitions. 5. If this is an existing install, move the kernel, initramfs and microcode from /efi to /boot. Otherwise, install the bootloader and the kernel. 6. Re-configure your bootloader (e.g. `grub-mkconfig -o /efi/grub/grub.cfg`). Now the large kernel and initramfs files don't take up space on the ESP that's being shared with Windows. Alternatively, just resize the ESP. However, that breaks Windows's bootloader since the starting point of the C:\ partition moved, so you need to fix it from a Windows setup USB using bootrec. I can't help you with that. Waldo On Wed, Apr 3, 2024 at 5:38=E2=80=AFPM V=C3=ADt Smol=C3=ADk wrote: > Do you store your initramfs on the 100mb partition? Or do you stire it > somewhere else? > > May the Force be with you, > V=C3=ADt Smol=C3=ADk. > > Dne st 3. 4. 2024 17:35 u=C5=BEivatel Alexis Praga > napsal: > >> Hi Vit, >> >> I have a dual boot with a 100Mb EFI partition. It works fine, except >> there isn=E2=80=99t enough place for both old and new kernels for upgrad= ing. So I >> moved the old kernel from /boot into a safe directory before upgrading. >> Maybe not the best strategy but I didn=E2=80=99t dare resize it. >> >> Alexis >> >> On Wednesday, April 3rd, 2024 at 17:10, V=C3=ADt Smol=C3=ADk >> wrote: >> >> Hello fellow Gentooers, >> >> I want to dual-boot Gentoo and M$ Windows on my computer, but windows >> only created a 100MB EFI partition. Is it necessary to resize it so my b= oot >> files will fit? If so - how to resize it so I don't mess up my Windows E= FI >> files? >> >> -- >> May the Force be with you, >> V=C3=ADt Smol=C3=ADk. >> >> >> >> --000000000000cb68f70615339fcc Content-Type: text/html; charset="UTF-8" Content-Transfer-Encoding: quoted-printable
Hi Vit

I pr= esume you plan to have a single boot partition that will contain your bootl= oader, kernel and initramfs. There are actually two kinds of boot partition= s that are commonly used together:
1. The EFI system partition (E= SP) contains Linux and Windows's bootloaders. It's formatted as FAT= .
2. The extended boot (XBOOTLDR) partition contains kernels,= initramfs's and microcode. It's formatted as anything the bootload= er supports (GRUB supports FAT, ext4 and more).

If you have a single boot partition, you're actually just combining t= he above two. If you want to create more room, you can split it:
= 1. Shrink your Linux partition to create space for the extended boot partit= ion. You can GParted from another system or bootable USB.
2. = Create and format the extended boot partition.
3. Modify /etc/fst= ab so the ESP gets mounted at /efi and the XBOOTLDR gets mounted at /boot.<= /div>
4. Mount these two partitions.
5. If this is an existin= g install, move the kernel, initramfs and microcode from /efi to /boot. Oth= erwise, install the bootloader and the kernel.
6. Re-configur= e your bootloader (e.g. `grub-mkconfig -o /efi/grub/grub.cfg`).

Now the large kernel and initramfs files don't take u= p space on the ESP that's being shared with Windows.

Alternatively, just resize the ESP. However, that breaks Windows'= ;s bootloader since the starting point of the C:\ partition moved, so you n= eed to fix it from a Windows setup USB using bootrec. I can't help you = with that.

Waldo

On Wed, Apr 3, 2024 at 5= :38=E2=80=AFPM V=C3=ADt Smol=C3=ADk <vit.smolik2@gmail.com> wrote:
Do you store your initram= fs on the 100mb partition? Or do you stire it somewhere else?
May the Force be with you,
V=C3=ADt Smol=C3=ADk.

Dne s= t 3. 4. 2024 17:35 u=C5=BEivatel Alexis Praga <alexis.praga@proton.me> napsal:
Hi Vit,

I have a dual boot with a 100Mb EFI partit= ion. It works fine, except there isn=E2=80=99t enough place for both old an= d new kernels for upgrading. So I moved the old kernel from /boot into a sa= fe directory before upgrading.
Maybe not the best strategy but I didn=E2=80=99t dare r= esize it.
<= br>
Alexis<= /div>
=20
=20
=20

On Wednesday, April 3rd, 2024 at 17:10, V=C3=ADt Smol=C3=ADk <vit.smolik2@gmail.com> wrote:
Hello fellow Gentooers,

I want to dual-boot Gentoo and M$ Windows on my computer, but windo= ws only created a 100MB EFI partition. Is it necessary to resize it so my b= oot files will fit? If so - how to resize it so I don't mess up my Wind= ows EFI files?

--
May the Force be with you,
V=C3=ADt Smol=C3=ADk.



--000000000000cb68f70615339fcc--