Links a file to another NTFS inode on the same volume.1
mklink /H "C:\path\to\hard_link" "C:\path\to\source_file"
Example: mklink /H "C:\Users\Dave\doc_link.txt" "C:\Users\Dave\doc.txt"
Creates a pointer to a file or directory, can cross volumes.2
mklink "C:\path\to\soft_link" "C:\path\to\source"
Example: mklink "C:\Users\Dave\doc_symlink.txt" "C:\Users\Dave\doc.txt"
For directories:
mklink /D "C:\Users\Dave\link_dir" "C:\Users\Dave\Docs"
Mount a volume to a directory or drive letter.
mountvol C:\mount\point \\?\Volume{volume_guid}\
Example: mountvol C:\mnt \\?\Volume{12345678-1234-1234-1234-1234567890ab}\
Note: Find volume GUID with mountvol
or Disk Management (diskmgmt.msc
)
Creates a directory link on NTFS.3
mklink /J "C:\path\to\junction" "C:\path\to\target_dir"
Example: mklink /J "C:\Users\Dave\Link" "C:\Users\Dave\Docs"