ISCSI Aktivieren

ISCSI Platten bereitstellen

Um iscsi-Platten bereitzustellen, muß ein iscsi-initiator oder ein iscsi-Ziel definiert werden. Unter yast muß zunächst nicht nur iscsi installiert werden, es müssen auch die iscsitarget Kernel-module iscsitarget-kpm-xen und iscsitarget-kpm-default gesondert installiert werden.

Leider sind diese (Version 0.4.15) nicht funktionsfähig ( https://bugzilla.novell.com/show_bug.cgi?id=365996 ). Daher Version iscsitarget-0.4.16 herunterladen, in das Verzeichnis iscsitarget-0.4.16 wechseln und mittels make und make install die aktuelle Version installieren. 

Anschließend muß die Datei /etc/ietd.conf eingerichtet werden.

# Example iscsi target configuration
#
# Everything until the first target definition belongs
# to the global configuration.
# Right now this is only the user configuration used
# during discovery sessions. "IncomingUser" specifies credentials the
# initiator has to provide - several of these are supported. If mutual
# CHAP shall be employed, "OutgoingUser" specifies the user/pass
# combination the target will provide - only one is supported.
# Leave them alone (keep them commented out) if you don't want to use
# authentication for discovery sessions.

IncomingUser joe secret
OutgoingUser jack 12charsecret


# Targets definitions start with "Target" and the target name.
# The target name must be a globally unique name, the iSCSI
# standard defines the "iSCSI Qualified Name" as follows:
#
# iqn.yyyy-mm.<reversed domain name>[:identifier]
#
# "yyyy-mm" is the date at which the domain is valid and the identifier
# is freely selectable. For further details please check the iSCSI spec.

Target iqn.2008-06.xxx-xxxx.xxx:a1830131-9708-4285-8568-93ae055b1185
    # Logical Unit definition
    # You must define one logical unit at least.
    # Block devices, regular files, LVM, and RAID can be offered
    # to the initiators as a block device.
    #Lun 0 Path=/dev/sdc,Type=fileio
Lun 0 Path=/dev/sdc11,Type=fileio,ScsiId=sdc11
    #Target iqn.2001-04.com.example:storage.disk2.sys1.xyz
    # Users, who can access this target. The same rules as for discovery
    # users apply here.
    # Leave them alone if you don't want to use authentication.
    #IncomingUser joe secret
    #OutgoingUser jim 12charpasswd
    # Alias name for this target
    # Alias Test
    # various iSCSI parameters
    # (not all are used right now, see also iSCSI spec for details)
    #MaxConnections 1
    #InitialR2T Yes
    #ImmediateData No
    #MaxRecvDataSegmentLength 8192
    #MaxXmitDataSegmentLength 8192
    #MaxBurstLength 262144
    #FirstBurstLength 65536
    #DefaultTime2Wait 2
    #DefaultTime2Retain 20
    #MaxOutstandingR2T 8
    #DataPDUInOrder Yes
    #DataSequenceInOrder Yes
    #ErrorRecoveryLevel 0
    #HeaderDigest CRC32C,None
    #DataDigest CRC32C,None
    # various target parameters
    #Wthreads 8

Mit rciscsitarget start wird iscsi getsratet. Mit cat /proc/net/iet/* kann kontrolliert werden, ob die Devices auch angeboten werden.

iscsi Platte einem System hinzufügen

Mit yast2 iscsi-client (zu finden als iscsi-client unter Netzwerkdienste) kann dann die iscsi-Platte dem System hinzugefügt werden. Zunächst Ermittelte Ziele und dann Erkennung wählen. Hier bitte die IP-Adresse des Rechnsers eingeben, der die iscsi-Platte zur Verfügung stellt. Bitte die Ausgehende Authentifizierung eintragen und dann Weiter wählen. Yast zeigt dann eine Liste mit möglichen Zielen. Eins auswählen und Anmelden drücken. Eventuell nochmals die Ausgehende Userid und das Passwort eingeben. Mittels Weiter wird die ausgewählte Platte dem System hinzugefügt. Test mit fdisk -l - jetzt sollte die Platte auftauchen.