question

DevonSprings-9314 avatar image
0 Votes"
DevonSprings-9314 asked DoronHolan commented

is it possible to set scsitargetid value from 0 to 1?

I have a simple application that need to look for a specific drive that has a value of 1 for scsitargetid.

When I use the command below to get all the scsi information for all of the PHYSICAL drives on my development PC I get the following output.

 Get-WmiObject Win32_DiskDrive | select-object DeviceID,{$_.size/1024/1024/1024},scsiport,scsibus,scsitargetid,scsilogicalunit | out-file -FilePath c:\Users\Tester\Desktop\OutputPhysicalDrives.txt


"OutputPhysicalDrives text file output's"


DeviceID : \.\PHYSICALDRIVE1
$_.size/1024/1024/1024 : 931.510956287384
scsiport : 0
scsibus : 1
scsitargetid : 0
scsilogicalunit : 0

DeviceID : \.\PHYSICALDRIVE2
$_.size/1024/1024/1024 : 465.759308338165
scsiport : 0
scsibus : 2
scsitargetid : 0
scsilogicalunit : 0

DeviceID : \.\PHYSICALDRIVE0
$_.size/1024/1024/1024 : 447.129242420197
scsiport : 0
scsibus : 0
scsitargetid : 0
scsilogicalunit : 0



Question is, how would I set PHYSICALDRIVE2's scsitargetid value from 0 to 1 so I can use this to identify PHYSICALDRIVE2 as the drive I want to use on my application.



Other Information
OS : Windows 10 Pro 20H2 64 bit


windows-10-generalwindows-hardware-code-generalwindows-hardware-code-storage
5 |1600 characters needed characters left characters exceeded

Up to 10 attachments (including images) can be used with a maximum of 3.0 MiB each and 30.0 MiB total.

PMT-7178 avatar image
0 Votes"
PMT-7178 answered DevonSprings-9314 commented
· 1
5 |1600 characters needed characters left characters exceeded

Up to 10 attachments (including images) can be used with a maximum of 3.0 MiB each and 30.0 MiB total.

Hello @PMT-7178 the environment that I am trying to configure is not virtualized and not using VMware. I am trying to do this on a physical system.

0 Votes 0 ·
DevonSprings-9314 avatar image
0 Votes"
DevonSprings-9314 answered DevonSprings-9314 commented

I still need help with this.

· 4
5 |1600 characters needed characters left characters exceeded

Up to 10 attachments (including images) can be used with a maximum of 3.0 MiB each and 30.0 MiB total.

What bigger problem are you trying to solve?

0 Votes 0 ·

I want to set PHYSICALDRIVE2's scsitargetid value from 0 to 1, but I want to do this on a non-virtualized environment that does not use Vmware. Overall question is, if this is even possible to do in a non virtualized/VM environment.

Thank You

0 Votes 0 ·
DoronHolan avatar image DoronHolan DevonSprings-9314 ·

Restating the original question is not describing the bigger problem you are trying to solve. WHY do you want to change the target id? What depends on the target id being a specific value?

0 Votes 0 ·
Show more comments
DevonSprings-9314 avatar image
0 Votes"
DevonSprings-9314 answered DoronHolan commented

I still need help with this issue, it has been described in more detail on another post.

· 1
5 |1600 characters needed characters left characters exceeded

Up to 10 attachments (including images) can be used with a maximum of 3.0 MiB each and 30.0 MiB total.

You can't change the target id from user mode. If you are using targetid as a way to uniquely identify the disks, there are other ways to do so. You have to change how the code is tracking the disks, you can't force the disks behavior to match the code.

1 Vote 1 ·