日韩性视频-久久久蜜桃-www中文字幕-在线中文字幕av-亚洲欧美一区二区三区四区-撸久久-香蕉视频一区-久久无码精品丰满人妻-国产高潮av-激情福利社-日韩av网址大全-国产精品久久999-日本五十路在线-性欧美在线-久久99精品波多结衣一区-男女午夜免费视频-黑人极品ⅴideos精品欧美棵-人人妻人人澡人人爽精品欧美一区-日韩一区在线看-欧美a级在线免费观看

歡迎訪問 生活随笔!

生活随笔

當前位置: 首頁 > 编程资源 > 编程问答 >内容正文

编程问答

构建SAN网络存储

發布時間:2023/12/19 编程问答 30 豆豆
生活随笔 收集整理的這篇文章主要介紹了 构建SAN网络存储 小編覺得挺不錯的,現在分享給大家,幫大家做個參考.

實驗目的:構建SAN網絡存儲
實驗環境:redhat 5.4三臺,scanstorage作為存儲服務,IP地址是:192.168.9.79。node1,node2作為客戶端測試
實驗步驟:
一、配置服務端:
1、添加一塊20G的盤
[root@scanstorage ~]# 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目錄下)
[root@scanstorage ~]# yum -y install iscsi-initiator-utils perl-Config-General scsi-target-utils
3、通過linux中的命令生成IQN編號
[root@scanstorage ~]# iscsi-iname
iqn.1994-05.com.redhat:a3c8bc769291
4、編輯配置文件
[root@scanstorage ~]# vim /etc/tgt/targets.conf
<target iqn.1994-05.com.redhat:4d4fa666619>
backing-store /dev/sdb
</target>
5、啟動服務
[root@scanstorage ~]# /etc/init.d/tgtd start
Starting SCSI target daemon: Starting target framework daemon
6、查看配置信息

[root@scanstorage ~]# 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
[root@scanstorage ~]#

以上就是ISCSI服務的配置,注意,ISCSI的鏈接端口是3260,保證防火墻正常通過。接下來我們配置客戶端。
二、配置客戶端
客戶端的配置的時候只需要安裝一個ISCSI Initiator的包即可。以node1,node2為例:
1、安裝包
[root@node1 ~]# yum -y install iscsi-initiator-utils

[root@node2 ~]# yum -y install iscsi-initiator-utils

2、使用iSCSI存儲
[root@node1 ~]# iscsiadm -m discovery -t st -p 192.168.9.79
192.168.9.79:3260,1 iqn.1994-05.com.redhat:bc2c8763fcdb

[root@node2 ~]# 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,然后登錄:

[root@node1 ~]# iscsiadm -m node -T iqn.1994-05.com.redhat:bc2c8763fcdb -p 192.168.9.79 -l
[root@node1 ~]# 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 doesn't contain a valid partition table

[root@node1 ~]# iscsiadm -m node -T iqn.1994-05.com.redhat:bc2c8763fcdb -p 192.168.9.79 -l
[root@node2 ~]# 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 doesn't contain a valid partition table

轉載于:https://blog.51cto.com/kongwx/1179830

總結

以上是生活随笔為你收集整理的构建SAN网络存储的全部內容,希望文章能夠幫你解決所遇到的問題。

如果覺得生活随笔網站內容還不錯,歡迎將生活随笔推薦給好友。