FILE_OPEN_BY_FILE_ID and RelatedFileObject

I noticed strange create requests at Vista beta 2 NTFS volumes. Create options have FILE_OPEN_BY_FILE_ID set and RelatedFileObject is non-NULL. When I query this RelatedFileObject for FileNameInformation, I get STATUS_INVALID_PARAMETER.

Has anybody an idea what does it mean? How can be file IDs relative?

Best regards,

Michal Vodicka
UPEK, Inc.
[xxxxx@upek.com, http://www.upek.com]

> Has anybody an idea what does it mean? How can be file IDs relative?

I guess that when opened by ID, RelatedFileObject is always ignored.

L.

Michal,

I noticed strange create requests at Vista beta 2 NTFS volumes.
Create options have FILE_OPEN_BY_FILE_ID set and RelatedFileObject
is non-NULL. When I query this RelatedFileObject for
FileNameInformation, I get STATUS_INVALID_PARAMETER.

Has anybody an idea what does it mean? How can be file IDs relative?

The related file object is some other file on the same volume.

You can open a file by ID as follows:

  1. Open a some file o the volume (e.g., the root of the volume, but any file
    will do, even the same file you are opening in step 2)
  2. Do an open by ID relative to the initial open using just the ID as the
    name (length 8). In this case, the create ends up with a related file
    object.

Note that the related file object could itself have been opened by ID. If
that is the case, then you would get STATUS_INVALID_PARAMETER back on the
name query. Conisder this sequence:

  1. FO1 = volume root
  2. FO2 = open by ID on FO1
  3. FO3 = open by ID on FO2

This may explain what you are seeing. Btw, do you know which component is
doing the creates in question?

  • Danilo

Danilo,

thanks for the info, now it makes sense. No, I haven’t checked which component makes these creates. It occurs relatively often; one reliable occurence was when a console application exited but I haven’t examined it further. I just needed to fix my filter driver to not try to check these relative opens and then complain :slight_smile:

Best regards,

Michal Vodicka
UPEK, Inc.
[xxxxx@upek.com, http://www.upek.com]


From: xxxxx@lists.osr.com[SMTP:xxxxx@lists.osr.com] on behalf of Danilo Almeida[SMTP:xxxxx@MIT.EDU]
Reply To: Windows File Systems Devs Interest List
Sent: Monday, June 12, 2006 2:50 AM
To: Windows File Systems Devs Interest List
Subject: RE: [ntfsd] FILE_OPEN_BY_FILE_ID and RelatedFileObject

Michal,

> I noticed strange create requests at Vista beta 2 NTFS volumes.
> Create options have FILE_OPEN_BY_FILE_ID set and RelatedFileObject
> is non-NULL. When I query this RelatedFileObject for
> FileNameInformation, I get STATUS_INVALID_PARAMETER.
>
> Has anybody an idea what does it mean? How can be file IDs relative?

The related file object is some other file on the same volume.

You can open a file by ID as follows:

  1. Open a some file o the volume (e.g., the root of the volume, but any file
    will do, even the same file you are opening in step 2)
  2. Do an open by ID relative to the initial open using just the ID as the
    name (length 8). In this case, the create ends up with a related file
    object.

Note that the related file object could itself have been opened by ID. If
that is the case, then you would get STATUS_INVALID_PARAMETER back on the
name query. Conisder this sequence:

  1. FO1 = volume root
  2. FO2 = open by ID on FO1
  3. FO3 = open by ID on FO2

This may explain what you are seeing. Btw, do you know which component is
doing the creates in question?

  • Danilo

Questions? First check the IFS FAQ at https://www.osronline.com/article.cfm?id=17

You are currently subscribed to ntfsd as: xxxxx@upek.com
To unsubscribe send a blank email to xxxxx@lists.osr.com