Bug 240327 - bsdinstall(8): Partitioning the disk via scriptedpart always adds an EFI partition
Summary: bsdinstall(8): Partitioning the disk via scriptedpart always adds an EFI part...
Status: New
Alias: None
Product: Base System
Classification: Unclassified
Component: misc (show other bugs)
Version: CURRENT
Hardware: Any Any
: --- Affects Only Me
Assignee: freebsd-sysinstall (Nobody)
URL:
Keywords: install
Depends on:
Blocks:
 
Reported: 2019-09-04 08:56 UTC by Mateusz Piotrowski
Modified: 2022-10-13 17:48 UTC (History)
0 users

See Also:


Attachments

Note You need to log in before you can comment on or make changes to this bug.
Description Mateusz Piotrowski freebsd_committer freebsd_triage 2019-09-04 08:56:19 UTC
Here's a script to reproduce the issue:

```
pool="${1:-"zroot"}"
dataset="${2:-"bsdinstall-bug"}"

zfs create -V 1G "${pool}/${dataset}"
bsdinstall scriptedpart zvol/${pool}/${dataset} \
	{512K freebsd-boot, 100M freebsd-swap, 512MB freebsd-ufs /}
gpart show zvol/${pool}/${dataset}
```

The result of the script is the following output:

```
=>     40  2097072  zvol/zroot/bsdinstall-bug  GPT  (1.0G)
       40        8                             - free -  (4.0K)
       48     1024                          1  freebsd-boot  (512K)
     1072   204800                          2  freebsd-swap  (100M)
   205872   532480                          3  efi  (260M)
   738352   516080                          4  freebsd-ufs  (252M)
  1254432   842680                             - free -  (411M)
```

As you can see, the EFI partition was included automatically. Also, the UFS partition is much smaller than requested.

Tested on FreeBSD 13.0-CURRENT r351325 GENERIC amd64.