What is the NTFS USN Journal?
The USN Journal (Update Sequence Number Journal, also called the NTFS change journal) is a log NTFS keeps of every change made to files and directories on a volume: creates, deletes, renames, writes, truncations, attribute and security changes. Each change appends a small record with a timestamp, the file's MFT reference, its parent directory's reference, the file name and a reason bitmask. Windows enables it on the system volume, and backup, search indexing and sync software rely on it, which is why it is almost always there when you need it for an investigation.
Where $UsnJrnl lives: the $J and $Max streams
The journal is the metadata file \$Extend\$UsnJrnl at the root of the volume.
It has two named data streams:
$UsnJrnl:$Jholds the records. It is a sparse stream that behaves like a ring buffer: new records are appended at the end, and NTFS frees the oldest region once the journal grows past its maximum size. A copy of$Jcan be hundreds of megabytes of zeros followed by the live records, so parsers skip the leading zeros.$UsnJrnl:$Maxonly holds the journal's configuration (maximum size, allocation delta, journal ID). It contains no records.
Explorer, copy or robocopy cannot copy either stream from a live system.
Collect $J with a raw-volume tool (FTK Imager, KAPE, RawCopy, The Sleuth
Kit's icat) as described in extracting $UsnJrnl from a disk
image, then drop it into the
parser above.
Inspect it with fsutil
On a live Windows host, from an elevated prompt:
fsutil usn queryjournal C:
This prints the journal ID, the first and next USN, and the configuration, for
example Maximum Size : 0x0000000002000000 (32 MB, the usual size on a client
system volume) and Allocation Delta : 0x0000000000800000 (8 MB). The other
fsutil usn subcommands:
| Command | What it does |
|---|---|
fsutil usn readjournal C: csv | Dumps the records (add startusn= to begin at a given USN) |
fsutil usn readdata C:\path\file.txt | Shows the file's latest USN and its file reference number |
fsutil usn createjournal m=1073741824 a=134217728 C: | Creates the journal or resizes it (here 1 GB max, 128 MB delta) |
fsutil usn deletejournal /d C: | Disables and deletes the journal |
How long does it go back? With a 32 MB journal, a busy workstation keeps
anywhere from hours to a few days of activity. Servers that someone resized to
1 GB or more can keep weeks. Comparing the timestamps of the first and last
records in the parser tells you the window you actually have. Raising
m= before an incident is one of the cheapest forensic-readiness changes you
can make. A deleted or recreated journal (deletejournal, or a new journal
ID) is itself an anti-forensics indicator.
What a record contains (USN_RECORD_V2 / V3)
NTFS writes version 2 records. Version 3 uses 128-bit file IDs (ReFS, and some APIs ask for them); the fields are otherwise the same.
| Field | Size (V2) | What it tells you |
|---|---|---|
RecordLength | 4 | Size of the record, including the name |
MajorVersion / MinorVersion | 2 + 2 | 2.0 on NTFS, 3.0 with 128-bit IDs |
FileReferenceNumber | 8 | MFT entry + sequence number: the key that ties every record for one file together |
ParentFileReferenceNumber | 8 | MFT entry of the parent directory: rebuild full paths with the $MFT |
Usn | 8 | Offset of the record in $J, increases monotonically |
TimeStamp | 8 | Windows FILETIME, UTC |
Reason | 4 | Bitmask of what changed (see below) |
SourceInfo | 4 | Set when the change came from the OS or a replication agent rather than a user |
SecurityId | 4 | Index into $Secure |
FileAttributes | 4 | Hidden, system, directory, archive... |
FileNameLength / FileNameOffset | 2 + 2 | Location of the name |
FileName | variable | UTF-16LE file name only, never the full path |
The reason flags you will read most
| Flag | Value | Meaning |
|---|---|---|
DATA_OVERWRITE | 0x00000001 | Existing data was rewritten |
DATA_EXTEND | 0x00000002 | Data was appended (file grew) |
DATA_TRUNCATION | 0x00000004 | File was truncated |
FILE_CREATE | 0x00000100 | File or directory created |
FILE_DELETE | 0x00000200 | File or directory deleted |
SECURITY_CHANGE | 0x00000800 | ACL changed |
RENAME_OLD_NAME | 0x00001000 | Name before a rename or move |
RENAME_NEW_NAME | 0x00002000 | Name after a rename or move |
BASIC_INFO_CHANGE | 0x00008000 | Attributes or timestamps changed (timestomping shows up here) |
CLOSE | 0x80000000 | Last handle closed: the flags in this record sum up the whole change |
Flags accumulate while a file is open, so a record usually carries several:
FILE_CREATE | DATA_EXTEND | CLOSE is a file written and closed in one go. The
reason codes guide covers every
bit and the patterns behind ransomware, exfiltration and secure-deletion tools.
The journal says what changed and when, not who: there is no user or process in a record. Correlate with Security event logs, Sysmon and Prefetch for that, and see USN journal vs $MFT vs $LogFile for which NTFS artefact answers which question.