RPI3 swap experiments, was Re: GPT vs MBR for swap devices

Mark Millard marklmi at yahoo.com
Mon Jun 25 04:22:52 UTC 2018


On 2018-Jun-24, at 4:10 PM, bob prohaska <fbsd at www.zefox.net> wrote:


> I've tried to replicate  the RPi3  "run out of swap" experiment after
> updating source, kernel and world to r335576. Roughly the same things happen:
> Errors flood the console, when swap usage goes a bit over 80% the machine becomes
> unresponsive.  No sign of the OOM assassin. 
> 
> However, -j4 buildworld got all the way to building libraries. With r334939 it
> always stopped in cross tools. That seems like a significant improvement
> in swap usage efficiency. Is this to be expected? 
> 

From the log file:

http://www.zefox.net/~fbsd/rpi3/swaptests/r335576/1gbsdflash/buildworld.log

is the text:

--- buildworld ---
make[1]: "/usr/src/Makefile.inc1" line 299: SYSTEM_COMPILER: Determined that CC=cc matches the source tree.  Not bootstrapping a cross-compiler.
make[1]: "/usr/src/Makefile.inc1" line 304: SYSTEM_LINKER: Determined that LD=ld matches the source tree.  Not bootstrapping a cross-linker.

So the cross compiler and cross linker were not built: the existing
llvm files were used.

It was during building of these that the earlier failures happened in
the cross-tools stage as I understand: the other stuff does not require
as big of processes, or as big of a maximum-total for -j4 .

> What details were captured can be seen at
> http://www.zefox.net/~fbsd/rpi3/swaptests/r335576/1gbsdflash/
> in case they're of interest.


You are still using the drive that gets the errors ( /dev/da0 ),
even if it is not being used for swapping.

http://www.zefox.net/~fbsd/rpi3/swaptests/r335576/1gbsdflash/console

shows:

_vfs_done():da0d[WRITE(offset=51819347968, length=131072)]error = 5
g_vfs_done():da0d[WRITE(offset=51819479040, length=28672)]error = 5
g_vfs_done():da0d[READ(offset=59586936832, length=32768)]error = 5
g_vfs_done():vm_fault: pager read error, pid 823 (tcsh)
da0d[READ(offset=59650965504, length=32768)]error = 5
g_vfs_done():vm_fault: pager read error, pid 3950 (sshd)
da0a[WRITE(offset=65536, length=4096)]error = 5
g_vfs_done():da0a[WRITE(offset=8585216, length=4096)]error = 5
:24 www kernel: Failed to fully fault in a core file segment at VA 0x405e6000 with size 0x10000 to be written at offset 0x346000 for process tcsh
Jun 24 13:25:25 www kernel: Failed to fully fault in a core file segment at VA 0x40c41000 with size 0x10000 to be written at offset 0x981000 for process tcsh
(da0:umass-sim0:0:0:0): WRITE(10). CDB: 2a 00 00 0b 3f c0 00 00 80 00 
(da0:umass-sim0:0:0:0): CAM status: CCB request completed with an error
(da0:umass-sim0:0:0:0): Retrying command, 3 more tries remain
(da0:umass-sim0:0:0:0): WRITE(10). CDB: 2a 00 00 0b 3f c0 00 00 80 00 
(da0:umass-sim0:0:0:0): CAM status: CCB request completed with an error
(da0:umass-sim0:0:0:0): Retrying command, 2 more tries remain
(da0:umass-sim0:0:0:0): WRITE(10). CDB: 2a 00 00 0b 3f c0 00 00 80 00 
(da0:umass-sim0:0:0:0): CAM status: CCB request completed with an error
(da0:umass-sim0:0:0:0): Retrying command, 1 more tries remain
(da0:umass-sim0:0:0:0): WRITE(10). CDB: 2a 00 00 0b 3f c0 00 00 80 00 
(da0:umass-sim0:0:0:0): CAM status: CCB request completed with an error
(da0:umass-sim0:0:0:0): Retrying command, 0 more tries remain
(da0:umass-sim0:0:0:0): WRITE(10). CDB: 2a 00 00 0b 3f c0 00 00 80 00 
(da0:umass-sim0:0:0:0): CAM status: CCB request completed with an error
(da0:umass-sim0:0:0:0): Error 5, Retries exhausted
g_vfs_done():da0a[WRITE(offset=805568512, length=32768)]error = 5
g_vfs_done():da0d[READ(offset=59580710912, length=32768)]error = 5
g_vfs_done():vm_fault: pager read error, pid 3960 (csh)
da0d[READ(offset=59604205568, length=32768)]error = 5
g_vfs_done():vm_fault: pager read error, pid 823 (tcsh)
da0a[WRITE(offset=65536, length=4096)]error = 5
g_vfs_done():da0a[WRITE(offset=8585216, length=4096)]error = 5
g_vfs_done():da0a[WRITE(offset=268599296, length=16384)]error = 5
g_vfs_done():da0a[WRITE(offset=268632064, length=32768)]error = 5
g_vfs_done():da0a[WRITE(offset=268664832, length=32768)]error = 5
g_vfs_done():da0a[WRITE(offset=289939456, length=4096)]error = 5
g_vfs_done():da0a[WRITE(offset=377454592, length=131072)]error = 5
(da0:umass-sim0:0:0:0): WRITE(10). CDB: 2a 00 00 00 41 80 00 00 08 00 
(da0:umass-sim0:0:0:0): CAM status: CCB request completed with an error
(da0:umass-sim0:0:0:0): Retrying command, 3 more tries remain
(da0:umass-sim0:0:0:0): WRITE(10). CDB: 2a 00 00 00 41 80 00 00 08 00 
(da0:umass-sim0:0:0:0): CAM status: CCB request completed with an error
(da0:umass-sim0:0:0:0): Retrying command, 2 more tries remain
(da0:umass-sim0:0:0:0): WRITE(10). CDB: 2a 00 00 00 41 80 00 00 08 00 
(da0:umass-sim0:0:0:0): CAM status: CCB request completed with an error
(da0:umass-sim0:0:0:0): Retrying command, 1 more tries remain
(da0:umass-sim0:0:0:0): WRITE(10). CDB: 2a 00 00 00 41 80 00 00 08 00 
(da0:umass-sim0:0:0:0): CAM status: CCB request completed with an error
(da0:umass-sim0:0:0:0): Retrying command, 0 more tries remain
(da0:umass-sim0:0:0:0): WRITE(10). CDB: 2a 00 00 00 41 80 00 00 08 00 
(da0:umass-sim0:0:0:0): CAM status: CCB request completed with an error
(da0:umass-sim0:0:0:0): Error 5, Retries exhausted
g_vfs_done():da0a[WRITE(offset=268664832, length=32768)]error = 5
g_vfs_done():da0a[WRITE(offset=377454592, length=32768)]error = 5
g_vfs_done():da0d[WRITE(offset=65536, length=4096)]error = 5
g_vfs_done():da0d[WRITE(offset=20709376, length=4096)]error = 5
g_vfs_done():da0d[R:20 www kernel: Failed to fully fault in a core file segment at VA 0x40c72000 with size 0x10000 to be written at offset 0x992000 for process tcsh
EAD(offset=17179279360, length=32768)]error = 5
g_vfs_done():vm_fault: pager read error, pid 817 (sshd)
da0d[READ(offset=36814438400, length=4096)]error = 5
g_vfs_done():da0d[WRITE(offset=51207864320, length=32768)]error = 5
g_vfs_done():da0d[WRITE(offset=51208126464, length=32768)]error = 5
g_vfs_done():da0a[WRITE(offset=65536, length=4096)]error = 5
g_vfs_done():da0a[WRITE(offset=8585216, length=4096)]error = 5
(da0:umass-sim0:0:0:0): WRITE(10). CDB: 2a 00 00 0b 3f c0 00 00 80 00 
(da0:umass-sim0:0:0:0): CAM status: CCB request completed with an error
(da0:umass-sim0:0:0:0): Retrying command, 3 more tries remain
(da0:umass-sim0:0:0:0): WRITE(10). CDB: 2a 00 00 0b 3f c0 00 00 80 00 
(da0:umass-sim0:0:0:0): CAM status: CCB request completed with an error
(da0:umass-sim0:0:0:0): Retrying command, 2 more tries remain
(da0:umass-sim0:0:0:0): WRITE(10). CDB: 2a 00 00 0b 3f c0 00 00 80 00 
(da0:umass-sim0:0:0:0): CAM status: CCB request completed with an error
(da0:umass-sim0:0:0:0): Retrying command, 1 more tries remain
(da0:umass-sim0:0:0:0): WRITE(10). CDB: 2a 00 00 0b 3f c0 00 00 80 00 
(da0:umass-sim0:0:0:0): CAM status: CCB request completed with an error
(da0:umass-sim0:0:0:0): Retrying command, 0 more tries remain
(da0:umass-sim0:0:0:0): WRITE(10). CDB: 2a 00 00 0b 3f c0 00 00 80 00 
(da0:umass-sim0:0:0:0): CAM status: CCB request completed with an error
(da0:umass-sim0:0:0:0): Error 5, Retries exhausted
g_vfs_done():da0a[WRITE(offset=377585664, length=8192)]error = 5
g_vfs_done():da0a[WRITE(offset=805568512, length=32768)]error = 5
g_vfs_done():da0a[WRITE(offset=825851904, length=16384)]error = 5
g_vfs_done():da0d[READ(offset=39456112640, length=32768)]error = 5
g_vfs_done():vm_fault: pager read error, pid 646 (getty)
da0d[WRITE(offset=51818659840, length=32768)]error = 5
g_vfs_done():da0d[WRITE(offset=51819053056, length=32768)]error = 5
g_vfs_done():da0d[WRITE(offset=51819347968, length=131072)]error = 5
g_vfs_done():da0d[WRITE(offset=51819479040, length=28672)]error = 5
g_vfs_done():da0d[READ(offset=59651031040, length=32768)]error = 5
g_vfs_done():vm_fault: pager read error, pid 817 (sshd)
da0a[WRITE(offset=65536, length=4096)]error = 5
g_vfs_done():da0a[WRITE(offset=8585216, length=4096)]error = 5
g_vfs_done():da0a[WRITE(offset=268599296, length=16384)]error = 5
g_vfs_done():da0a[WRITE(offset=268632064, length=32768)]error = 5
g_vfs_done():da0a[WRITE(offset=268664832, length=32768)]error = 5
g_vfs_done():da0a[WRITE(offset=277078016, length=4096)]error = 5
g_vfs_done():da0a[WRITE(offset=377454592, length=131072)]error = 5
(da0:umass-sim0:0:0:0): WRITE(10). CDB: 2a 00 00 00 41 80 00 00 08 00 
(da0:umass-sim0:0:0:0): CAM status: CCB request completed with an error
(da0:umass-sim0:0:0:0): Retrying command, 3 more tries remain
(da0:umass-sim0:0:0:0): WRITE(10). CDB: 2a 00 00 00 41 80 00 00 08 00 
(da0:umass-sim0:0:0:0): CAM status: CCB request completed with an error
(da0:umass-sim0:0:0:0): Retrying command, 2 more tries remain
(da0:umass-sim0:0:0:0): WRITE(10). CDB: 2a 00 00 00 41 80 00 00 08 00 
(da0:umass-sim0:0:0:0): CAM status: CCB request completed with an error
(da0:umass-sim0:0:0:0): Retrying command, 1 more tries remain
(da0:umass-sim0:0:0:0): WRITE(10). CDB: 2a 00 00 00 41 80 00 00 08 00 
(da0:umass-sim0:0:0:0): CAM status: CCB request completed with an error
(da0:umass-sim0:0:0:0): Retrying command, 0 more tries remain
(da0:umass-sim0:0:0:0): WRITE(10). CDB: 2a 00 00 00 41 80 00 00 08 00 
(da0:umass-sim0:0:0:0): CAM status: CCB request completed with an error
(da0:umass-sim0:0:0:0): Error 5, Retries exhausted
g_vfs_done():da0a[WRITE(offset=377454592, length=32768)]error = 5
g_vfs_done():da0d[WRITE(offset=65536, length=4096)]error = 5
g_vfs_done():da0d[WRITE(offset=20709376, length=4096)]error = 5
g_vfs_done():da0d[READ(offset=17179312128, length=32768)]error = 5
g_vfs_done():vm_fault: pager read error, pid 695 (sshd)
da0d[READ(offset=39456473088, length=32768)]error = 5
g_vfs_done():vm_fault: pager read error, pid 646 (getty)
da0d[WRITE(offset=51207864320, length=32768)]error = 5
g_vfs_done():da0d[WRITE(offset=51208126464, length=32768)]error = 5
g_vfs_done():da0a[WRITE(offset=65536, length=4096)]error = 5
g_vfs_done():da0a[WRITE(offset=8585216, length=4096)]error = 5
(da0:umass-sim0:0:0:0): WRITE(10). CDB: 2a 00 00 0b 3f c0 00 00 80 00 
(da0:umass-sim0:0:0:0): CAM status: CCB request completed with an error
(da0:umass-sim0:0:0:0): Retrying command, 3 more tries remain
(da0:umass-sim0:0:0:0): WRITE(10). CDB: 2a 00 00 0b 3f c0 00 00 80 00 
(da0:umass-sim0:0:0:0): CAM status: CCB request completed with an error
(da0:umass-sim0:0:0:0): Retrying command, 2 more tries remain
(da0:umass-sim0:0:0:0): WRITE(10). CDB: 2a 00 00 0b 3f c0 00 00 80 00 
(da0:umass-sim0:0:0:0): CAM status: CCB request completed with an error
(da0:umass-sim0:0:0:0): Retrying command, 1 more tries remain
(da0:umass-sim0:0:0:0): WRITE(10). CDB: 2a 00 00 0b 3f c0 00 00 80 00 
(da0:umass-sim0:0:0:0): CAM status: CCB request completed with an error
(da0:umass-sim0:0:0:0): Retrying command, 0 more tries remain
(da0:umass-sim0:0:0:0): WRITE(10). CDB: 2a 00 00 0b 3f c0 00 00 80 00 
(da0:umass-sim0:0:0:0): CAM status: CCB request completed with an error
(da0:umass-sim0:0:0:0): Error 5, Retries exhausted
g_vfs_done():da0a[WRITE(offset=377585664, length=16384)]error = 5
g_vfs_done():da0a[WRITE(offset=805568512, length=32768)]error = 5
g_vfs_done():da0d[READ(offset=39456047104, length=32768)]error = 5
g_vfs_done():da0a[WRITE(offset=65536, length=4096)]error = 5
g_vfs_done():da0a[WRITE(offset=8585216, length=4096)]error = 5
g_vfs_done():da0a[WRITE(offset=268599296, length=16384)]error = 5
g_vfs_done():da0a[WRITE(offset=268632064, length=32768)]error = 5
g_vfs_done():da0a[WRITE(offset=268664832, length=32768)]error = 5
g_vfs_done():da0a[WRITE(offset=277078016, length=4096)]error = 5
g_vfs_done():da0a[WRITE(offset=377454592, length=131072)]error = 5
(da0:umass-sim0:0:0:0): WRITE(10). CDB: 2a 00 00 00 41 80 00 00 08 00 
(da0:umass-sim0:0:0:0): CAM status: CCB request completed with an error
(da0:umass-sim0:0:0:0): Retrying command, 3 more tries remain
(da0:umass-sim0:0:0:0): WRITE(10). CDB: 2a 00 00 00 41 80 00 00 08 00 
(da0:umass-sim0:0:0:0): CAM status: CCB request completed with an error
(da0:umass-sim0:0:0:0): Retrying command, 2 more tries remain

There are examples of > 50 seconds for ms/w:

    2      0      0      0    0.0      0     10  53783      0      0    0.0  537.8  da0d
    5      1      0      0    0.0      1     14  54159      0      0    0.0  551.9  da0
    3      0      0      0    0.0      0      3  55101      0      0    0.0  551.9  da0a

There are a lot with > 20 seconds for ms/w, I'll not list them here.
Similarly for > 20 seconds for ms/r.

===
Mark Millard
marklmi at yahoo.com
( dsl-only.net went
away in early 2018-Mar)



More information about the freebsd-arm mailing list