Search the Knowledgebase |
Browse by Category |
|
|
|
|
|
| How to Connect to an iSCSI Volume using Open-iscsi in Linux. |
|
Thank you for rating this answer.
|
Instruction notes: Replace the "ISCSI_USER" token with one of the values in the "username" column above. Replace the "ISCSI_PASS" token with the corresponding value in the "password" column above. Replace the "ISCSI_TARGET_HOST" token with the corresponding value in the "IP Address" column above.
Setup Instructions: Install the open-iscsi package for your OS: CentOS 5, Redhat ES 5, Fedora Core 6, Fedora Release 7 yum install iscsi-initiator-utils
Debian apt-get install open-iscsi
Debian only: fix file paths for iscsiadm: ln -s /etc/{iscsid.conf,initiatorname.iscsi} /etc/iscsi/
Create the iscsid.conf configuration file: Backup the original configuration: cp /etc/iscsi/iscsid.conf{,.save}
Open /etc/iscsi/iscsid.conf with your favorite text editor and replace the contents with the following:
node.startup = automatic node.session.auth.username = ISCSI_USER node.session.auth.password = ISCSI_PASS discovery.sendtargets.auth.username = ISCSI_USER discovery.sendtargets.auth.password = ISCSI_PASS 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 = 10 node.conn[0].timeo.noop_out_timeout = 15 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 = 65536
Start iscsid: CentOS 5, Redhat ES 5, Fedora Core 6, Fedora Release 7: /etc/init.d/iscsi start
Debian: /etc/init.d/open-iscsi restart
Run a discovery against the iscsi target host: iscsiadm -m discovery -t sendtargets -p ISCSI_TARGET_HOST
Restart the iscsi service (Since node.startup was set to automatic in iscsid.conf it will automatically login to the target host). CentOS 5, Redhat ES 5, Fedora Core 6, Fedora Release 7: /etc/init.d/iscsi restart
Debian: /etc/init.d/open-iscsi restart
You should now see an additional drive on the system. You can print out the drive device with the following command: find /sys/devices/platform/host* -name block\* -exec ls -la '{}' \; | sed s#^.*../block/#/dev/#g
|
| Attachments |
|
No attachments were found.
|