Navigation

    全志在线开发者论坛

    • Register
    • Login
    • Search
    • Categories
    • Tags
    • 在线文档
    • 社区主页

    【新人上手】D1哪吒开发板Tina Linux下查看系统内存和测试存储器件读写速率

    MR Series
    1
    1
    1194
    Loading More Posts
    • Oldest to Newest
    • Newest to Oldest
    • Most Votes
    Reply
    • Reply as topic
    Log in to reply
    This topic has been deleted. Only users with topic management privileges can see it.
    • Randolph
      Randolph LV 6 last edited by xiaowenge

      7、查看当前系统内存

      查看内存指令:

      系统优化满足运行内存≤32MB

      echo 3 > /proc/sys/vm/drop_caches;
      free
      

      可以看到

      root@TinaLinux:/# echo 3 > /proc/sys/vm/drop_caches;
      [ 1130.933910] ash (138): drop_caches: 3
      root@TinaLinux:/# free
                   total       used       free     shared    buffers     cached
      Mem:       1021656      37612     984044         36        548       4204
      -/+ buffers/cache:      32860     988796
      Swap:            0          0          0
      

      8、查看储存情况

      SPI-Nand大小查看,方式一:

      cat /proc/partitions
      

      可见

      root@TinaLinux:/# cat /proc/partitions
      major minor  #blocks  name
      
        31        0       1024 mtdblock0
        31        1       4096 mtdblock1
        31        2       1024 mtdblock2
        31        3     256000 mtdblock3
       254        0      20412 ubiblock0_5
      

      以上所有相加即为262144KB=256M。

      方式二:启动log中已经包含

      [    1.425770] sunxi-spinand-phy: TotalSize:    256 M
      

      9、SPI-Nand顺序写

      SPI-Nand顺序写:>=2MB/s(四线)。

      先切换到性能模式

      root@TinaLinux:/# echo "performance"  /sys/devices/system/cpu/cpufreq/policy0/sc
      aling_governor
      

      后执行

      tt /spec/storage/seq
      

      可见如下内容:

      root@TinaLinux:/# tt /spec/storage/seq
      [DEBUG]: ---enter init_entry
      [DEBUG]: --before bind
      [ERROR]: bind socket fail
      [ERROR]: socket init fail
      [ERROR]: (dragonmat_init-289): init entry of socket_db failed
      
      ============================ tasks list ============================
      /spec/storage/seq
      ============================    end     ============================
      [ 3863.564843] [BH_WRN] miss interrupt!
      ------------------- INFO -------------------
      fast mode: false
      async mode:
      ddr total size: 1021656 KB
      cpu policy: performance
      flash device: overlayfs:/overlay
      flash device fs: ubifs
      flash device size: 176576 KB
      flash device free: 78956 KB
      test directory: /mnt/UDISK
      test file size: 73728 KB
      test block size: 4096 KB
      test times for average: 3
      ------------------- END -------------------
      filling ...... OK (4608KB in 5s)
      
      
      =========== the 1 times ===========
      
      clear cache
      sync
      real    0m 0.62s
      user    0m 0.00s
      sys     0m 0.02s
      [ 3870.916775] spec-seq.sh (700): drop_caches: 3
      
              Iozone: Performance Test of File I/O
                      Version $Revision: 3.489 $
                      Compiled for 64 bit mode.
                      Build: linux
      
              Contributors:William Norcott, Don Capps, Isom Crawford, Kirby Collins
                           Al Slater, Scott Rhine, Mike Wisner, Ken Goss
                           Steve Landherr, Brad Smith, Mark Kelly, Dr. Alain CYR,
                           Randy Dunlap, Mark Montague, Dan Million, Gavin Brebner,
                           Jean-Marc Zucconi, Jeff Blomberg, Benny Halevy, Dave Boone,
                           Erik Habbinga, Kris Strecker, Walter Wong, Joshua Root,
                           Fabrice Bacchella, Zhenghua Xue, Qin Li, Darren Sawyer,
                           Vangel Bojaxhi, Ben England, Vikentsi Lapa,
                           Alexey Skidanov, Sudhir Kumar.
      
              Run began: Thu Jan  1 09:04:32 1970
      
              Setting no_unlink
              Auto Mode
              SYNC Mode.
              Include fsync in write timing
              Read & Write sync mode active.
              File size set to 73728 kB
              Record Size 4096 kB
              Dedup+compress enabled
              Dedup activated 50 percent.
              Zero Percent 50
              Command line used: iozone -i 0 -w -a -o -e -+r -s 73728k -r 4096k -f /mnt/UDISK/iozone.tmp -+M -+w 50 -+a 50
              Output is in kBytes/sec
              Time Resolution = 0.000001 seconds.
              Processor cache size set to 1024 kBytes.
              Processor cache line size set to 32 bytes.
              File stride size set to 17 * record size.
                                                                    random    random     bkwd    record    stride
                    kB  reclen    write  rewrite    read    reread    read     write     read   rewrite      read   fwrite frewrite    fread  freread
                 73728    4096     1334     1303
      
      iozone test complete.
      
      clear cache
      sync
      real    0m 1.51s
      user    0m 0.00s
      sys     0m 0.02s
      [ 3989.626106] spec-seq.sh (700): drop_caches: 3
      
              Iozone: Performance Test of File I/O
                      Version $Revision: 3.489 $
                      Compiled for 64 bit mode.
                      Build: linux
      
              Contributors:William Norcott, Don Capps, Isom Crawford, Kirby Collins
                           Al Slater, Scott Rhine, Mike Wisner, Ken Goss
                           Steve Landherr, Brad Smith, Mark Kelly, Dr. Alain CYR,
                           Randy Dunlap, Mark Montague, Dan Million, Gavin Brebner,
                           Jean-Marc Zucconi, Jeff Blomberg, Benny Halevy, Dave Boone,
                           Erik Habbinga, Kris Strecker, Walter Wong, Joshua Root,
                           Fabrice Bacchella, Zhenghua Xue, Qin Li, Darren Sawyer,
                           Vangel Bojaxhi, Ben England, Vikentsi Lapa,
                           Alexey Skidanov, Sudhir Kumar.
      
              Run began: Thu Jan  1 09:06:31 1970
      
              Auto Mode
              SYNC Mode.
              Include fsync in write timing
              Read & Write sync mode active.
              File size set to 73728 kB
              Record Size 4096 kB
              Dedup+compress enabled
              Dedup activated 50 percent.
              Zero Percent 50
              Command line used: iozone -i 1 -a -o -e -+r -s 73728k -r 4096k -f /mnt/UDISK/iozone.tmp -+M -+w 50 -+a 50
              Output is in kBytes/sec
              Time Resolution = 0.000001 seconds.
              Processor cache size set to 1024 kBytes.
              Processor cache line size set to 32 bytes.
              File stride size set to 17 * record size.
                                                                    random    random     bkwd    record    stride
                    kB  reclen    write  rewrite    read    reread    read     write     read   rewrite      read   fwrite frewrite    fread  freread
                 73728    4096                       2040     1356
      
      iozone test complete.
      /usr/bin/spec-seq.sh: line 208: arithmetic syntax error
           2610   615266
      
      iozone test complete.
      
      =========== the 2 times ===========
      
      clear cache
      sync
      real    0m 0.05s
      user    0m 0.02s
      sys     0m 0.00s
      [ 4023.326958] spec-seq.sh (700): drop_caches: 3
      
              Iozone: Performance Test of File I/O
                      Version $Revision: 3.489 $
                      Compiled for 64 bit mode.
                      Build: linux
      
              Contributors:William Norcott, Don Capps, Isom Crawford, Kirby Collins
                           Al Slater, Scott Rhine, Mike Wisner, Ken Goss
                           Steve Landherr, Brad Smith, Mark Kelly, Dr. Alain CYR,
                           Randy Dunlap, Mark Montague, Dan Million, Gavin Brebner,
                           Jean-Marc Zucconi, Jeff Blomberg, Benny Halevy, Dave Boone,
                           Erik Habbinga, Kris Strecker, Walter Wong, Joshua Root,
                           Fabrice Bacchella, Zhenghua Xue, Qin Li, Darren Sawyer,
                           Vangel Bojaxhi, Ben England, Vikentsi Lapa,
                           Alexey Skidanov, Sudhir Kumar.
      
              Run began: Thu Jan  1 09:07:05 1970
      
              Setting no_unlink
              Auto Mode
              SYNC Mode.
              Include fsync in write timing
              Read & Write sync mode active.
              File size set to 73728 kB
              Record Size 4096 kB
              Dedup+compress enabled
              Dedup activated 50 percent.
              Zero Percent 50
              Command line used: iozone -i 0 -w -a -o -e -+r -s 73728k -r 4096k -f /mnt/UDISK/iozone.tmp -+M -+w 50 -+a 50
              Output is in kBytes/sec
              Time Resolution = 0.000001 seconds.
              Processor cache size set to 1024 kBytes.
              Processor cache line size set to 32 bytes.
              File stride size set to 17 * record size.
                                                                    random    random     bkwd    record    stride
                    kB  reclen    write  rewrite    read    reread    read     write     read   rewrite      read   fwrite frewrite    fread  freread
                 73728    4096     2621     2653
      
      iozone test complete.
      
      clear cache
      sync
      real    0m 0.03s
      user    0m 0.00s
      sys     0m 0.01s
      [ 4081.982781] spec-seq.sh (700): drop_caches: 3
      
              Iozone: Performance Test of File I/O
                      Version $Revision: 3.489 $
                      Compiled for 64 bit mode.
                      Build: linux
      
              Contributors:William Norcott, Don Capps, Isom Crawford, Kirby Collins
                           Al Slater, Scott Rhine, Mike Wisner, Ken Goss
                           Steve Landherr, Brad Smith, Mark Kelly, Dr. Alain CYR,
                           Randy Dunlap, Mark Montague, Dan Million, Gavin Brebner,
                           Jean-Marc Zucconi, Jeff Blomberg, Benny Halevy, Dave Boone,
                           Erik Habbinga, Kris Strecker, Walter Wong, Joshua Root,
                           Fabrice Bacchella, Zhenghua Xue, Qin Li, Darren Sawyer,
                           Vangel Bojaxhi, Ben England, Vikentsi Lapa,
                           Alexey Skidanov, Sudhir Kumar.
      
              Run began: Thu Jan  1 09:08:03 1970
      
              Auto Mode
              SYNC Mode.
              Include fsync in write timing
              Read & Write sync mode active.
              File size set to 73728 kB
              Record Size 4096 kB
              Dedup+compress enabled
              Dedup activated 50 percent.
              Zero Percent 50
              Command line used: iozone -i 1 -a -o -e -+r -s 73728k -r 4096k -f /mnt/UDISK/iozone.tmp -+M -+w 50 -+a 50
              Output is in kBytes/sec
              Time Resolution = 0.000001 seconds.
              Processor cache size set to 1024 kBytes.
              Processor cache line size set to 32 bytes.
              File stride size set to 17 * record size.
                                                                    random    random     bkwd    record    stride
                    kB  reclen    write  rewrite    read    reread    read     write     read   rewrite      read   fwrite frewrite    fread  freread
                 73728    4096                       4787   606201
      
      iozone test complete.
      
      =========== the 3 times ===========
      
      clear cache
      sync
      real    0m 0.04s
      user    0m 0.00s
      sys     0m 0.02s
      [ 4099.957266] spec-seq.sh (700): drop_caches: 3
      
              Iozone: Performance Test of File I/O
                      Version $Revision: 3.489 $
                      Compiled for 64 bit mode.
                      Build: linux
      
              Contributors:William Norcott, Don Capps, Isom Crawford, Kirby Collins
                           Al Slater, Scott Rhine, Mike Wisner, Ken Goss
                           Steve Landherr, Brad Smith, Mark Kelly, Dr. Alain CYR,
                           Randy Dunlap, Mark Montague, Dan Million, Gavin Brebner,
                           Jean-Marc Zucconi, Jeff Blomberg, Benny Halevy, Dave Boone,
                           Erik Habbinga, Kris Strecker, Walter Wong, Joshua Root,
                           Fabrice Bacchella, Zhenghua Xue, Qin Li, Darren Sawyer,
                           Vangel Bojaxhi, Ben England, Vikentsi Lapa,
                           Alexey Skidanov, Sudhir Kumar.
      
              Run began: Thu Jan  1 09:08:22 1970
      
              Setting no_unlink
              Auto Mode
              SYNC Mode.
              Include fsync in write timing
              Read & Write sync mode active.
              File size set to 73728 kB
              Record Size 4096 kB
              Dedup+compress enabled
              Dedup activated 50 percent.
              Zero Percent 50
              Command line used: iozone -i 0 -w -a -o -e -+r -s 73728k -r 4096k -f /mnt/UDISK/iozone.tmp -+M -+w 50 -+a 50
              Output is in kBytes/sec
              Time Resolution = 0.000001 seconds.
              Processor cache size set to 1024 kBytes.
              Processor cache line size set to 32 bytes.
              File stride size set to 17 * record size.
                                                                    random    random     bkwd    record    stride
                    kB  reclen    write  rewrite    read    reread    read     write     read   rewrite      read   fwrite frewrite    fread  freread
                 73728    4096     2749     2643
      
      iozone test complete.
      
      clear cache
      sync
      real    0m 0.05s
      user    0m 0.00s
      sys     0m 0.01s
      [ 4157.455638] spec-seq.sh (700): drop_caches: 3
      
              Iozone: Performance Test of File I/O
                      Version $Revision: 3.489 $
                      Compiled for 64 bit mode.
                      Build: linux
      
              Contributors:William Norcott, Don Capps, Isom Crawford, Kirby Collins
                           Al Slater, Scott Rhine, Mike Wisner, Ken Goss
                           Steve Landherr, Brad Smith, Mark Kelly, Dr. Alain CYR,
                           Randy Dunlap, Mark Montague, Dan Million, Gavin Brebner,
                           Jean-Marc Zucconi, Jeff Blomberg, Benny Halevy, Dave Boone,
                           Erik Habbinga, Kris Strecker, Walter Wong, Joshua Root,
                           Fabrice Bacchella, Zhenghua Xue, Qin Li, Darren Sawyer,
                           Vangel Bojaxhi, Ben England, Vikentsi Lapa,
                           Alexey Skidanov, Sudhir Kumar.
      
              Run began: Thu Jan  1 09:09:19 1970
      
              Auto Mode
              SYNC Mode.
              Include fsync in write timing
              Read & Write sync mode active.
              File size set to 73728 kB
              Record Size 4096 kB
              Dedup+compress enabled
              Dedup activated 50 percent.
              Zero Percent 50
              Command line used: iozone -i 1 -a -o -e -+r -s 73728k -r 4096k -f /mnt/UDISK/iozone.tmp -+M -+w 50 -+a 50
              Output is in kBytes/sec
              Time Resolution = 0.000001 seconds.
              Processor cache size set to 1024 kBytes.
              Processor cache line size set to 32 bytes.
              File stride size set to 17 * record size.
                                                                    random    random     bkwd    record    stride
                    kB  reclen    write  rewrite    read    reread    read     write     read   rewrite      read   fwrite frewrite    fread  freread
                 73728    4096                       4792   613387
      
      iozone test complete.
      ------------------- SEQ SPEED -------------------
      seq read: 4063 KB/s
      seq write: 2234 KB/s
      ------------------- end -------------------
      
      ======================== Testcase Information  ========================
      </spec/storage/seq>:
      seq read: 4063 KB/s
      seq write: 2234 KB/s
      
      ---------------------------- /spec/storage/seq ----------------------------
      * task path : /spec/storage/seq
      * task command : spec-seq.sh
      * run times(real/max) : 1/1
      * run parallel : no
      * run alone : no
      * may reboot : no
      * run once time limit : 30758400s
      * run time limit : 30758400s
      * timeout with : pass
      * exit once failed : no
      * real-time log: yes
      * begin date : Thu Jan  1 09:04:19 1970
      * end date : Thu Jan  1 09:09:37 1970
      * result :
      *     num    pid    pgid    return     begin       end    note
      *       0    699     698         0  01:04:19  01:09:37
      * task resource :
      *     user cpu time = 10.421
      *     system cpu time = 167.940
      *     maximum resident size = 11034kB
      *     page faults break times (without I/O) = 50615
      *     page faults break times (with I/O) = 59
      *     input times = 0
      *     output times = 0
      *     wait resource actively times = 288124
      *     wait resource passively times = 2409102
      * run log: real_time_log was set, None!
      ---------------------------- end ----------------------------
      
      ============================ tasks result ============================
      /spec/storage/seq - YES
      ============================     end      ============================
      

      10、SPI-Nand顺序读

      SPI-Nand顺序读:SPI-Nand顺序读:>=4MB/s(四线)

      先切换到性能模式:

      echo "performance" > /sys/devices/system/cpu/cpufreq/policy0/scaling_governor
      

      再执行测试命令 :

      tt /spec/storage/seq
      

      结果如下:

      root@TinaLinux:/# tt /spec/storage/seq
      [DEBUG]: ---enter init_entry
      [DEBUG]: --before bind
      [ERROR]: bind socket fail
      [ERROR]: socket init fail
      [ERROR]: (dragonmat_init-289): init entry of socket_db failed
      
      ============================ tasks list ============================
      /spec/storage/seq
      ============================    end     ============================
      ------------------- INFO -------------------
      fast mode: false
      async mode:
      ddr total size: 1021656 KB
      cpu policy: performance
      flash device: overlayfs:/overlay
      flash device fs: ubifs
      flash device size: 176576 KB
      flash device free: 49176 KB
      test directory: /mnt/UDISK
      test file size: 45056 KB
      test block size: 4096 KB
      test times for average: 3
      ------------------- END -------------------
      filling ... OK (3584KB in 2s)
      
      
      =========== the 1 times ===========
      
      clear cache
      sync
      real    0m 0.04s
      user    0m 0.00s
      sys     0m 0.01s
      [  189.972171] spec-seq.sh (658): drop_caches: 3
      
              Iozone: Performance Test of File I/O
                      Version $Revision: 3.489 $
                      Compiled for 64 bit mode.
                      Build: linux
      
              Contributors:William Norcott, Don Capps, Isom Crawford, Kirby Collins
                           Al Slater, Scott Rhine, Mike Wisner, Ken Goss
                           Steve Landherr, Brad Smith, Mark Kelly, Dr. Alain CYR,
                           Randy Dunlap, Mark Montague, Dan Million, Gavin Brebner,
                           Jean-Marc Zucconi, Jeff Blomberg, Benny Halevy, Dave Boone,
                           Erik Habbinga, Kris Strecker, Walter Wong, Joshua Root,
                           Fabrice Bacchella, Zhenghua Xue, Qin Li, Darren Sawyer,
                           Vangel Bojaxhi, Ben England, Vikentsi Lapa,
                           Alexey Skidanov, Sudhir Kumar.
      
              Run began: Thu Jan  1 08:03:12 1970
      
              Setting no_unlink
              Auto Mode
              SYNC Mode.
              Include fsync in write timing
              Read & Write sync mode active.
              File size set to 45056 kB
              Record Size 4096 kB
              Dedup+compress enabled
              Dedup activated 50 percent.
              Zero Percent 50
              Command line used: iozone -i 0 -w -a -o -e -+r -s 45056k -r 4096k -f /mnt/UDISK/iozone.tmp -+M -+w 50 -+a 50
              Output is in kBytes/sec
              Time Resolution = 0.000001 seconds.
              Processor cache size set to 1024 kBytes.
              Processor cache line size set to 32 bytes.
              File stride size set to 17 * record size.
                                                                    random    random     bkwd    record    stride
                    kB  reclen    write  rewrite    read    reread    read     write     read   rewrite      read   fwrite frewrite    fread  freread
                 45056    4096     2358     2672
      
      iozone test complete.
      
      clear cache
      sync
      real    0m 0.07s
      user    0m 0.00s
      sys     0m 0.02s
      [  228.738321] spec-seq.sh (658): drop_caches: 3
      
              Iozone: Performance Test of File I/O
                      Version $Revision: 3.489 $
                      Compiled for 64 bit mode.
                      Build: linux
      
              Contributors:William Norcott, Don Capps, Isom Crawford, Kirby Collins
                           Al Slater, Scott Rhine, Mike Wisner, Ken Goss
                           Steve Landherr, Brad Smith, Mark Kelly, Dr. Alain CYR,
                           Randy Dunlap, Mark Montague, Dan Million, Gavin Brebner,
                           Jean-Marc Zucconi, Jeff Blomberg, Benny Halevy, Dave Boone,
                           Erik Habbinga, Kris Strecker, Walter Wong, Joshua Root,
                           Fabrice Bacchella, Zhenghua Xue, Qin Li, Darren Sawyer,
                           Vangel Bojaxhi, Ben England, Vikentsi Lapa,
                           Alexey Skidanov, Sudhir Kumar.
      
              Run began: Thu Jan  1 08:03:50 1970
      
              Auto Mode
              SYNC Mode.
              Include fsync in write timing
              Read & Write sync mode active.
              File size set to 45056 kB
              Record Size 4096 kB
              Dedup+compress enabled
              Dedup activated 50 percent.
              Zero Percent 50
              Command line used: iozone -i 1 -a -o -e -+r -s 45056k -r 4096k -f /mnt/UDISK/iozone.tmp -+M -+w 50 -+a 50
              Output is in kBytes/sec
              Time Resolution = 0.000001 seconds.
              Processor cache size set to 1024 kBytes.
              Processor cache line size set to 32 bytes.
              File stride size set to 17 * record size.
                                                                    random    random     bkwd    record    stride
                    kB  reclen    write  rewrite    read    reread    read     write     read   rewrite      read   fwrite frewrite    fread  freread
                 45056    4096                       4951   599763
      
      iozone test complete.
      
      =========== the 2 times ===========
      
      clear cache
      sync
      real    0m 0.04s
      user    0m 0.01s
      sys     0m 0.00s
      [  240.340556] spec-seq.sh (658): drop_caches: 3
      
              Iozone: Performance Test of File I/O
                      Version $Revision: 3.489 $
                      Compiled for 64 bit mode.
                      Build: linux
      
              Contributors:William Norcott, Don Capps, Isom Crawford, Kirby Collins
                           Al Slater, Scott Rhine, Mike Wisner, Ken Goss
                           Steve Landherr, Brad Smith, Mark Kelly, Dr. Alain CYR,
                           Randy Dunlap, Mark Montague, Dan Million, Gavin Brebner,
                           Jean-Marc Zucconi, Jeff Blomberg, Benny Halevy, Dave Boone,
                           Erik Habbinga, Kris Strecker, Walter Wong, Joshua Root,
                           Fabrice Bacchella, Zhenghua Xue, Qin Li, Darren Sawyer,
                           Vangel Bojaxhi, Ben England, Vikentsi Lapa,
                           Alexey Skidanov, Sudhir Kumar.
      
              Run began: Thu Jan  1 08:04:02 1970
      
              Setting no_unlink
              Auto Mode
              SYNC Mode.
              Include fsync in write timing
              Read & Write sync mode active.
              File size set to 45056 kB
              Record Size 4096 kB
              Dedup+compress enabled
              Dedup activated 50 percent.
              Zero Percent 50
              Command line used: iozone -i 0 -w -a -o -e -+r -s 45056k -r 4096k -f /mnt/UDISK/iozone.tmp -+M -+w 50 -+a 50
              Output is in kBytes/sec
              Time Resolution = 0.000001 seconds.
              Processor cache size set to 1024 kBytes.
              Processor cache line size set to 32 bytes.
              File stride size set to 17 * record size.
                                                                    random    random     bkwd    record    stride
                    kB  reclen    write  rewrite    read    reread    read     write     read   rewrite      read   fwrite frewrite    fread  freread
                 45056    4096     2752     2643
      
      iozone test complete.
      
      clear cache
      sync
      real    0m 0.04s
      user    0m 0.00s
      sys     0m 0.01s
      [  276.075574] spec-seq.sh (658): drop_caches: 3
      
              Iozone: Performance Test of File I/O
                      Version $Revision: 3.489 $
                      Compiled for 64 bit mode.
                      Build: linux
      
              Contributors:William Norcott, Don Capps, Isom Crawford, Kirby Collins
                           Al Slater, Scott Rhine, Mike Wisner, Ken Goss
                           Steve Landherr, Brad Smith, Mark Kelly, Dr. Alain CYR,
                           Randy Dunlap, Mark Montague, Dan Million, Gavin Brebner,
                           Jean-Marc Zucconi, Jeff Blomberg, Benny Halevy, Dave Boone,
                           Erik Habbinga, Kris Strecker, Walter Wong, Joshua Root,
                           Fabrice Bacchella, Zhenghua Xue, Qin Li, Darren Sawyer,
                           Vangel Bojaxhi, Ben England, Vikentsi Lapa,
                           Alexey Skidanov, Sudhir Kumar.
      
              Run began: Thu Jan  1 08:04:38 1970
      
              Auto Mode
              SYNC Mode.
              Include fsync in write timing
              Read & Write sync mode active.
              File size set to 45056 kB
              Record Size 4096 kB
              Dedup+compress enabled
              Dedup activated 50 percent.
              Zero Percent 50
              Command line used: iozone -i 1 -a -o -e -+r -s 45056k -r 4096k -f /mnt/UDISK/iozone.tmp -+M -+w 50 -+a 50
              Output is in kBytes/sec
              Time Resolution = 0.000001 seconds.
              Processor cache size set to 1024 kBytes.
              Processor cache line size set to 32 bytes.
              File stride size set to 17 * record size.
                                                                    random    random     bkwd    record    stride
                    kB  reclen    write  rewrite    read    reread    read     write     read   rewrite      read   fwrite frewrite    fread  freread
                 45056    4096                       4994   609400
      
      iozone test complete.
      
      =========== the 3 times ===========
      
      clear cache
      sync
      real    0m 0.04s
      user    0m 0.00s
      sys     0m 0.01s
      [  287.598598] spec-seq.sh (658): drop_caches: 3
      
              Iozone: Performance Test of File I/O
                      Version $Revision: 3.489 $
                      Compiled for 64 bit mode.
                      Build: linux
      
              Contributors:William Norcott, Don Capps, Isom Crawford, Kirby Collins
                           Al Slater, Scott Rhine, Mike Wisner, Ken Goss
                           Steve Landherr, Brad Smith, Mark Kelly, Dr. Alain CYR,
                           Randy Dunlap, Mark Montague, Dan Million, Gavin Brebner,
                           Jean-Marc Zucconi, Jeff Blomberg, Benny Halevy, Dave Boone,
                           Erik Habbinga, Kris Strecker, Walter Wong, Joshua Root,
                           Fabrice Bacchella, Zhenghua Xue, Qin Li, Darren Sawyer,
                           Vangel Bojaxhi, Ben England, Vikentsi Lapa,
                           Alexey Skidanov, Sudhir Kumar.
      
              Run began: Thu Jan  1 08:04:49 1970
      
              Setting no_unlink
              Auto Mode
              SYNC Mode.
              Include fsync in write timing
              Read & Write sync mode active.
              File size set to 45056 kB
              Record Size 4096 kB
              Dedup+compress enabled
              Dedup activated 50 percent.
              Zero Percent 50
              Command line used: iozone -i 0 -w -a -o -e -+r -s 45056k -r 4096k -f /mnt/UDISK/iozone.tmp -+M -+w 50 -+a 50
              Output is in kBytes/sec
              Time Resolution = 0.000001 seconds.
              Processor cache size set to 1024 kBytes.
              Processor cache line size set to 32 bytes.
              File stride size set to 17 * record size.
                                                                    random    random     bkwd    record    stride
                    kB  reclen    write  rewrite    read    reread    read     write     read   rewrite      read   fwrite frewrite    fread  freread
                 45056    4096     2720     2630
      
      iozone test complete.
      
      clear cache
      sync
      real    0m 0.10s
      user    0m 0.00s
      sys     0m 0.03s
      [  323.735964] spec-seq.sh (658): drop_caches: 3
      
              Iozone: Performance Test of File I/O
                      Version $Revision: 3.489 $
                      Compiled for 64 bit mode.
                      Build: linux
      
              Contributors:William Norcott, Don Capps, Isom Crawford, Kirby Collins
                           Al Slater, Scott Rhine, Mike Wisner, Ken Goss
                           Steve Landherr, Brad Smith, Mark Kelly, Dr. Alain CYR,
                           Randy Dunlap, Mark Montague, Dan Million, Gavin Brebner,
                           Jean-Marc Zucconi, Jeff Blomberg, Benny Halevy, Dave Boone,
                           Erik Habbinga, Kris Strecker, Walter Wong, Joshua Root,
                           Fabrice Bacchella, Zhenghua Xue, Qin Li, Darren Sawyer,
                           Vangel Bojaxhi, Ben England, Vikentsi Lapa,
                           Alexey Skidanov, Sudhir Kumar.
      
              Run began: Thu Jan  1 08:05:25 1970
      
              Auto Mode
              SYNC Mode.
              Include fsync in write timing
              Read & Write sync mode active.
              File size set to 45056 kB
              Record Size 4096 kB
              Dedup+compress enabled
              Dedup activated 50 percent.
              Zero Percent 50
              Command line used: iozone -i 1 -a -o -e -+r -s 45056k -r 4096k -f /mnt/UDISK/iozone.tmp -+M -+w 50 -+a 50
              Output is in kBytes/sec
              Time Resolution = 0.000001 seconds.
              Processor cache size set to 1024 kBytes.
              Processor cache line size set to 32 bytes.
              File stride size set to 17 * record size.
                                                                    random    random     bkwd    record    stride
                    kB  reclen    write  rewrite    read    reread    read     write     read   rewrite      read   fwrite frewrite    fread  freread
                 45056    4096                       4948   604526
      
      iozone test complete.
      ------------------- SEQ SPEED -------------------
      seq read: 4964 KB/s
      seq write: 2610 KB/s
      ------------------- end -------------------
      
      ---------------------------- /spec/storage/seq ----------------------------
      * task path : /spec/storage/seq
      * task command : spec-seq.sh
      * run times(real/max) : 1/1
      * run parallel : no
      * run alone : no
      * may reboot : no
      * run once time limit : 30758400s
      * run time limit : 30758400s
      * timeout with : pass
      * exit once failed : no
      * real-time log: yes
      * begin date : Thu Jan  1 08:03:05 1970
      * end date : Thu Jan  1 08:05:37 1970
      * result :
      *     num    pid    pgid    return     begin       end    note
      *       0    657     656         0  00:03:05  00:05:37
      * task resource :
      *     user cpu time = 9.25
      *     system cpu time = 103.770
      *     maximum resident size = 11028kB
      *     page faults break times (without I/O) = 50224
      *     page faults break times (with I/O) = 57
      *     input times = 0
      *     output times = 0
      *     wait resource actively times = 168110
      *     wait resource passively times = 1460900
      * run log: real_time_log was set, None!
      ---------------------------- end ----------------------------
      
      ======================== Testcase Information  ========================
      </spec/storage/seq>:
      seq read: 4964 KB/s
      seq write: 2610 KB/s
      [  359.764953] [BH_WRN] miss interrupt!
      
      ============================ tasks result ============================
      /spec/storage/seq - YES
      
      

      11、SPI-Nand随机写/读

      SPI-Nand随机写:>=120iops(四线)

      先切换到性能模式:

      echo "performance" > /sys/devices/system/cpu/cpufreq/policy0/scaling_governor
      

      再执行测试命令 :

      tt /spec/storage/rand
      

      结果如下:

      root@TinaLinux:/# tt /spec/storage/rand
      [DEBUG]: ---enter init_entry
      [DEBUG]: --before bind
      [ERROR]: bind socket fail
      [ERROR]: socket init fail
      [ERROR]: (dragonmat_init-289): init entry of socket_db failed
      
      ============================ tasks list ============================
      /spec/storage/rand
      ============================    end     ============================
      ------------------- INFO -------------------
      fast mode: true
      async mode:
      ddr total size: 1021656 KB
      cpu policy: performance
      flash device: overlayfs:/overlay
      flash device fs: ubifs
      flash device size: 176576 KB
      flash device free: 175568 KB
      test directory: /mnt/UDISK
      test file size: 166788 KB
      test block size: 4 KB
      test times for average: 3
      ------------------- END -------------------
      initializing ..... OK (166788KB in 124s)
      
      =========== the 1 times ===========
      
      clear cache
      real    0m 0.04s
      user    0m 0.00s
      sys     0m 0.01s
      [ 3650.078789] spec-rand.sh (810): drop_caches: 3
      
              Iozone: Performance Test of File I/O
                      Version $Revision: 3.489 $
                      Compiled for 64 bit mode.
                      Build: linux
      
              Contributors:William Norcott, Don Capps, Isom Crawford, Kirby Collins
                           Al Slater, Scott Rhine, Mike Wisner, Ken Goss
                           Steve Landherr, Brad Smith, Mark Kelly, Dr. Alain CYR,
                           Randy Dunlap, Mark Montague, Dan Million, Gavin Brebner,
                           Jean-Marc Zucconi, Jeff Blomberg, Benny Halevy, Dave Boone,
                           Erik Habbinga, Kris Strecker, Walter Wong, Joshua Root,
                           Fabrice Bacchella, Zhenghua Xue, Qin Li, Darren Sawyer,
                           Vangel Bojaxhi, Ben England, Vikentsi Lapa,
                           Alexey Skidanov, Sudhir Kumar.
      
              Run began: Thu Jan  1 09:00:52 1970
      
              Auto Mode
              Setting no_unlink
              SYNC Mode.
              Read & Write sync mode active.
              File size set to 166788 kB
              Record Size 4 kB
              Dedup+compress enabled
              Dedup activated 50 percent.
              Zero Percent 50
              Command line used: iozone -a -w -i 2 -o -+r -s 166788k -r 4k -f /mnt/UDISK/iozone.tmp -+M -+w 50 -+a 50
              Output is in kBytes/sec
              Time Resolution = 0.000001 seconds.
              Processor cache size set to 1024 kBytes.
              Processor cache line size set to 32 bytes.
              File stride size set to 17 * record size.
                                                                    random    random     bkwd    record    stride
                    kB  reclen    write  rewrite    read    reread    read     write     read   rewrite      read   fwrite frewrite    fread  freread
                166788       4                                         3054     1058
      
      iozone test complete.
      =========== the 2 times ===========
      
      clear cache
      real    0m 0.27s
      user    0m 0.00s
      sys     0m 0.10s
      [ 3866.126220] spec-rand.sh (810): drop_caches: 3
      
              Iozone: Performance Test of File I/O
                      Version $Revision: 3.489 $
                      Compiled for 64 bit mode.
                      Build: linux
      
              Contributors:William Norcott, Don Capps, Isom Crawford, Kirby Collins
                           Al Slater, Scott Rhine, Mike Wisner, Ken Goss
                           Steve Landherr, Brad Smith, Mark Kelly, Dr. Alain CYR,
                           Randy Dunlap, Mark Montague, Dan Million, Gavin Brebner,
                           Jean-Marc Zucconi, Jeff Blomberg, Benny Halevy, Dave Boone,
                           Erik Habbinga, Kris Strecker, Walter Wong, Joshua Root,
                           Fabrice Bacchella, Zhenghua Xue, Qin Li, Darren Sawyer,
                           Vangel Bojaxhi, Ben England, Vikentsi Lapa,
                           Alexey Skidanov, Sudhir Kumar.
      
              Run began: Thu Jan  1 09:04:28 1970
      
              Auto Mode
              Setting no_unlink
              SYNC Mode.
              Read & Write sync mode active.
              File size set to 166788 kB
              Record Size 4 kB
              Dedup+compress enabled
              Dedup activated 50 percent.
              Zero Percent 50
              Command line used: iozone -a -w -i 2 -o -+r -s 166788k -r 4k -f /mnt/UDISK/iozone.tmp -+M -+w 50 -+a 50
              Output is in kBytes/sec
              Time Resolution = 0.000001 seconds.
              Processor cache size set to 1024 kBytes.
              Processor cache line size set to 32 bytes.
              File stride size set to 17 * record size.
                                                                    random    random     bkwd    record    stride
                    kB  reclen    write  rewrite    read    reread    read     write     read   rewrite      read   fwrite frewrite    fread  freread
                166788       4                                         3533     1798
      
      iozone test complete.
      =========== the 3 times ===========
      
      clear cache
      real    0m 0.31s
      user    0m 0.00s
      sys     0m 0.12s
      [ 4009.745178] spec-rand.sh (810): drop_caches: 3
      
              Iozone: Performance Test of File I/O
                      Version $Revision: 3.489 $
                      Compiled for 64 bit mode.
                      Build: linux
      
              Contributors:William Norcott, Don Capps, Isom Crawford, Kirby Collins
                           Al Slater, Scott Rhine, Mike Wisner, Ken Goss
                           Steve Landherr, Brad Smith, Mark Kelly, Dr. Alain CYR,
                           Randy Dunlap, Mark Montague, Dan Million, Gavin Brebner,
                           Jean-Marc Zucconi, Jeff Blomberg, Benny Halevy, Dave Boone,
                           Erik Habbinga, Kris Strecker, Walter Wong, Joshua Root,
                           Fabrice Bacchella, Zhenghua Xue, Qin Li, Darren Sawyer,
                           Vangel Bojaxhi, Ben England, Vikentsi Lapa,
                           Alexey Skidanov, Sudhir Kumar.
      
              Run began: Thu Jan  1 09:06:51 1970
      
              Auto Mode
              Setting no_unlink
              SYNC Mode.
              Read & Write sync mode active.
              File size set to 166788 kB
              Record Size 4 kB
              Dedup+compress enabled
              Dedup activated 50 percent.
              Zero Percent 50
              Command line used: iozone -a -w -i 2 -o -+r -s 166788k -r 4k -f /mnt/UDISK/iozone.tmp -+M -+w 50 -+a 50
              Output is in kBytes/sec
              Time Resolution = 0.000001 seconds.
              Processor cache size set to 1024 kBytes.
              Processor cache line size set to 32 bytes.
              File stride size set to 17 * record size.
                                                                    random    random     bkwd    record    stride
                    kB  reclen    write  rewrite    read    reread    read     write     read   rewrite      read   fwrite frewrite    fread  freread
                166788       4                                         3573     1819
      
      iozone test complete.
      ------------------- RAND SPEED -------------------
      random read: 3386 KB/s
      random write: 1558 KB/s
      random read iops: 846
      random write iops: 389
      ------------------- end -------------------
      
      ---------------------------- /spec/storage/rand ----------------------------
      * task path : /spec/storage/rand
      * task command : spec-rand.sh
      * run times(real/max) : 1/1
      * run parallel : no
      * run alone : no
      * may reboot : no
      * run once time limit : 30758400s
      * run time limit : 30758400s
      * timeout with : pass
      * exit once failed : no
      * real-time log: yes
      * begin date : Thu Jan  1 08:58:42 1970
      * end date : Thu Jan  1 09:09:11 1970
      * result :
      *     num    pid    pgid    return     begin       end    note
      *       0    809     808         0  00:58:42  01:09:11
      * task resource :
      *     user cpu time = 20.769
      *     system cpu time = 363.649
      *     maximum resident size = 11032kB
      *     page faults break times (without I/O) = 43552
      *     page faults break times (with I/O) = 27
      *     input times = 0
      *     output times = 0
      *     wait resource actively times = 688130
      *     wait resource passively times = 5592580
      * run log: real_time_log was set, None!
      ---------------------------- end ----------------------------
      
      ======================== Testcase Information  ========================
      </spec/storage/rand>:
      random read: 3386 KB/s
      random write: 1558 KB/s
      random read iops: 846
      random write iops: 389
      
      ============================ tasks result ============================
      /spec/storage/rand - YES
      ============================     end      ============================
      

      12、TF卡

      支持最大128G TF卡,支持热拔插,提供命令查看储存情况。

      插了卡的情况下执行:

      cat /proc/partitions
      

      结果如下:

      root@TinaLinux:/# cat /proc/partitions
      major minor  #blocks  name
      
        31        0       1024 mtdblock0
        31        1       4096 mtdblock1
        31        2       1024 mtdblock2
        31        3     256000 mtdblock3
       254        0      20412 ubiblock0_5
       179        0   31205376 mmcblk0
       179        1       4032 mmcblk0p1
       179        2        252 mmcblk0p2
       179        3        252 mmcblk0p3
       179        4      10332 mmcblk0p4
       179        5      20412 mmcblk0p5
       179        6        504 mmcblk0p6
       179        7      14112 mmcblk0p7
       259        0   31133724 mmcblk0p8
      
      

      取mmcblk0前的数字,例如31205376 KB,换算得31.1G,往上取整,即为32G卡。

      1 Reply Last reply Reply Quote Share 0
      • Referenced by  q1215200171 q1215200171 
      • Referenced by  q1215200171 q1215200171 
      • 1 / 1
      • First post
        Last post

      Copyright © 2024 深圳全志在线有限公司 粤ICP备2021084185号 粤公网安备44030502007680号

      行为准则 | 用户协议 | 隐私权政策