SCSI targets having same IDs and LUNs

Hi

I am using the IOCTL_SCSI_GET_ADDRESS and seeing that two SCSI harddisks
have the same Target ID, bus number and LUN. There SCSI port numbers
are different. This is very surprising since I was expecting a unique
combination of TargetID+LUN for each device that is present on the same SCSI
bus. I dont at all understand the meaning of SCSI port number here. Can
anyone help me out to understand the underlying architecture?

I would think that having the SCSI harddisks daisy chained, with a unique
target ID and a LUN=0 would give me better write performance on these disks.
I am comparing with the present scenario. Of course I cannot have a total of
more than 16 SCSI devices connected to the same HBA. Can anyone comment on
this?

Thanks in advance.
regards

SCSI_ADDRESS have PortNumber, PathId, TargetId and Lun only.
Where did you get the bus number?

AFAIK, SCSI Port Number is the number for opening the actual scsi port as a symbolic link as a form of
“\.\Scsi%d:” (e.g. \.\Scsi1:, \.\Scsi2: ). I haven’t found the formal definition of it yet.

If disks have different scsi port numbers, those are attached to different scsi port devices. :slight_smile:
(SCSI Port devices include IDE ports.) The device identification should be (port,target,lun) tuples (excluding pathid).
not (target id, lun). And again SCSI_ADDRESS does not have bus number.

SCSI controllers may have multiple scsi port devices, which may explain why you have different port numbers.

Regards,

Chesong Lee


From: xxxxx@lists.osr.com [mailto:xxxxx@lists.osr.com] On Behalf Of Arijit Bhattacharyya
Sent: Thursday, November 24, 2005 5:33 AM
To: Windows File Systems Devs Interest List
Subject: [ntfsd] SCSI targets having same IDs and LUNs

Hi

I am using the IOCTL_SCSI_GET_ADDRESS and seeing that two SCSI harddisks have the same Target ID, bus number and LUN. There SCSI port numbers are different. This is very surprising since I was expecting a unique combination of TargetID+LUN for each device that is present on the same SCSI bus. I dont at all understand the meaning of SCSI port number here. Can anyone help me out to understand the underlying architecture?

I would think that having the SCSI harddisks daisy chained, with a unique target ID and a LUN=0 would give me better write performance on these disks. I am comparing with the present scenario. Of course I cannot have a total of more than 16 SCSI devices connected to the same HBA. Can anyone comment on this?

Thanks in advance.
regards
— Questions? First check the IFS FAQ at https://www.osronline.com/article.cfm?id=17 You are currently subscribed to ntfsd as: unknown lmsubst tag argument: ‘’ To unsubscribe send a blank email to xxxxx@lists.osr.com

You can safely use “pathid” as Scsi Bus number.

Cheers!!!

-Kumar


From: xxxxx@lists.osr.com
[mailto:xxxxx@lists.osr.com] On Behalf Of Chesong Lee
Sent: Thursday, November 24, 2005 4:33 PM
To: Windows File Systems Devs Interest List
Subject: RE: [ntfsd] SCSI targets having same IDs and LUNs

SCSI_ADDRESS have PortNumber, PathId, TargetId and Lun only.
Where did you get the bus number?

AFAIK, SCSI Port Number is the number for opening the actual scsi port
as a symbolic link as a form of
“\.\Scsi%d:” (e.g. \.\Scsi1:, \.\Scsi2: ). I haven’t found the formal
definition of it yet.

If disks have different scsi port numbers, those are attached to
different scsi port devices. :slight_smile:
(SCSI Port devices include IDE ports.) The device identification should
be (port,target,lun) tuples (excluding pathid).
not (target id, lun). And again SCSI_ADDRESS does not have bus number.

SCSI controllers may have multiple scsi port devices, which may explain
why you have different port numbers.

Regards,

Chesong Lee


From: xxxxx@lists.osr.com
[mailto:xxxxx@lists.osr.com] On Behalf Of Arijit
Bhattacharyya
Sent: Thursday, November 24, 2005 5:33 AM
To: Windows File Systems Devs Interest List
Subject: [ntfsd] SCSI targets having same IDs and LUNs

Hi

I am using the IOCTL_SCSI_GET_ADDRESS and seeing that two SCSI harddisks
have the same Target ID, bus number and LUN. There SCSI port numbers are
different. This is very surprising since I was expecting a unique
combination of TargetID+LUN for each device that is present on the same
SCSI bus. I dont at all understand the meaning of SCSI port number here.
Can anyone help me out to understand the underlying architecture?

I would think that having the SCSI harddisks daisy chained, with a
unique target ID and a LUN=0 would give me better write performance on
these disks. I am comparing with the present scenario. Of course I
cannot have a total of more than 16 SCSI devices connected to the same
HBA. Can anyone comment on this?

Thanks in advance.
regards
— Questions? First check the IFS FAQ at
https://www.osronline.com/article.cfm?id=17 You are currently subscribed
to ntfsd as: unknown lmsubst tag argument: ‘’ To unsubscribe send a
blank email to xxxxx@lists.osr.com

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

You are currently subscribed to ntfsd as: unknown lmsubst tag argument:
‘’
To unsubscribe send a blank email to xxxxx@lists.osr.com

Hi

Ok…I got ur point. The disk management utility shows Location of a disk as:
Bus number + Target ID + LUN. I compared this bus number with the Path ID
that I get from IOCTL_SCSI_GET_ADDRESS and they somehow seem to be the same.
Hence the conclusion. It would be great if you can explain what this bus
number means. Apart from this, I have another question which is more
important to me:

I have 8 SCSI disks. And they have almost the same write speed. But suppose
I just select 5 disks from these 8 disks and write to them parallely, I get
very different results for the total write speed with different subsets of 5
disks. And I am comparing the speeds with same load conditions. I am trying
to figure out why this is happening and I have a strong hunch that it is
dependent on the layout of these disks. Also, one more thing…i have 3 SCSI
controllers in my system. Can anyone solve this anomaly?

regards and thanks again.

On 11/24/05, Chesong Lee wrote:
>
>
> SCSI_ADDRESS have PortNumber, PathId, TargetId and Lun only.
> Where did you get the bus number?
>
> AFAIK, SCSI Port Number is the number for opening the actual scsi port as
> a symbolic link as a form of
> “\.\Scsi%d:” (e.g. \.\Scsi1:, \.\Scsi2: ). I haven’t found the formal
> definition of it yet.
>
> If disks have different scsi port numbers, those are attached to different
> scsi port devices. :slight_smile:
> (SCSI Port devices include IDE ports.) The device identification should be
> (port,target,lun) tuples (excluding pathid).
> not (target id, lun). And again SCSI_ADDRESS does not have bus number.
>
> SCSI controllers may have multiple scsi port devices, which may explain
> why you have different port numbers.
>
> Regards,
>
> Chesong Lee
>
>
>
> ------------------------------
> From: xxxxx@lists.osr.com [mailto:
> xxxxx@lists.osr.com] *On Behalf Of *Arijit Bhattacharyya
> Sent: Thursday, November 24, 2005 5:33 AM
> To: Windows File Systems Devs Interest List
> Subject: [ntfsd] SCSI targets having same IDs and LUNs
>
>
> Hi
>
> I am using the IOCTL_SCSI_GET_ADDRESS and seeing that two SCSI harddisks
> have the same Target ID, bus number and LUN. There SCSI port numbers
> are different. This is very surprising since I was expecting a unique
> combination of TargetID+LUN for each device that is present on the same SCSI
> bus. I dont at all understand the meaning of SCSI port number here. Can
> anyone help me out to understand the underlying architecture?
>
> I would think that having the SCSI harddisks daisy chained, with a unique
> target ID and a LUN=0 would give me better write performance on these disks.
> I am comparing with the present scenario. Of course I cannot have a total of
> more than 16 SCSI devices connected to the same HBA. Can anyone comment on
> this?
>
> Thanks in advance.
> regards
> — Questions? First check the IFS FAQ at
> https://www.osronline.com/article.cfm?id=17 You are currently subscribed
> to ntfsd as: unknown lmsubst tag argument: ‘’ To unsubscribe send a blank
> email to xxxxx@lists.osr.com
> —
> Questions? First check the IFS FAQ at
> https://www.osronline.com/article.cfm?id=17
>
> You are currently subscribed to ntfsd as: unknown lmsubst tag argument: ‘’
>
> To unsubscribe send a blank email to xxxxx@lists.osr.com

SCSI_ADDRESS structure says:

PortNumber : Identifies the SCSI controller.
PathId : Identifies the bus on the SCSI controller.
TargetId : Identifies the target device on the SCSI bus.
Lun : Identifies the individual logical unit at the target device specified by TargetId.

i.e. Bus number is the identifier in the SCSI controller. Not the bus in Windows.
But the port number is an unique number of the SCSI port device object.

I think it is too tricky to say the same load conditions.
Especially, disk performance is heavily affected by the positions of sectors
where you want to access. I don’t know how to explain your results good enough.
Disable Tagged queuing and synchronous transfer mode when measuring the performance
if the parallel transfer matters.

Regards,

Chesong Lee


From: xxxxx@lists.osr.com [mailto:xxxxx@lists.osr.com] On Behalf Of Arijit Bhattacharyya
Sent: Thursday, November 24, 2005 6:22 AM
To: Windows File Systems Devs Interest List
Subject: Re: [ntfsd] SCSI targets having same IDs and LUNs

Hi

Ok…I got ur point. The disk management utility shows Location of a disk as: Bus number + Target ID + LUN. I compared this bus number with the Path ID that I get from IOCTL_SCSI_GET_ADDRESS and they somehow seem to be the same. Hence the conclusion. It would be great if you can explain what this bus number means. Apart from this, I have another question which is more important to me:

I have 8 SCSI disks. And they have almost the same write speed. But suppose I just select 5 disks from these 8 disks and write to them parallely, I get very different results for the total write speed with different subsets of 5 disks. And I am comparing the speeds with same load conditions. I am trying to figure out why this is happening and I have a strong hunch that it is dependent on the layout of these disks. Also, one more thing…i have 3 SCSI controllers in my system. Can anyone solve this anomaly?

regards and thanks again.

On 11/24/05, Chesong Lee wrote:

SCSI_ADDRESS have PortNumber, PathId, TargetId and Lun only.
Where did you get the bus number?

AFAIK, SCSI Port Number is the number for opening the actual scsi port as a symbolic link as a form of
“\.\Scsi%d:” (e.g. \.\Scsi1:, \.\Scsi2: ). I haven’t found the formal definition of it yet.

If disks have different scsi port numbers, those are attached to different scsi port devices. :slight_smile:
(SCSI Port devices include IDE ports.) The device identification should be (port,target,lun) tuples (excluding pathid).
not (target id, lun). And again SCSI_ADDRESS does not have bus number.

SCSI controllers may have multiple scsi port devices, which may explain why you have different port numbers.

Regards,

Chesong Lee

________________________________

From: xxxxx@lists.osr.com [mailto: xxxxx@lists.osr.com mailto:xxxxx] On Behalf Of Arijit Bhattacharyya
Sent: Thursday, November 24, 2005 5:33 AM
To: Windows File Systems Devs Interest List
Subject: [ntfsd] SCSI targets having same IDs and LUNs

Hi

I am using the IOCTL_SCSI_GET_ADDRESS and seeing that two SCSI harddisks have the same Target ID, bus number and LUN. There SCSI port numbers are different. This is very surprising since I was expecting a unique combination of TargetID+LUN for each device that is present on the same SCSI bus. I dont at all understand the meaning of SCSI port number here. Can anyone help me out to understand the underlying architecture?

I would think that having the SCSI harddisks daisy chained, with a unique target ID and a LUN=0 would give me better write performance on these disks. I am comparing with the present scenario. Of course I cannot have a total of more than 16 SCSI devices connected to the same HBA. Can anyone comment on this?

Thanks in advance.
regards
— Questions? First check the IFS FAQ at https://www.osronline.com/article.cfm?id=17 You are currently subscribed to ntfsd as: unknown lmsubst tag argument: ‘’ To unsubscribe send a blank email to xxxxx@lists.osr.com

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

You are currently subscribed to ntfsd as: unknown lmsubst tag argument: ‘’
To unsubscribe send a blank email to xxxxx@lists.osr.com mailto:xxxxx

— Questions? First check the IFS FAQ at https://www.osronline.com/article.cfm?id=17 You are currently subscribed to ntfsd as: unknown lmsubst tag argument: ‘’ To unsubscribe send a blank email to xxxxx@lists.osr.com</mailto:xxxxx></mailto:xxxxx>

>have the same Target ID, bus number and LUN. There SCSI port numbers

are different. This is very surprising since I was expecting a unique
combination of TargetID+LUN for each device that is present on the same SCSI
bus. I dont at all understand the meaning of SCSI port number here.

“Port” is “controller instance”. The 2 disks are on different controllers.

Maxim Shatskih, Windows DDK MVP
StorageCraft Corporation
xxxxx@storagecraft.com
http://www.storagecraft.com

If “port” is the controller instance, then I have a scenario like this:

CI1----HDD1—HDD2—HDD3
CI2—HDD4—HDD5—HDD6
CI3—HDD7—HDD8—HDD9

I am seeing the same bus number (I mean the scsi bus number) for all HDDs.
How do I complete the above picture?? Note that
Target ID (HDD1)=TargetID(HDD4)=TargetID(HDD7)
Similarly for HDD2, HDD5 and HDD8 and for HDD3, 6 and 9.

All LUNs are equal to 0.

regards

On 11/24/05, Maxim S. Shatskih wrote:
>
> >have the same Target ID, bus number and LUN. There SCSI port numbers
> >are different. This is very surprising since I was expecting a unique
> >combination of TargetID+LUN for each device that is present on the same
> SCSI
> >bus. I dont at all understand the meaning of SCSI port number here.
>
> “Port” is “controller instance”. The 2 disks are on different controllers.
>
> Maxim Shatskih, Windows DDK MVP
> StorageCraft Corporation
> xxxxx@storagecraft.com
> http://www.storagecraft.com
>
>
>
> —
> Questions? First check the IFS FAQ at
> https://www.osronline.com/article.cfm?id=17
>
> You are currently subscribed to ntfsd as: xxxxx@gmail.com
> To unsubscribe send a blank email to xxxxx@lists.osr.com
>

Off-topic:
Please, DON’T use ActiveX controls in mails sent to NTFSD.

L.
----- Original Message -----
From: Rajendrakumar Rajguru
To: Windows File Systems Devs Interest List
Sent: Thursday, November 24, 2005 12:09 PM
Subject: RE: [ntfsd] SCSI targets having same IDs and LUNs

You can safely use “pathid” as Scsi Bus number.
Cheers!!!

-Kumar

You use the entire address: Port,Path,Target,Lun. That combination is a
unique address.
From your example:
CI1 = 0,0,0,0—0,0,1,0—0,0,2,0
CI2 = 1,0,0,0—1,0,1,0—1,0,2,0
CI2 = 2,0,0,0—2,0,1,0—2,0,2,0

=====================
Mark Roddy DDK MVP
Windows 2003/XP/2000 Consulting
Hollis Technology Solutions 603-321-1032
www.hollistech.com


From: xxxxx@lists.osr.com
[mailto:xxxxx@lists.osr.com] On Behalf Of Arijit Bhattacharyya
Sent: Thursday, November 24, 2005 8:28 AM
To: Windows File Systems Devs Interest List
Subject: Re: [ntfsd] SCSI targets having same IDs and LUNs

If “port” is the controller instance, then I have a scenario like
this:

CI1----HDD1—HDD2—HDD3
CI2—HDD4—HDD5—HDD6
CI3—HDD7—HDD8—HDD9

I am seeing the same bus number (I mean the scsi bus number) for all
HDDs. How do I complete the above picture?? Note that
Target ID (HDD1)=TargetID(HDD4)=TargetID(HDD7)
Similarly for HDD2, HDD5 and HDD8 and for HDD3, 6 and 9.

All LUNs are equal to 0.

regards

On 11/24/05, Maxim S. Shatskih wrote:

>have the same Target ID, bus number and LUN. There SCSI
port numbers
>are different. This is very surprising since I was
expecting a unique
>combination of TargetID+LUN for each device that is present
on the same SCSI
>bus. I dont at all understand the meaning of SCSI port
number here.

“Port” is “controller instance”. The 2 disks are on
different controllers.

Maxim Shatskih, Windows DDK MVP
StorageCraft Corporation
xxxxx@storagecraft.com
http://www.storagecraft.com


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

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

— Questions? First check the IFS FAQ at
https://www.osronline.com/article.cfm?id=17 You are currently subscribed to
ntfsd as: unknown lmsubst tag argument: ‘’ To unsubscribe send a blank email
to xxxxx@lists.osr.com