加入收藏 | 设为首页 | 会员中心 | 我要投稿 李大同 (https://www.lidatong.com.cn/)- 科技、建站、经验、云计算、5G、大数据,站长网!
当前位置: 首页 > 综合聚焦 > 服务器 > Windows > 正文

windows – NTFS和$Object_ID上的唯一文件标识符

发布时间:2020-12-14 01:54:39 所属栏目:Windows 来源:网络整理
导读:从我在网上找到的文章看来,NTFS上的文件似乎有两种形式的唯一标识符: 使用Windows API GetFileInformationByHandle(),我们可以访问结构BY_HANDLE_FILE_INFORMATION,其中包含卷序列号和低/高文件索引. http://msdn.microsoft.com/en-us/library/aa363788(VS.
从我在网上找到的文章看来,NTFS上的文件似乎有两种形式的唯一标识符:

>使用Windows API GetFileInformationByHandle(),我们可以访问结构BY_HANDLE_FILE_INFORMATION,其中包含卷序列号和低/高文件索引.
http://msdn.microsoft.com/en-us/library/aa363788(VS.85).aspx
> $Object_ID – 文章http://blogs.technet.com/b/askcore/archive/2010/08/25/ntfs-file-attributes.aspx声明:

$OBJECT_ID – This is an attribute that holds an ID. This ID is used by the Distributed Link Tracking Service. An example of how it is used would be found in shortcuts. Make a shortcut on your desktop that points to a file. Then move that file. The shortcut will still function because it is using a way to tack the source file other than just the path and file name.

Not all files will have an $OBJECT_ID attribute. In fact,it isn’t until an actual ID is to be assigned that the attribute is added to the file.

我试图了解何时设置了对象ID.以下是一些问题:

>何时分配对象ID?根据上面的文章,在一种情况下,当创建文件的快捷方式时,会出现这种情况.
>当文件引用另一个文件时,是否自动分配对象ID,例如一个Word文档,嵌入Visio图表?
>只有在启用/运行分布式链接跟踪时才会分配对象ID,或者无论分布式链接跟踪如何,它们是否都存在?
>如果我想跟踪文件的唯一标识符,那么在组合的卷序列号和文件索引(低/高)上使用对象ID(64字节)是否有任何好处,它们组合为12个字节.

谢谢,Elan

解决方法

这一切都取决于你想要做什么.

(编辑:李大同)

【声明】本站内容均来自网络,其相关言论仅代表作者个人观点,不代表本站立场。若无意侵犯到您的权利,请及时与联系站长删除相关内容!

    推荐文章
      热点阅读