Take the 2-minute tour ×
Server Fault is a question and answer site for system and network administrators. It's 100% free, no registration required.

This should be really simple but I can't just figure it out. I want to get the cluster size for a partition, e.g. 512, 1024, 2048 .. etc. How can I get this?

On my Windows XP I use a small utility called TreeSize to get the cluster size along with many other details, I believe it should work with Windows 2008 too but I can't believe it's not possible without a utility.

Your help is really appreciated

share|improve this question

4 Answers 4

up vote 9 down vote accepted

Use the following command:

fsutil fsinfo ntfsinfo c: (where c: is the volume/path to obtain the data for)

This will show you smilar to the following:

NTFS Volume Serial Number :       0x9e800d87800d675d
Version :                         3.1
Number Sectors :                  0x000000000c7fffff
Total Clusters :                  0x00000000018fffff
Free Clusters  :                  0x000000000091cfd1
Total Reserved :                  0x00000000000001b0
Bytes Per Sector  :               512
Bytes Per Cluster :               4096
Bytes Per FileRecord Segment    : 1024
Clusters Per FileRecord Segment : 0
Mft Valid Data Length :           0x0000000009fc0000
Mft Start Lcn  :                  0x00000000000c0000
Mft2 Start Lcn :                  0x0000000000c7ffff
Mft Zone Start :                  0x00000000000c9ca0
Mft Zone End   :                  0x00000000000ca7e0
RM Identifier:        07A1930B-353D-11DE-AB63-E15CC5EE82D6
share|improve this answer

You can use diskpart to do this. It's a little involved but it also prevents you from putting another utility on the server.

Commands:

C:\>diskpart
DISKPART>list disk

Disk ###  Status         Size     Free     Dyn  Gpt
--------  -------------  -------  -------  ---  ---
Disk 0    Online          232 GB     9 MB
Disk 1    Online          232 GB  1024 KB

DISKPART>Select disk 1 
DISKPART> list partition

Partition ###  Type              Size     Offset
-------------  ----------------  -------  -------
Partition 1    Primary            232 GB    31 KB

DISKPART> select Partition 1

Partition 1 is now the selected partition.

DISKPART> FILESYSTEMS

Current File System

Type                 : NTFS
Allocation Unit Size : 4096
Flags : 00000000

File Systems Supported for Formatting

Type                 : NTFS (Default)
Allocation Unit Sizes: 512, 1024, 2048, 4096 (Default), 8192, 16K, 32K, 64K

DISKPART>

You want the "Allocation unit Size" entry.

share|improve this answer
    
Thanks, this is the only way to view FAT and other partitions; fsutil only shows cluster size for NTFS. –  SilverbackNet Nov 22 '13 at 23:33

You can look for a small file (~1K) and check the Size on Disk value in the properties. That will be the cluster size for the volume.

share|improve this answer
    
That's an ingenious way to do it. Thanks for the tip! The only drawback is if the clutser size is 512 bytes but since the default clutser size for everything since W2K is at least 4K, it probably won't be an issue. –  joeqwerty Sep 15 '09 at 2:58
    
Geeze if you're using a 512b cluster then I would expect massive disk overheads and huuuge fragmentation! –  Mark Henderson Sep 15 '09 at 3:11
    
True, but you'd have less wated space if there are a large number of small files. –  joeqwerty Sep 15 '09 at 3:16
    
+1 I love the trick! –  Mee Sep 19 '09 at 6:31

Run chdsk and look at the allocation unit size. This is the cluster size.

share|improve this answer
    
I read about this but it takes way too long as it also checks the disk for errors. Is there a way to get the disk details without running the check? –  Mee Sep 15 '09 at 1:28
    
By default it does not check the disk for errors, it only does that if you run it with the /F switch. Running just "chkdsk" runs it in read only mode, so it's really just checking the disk and displaying info. If you run it with the /I and /C switches it will skip some steps and run a little faster. –  joeqwerty Sep 15 '09 at 1:34
    
You're right but it still performs some other checks, there got to be a better way considering that I only want the cluster size. I think I'll eventually use TreeSize but thanks for your answer anyway –  Mee Sep 15 '09 at 1:39
    
Glad to help. Sorry I didn't have more for you. –  joeqwerty Sep 15 '09 at 1:42

Your Answer

 
discard

By posting your answer, you agree to the privacy policy and terms of service.

Not the answer you're looking for? Browse other questions tagged or ask your own question.