이 콘텐츠는 선택한 언어로 제공되지 않습니다.

Chapter 36. Scanning iSCSI Targets with Multiple LUNs or Portals


With some device models (for example, from EMC and Netapp), however, a single target may have multiple logical units or portals. In this case, issue a sendtargets command to the host first to find new portals on the target. Then, rescan the existing sessions using:
# iscsiadm -m session --rescan
You can also rescan a specific session by specifying the session's SID value, as in:
# iscsiadm -m session -r SID --rescan[8]
If your device supports multiple targets, you will need to issue a sendtargets command to the hosts to find new portals for each target. Then, rescan existing sessions to discover new logical units on existing sessions (i.e. using the --rescan option).

Important

The sendtargets command used to retrieve --targetname and --portal values overwrites the contents of the /var/lib/iscsi/nodes database. This database will then be repopulated using the settings in /etc/iscsi/iscsid.conf. However, this will not occur if a session is currently logged in and in use.
To safely add new targets/portals or delete old ones, use the -o new or -o delete options, respectively. For example, to add new targets/portals without overwriting /var/lib/iscsi/nodes, use the following command:
iscsiadm -m discovery -t st -p target_IP -o new
To delete /var/lib/iscsi/nodes entries that the target did not display during discovery, use:
iscsiadm -m discovery -t st -p target_IP -o delete
You can also perform both tasks simultaneously, as in:
iscsiadm -m discovery -t st -p target_IP -o delete -o new
The sendtargets command will yield the following output:
ip:port,target_portal_group_tag proper_target_name

Example 36.1. Output of the sendtargets command

For example, given a device with a single target, logical unit, and portal, with equallogic-iscsi1 as your target_name, the output should appear similar to the following:
10.16.41.155:3260,0 iqn.2001-05.com.equallogic:6-8a0900-ac3fe0101-63aff113e344a4a2-dl585-03-1
Note that proper_target_name and ip:port,target_portal_group_tag are identical to the values of the same name in Section 27.2, “iSCSI Initiator Creation”.
At this point, you now have the proper --targetname and --portal values needed to manually scan for iSCSI devices. To do so, run the following command:
# iscsiadm --mode node --targetname proper_target_name --portal ip:port,target_portal_group_tag \ --login 
[9]

Example 36.2. Full iscsiadm command

Using our previous example (where proper_target_name is equallogic-iscsi1), the full command would be:
# iscsiadm --mode node --targetname  \ iqn.2001-05.com.equallogic:6-8a0900-ac3fe0101-63aff113e344a4a2-dl585-03-1 	\ --portal 10.16.41.155:3260,0 --login[9]


[8] For information on how to retrieve a session's SID value, refer to Section 27.2, “iSCSI Initiator Creation”.
[9] This is a single command split into multiple lines, to accommodate printed and PDF versions of this document. All concatenated lines — preceded by the backslash (\) — should be treated as one command, sans backslashes.
Red Hat logoGithubRedditYoutubeTwitter

자세한 정보

평가판, 구매 및 판매

커뮤니티

Red Hat 문서 정보

Red Hat을 사용하는 고객은 신뢰할 수 있는 콘텐츠가 포함된 제품과 서비스를 통해 혁신하고 목표를 달성할 수 있습니다.

보다 포괄적 수용을 위한 오픈 소스 용어 교체

Red Hat은 코드, 문서, 웹 속성에서 문제가 있는 언어를 교체하기 위해 최선을 다하고 있습니다. 자세한 내용은 다음을 참조하세요.Red Hat 블로그.

Red Hat 소개

Red Hat은 기업이 핵심 데이터 센터에서 네트워크 에지에 이르기까지 플랫폼과 환경 전반에서 더 쉽게 작업할 수 있도록 강화된 솔루션을 제공합니다.

© 2024 Red Hat, Inc.