Use the Fsutil command to create a file of a certain size in Windows 10.
Sometimes you need to create a file of a certain size for purposes essays. Of course, you can create it with a third-party application, such as WinRAR, by compressing a large volume archives in rar or zip files of desired volume, but do you know that Windows 10 offers you a ready-made solution through the Fsutil command?
Windows comes with a special command-line tool, called fsutil. This tool is aimed at advanced users and system administrators. Performs tasks related to FAT and NTFS file systems such as management mount points, manage sporadic files, or remove a volume. If used without parameters, Fsutil displays a list of the individual commands supported. The tool has been available on Windows since Windows XP.
You must be logged in as an Administrator or a member of the Administrators group to use Fsutil. You may need to enable it WSL mode to have full functionality in fsutil.
One of the parameters of fsutil is the "file". Contains a list of subtitles that can be used to find a file with a username (if Disk Quotas are enabled), to find a selected file range, to set a short file name, to zero data in a file, to create a new file etc
In our case, we will use the fsutil application to create a specific size file in Windows 10. See how.
Step 1: Open a command line with administrative privileges.
Step 2: Type or copy-paste the following command: fsutil file createnew
Replace the part with the actual file name and the desired file size in BYTES.
The following command will create the iguru.bin file with 4 kilobytes size under c: \.
fsutil file createnew c: \ config.bin 4096
Do not forget to put quotes in your file path if it contains spaces.