本篇是ISCSI服务端的续篇,操作前请确保已经安装好你的iscsi-target
2.1 Install essential software
sudo apt-get install open-iscsi
2.2 Modify configuration file
vim /etc/iscsi/iscsid.conf
and change it to:
node.session.auth.authmethod = CHAP
# make sure user and password is same with iscsi-target
node.session.auth.username =
node.session.auth.password =
2.3 Attach iscsi-target volume
sudo iscsiadm -m discovery -t sendtargets -p
sudo iscsiadm -m node --login
other useful command:
sudo iscsiadm -m node -o show
sudo iscsiadm -m session -o show
Then, you could find the new patiition:
$ more /proc/partitions
You could use it as a normal partition, create file system and formation, or provide it to QEMU or Libvirt.
2.4 Logout iscsi partition
sudo iscsiadm -m node --logout
阅读(5553) | 评论(0) | 转发(0) |