Crystal Kolipe <kolip...@exoticsilicon.com> wrote: > On Fri, Jun 10, 2022 at 06:21:42PM +0200, Claudio Jeker wrote: > > On Fri, Jun 10, 2022 at 11:43:50AM -0400, Andrew Cagney wrote: > > > On Fri, 10 Jun 2022 at 10:52, Crystal Kolipe <kolip...@exoticsilicon.com> > > > wrote: > > > > > > > > On Fri, Jun 10, 2022 at 10:40:47AM -0400, Andrew Cagney wrote: > > > > > I'm trying to use <<disklabel -A -T ...>> to auto partition a disk > > > > > with most of the disk assigned to / but also with some swap. > > > > > > > > Try: > > > > > > > > / 1g-* 100% > > > > swap 1g 0% > > > > > > That worked: > > > > > > [root@openbsd root]# disklabel sd0 > > > ... > > > # size offset fstype [fsize bsize cpg] > > > a: 18874240 64 4.2BSD 2048 16384 12960 # / > > > b: 2097152 18874304 swap # none > > > c: 20971520 0 unused > > > > > > Thanks! > > > > > > Can I suggest adding this as an example to disklabel(8). I suspect > > > assigning the entire disk to / is a common scenario, and would help > > > clarify how * and % interact. > > > > That is a bad advice. Using single / is just bad habit and does not allow > > to limit mountpoints with nodev, nosuid or wxallowed. For disks in the 10G > > space I would make sure that /var, /tmp, /usr, /home are different > > partitions. > > Just for the record, the original post doesn't actually mention anything > about this being for the _root_ disk. > > I assumed that he had a second or subsequent disk that was to be used as > a single volume, but wanted to reserve a small space for swap to improve > performance by interleaving the swap over multiple physical disks.
It is you making an assumption on thin evidence. 99% of our user base has 1 disk.