windows - Unique file identifiers on NTFS and $Object_ID -
from articles have found online there appears 2 forms of unique identifiers files on ntfs:
using windows api getfileinformationbyhandle(), can access struct by_handle_file_information, contains volume serial number , low/high file index. http://msdn.microsoft.com/en-us/library/aa363788(vs.85).aspx
$object_id - article http://blogs.technet.com/b/askcore/archive/2010/08/25/ntfs-file-attributes.aspx states:
$object_id – attribute holds id. id used distributed link tracking service. example of how used found in shortcuts. make shortcut on desktop points file. move file. shortcut still function because using way tack source file other path , file name.
not files have $object_id attribute. in fact, isn’t until actual id assigned attribute added file.
i trying understand when object id set. here few questions:
when object id assigned? appear based on above article in 1 scenario occurs when shortcut file created.
does object id assigned automatically when file references file, e.g. word document, embeds visio diagram?
do object ids assigned when distributed link tracking enabled/running or exist regardless of distributed link tracking?
if wanted track unique identifier file, there advantage me use object id (64 bytes) on combined volume serial number , file index (low/high), 12 bytes combined.
thanks, elan
it depends on you're trying do. :)
the file index number, documentation says, identifier file in ntfs (as opposed fat), can change if file deleted , recreated (think backup/restore), though might consider bonus if looking distinguish those.
it's best not worry link tracking service regard object ids, , instead think of them can create/set/read, though again in ntfs.
object ids have overhead, whereas file ids not. applications, end picking file reference numbers (even though potentially fragile).
Comments
Post a Comment