2015-02-06 24 views
1

好的我有一個實驗室安裝程序,我有一個Freenas服務器iscsi安裝程序,Chap安裝程序用於發現目標和相互之間的目標。Iscsi Chap尋找發現,目標互不相連。

這裏是要求: 實現CHAP安全 用於發現 雙向(相互)CHAP的目標

單向CHAP我可以連接並有兩個ESXi服務器成功地發現,Windows 7中,Windows 2003中,2008年和2012年

的Centos可以看到發現列表,但是嘗試連接時:

iscsiadm --mode node --targetname iqn.2015.lab.com:centos --portal 192.168.1.60:3260 --login 

端子輸出:

no records found 

這裏是我的iscsid.conf,我留在在插部分的意見,但去除它剩下的,因爲它僅僅是如此之大:

iscsid.startup = /etc/rc.d/init.d/iscsid force-start 
    node.startup = automatic 
    node.leading_login = No 

    # ************* 
    # CHAP Settings 
    # ************* 

    # To enable CHAP authentication set node.session.auth.authmethod 
    # to CHAP. The default is None. 
    node.session.auth.authmethod = CHAP 

    # To set a CHAP username and password for initiator 
    # authentication by the target(s), uncomment the following lines: 
    #node.session.auth.username = group7 
    #node.session.auth.password = passwordpassword 

    # To set a CHAP username and password for target(s) 
    # authentication by the initiator, uncomment the following lines: 
    node.session.auth.username_in = group7 
    node.session.auth.password_in = passwordpassword 

    # To enable CHAP authentication for a discovery session to the target 
    # set discovery.sendtargets.auth.authmethod to CHAP. The default is None. 
    discovery.sendtargets.auth.authmethod = CHAP 

    # To set a discovery session CHAP username and password for the initiator 
    # authentication by the target(s), uncomment the following lines: 
    discovery.sendtargets.auth.username = group7 
    discovery.sendtargets.auth.password = passwordpassword 

    # To set a discovery session CHAP username and password for target(s) 
    # authentication by the initiator, uncomment the following lines: 
    #discovery.sendtargets.auth.username_in = group7 
    #discovery.sendtargets.auth.password_in = passwordpassword 


    node.session.timeo.replacement_timeout = 120 
    node.conn[0].timeo.login_timeout = 15 
    node.conn[0].timeo.logout_timeout = 15 
    node.conn[0].timeo.noop_out_interval = 5 
    node.conn[0].timeo.noop_out_timeout = 5 
    node.session.err_timeo.abort_timeout = 15 
    node.session.err_timeo.lu_reset_timeout = 30 
    node.session.err_timeo.tgt_reset_timeout = 30 
    node.session.initial_login_retry_max = 8 
    node.session.cmds_max = 128 
    node.session.queue_depth = 32 
    node.session.xmit_thread_priority = -20 
    node.session.iscsi.InitialR2T = No 
    node.session.iscsi.ImmediateData = Yes 
    node.session.iscsi.FirstBurstLength = 262144 
    node.session.iscsi.MaxBurstLength = 16776192 
    node.conn[0].iscsi.MaxRecvDataSegmentLength = 262144 
    node.conn[0].iscsi.MaxXmitDataSegmentLength = 0 
    node.conn[0].iscsi.HeaderDigest = None 
    node.session.nr_sessions = 1 
    node.session.iscsi.FastAbort = Yes 

任何幫助表示讚賞。謝謝。

回答

1

你想建立會話相互CHAP,但在配置文件中已註釋掉的定義從發起登錄該行的目標:

# To set a CHAP username and password for initiator 
# authentication by the target(s), uncomment the following lines: 
#node.session.auth.username = group7 
#node.session.auth.password = passwordpassword