广州网站设计流程,淘宝网站开发费用,上海公司注册费用,免费的网页制作实验目的#xff1a;构建SAN网络存储 实验环境#xff1a;redhat 5.4三台#xff0c;scanstorage作为存储服务#xff0c;IP地址是#xff1a;192.168.9.79。node1,node2作为客户端测试 实验步骤#xff1a; 一、配置服务端#xff1a; 1、添加一块20G的盘 [rootscans… 实验目的构建SAN网络存储 实验环境redhat 5.4三台scanstorage作为存储服务IP地址是192.168.9.79。node1,node2作为客户端测试 实验步骤 一、配置服务端 1、添加一块20G的盘 [rootscanstorage ~]# fdisk -l |grep Disk Disk /dev/sdc: 21.4 GB, 21474836480 bytes 2、在RHEL5中安装如下的包 iscsi-initiator-utils-6.2.0.868-0.18.el5.i386.rpm perl-Config-General-2.40-1.el5.noarch.rpm scsi-target-utils-0.0-5.20080917snap.el5.i386.rpm (这个包在光盘的cluster storage目录下 [rootscanstorage ~]# yum -y install iscsi-initiator-utils perl-Config-General scsi-target-utils 3、通过linux中的命令生成IQN编号 [rootscanstorage ~]# iscsi-iname iqn.1994-05.com.redhat:a3c8bc769291 4、编辑配置文件 [rootscanstorage ~]# vim /etc/tgt/targets.conf target iqn.1994-05.com.redhat:4d4fa666619 backing-store /dev/sdb /target 5、启动服务 [rootscanstorage ~]# /etc/init.d/tgtd start Starting SCSI target daemon: Starting target framework daemon 6、查看配置信息 [rootscanstorage ~]# tgtadm --lld iscsi --op show --mode target Target 1: iqn.1994-05.com.redhat:bc2c8763fcdb System information: Driver: iscsi State: ready I_T nexus information: LUN information: LUN: 0 Type: controller SCSI ID: IET 00010000 SCSI SN: beaf10 Size: 0 MB Online: Yes Removable media: No Backing store type: rdwr Backing store path: None LUN: 1 Type: disk SCSI ID: IET 00010001 SCSI SN: beaf11 Size: 21475 MB Online: Yes Removable media: No Backing store type: rdwr Backing store path: /dev/sdb Account information: ACL information: ALL [rootscanstorage ~]# 以上就是ISCSI服务的配置注意ISCSI的链接端口是3260保证防火墙正常通过。接下来我们配置客户端。 二、配置客户端 客户端的配置的时候只需要安装一个ISCSI Initiator的包即可。以node1node2为例 1、安装包 [rootnode1 ~]# yum -y install iscsi-initiator-utils [rootnode2 ~]# yum -y install iscsi-initiator-utils 2、使用iSCSI存储 [rootnode1 ~]# iscsiadm -m discovery -t st -p 192.168.9.79 192.168.9.79:3260,1 iqn.1994-05.com.redhat:bc2c8763fcdb [rootnode2 ~]# iscsiadm -m discovery -t st -p 192.168.9.79 192.168.9.79:3260,1 iqn.1994-05.com.redhat:bc2c8763fcdb 在node1和node2上开启服务如下服务iscsid network iscsi netfs然后登录 [rootnode1 ~]# iscsiadm -m node -T iqn.1994-05.com.redhat:bc2c8763fcdb -p 192.168.9.79 -l [rootnode1 ~]# fdisk -l Disk /dev/sda: 32.2 GB, 32212254720 bytes 255 heads, 63 sectors/track, 3916 cylinders Units cylinders of 16065 * 512 8225280 bytes Device Boot Start End Blocks Id System /dev/sda1 * 1 3393 27254241 83 Linux /dev/sda2 3394 3915 4192965 82 Linux swap / Solaris Disk /dev/sdb: 21.4 GB, 21474836480 bytes64 heads, 32 sectors/track, 20480 cylinders Units cylinders of 2048 * 512 1048576 bytes Disk /dev/sdb doesnt contain a valid partition table [rootnode1 ~]# iscsiadm -m node -T iqn.1994-05.com.redhat:bc2c8763fcdb -p 192.168.9.79 -l [rootnode2 ~]# fdisk -l Disk /dev/sda: 32.2 GB, 32212254720 bytes 255 heads, 63 sectors/track, 3916 cylinders Units cylinders of 16065 * 512 8225280 bytes Device Boot Start End Blocks Id System /dev/sda1 * 1 3393 27254241 83 Linux /dev/sda2 3394 3915 4192965 82 Linux swap / Solaris Disk /dev/sdb: 21.4 GB, 21474836480 bytes64 heads, 32 sectors/track, 20480 cylinders Units cylinders of 2048 * 512 1048576 bytes Disk /dev/sdb doesnt contain a valid partition table 转载于:https://blog.51cto.com/kongwx/1179830