- 论坛徽章:
- 0
|
最近想对unh_iscsi进行一下chap的配置,遇到了一些问题,请大家帮忙指导一下:
1.具体的实现步骤
Iscsi_manage target restore(target端恢复为初始设置,可以清除所有的修改)
Iscsi_manage target set Authmethod=CHAP,NONE(用户验证方式为双选,可以验证,也可不验证,验证的时候,需输入两套用户名和密码,一套是peer x/n,一套是local x/n)
Iscsi_manage target set Sessiontype=Discovery(指定会话的方式为discovery)Iscsi_manage target force s(强制认证,格式必须)
Iscsi_manage target force px=“123”(target端用户密码)
Iscsi_manage target force pn=“haha”(target端用户名)
Iscsi_manage target force t(格式必须,指定2套认证方式,要输入lx/ln必须输入force t)
Iscsi_manage target force lx=“123”(本地用户密码)
Iscsi_manage target force ln=“haha1”(本地用户名)
输入命令之后,采用/etc/init.d/unh_iscsi restart,能够出现连接成功,可是,这和无验证方式none的反应一模一样。我想问一下,是我的配置不成功?日志如下:
Starting UNH iSCSI Initiator (unh_iscsi_initiator)
UNH iSCSI Initiator loaded successfully.
Connecting to UNH iSCSI Targets
Attempting to connect to TARGET_1...
/opt/unh/iscsi/conf/TARGET_1: Host: 0
/opt/unh/iscsi/conf/TARGET_1: TARGET_NO: 0
/opt/unh/iscsi/conf/TARGET_1: Target:
/opt/unh/iscsi/conf/TARGET_1: INAME:
/opt/unh/iscsi/conf/TARGET_1: IP: 222.27.255.138
/opt/unh/iscsi/conf/TARGET_1: LUNS: ALL
/opt/unh/iscsi/conf/TARGET_1: LOCAL_SECRET: Initiator_secret
/opt/unh/iscsi/conf/TARGET_1: LOCAL_NAME: Initiator_name
/opt/unh/iscsi/conf/TARGET_1: PEER_SECRET: Target_secret
/opt/unh/iscsi/conf/TARGET_1: PEER_NAME: Target_anonymous-user
+ iscsi_manage init restore host=0 target=0
+ iscsi_manage init set InitiatorName= host=0 target=0
+ iscsi_manage init set TargetName= host=0 target=0
+ Chap
/opt/unh/iscsi/conf/TARGET_1: line 98: Chap: command not found
+ iscsi_manage init set AuthMethod=CHAP,None host=0 target=0
+ iscsi_manage init force s b t cl=256 host=0 target=0 lx=Initiator_secret ln=Initiator_name px=Target_secret pn=Target_anonymous-user
+ '[' ALL = ALL ']'
+ iscsi_config up ip=222.27.255.138 host=0 target=0 port=3260 lun=0
+ iscsi_manage init force V=0 host=0 target=0
+ exit 0
UNH iSCSI Targets connected.
Mounting file systems on UNH iSCSI Targets
File systems on UNH iSCSI Disks mounted. |
|