Subscribe to Windows IT Pro
November 03, 2003 12:00 AM

JSI Tip 7400. How do I create a sparse file of a specific size in Windows XP and greater?

Windows IT Pro
InstantDoc ID #79583
Rating: (3)

If you have the need to create a file of a specific size, and don't care about the contents, Windows XP, and greater (Windows NT 5.1+), has the fsutil.exe command-line tool.

The syntax for using fsutil.exe to create a new file is:

fsutil file createnew FileName Size

where FileName is the name of the file, such as test.txt, or c:\folder\test.doc, and Size is the size of the file in bytes.

NOTE: This is useful when an old install program fails because too much freespace causes its' freespace calculation to overflow.



Related Content:

ARTICLE TOOLS

Comments
    There are no comments to display. Be the first one!
You must log on before posting a comment.

Are you a new visitor? Register Here

advertisement

advertisement

Windows is a trademark of the Microsoft group of companies. Windows IT Pro is used by Penton Media Inc. under license from owner.