I have 15x1TB disks, each disk usable space should be 1Tib=1000000000000B=1000000000000/1024/1024/1024G=931G. As it shows in command format: # echo | format | grep MD 3. c4t60026B900053AA15000002C74B8F0EADd0 <DELL-MD3000-0735-931.01GB> 4. c4t60026B900053AA15000002C94B8F0EE3d0 <DELL-MD3000-0735-931.01GB> 5. c4t60026B900053AA15000002CB4B8F0F0Dd0 <DELL-MD3000-0735-931.01GB> 6. c4t60026B900053AA15000002CD4B8F0F3Dd0 <DELL-MD3000-0735-931.01GB> 7. c4t60026B900053AA15000002CF4B8F0F6Dd0 <DELL-MD3000-0735-931.01GB> 8. c4t60026B900053AA15000002D14B8F0F9Cd0 <DELL-MD3000-0735-931.01GB> 9. c4t60026B900053AA15000002D34B8F0FC8d0 <DELL-MD3000-0735-931.01GB> 10. c4t60026B900053AA18000002A04B8F0D91d0 <DELL-MD3000-0735-931.01GB> 11. c4t60026B900053AA18000002A24B8F0DC5d0 <DELL-MD3000-0735-931.01GB> 12. c4t60026B900053AA18000002A44B8F0DEDd0 <DELL-MD3000-0735-931.01GB> 13. c4t60026B900053AA180000029C4B8F0D35d0 <DELL-MD3000-0735-931.01GB> 14. c4t60026B900053AA180000029E4B8F0D61d0 <DELL-MD3000-0735-931.01GB> 15. c4t60026B900053AA180000036E4DBF6BA6d0 <DELL-MD3000-0735-931.01GB> 16. c4t60026B900053AA18000002984B8F0CD2d0 <DELL-MD3000-0735-931.01GB> 17. c4t60026B900053AA15000003074B901CF3d0 <DELL-MD3000-0735-931.01GB> # I create 2 raidz1(7 disk) and 1 global hot spare as zpool: NAME STATE READ WRITE CKSUM datapool ONLINE 0 0 0 raidz1 ONLINE 0 0 0 c4t60026B900053AA15000002C74B8F0EADd0 ONLINE 0 0 0 c4t60026B900053AA15000002C94B8F0EE3d0 ONLINE 0 0 0 c4t60026B900053AA15000002CB4B8F0F0Dd0 ONLINE 0 0 0 c4t60026B900053AA15000002CD4B8F0F3Dd0 ONLINE 0 0 0 c4t60026B900053AA15000002CF4B8F0F6Dd0 ONLINE 0 0 0 c4t60026B900053AA15000002D14B8F0F9Cd0 ONLINE 0 0 0 c4t60026B900053AA15000002D34B8F0FC8d0 ONLINE 0 0 0 raidz1 ONLINE 0 0 0 spare ONLINE 0 0 7 c4t60026B900053AA18000002A04B8F0D91d0 ONLINE 10 0 0 194K resilvered c4t60026B900053AA180000036E4DBF6BA6d0 ONLINE 0 0 0 531G resilvered c4t60026B900053AA18000002A24B8F0DC5d0 ONLINE 0 0 0 c4t60026B900053AA18000002A44B8F0DEDd0 ONLINE 0 0 0 c4t60026B900053AA15000003074B901CF3d0 ONLINE 0 0 0 c4t60026B900053AA180000029C4B8F0D35d0 ONLINE 0 0 0 c4t60026B900053AA180000029E4B8F0D61d0 ONLINE 0 0 0 c4t60026B900053AA18000002984B8F0CD2d0 ONLINE 0 0 0 spares c4t60026B900053AA180000036E4DBF6BA6d0 INUSE currently in use I expect to have 14*931/1024=12.7TB zpool space, but actually, it only have 12.6TB zpool space: # zpool list NAME SIZE USED AVAIL CAP HEALTH ALTROOT datapool 12.6T 9.96T 2.66T 78% ONLINE - # And I expect the zfs usable space is 12*931/1024=10.91TB, but actually, it only have 10.58TB zfs space. Can any one explain where the disk space goes? Regards, Ding
On Tue, Jun 14, 2011 at 10:09 PM, Ding Honghui <ding_honghui at vobile.cn> wrote:> I expect to have 14*931/1024=12.7TB zpool space, but actually, it only have > 12.6TB zpool space: > # zpool list > NAME ? ? ? SIZE ? USED ?AVAIL ? ?CAP ?HEALTH ?ALTROOT > datapool ?12.6T ?9.96T ?2.66T ? ?78% ?ONLINE ?- > # > > And I expect the zfs usable space is 12*931/1024=10.91TB, but actually, it > only have 10.58TB zfs space. > > Can any one explain where the disk space goes?I generally like to start with the number of guaranteed sectors on a drive rather than worrying about converting "vendor math". :) Then I do $NSEC/2097152 to get GB (assuming 512-byte sectors). ZFS reserves 1/64 of the pool size to protect copy-on-write as the pool approaches being full. After you make your usable space calculation, subtract 1/64 of that (total*.016) and that should be very close to the available space reported by ''zfs list''. Eric