Flash Memory Plugin

    • OMV 4.x
    • sweetbb wrote:

      SSH is slow, when loggin in and when typing commands. Also, the OMV web interface is almost dead now, it is so slow. I've rebooted the server and there seems to be no change after the reboot
      Maybe your flash drive sucks (which is pretty normal, the majority of these things does when used as an OS drive).

      Can you please provide the output of these two commands (stopping the second one after 60 seconds with ctrl-c:

      Source Code

      1. df -h
      2. iostat 10
      For iostat to work on x86 it most probably needs an apt-get install sysstat before. And while iostat is running, please click around in OMV's web UI.

      The post was edited 1 time, last by tkaiser ().

    • Thank you. I will do so now. I've installed 'apt-get install sysstat', it worked fine.
      However, when I do 'df -h iostat 10' i get an error message:

      root@quincy:~# df -h iostat 10
      df: iostat: No such file or directory
      df: 10: No such file or directory
      root@quincy:~#

      The post was edited 1 time, last by sweetbb ().

    • Sorry, I really am a noob. I will try again. Ithought it was one command. Before anybody responded on the forum, I managed to remove the flash memory utility, but it seems to have made no difference.

      root@quincy:~# df -h
      Filesystem Size Used Avail Use% Mounted on
      udev 1.9G 0 1.9G 0% /dev
      tmpfs 384M 6.4M 378M 2% /run
      /dev/sde1 25G 16G 7.5G 68% /
      tmpfs 1.9G 0 1.9G 0% /dev/shm
      tmpfs 5.0M 0 5.0M 0% /run/lock
      tmpfs 1.9G 0 1.9G 0% /sys/fs/cgroup
      tmpfs 1.9G 0 1.9G 0% /tmp
      /dev/sdb1 7.3T 5.2T 2.1T 72% /srv/dev-disk-by-label-Data2
      /dev/sdd1 7.3T 618G 6.7T 9% /srv/dev-disk-by-label-Data4
      /dev/sda1 7.3T 5.7T 1.6T 79% /srv/dev-disk-by-label-Data1
      /dev/sdc1 7.3T 93M 7.3T 1% /srv/dev-disk-by-label-Data3
      cy:~# df -h iostat 10
      Linux 4.19.0-0.bpo.4-amd64 (quincy) 22/05/2019 _x86_64_ (2 CPU)
      avg-cpu: %user %nice %system %iowait %steal %idle
      2.14 0.00 6.37 22.38 0.00 69.10
      Device: tps kB_read/s kB_wrtn/s kB_read kB_wrtn
      avg-cpu: %user %nice %system %iowait %steal %idle
      1.73 0.00 6.66 2.95 0.00 88.67
      Device: tps kB_read/s kB_wrtn/s kB_read kB_wrtn
      avg-cpu: %user %nice %system %iowait %steal %idle
      1.97 0.00 5.20 21.05 0.00 71.78
      Device: tps kB_read/s kB_wrtn/s kB_read kB_wrtn
      avg-cpu: %user %nice %system %iowait %steal %idle
      1.89 0.00 5.66 4.59 0.00 87.87
      Device: tps kB_read/s kB_wrtn/s kB_read kB_wrtn
      avg-cpu: %user %nice %system %iowait %steal %idle
      1.78 0.00 7.57 12.20 0.00 78.44
      Device: tps kB_read/s kB_wrtn/s kB_read kB_wrtn
    • Sorry, I really am a noob. I will try again. Ithought it was one command. Before anybody responded on the forum, I managed to remove the flash memory utility, but it seems to have made no difference.


      root@quincy:~# df -h
      Filesystem Size Used Avail Use% Mounted on
      udev 1.9G 0 1.9G 0% /dev
      tmpfs 384M 6.5M 378M 2% /run
      /dev/sde1 25G 16G 7.5G 68% /
      tmpfs 1.9G 0 1.9G 0% /dev/shm
      tmpfs 5.0M 0 5.0M 0% /run/lock
      tmpfs 1.9G 0 1.9G 0% /sys/fs/cgroup
      tmpfs 1.9G 0 1.9G 0% /tmp
      /dev/sdb1 7.3T 5.2T 2.1T 72% /srv/dev-disk-by-label-Data2
      /dev/sdd1 7.3T 618G 6.7T 9% /srv/dev-disk-by-label-Data4
      /dev/sda1 7.3T 5.7T 1.6T 79% /srv/dev-disk-by-label-Data1
      /dev/sdc1 7.3T 93M 7.3T 1% /srv/dev-disk-by-label-Data3
      root@quincy:~# iostat 10
      Linux 4.19.0-0.bpo.4-amd64 (quincy) 22/05/2019 _x86_64_ (2 CPU)
      avg-cpu: %user %nice %system %iowait %steal %idle
      2.06 0.00 6.57 19.42 0.00 71.94
      Device: tps kB_read/s kB_wrtn/s kB_read kB_wrtn
      sdd 0.34 17.08 0.01 18594 9
      sdc 0.36 18.65 0.01 20294 9
      sdb 1.24 20.30 0.01 22094 9
      sda 33.38 61.27 21553.29 66686 23457089
      sde 15.70 360.23 77.83 392047 84704
      avg-cpu: %user %nice %system %iowait %steal %idle
      6.07 0.00 7.95 7.24 0.00 78.74
      Device: tps kB_read/s kB_wrtn/s kB_read kB_wrtn
      sdd 1.00 54.75 0.00 547 0
      sdc 0.60 37.95 0.00 379 0
      sdb 0.20 0.80 0.00 8 0
      sda 1.20 3.15 2.40 31 24
      sde 25.70 520.80 279.20 5208 2792
      avg-cpu: %user %nice %system %iowait %steal %idle
      4.38 0.00 6.88 20.63 0.00 68.11
      Device: tps kB_read/s kB_wrtn/s kB_read kB_wrtn
      sdd 0.00 0.00 0.00 0 0
      sdc 0.00 0.00 0.00 0 0
      sdb 0.00 0.00 0.00 0 0
      sda 52.80 1.20 48894.00 12 488940
      sde 24.90 247.60 21.20 2476 212
      avg-cpu: %user %nice %system %iowait %steal %idle
      10.03 0.00 9.67 13.28 0.00 67.02
      Device: tps kB_read/s kB_wrtn/s kB_read kB_wrtn
      sdd 0.00 0.00 0.00 0 0
      sdc 0.00 0.00 0.00 0 0
      sdb 0.00 0.00 0.00 0 0
      sda 4.00 0.00 3715.60 0 37156
      sde 122.60 7287.20 52.40 72872 524
      avg-cpu: %user %nice %system %iowait %steal %idle
      6.79 0.00 9.55 17.11 0.00 66.55
      Device: tps kB_read/s kB_wrtn/s kB_read kB_wrtn
      sdd 0.00 0.00 0.00 0 0
      sdc 0.00 0.00 0.00 0 0
      sdb 0.00 0.00 0.00 0 0
      sda 49.20 0.00 45701.60 0 457016
      sde 35.90 686.00 41.60 6860 416
    • sweetbb wrote:

      df -h iostat 10
      My mistake, sorry. It should've been two lines instead.

      Anyway, your output shows that the flashmemory plugin is NOT active and that your flash drive sucks as expected. That's the output:

      Source Code

      1. avg-cpu: %user %nice %system %iowait %steal %idle
      2. 2.14 0.00 6.37 22.38 0.00 69.10
      3. 1.73 0.00 6.66 2.95 0.00 88.67
      4. 1.97 0.00 5.20 21.05 0.00 71.78
      5. 1.89 0.00 5.66 4.59 0.00 87.87
      6. 1.78 0.00 7.57 12.20 0.00 78.44
      High %iowait values are an indication that your flash drive is horribly slow if it's about random IO.

      I would try a reboot now and also disable Monitoring in the UI since most probably that's the culprit. Then please check again with df -h since there should be a bunch of folder2ram occurrences otherwise the plugin still isn't active.
    • I've rebooted the system now. Logging in via the shellinabox is much faster now. Before you answered I did uninstall that flash-drive utility, so it is no longer on the system.

      root@quincy:~# df -h
      Filesystem Size Used Avail Use% Mounted on
      udev 1.9G 0 1.9G 0% /dev
      tmpfs 384M 5.9M 379M 2% /run
      /dev/sde1 25G 16G 7.5G 68% /
      tmpfs 1.9G 0 1.9G 0% /dev/shm
      tmpfs 5.0M 0 5.0M 0% /run/lock
      tmpfs 1.9G 0 1.9G 0% /sys/fs/cgroup
      tmpfs 1.9G 0 1.9G 0% /tmp
      /dev/sda1 7.3T 5.7T 1.6T 79% /srv/dev-disk-by-label-Data1
      /dev/sdb1 7.3T 5.2T 2.1T 72% /srv/dev-disk-by-label-Data2
      /dev/sdc1 7.3T 93M 7.3T 1% /srv/dev-disk-by-label-Data3
      /dev/sdd1 7.3T 618G 6.7T 9% /srv/dev-disk-by-label-Data4
      root@quincy:~#


      root@quincy:~# iostat 10
      Linux 4.19.0-0.bpo.4-amd64 (quincy) 22/05/2019 _x86_64_ (2 CPU)
      avg-cpu: %user %nice %system %iowait %steal %idle
      1.53 0.11 1.95 9.12 0.00 87.29
      Device: tps kB_read/s kB_wrtn/s kB_read kB_wrtn
      sda 40.65 212.30 2031.08 66202 633373
      sdb 4.39 70.84 0.03 22090 9
      sdd 1.17 57.92 0.03 18062 9
      sdc 1.13 57.78 0.03 18018 9
      sde 58.24 1127.05 20.38 351459 6356
      avg-cpu: %user %nice %system %iowait %steal %idle
      5.22 0.00 7.70 9.27 0.00 77.81
      Device: tps kB_read/s kB_wrtn/s kB_read kB_wrtn
      sda 14.10 0.00 13901.60 0 139016
      sdb 0.00 0.00 0.00 0 0
      sdd 0.00 0.00 0.00 0 0
      sdc 0.00 0.00 0.00 0 0
      sde 5.10 3.60 27.20 36 272
      avg-cpu: %user %nice %system %iowait %steal %idle
      16.47 0.00 11.59 28.11 0.00 43.82
      Device: tps kB_read/s kB_wrtn/s kB_read kB_wrtn
      sda 47.80 0.40 45646.40 4 456464
      sdb 0.00 0.00 0.00 0 0
      sdd 0.00 0.00 0.00 0 0
      sdc 0.00 0.00 0.00 0 0
      sde 83.10 4796.00 26.00 47960 260
      ^C
      root@quincy:~#


    • To post these command outputs please use the </> symbol in the toolbar since otherwise spacing is incorrect.

      That's what iostat still says:

      Source Code

      1. avg-cpu: %user %nice %system %iowait %steal %idle
      2. 16.47 0.00 11.59 28.11 0.00 43.82
      3. Device tps kB_read/s kB_wrtn/s kB_read kB_wrtn
      4. sda 47.80 0.40 45646.40 4 456464
      5. sde 83.10 4796.00 26.00 47960 260
      sde is your flash drive and there's an awful lot of read activity (+80 transactions per second). And %iowait is still way too high. I would try to reinstall the flashmemory plugin and check again.
    • Source Code

      1. root@quincy:~# df -h
      2. Filesystem Size Used Avail Use% Mounted on
      3. udev 1.9G 0 1.9G 0% /dev
      4. tmpfs 384M 14M 371M 4% /run
      5. /dev/sde1 25G 16G 7.5G 68% /
      6. tmpfs 1.9G 0 1.9G 0% /dev/shm
      7. tmpfs 5.0M 0 5.0M 0% /run/lock
      8. tmpfs 1.9G 0 1.9G 0% /sys/fs/cgroup
      9. tmpfs 1.9G 0 1.9G 0% /tmp
      10. /dev/sda1 7.3T 5.8T 1.5T 80% /srv/dev-disk-by-label-Data1
      11. /dev/sdb1 7.3T 5.2T 2.1T 72% /srv/dev-disk-by-label-Data2
      12. /dev/sdc1 7.3T 93M 7.3T 1% /srv/dev-disk-by-label-Data3
      13. /dev/sdd1 7.3T 843G 6.4T 12% /srv/dev-disk-by-label-Data4
      14. folder2ram 1.9G 45M 1.9G 3% /var/log
      15. folder2ram 1.9G 0 1.9G 0% /var/tmp
      16. folder2ram 1.9G 916K 1.9G 1% /var/lib/openmediavault/rrd
      17. folder2ram 1.9G 16K 1.9G 1% /var/spool
      18. folder2ram 1.9G 8.3M 1.9G 1% /var/lib/rrdcached
      19. folder2ram 1.9G 12K 1.9G 1% /var/lib/monit
      20. folder2ram 1.9G 4.0K 1.9G 1% /var/lib/php
      21. folder2ram 1.9G 0 1.9G 0% /var/lib/netatalk/CNID
      22. folder2ram 1.9G 420K 1.9G 1% /var/cache/samba
      23. root@quincy:~# iostat 10
      24. Linux 4.19.0-0.bpo.4-amd64 (quincy) 22/05/2019 _x86_64_ (2 CPU)
      25. avg-cpu: %user %nice %system %iowait %steal %idle
      26. 3.50 0.39 15.85 30.73 0.00 49.53
      27. Device: tps kB_read/s kB_wrtn/s kB_read kB_wrtn
      28. sda 22.44 25.05 17867.01 128506 91643997
      29. sdb 0.27 4.33 0.00 22234 9
      30. sdd 54.46 8.07 46355.90 41394 237770057
      31. sdc 0.07 3.62 0.00 18560 9
      32. sde 20.51 221.68 111.85 1137059 573720
      33. avg-cpu: %user %nice %system %iowait %steal %idle
      34. 6.79 0.00 21.15 35.51 0.00 36.54
      35. Device: tps kB_read/s kB_wrtn/s kB_read kB_wrtn
      36. sda 23.40 0.00 20115.60 0 201156
      37. sdb 0.00 0.00 0.00 0 0
      38. sdd 76.90 0.00 61870.80 0 618708
      39. sdc 0.00 0.00 0.00 0 0
      40. sde 36.50 252.40 138.40 2524 1384
      41. avg-cpu: %user %nice %system %iowait %steal %idle
      42. 12.88 1.73 24.89 33.13 0.00 27.38
      Display All
    • Source Code

      1. root@quincy:~# df -h
      2. Filesystem Size Used Avail Use% Mounted on
      3. udev 1.9G 0 1.9G 0% /dev
      4. tmpfs 384M 14M 371M 4% /run
      5. /dev/sde1 25G 16G 7.5G 68% /
      6. tmpfs 1.9G 0 1.9G 0% /dev/shm
      7. tmpfs 5.0M 0 5.0M 0% /run/lock
      8. tmpfs 1.9G 0 1.9G 0% /sys/fs/cgroup
      9. tmpfs 1.9G 0 1.9G 0% /tmp
      10. /dev/sda1 7.3T 5.8T 1.5T 80% /srv/dev-disk-by-label-Data1
      11. /dev/sdb1 7.3T 5.2T 2.1T 72% /srv/dev-disk-by-label-Data2
      12. /dev/sdc1 7.3T 93M 7.3T 1% /srv/dev-disk-by-label-Data3
      13. /dev/sdd1 7.3T 843G 6.4T 12% /srv/dev-disk-by-label-Data4
      14. folder2ram 1.9G 45M 1.9G 3% /var/log
      15. folder2ram 1.9G 0 1.9G 0% /var/tmp
      16. folder2ram 1.9G 916K 1.9G 1% /var/lib/openmediavault/rrd
      17. folder2ram 1.9G 16K 1.9G 1% /var/spool
      18. folder2ram 1.9G 8.3M 1.9G 1% /var/lib/rrdcached
      19. folder2ram 1.9G 12K 1.9G 1% /var/lib/monit
      20. folder2ram 1.9G 4.0K 1.9G 1% /var/lib/php
      21. folder2ram 1.9G 0 1.9G 0% /var/lib/netatalk/CNID
      22. folder2ram 1.9G 420K 1.9G 1% /var/cache/samba
      23. root@quincy:~# iostat 10
      24. Linux 4.19.0-0.bpo.4-amd64 (quincy) 22/05/2019 _x86_64_ (2 CPU)
      25. avg-cpu: %user %nice %system %iowait %steal %idle
      26. 3.50 0.39 15.85 30.73 0.00 49.53
      27. Device: tps kB_read/s kB_wrtn/s kB_read kB_wrtn
      28. sda 22.44 25.05 17867.01 128506 91643997
      29. sdb 0.27 4.33 0.00 22234 9
      30. sdd 54.46 8.07 46355.90 41394 237770057
      31. sdc 0.07 3.62 0.00 18560 9
      32. sde 20.51 221.68 111.85 1137059 573720
      33. avg-cpu: %user %nice %system %iowait %steal %idle
      34. 6.79 0.00 21.15 35.51 0.00 36.54
      35. Device: tps kB_read/s kB_wrtn/s kB_read kB_wrtn
      36. sda 23.40 0.00 20115.60 0 201156
      37. sdb 0.00 0.00 0.00 0 0
      38. sdd 76.90 0.00 61870.80 0 618708
      39. sdc 0.00 0.00 0.00 0 0
      40. sde 36.50 252.40 138.40 2524 1384
      41. avg-cpu: %user %nice %system %iowait %steal %idle
      42. 12.88 1.73 24.89 33.13 0.00 27.38
      Display All
    • sweetbb wrote:

      I don't trust the flash drive installation

      There's nothing wrong with flash other than

      • Counterfeit flash storage (that's the root cause for so many people having bad experiences with flash drives. If you buy genuine flash products and test them for fake capacity first then everything's ok)
      • Due to high Write Amplification flash can wear out a lot faster than necessary. That's what the flashmemory plugin is for and that's why on installations running on flash memory OMV's internal monitoring should be disabled (unfortunately the so called 'New User Guide' recommends to enable monitoring -- see the remark for page 38). I already suggested to disable monitoring. Did you follow the advice?
    • Just make sure to use a good quality USB thumbdrive and the flash memory plugin. And don't use the rootfs for data storage. Two thumbdrives simplifies backups and rollback a lot. Flash improves performance. And frees a valuable hdd for use for data. Possibly use high end USB drives, like SanDisk Extreme Pro. But still use the flash memory plugin.
      OMV 4, 7 x ODROID HC2, 1 x ODROID HC1, 5 x 12TB, 1 x 8TB, 1 x 2TB SSHD, 1 x 500GB SSD, GbE, WiFi mesh

      The post was edited 1 time, last by Adoby ().

    • HI tkaiser,

      Yes, I followed your advice, it is disabled, and the flash utility has been re-installed. The system seems stable today. I will see once all files have been synchronized. Then data transfers will be much reduced.
      I'll check but I believe it is a high quality thumb drive, bought it from Makro, a reputable dealer (I would like to believe they are). Makro are owned by MassMart these days. (I live in South Africa). It is a SanDisk UltraFit USB 3.1 Flash drive. The rated speeds are up to 130MB/s on the packaging.
    • sweetbb wrote:

      It is a SanDisk UltraFit USB 3.1 Flash drive
      That's at least written on the outside. SanDisk estimated some time ago that 30% of flash products showing their logo are fakes. That's why testing for fake capacity prior to usage is so important :)

      Even reputable sellers can't prevent fake products being inserted into the supply chain early. Though reputable sellers with a 'no questions asked' return/refund policy at least allow for compensation. But this still requires testing the device in question with either F3 or H2testw. Testing with f3 is even possible from within a running Linux/OMV install (on the OMV images for ARM I prepared this long ago, there it's just executing armbianmonitor -c $HOME but on x86 you are on your own -- in case of interest feel free to ask for details)
    • tkaiser wrote:

      (on the OMV images for ARM ... it's just executing armbianmonitor -c $HOME
      Since I had to check the internal eMMC of a mini server (NanoPi M1 Plus) anyway I did it right now and here the results as an example (the most important stuff at the bottom: Health status and performance overview):

      Source Code

      1. tk@monit:~$ armbianmonitor -c $HOME
      2. WARNING: It seems you're not testing the SD card but instead /dev/mmcblk1p1 (ext4)
      3. Starting to fill /dev/mmcblk1p1 with test patterns, please be patient this might take a very long time
      4. F3 write 7.0
      5. Copyright (C) 2010 Digirati Internet LTDA.
      6. This is free software; see the source for copying conditions.
      7. Free space: 5.54 GB
      8. Creating file 1.h2w ... OK!
      9. Creating file 2.h2w ... OK!
      10. Creating file 3.h2w ... OK!
      11. Creating file 4.h2w ... OK!
      12. Creating file 5.h2w ... OK!
      13. Creating file 6.h2w ... OK!
      14. Free space: 96.82 MB
      15. Average writing speed: 7.40 MB/s
      16. Now verifying the written data:
      17. F3 read 7.0
      18. Copyright (C) 2010 Digirati Internet LTDA.
      19. This is free software; see the source for copying conditions.
      20. SECTORS ok/corrupted/changed/overwritten
      21. Validating file 1.h2w ... 2097152/ 0/ 0/ 0
      22. Validating file 2.h2w ... 2097152/ 0/ 0/ 0
      23. Validating file 3.h2w ... 2097152/ 0/ 0/ 0
      24. Validating file 4.h2w ... 2097152/ 0/ 0/ 0
      25. Validating file 5.h2w ... 2097152/ 0/ 0/ 0
      26. Validating file 6.h2w ... 934656/ 0/ 0/ 0
      27. Data OK: 5.45 GB (11420416 sectors)
      28. Data LOST: 0.00 Byte (0 sectors)
      29. Corrupted: 0.00 Byte (0 sectors)
      30. Slightly changed: 0.00 Byte (0 sectors)
      31. Overwritten: 0.00 Byte (0 sectors)
      32. Average reading speed: 76.93 MB/s
      33. Starting iozone tests. Be patient, this can take a very long time to complete:
      34. Iozone: Performance Test of File I/O
      35. Version $Revision: 3.429 $
      36. Compiled for 32 bit mode.
      37. Build: linux
      38. Contributors:William Norcott, Don Capps, Isom Crawford, Kirby Collins
      39. Al Slater, Scott Rhine, Mike Wisner, Ken Goss
      40. Steve Landherr, Brad Smith, Mark Kelly, Dr. Alain CYR,
      41. Randy Dunlap, Mark Montague, Dan Million, Gavin Brebner,
      42. Jean-Marc Zucconi, Jeff Blomberg, Benny Halevy, Dave Boone,
      43. Erik Habbinga, Kris Strecker, Walter Wong, Joshua Root,
      44. Fabrice Bacchella, Zhenghua Xue, Qin Li, Darren Sawyer,
      45. Vangel Bojaxhi, Ben England, Vikentsi Lapa.
      46. Run began: Thu May 23 11:28:27 2019
      47. Include fsync in write timing
      48. O_DIRECT feature enabled
      49. Auto Mode
      50. File size set to 102400 kB
      51. Record Size 4 kB
      52. Record Size 512 kB
      53. Record Size 16384 kB
      54. Command line used: iozone -e -I -a -s 100M -r 4k -r 512k -r 16M -i 0 -i 1 -i 2
      55. Output is in kBytes/sec
      56. Time Resolution = 0.000001 seconds.
      57. Processor cache size set to 1024 kBytes.
      58. Processor cache line size set to 32 bytes.
      59. File stride size set to 17 * record size.
      60. random random bkwd record stride
      61. kB reclen write rewrite read reread read write read rewrite read fwrite frewrite fread freread
      62. 102400 4 3753 7213 16275 16045 13633 4111
      63. 102400 512 10289 7545 77413 70826 76048 6414
      64. 102400 16384 7199 9650 80916 80943 80967 18441
      65. iozone test complete.
      66. The results from testing /dev/mmcblk1p1 (ext4):
      67. Data OK: 5.45 GB (11420416 sectors)
      68. Data LOST: 0.00 Byte (0 sectors)
      69. Average writing speed: 7.40 MB/s
      70. Average reading speed: 76.93 MB/s
      71. random random
      72. reclen write rewrite read reread read write
      73. 4 3753 7213 16275 16045 13633 4111
      74. 512 10289 7545 77413 70826 76048 6414
      75. 16384 7199 9650 80916 80943 80967 18441
      76. Health summary: OK
      77. Performance summary:
      78. Sequential reading speed: 76.93 MB/s
      79. 4K random reading speed: 13633 KB/s
      80. Sequential writing speed: 7.40 MB/s
      81. 4K random writing speed: 4111 KB/s
      82. To interpret the results above correctly or search for better storage
      83. alternatives please refer to http://oss.digirati.com.br/f3/ and also
      84. http://www.jeffgeerling.com/blogs/jeff-geerling/raspberry-pi-microsd-card
      85. and http://thewirecutter.com/reviews/best-microsd-card/
      Display All