Date: Sat, 14 Jul 2018 11:41:43 -0600 From: Ian Lepore <ian@freebsd.org> To: Per olof Ljungmark <peo@nethead.se>, freebsd-arm@freebsd.org Subject: Re: add swap on a rpi3 Message-ID: <1531590103.21781.10.camel@freebsd.org> In-Reply-To: <cba281c2-4175-803e-43c7-c9bb10f6fead@nethead.se> References: <cba281c2-4175-803e-43c7-c9bb10f6fead@nethead.se>
next in thread | previous in thread | raw e-mail | index | archive | help
On Sat, 2018-07-14 at 19:28 +0200, Per olof Ljungmark wrote: > 12.0-CURRENT #0 r336134 arm64 GENERIC on a rpi3 Cortex-A53 > > Can I add a swap "partition" somewhere below? I am booting from the > SD > card and run the system from an attached USB disk. > > As I understand it, I cannot create a freebsd-swap partition/slice > with > the BSD/MBR scheme, but is there another way to create a reasonably > large swap (>1G) under ARM? > > => 63 31116225 mmcsd0 MBR (15G) > 63 2016 - free - (1.0M) > 2079 102312 1 fat32lba [active] (50M) > 104391 31008825 2 freebsd (15G) > 31113216 3072 - free - (1.5M) > > => 0 31008825 mmcsd0s2 BSD (15G) > 0 57 - free - (29K) > 57 31008768 1 freebsd-ufs (15G) > > => 63 125045361 da0 MBR (60G) > 63 2016 - free - (1.0M) > 2079 102312 1 fat32lba [active] (50M) > 104391 83884089 2 freebsd (40G) > 83988480 41056944 - free - (20G) > > => 0 83884089 da0s2 BSD (40G) > 0 57 - free - (29K) > 57 83884032 1 freebsd-ufs (40G) > > Looks like you've got some free space is on da0, so: gpart add -t freebsd -s <slicesize> -i 3 da0 gpart create -s bsd da0s3 gpart add -t freebsd-swap -s <swapsize> -i 2 da0s3 Now you have a swap parition at da0s3b (-i 2/partition b is sort of traditional for freebsd swap partitions, but there's no real need for it to be so). You can make the size of da0s3 bigger than 1g, and then carve out just 1g of it for swap, leaving space to add ufs partitions in that slice later if you want. -- Ian
Want to link to this message? Use this URL: <https://mail-archive.FreeBSD.org/cgi/mid.cgi?1531590103.21781.10.camel>