Section 6.3. Device Namespace

   

6.3 Device Namespace

The device namespace has evolved over the years with different versions of the Windows NT operating system. To allow backward compatibility, the new namespace is joined with the old namespace via symbolic links. In addition, kernel mode drivers create a namespace in kernel mode, using the services of the Object Manager. User mode applications see a different namespace, and the two are logically mapped to each other via symbolic links. Staying on top of the namespace issues is not an easy task. This section takes a humble stab at enumerating most of the storage- related important device names created.

The disk class driver creates device objects to represent each physical disk. These objects are named in the format "\device\harddiskX," where X is a number starting from value zero and increases by one for each new hard disk found on the system.

The disk class driver also creates a device object for each primary partition that it finds. The disk class driver uses the I/O Manager API IoReadPartitionTable to identify all primary partitions on a disk. These primary partitions are named in the format "\device\harddiskX\partitionY," where X represents the physical disk number and Y represents the primary partition number on that physical disk. The I/O Manager creates a symbolic link in the format "\??\PhysicalDriveX," where X is a number starting from zero that maps to "\device\harddiskX\partitionY".

The LDM volume manager creates an object for each volume that it is responsible for. This device object has a name with the format "\Device\HarddiskDmVolumes\PhysicalDmVolumes\BlockVolumeX," where X is an identifier that the volume manager assigns to the volume. This kernel mode device is mapped to a Win32 device created by the Mount Manager with the format "\??\Volume[GUID]," where GUID is a globally unique identifier. The LDM volume manager also creates a symbolic link in the format "\Device\HarddiskDmVolumes\ComputerNameDg0\VolumeY" for each volume and maps it to the corresponding device in the PhysicalVolumes directory. ComputerName is replaced with the actual computer name, and Y is replaced with a volume identifier.

To allow raw access to a volume, the LDM volume manager also creates an object for each volume it is responsible for. This device object has a name in the format "\Device\HarddiskDmVolumes\PhysicalDmVolumes\RawVolumeX".

Note that this section is not an exhaustive list of all the possible device names and their formats. It is simply meant to indicate the complexity involved. Avid readers are encouraged to run the Windows GUI disk and volume management tools and study the GUI output.


   
Top


Inside Windows Storage
Inside Windows Storage: Server Storage Technologies for Windows 2000, Windows Server 2003 and Beyond
ISBN: 032112698X
EAN: 2147483647
Year: 2003
Pages: 111
Authors: Dilip C. Naik

flylib.com © 2008-2017.
If you may any questions please contact us: flylib@qtcs.net