1

I have installed an official FreeBSD 13-RELEASE on Raspberry Pi 1 B+ (armv6l) with a Goodram Class 10 16GB SD Card, yet the disk read/write speed is super slow (186 kbytes/sec):

# diskinfo -tv /dev/mmcsd0 /dev/mmcsd0 512 # sectorsize 15634268160 # mediasize in bytes (15G) 30535680 # mediasize in sectors 4194304 # stripesize 0 # stripeoffset SDHC SD16G 2.0 SN 00000247 MFG 04/2021 by 254 42 # Disk descr. 00000247 # Disk ident. # Attachment Yes # TRIM/UNMAP support 0 # Rotation rate in RPM Seek times: Full stroke: 250 iter in 0.954876 sec = 3.820 msec Half stroke: 250 iter in 0.946644 sec = 3.787 msec Quarter stroke: 500 iter in 1.888141 sec = 3.776 msec Short forward: 400 iter in 1.510555 sec = 3.776 msec Short backward: 400 iter in 1.510279 sec = 3.776 msec Seq outer: 2048 iter in 7.485804 sec = 3.655 msec Seq inner: 2048 iter in 7.220448 sec = 3.526 msec Transfer rates: outside: 102400 kbytes in 549.596899 sec = 186 kbytes/sec middle: 102400 kbytes in 549.520508 sec = 186 kbytes/sec inside: 102400 kbytes in 547.767644 sec = 187 kbytes/sec 

Uname:

# uname -a FreeBSD rpi-b 13.0-RELEASE FreeBSD 13.0-RELEASE #0 releng/13.0-n244733-ea31abc261f: Fri Apr 9 06:30:27 UTC 2021 [email protected]:/usr/obj/usr/src/arm.armv6/sys/RPI-B arm 

The overall system speed is super slow either (e.g. boot time is ~ 5 min). Any thoughts what is to be done here?

10
  • Just judging on the knowledge of the other models: Some RB-Pi need max 2GB sd card, what is hard to buy now. It is recomended to save all the OS on USB (flash or HD) except of /boot and MBR, of course. With some models it is possible to set up the RB-Pi to boot form USB only, without need of any SD card. I have not seen the RB-Pi running FreeBSD, lot of users run raspberian clon of debian. Cannot confirm the idea to create just 2GB volume on the SD card. Commented Aug 30, 2021 at 10:27
  • 1
    @schweik, I had been running Arch Linux ARM on this very SBC for years prior, both with SD for /boot and 8GB USB flash for /, as well as 16GB and 32GB SDs for everything, and there had been zero problems with these. I wonder if it is something wrong with the FreeBSD armv6l implementation, or simply the card is faulty. Commented Aug 30, 2021 at 10:50
  • well I tried to remember all my problems with RB-Pi but I never used FreBSD runnig on it. I can recommend to move in bootloader the root directory to another blockdevice - other USB disk, to see if it helps. Also it could be a good practise to enable deep level of logging and analyse the log output. On the other hand the SD cards are flash based, so too many writes can dramaticaly slow down the response. Commented Aug 30, 2021 at 11:47
  • The solution must be some combiantion of this: Try to move the root dir to another blockdevice, reduce the amount of needless writes ro the SD card (do not modify access time ...), analyse the bootlogs and try to find the bottleneck. I hope there must be some FreeBSD - ARM forum where you can get more qualified answers. With a very thiny OS you can load the OS into the RAMdisk, and you can see the speed. Commented Aug 30, 2021 at 11:47
  • 1
    @Philippos here is the dmesg output: dmesg | grep -i mmc | less mmc0: <MMC/SD bus> on sdhci_bcm0 mmc0: Card at relative address 1 failed to set high speed timing mmcsd0: 16GB <SDHC SD16G 2.0 SN 00000247 MFG 04/2021 by 254 42> at mmc0 0.4MHz/4bit/65535-block Commented Aug 30, 2021 at 14:05

1 Answer 1

0

Sandisk Ultra SDHC 16G works for me


  • RPi Zero (ARM ARM1176 r0p7) in 13.0
  • mmcsd0: 16GB <SDHC SU16G 8.0 SN 00736959 MFG 06/2013 by 3 SD> at mmc0 50.0MHz/4bit/65535-block
  • Without any load for occasional testing only
  • 9:34PM up 33 days, 18:34, 1 user, load averages: 0.01, 0.02, 0.00
root@rpi-b:~ # diskinfo -tv /dev/mmcsd0 /dev/mmcsd0 512 # sectorsize 15931539456 # mediasize in bytes (15G) 31116288 # mediasize in sectors 4194304 # stripesize 0 # stripeoffset SDHC SU16G 8.0 SN 00736959 MFG 06/2013 by 3 SD # Disk descr. 00736959 # Disk ident. # Attachment Yes # TRIM/UNMAP support 0 # Rotation rate in RPM Seek times: Full stroke: 250 iter in 0.176581 sec = 0.706 msec Half stroke: 250 iter in 0.346380 sec = 1.386 msec Quarter stroke: 500 iter in 0.318554 sec = 0.637 msec Short forward: 400 iter in 0.249260 sec = 0.623 msec Short backward: 400 iter in 0.242115 sec = 0.605 msec Seq outer: 2048 iter in 1.541124 sec = 0.753 msec Seq inner: 2048 iter in 1.592520 sec = 0.778 msec Transfer rates: outside: 102400 kbytes in 6.119237 sec = 16734 kbytes/sec middle: 102400 kbytes in 6.354481 sec = 16115 kbytes/sec inside: 102400 kbytes in 6.650328 sec = 15398 kbytes/sec 

  • RPi3 (ARM Cortex-A53 r0p4) in 12.2
  • mmcsd0: 16GB <SDHC SU16G 8.0 SN 1CCBFA6F MFG 10/2012 by 3 SD> at mmc0 50.0MHz/4bit/65535-block.
  • Testing low volume Nagios without problems
  • 12:00AM up 89 days, 23:38, 1 user, load averages: 0.00, 0.00, 0.00
root@rpi-3:~ # diskinfo -tv /dev/mmcsd0 /dev/mmcsd0 512 # sectorsize 15931539456 # mediasize in bytes (15G) 31116288 # mediasize in sectors 4194304 # stripesize 0 # stripeoffset SDHC SU16G 8.0 SN 1CCBFA6F MFG 10/2012 by 3 SD # Disk descr. 1CCBFA6F # Disk ident. Yes # TRIM/UNMAP support 0 # Rotation rate in RPM Seek times: Full stroke: 250 iter in 0.825192 sec = 3.301 msec Half stroke: 250 iter in 0.533887 sec = 2.136 msec Quarter stroke: 500 iter in 0.648232 sec = 1.296 msec Short forward: 400 iter in 0.198193 sec = 0.495 msec Short backward: 400 iter in 1.061558 sec = 2.654 msec Seq outer: 2048 iter in 1.054052 sec = 0.515 msec Seq inner: 2048 iter in 0.821306 sec = 0.401 msec Transfer rates: outside: 102400 kbytes in 5.042619 sec = 20307 kbytes/sec middle: 102400 kbytes in 4.768441 sec = 21475 kbytes/sec inside: 102400 kbytes in 5.317633 sec = 19257 kbytes/sec 
2
  • 1
    In which respect does this answer the question ("what is to be done here")? Commented Aug 31, 2021 at 10:24
  • In providing working examples, obviously. (With respect to your comment "You could narrow the problem by trying with a different card vendor"). Commented Aug 31, 2021 at 10:56

You must log in to answer this question.

Start asking to get answers

Find the answer to your question by asking.

Ask question

Explore related questions

See similar questions with these tags.