RPI3 swap experiments

Trev freebsd-arm at sentry.org
Sun Jul 22 08:50:54 UTC 2018


Trev wrote on 04/07/2018 07:09:
> Ok, the final, final swap experiment.
> 
> I created a 2G swap partition on the SDCard:
> 
> gpart show
> =>      63  31116225  mmcsd0  MBR  (15G)
>          63      2016          - free -  (1.0M)
>        2079    102400       1  fat32lba  [active]  (50M)
>      104479  31011809       2  freebsd  (15G)
> 
> =>       0  31011809  mmcsd0s2  BSD  (15G)
>           0  25165824         1  freebsd-ufs  (12G)
>    25165824   4194304         2  freebsd-swap  (2.0G)
>    29360128   1651681            - free -  (806M)
> 
> and, yes, it still died during make -j4 buildworld:
> 
> Jul  3 22:15:24 rpi3 kernel: pid 57011 (c++), uid 0, was killed: out of 
> swap space

I replaced the SanDisk 16G Ultra (Speed Class 10, UHS Speed Class 1, 
minimum 10MB/s seq write) used above with a SanDisk 32G Extreme (Speed 
Class 10, UHS Speed Class 3, minimum 30MB/s seq write) micro-SD card and 
now the above configuration survives make -j4 buildworld to end 
successfully. Twice so far.

The configuration is a little different because of the extra space:

root at rpi3:~ # gpart show mmcsd0s2
=>       0  62229473  mmcsd0s2  BSD  (30G)
          0  12582912         1  freebsd-ufs  (6.0G) [root s2a]
   12582912   4194304         2  freebsd-swap (2.0G) [swap s2b]
   16777216  12582912         4  freebsd-ufs  (6.0G) [home s2d]
   29360128  32869345         5  freebsd-ufs  (16G)  [usr  s2e]

Note: the SanDisk 32G Extreme I bought at the local (rural) OfficeWorks 
is "old" stock as it does not have the "application performance class 
rating" (A1) on it which signifies minimum random read of 1500 IOPS and 
minimum random write of 500 IOPS. There's also an A2 which signifies 
minimum random read of 4000 IOPS and minimum random write of 2000 IOPS.

Everything subjectively seems snappier. Watching gstat randomly during 
buildworld I saw no busy percentage greater than 101% and no queue 
greater than 17, whereas with the Ultra card, I often saw 200-400% with 
large queues in the 100s. Take the observations in this paragraph with a 
grain of evidence-free, anecdotal salt.

Trying to determine the real difference between Ultra and Extreme cards 
was difficult. The best I could come up with were unsupported claims 
that the Extreme series contain "card controller technology that allows 
parallel processing of reads and writes" which might just be confusing 
UHS-I/HC-I (half-duplex) and UHS-II/HC-II (full duplex) bus interfaces.



More information about the freebsd-arm mailing list