Set up an ISCSI server on CentOS

Source: Internet
Author: User

Set up an ISCSI server on CentOS
ISCSI server, install target software

yum install scsi-target-utils -y
  • 1

Modify the configuration file/etc/tgt/targets. conf and add the content to the last line.

& Lt; target iqn.2014-09.com. example: target1> # target custom backing-store/dev/sdb # scsi specifies the disk or partition initiator-address 10.0.0.0/24 # write-cache off # disable write cache incoming test 123.com # create the account test password 123.com</target>
  • 1
  • 2
  • 3
  • 4
  • 5
  • 6

Restart the service

Service tgtd restart chkconfig tgtd on tgt-admin-show # view the current scsi Configuration

Install the initiator software on the ISCSI client.
yum -y install iscsi-initiator-utilsservice iscsid force-startchkconfig iscsid on
  • 1
  • 2
  • 3

The remote iqn is found and the lun is connected.

iscsiadm --mode discovery --type sendtargets --portal 10.0.0.202iscsiadm -m node -T iqn.2014-09.com.example:target1 -p 10.0.0.202 -l
  • 1
  • 2

Fdisk-l can be viewed

Related Article

Contact Us

The content source of this page is from Internet, which doesn't represent Alibaba Cloud's opinion; products and services mentioned on that page don't have any relationship with Alibaba Cloud. If the content of the page makes you feel confusing, please write us an email, we will handle the problem within 5 days after receiving your email.

If you find any instances of plagiarism from the community, please send an email to: info-contact@alibabacloud.com and provide relevant evidence. A staff member will contact you within 5 working days.

A Free Trial That Lets You Build Big!

Start building with 50+ products and up to 12 months usage for Elastic Compute Service

  • Sales Support

    1 on 1 presale consultation

  • After-Sales Support

    24/7 Technical Support 6 Free Tickets per Quarter Faster Response

  • Alibaba Cloud offers highly flexible support services tailored to meet your exact needs.