Created
May 8, 2017 04:03
-
-
Save tom-henderson/e3a98cbd71664aa10a667ef101492561 to your computer and use it in GitHub Desktop.
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
$size = 20Mb # Size in bits, eg 1Mb / 1Gb | |
$dest = 'Z:\Destination\' | |
fsutil file createnew "C:\temp\test.dat" ($size) | |
$Write = Measure-Command { Copy-Item "C:\temp\test.dat" "$dest\test.dat" } | |
$WriteMbps = [Math]::Round( (($size * 8) / $w.TotalSeconds) / 1Mb, 2 ) | |
rm "C:\temp\test.dat" | |
$Read = Measure-Command { Copy-Item "$dest\test.dat" "C:\temp\test.dat" } | |
$ReadMbps = [Math]::Round( (($size * 8) / $w.TotalSeconds) / 1Mb, 2 ) | |
rm "$dest\test.dat" | |
Write-Output "Write speed $WriteMbps Mbps" | |
Write-Output "Read speed $ReadMbps Mbps" |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment