11月个人指标

配置提供 iSCSI 服务,磁盘名为 iqn.2018-04.com.example.groupX:system1, 并符合下列要求:  服务端口为 3260 使用 iscsi_store 作其后端卷,其大小为 3GiB  此服务只能被 system2.groupX.example.com 访问
1)准备磁盘空间
[[email protected] ~]# parted /dev/sdb
(parted) mktable gpt //建立分区表
(parted) mkpart primary ext4 0 3GiB //添加指定大小的分区
(parted) quit
[[email protected] ~]# partprobe /dev/sdb
2)安装、配置 iSCSI 磁盘
[[email protected] ~]# yum -y install targetcli
[[email protected] ~]# targetcli
/> ls
/> backstores/block create iscsi_store /dev/sdb1 //定义后端存储
/> /iscsi create iqn.2018-04.com.example:serverX //创建 iqn 对象
/> /iscsi/iqn.2018-04.com.example:serverX/tpg1/acls create iqn.2018-04.com.example:desktopX //授权客户机(的 IQN)
/> /iscsi/iqn.2018-04.com.example:serverX/tpg1/luns create /backstores/block/iscsi_store //绑定存储
/> /iscsi/iqn.2018-04.com.example:serverX/tpg1/portals create 0.0.0.0 3260 //指定监听地址(本机 IP 及端口)
/> saveconfig //保存配置结果
/> exit
[[email protected] ~]# systemctl restart target
[[email protected] ~]# systemctl enable target

11月个人指标
11月个人指标
11月个人指标
11月个人指标
11月个人指标
11月个人指标

转载于:https://blog.51cto.com/13673837/2328395