iSCSI是internet Small Computer System Interface的缩写,又称为IP-SAN,是一种基于因特网及SCSI-3协议下的存储技术,由IETF提出,并于2003年2月11日成为正式的标准。
iSCSI的目的是为了用IP协议将存储设备连接在一起。通过在IP网上传送SCSI命令和数据,iSCSI推动了数据在网络之间的传递,同时也促进了数据的远距离管理。由于其出色的数据传输能力,iSCSI协议被认为是促进存储区域网(SAN)市场快速发展的关键因素之一。因为IP网络的广泛应用,iSCSI能够在LAN、WAN甚至Internet上进行数据传送,使得数据的存储不再受地域的现在。iSCSI技术的核心是在TCP/IP网络上传输SCSI协议,即使用TCP/IP报文和iSCSI报文封装SCSI报文,使得SCSI命令和数据可以在普通以太网络上进行传输,如下图所示。
iSCSI的工作过程:当iSCSI主机应用程序发出数据读写请求后,操作系统会生成一个相应的SCSI命令,该SCSI命令在iSCSI initiator层被封装成ISCSI消息包并通过TCP/IP传送到设备侧,设备侧的iSCSI target层会解开iSCSI消息包,得到SCSI命令的内容,然后传送给SCSI设备执行;设备执行SCSI命令后的响应,在经过设备侧iSCSI target层时被封装成ISCSI响应PDU,通过TCP/IP网络传送给主机的ISCSI initiator层,iSCSI initiator会从ISCSI响应PDU里解析出SCSI响应并传送给操作系统,操作系统再响应给应用程序。
iet(iSCSI Enterprise Target)是Linux下的iSCSI Target实现,open-iscsi是Linux下的iscsi initiator实现,使用iet(官方网站:http://iscsitarget.sourceforge.net)和open-iscsi就可以方便的实现简单的IPSAN,同时iet也可以和其他系统的iscsi initiator配合使用。
这几天格式化硬盘,记录一下用到的命令:
[root@db ~]# fdisk /dev/sdb
The number of cylinders for this disk is set to 253981.
There is nothing wrong with that, but this is larger than 1024,
and could in certain setups cause problems with:
1) software that runs at boot time (e.g., old versions of LILO)
2) booting and partitioning software from other OSs
(e.g., DOS FDISK, OS/2 FDISK)
Command (m for help): p
Disk /dev/sdb: 2089.0 GB, 2089072092672 bytes
255 heads, 63 sectors/track, 253981 cylinders
Units = cylinders of 16065 * 512 = 8225280 bytes
Device Boot Start End Blocks Id System
/dev/sdb1 1 124495 1000006056 83 Linux
Command (m for help): n
Command action
e extended
p primary partition (1-4)
p
Partition number (1-4): 2
First cylinder (124496-253981, default 124496):
Using default value 124496
Last cylinder or +size or +sizeM or +sizeK (124496-253981, default 253981):
Using default value 253981
Command (m for help): p
Disk /dev/sdb: 2089.0 GB, 2089072092672 bytes
255 heads, 63 sectors/track, 253981 cylinders
Units = cylinders of 16065 * 512 = 8225280 bytes
Device Boot Start End Blocks Id System
/dev/sdb1 1 124495 1000006056 83 Linux
/dev/sdb2 124496 253981 1040096295 83 Linux
Command (m for help): w
The partition table has been altered!
Calling ioctl() to re-read partition table.
WARNING: Re-reading the partition table failed with error 16: Device or resource busy.
The kernel still uses the old table.
The new table will be used at the next reboot.
Syncing disks.
此时,分区里看不到新建的磁盘分区,提示通过重启才可以重用分区表,此时可以通过partprobe探测硬盘:
背景:6块硬盘,每个1TB,用一块硬盘做raid0,安装系统,剩余5块做raid5。由于ext3文件系统不支持大于2TB的分区,所以考虑使用GPT首先以root身份登录系统,查看硬盘信息:fdisk -l
[root@libftp ~]# fdisk -l
Disk /dev/cciss/c0d0: 1000.1 GB, 1000171331584 bytes
255 heads, 63 sectors/track, 121597 cylinders
Units = cylinders of 16065 * 512 = 8225280 bytes
Device Boot Start End Blocks Id System
/dev/cciss/c0d0p1 * 1 33 265041 83 Linux
/dev/cciss/c0d0p2 34 116105 932348340 83 Linux
/dev/cciss/c0d0p3 116106 118655 20482875 83 Linux
/dev/cciss/c0d0p4 118656 121597 23631615 5 Extended
/dev/cciss/c0d0p5 118656 120567 15358108+ 83 Linux
/dev/cciss/c0d0p6 120568 121587 8193118+ 82 Linux swap / Solaris
WARNING: GPT (GUID Partition Table) detected on '/dev/cciss/c0d1'! The util fdisk doesn't support GPT. Use GNU Parted.
Disk /dev/cciss/c0d1: 4000.6 GB, 4000684662784 bytes
255 heads, 63 sectors/track, 486388 cylinders
Units = cylinders of 16065 * 512 = 8225280 bytes
Device Boot Start End Blocks Id System
/dev/cciss/c0d1p1 1 267350 2147483647+ ee EFI GPT
本日志由 flyinweb 于 2011-05-24 14:41:58 发表到 云计算与虚拟化 中,目前已经被浏览 2399 次,评论 0 次;
作者添加了以下标签: vSphere Client Help;
1、安装
首先要在存储设备上做好RAID,设置好iSCSI 目标方(target)。
这里主要说明iSCSI initiator的安装。
不同的操作系统对应各自的iSCSI initiator,以Redhat enterprise5为例。到网上下载iscsi-initiator-utils-6.2.0.742-0.5.el5.i386.rpm
# rpm -ivh iscsi-initiator-utils-6.2.0.742-0.5.el5.i386.rpm
在服务器上安装了iSCSI initiator以及iscsiadm
iscsiadm是基于命令行的iscsi管理工具,提供了对iscsi节点、会话、连接以及发现记录的操作。
iscsiadm的使用说明可以查看/usr/share/doc/iscsi-initiator-utils-6.2.0.742/README,也可以运行man iscsiadm或iscsiadm -help
ZooKeeper is a high-performance coordination service for distributed applications. It exposes common services - such as naming, configuration management, synchronization, and group services - in a simple interface so you don't have to write them from scratch. You can use it off-the-shelf to implement consensus, group management, leader election, and presence protocols. And you can build on it for your own, specific needs.
本日志由 flyinweb 于 2011-05-11 09:00:09 发表到 Windows 中,目前已经被浏览 1057 次,评论 0 次;
作者添加了以下标签: 忘记管理员账户密码,forgot Windows 2008 R2 administrator password;
首页只显示了部分日志内容,要查看日志的全部内容请阅读全文;
For some reason that has escaped me Path MTU Discovery in Windows just doesn’t seem to figure out the MTU for a given path (something to do with routers being poorly configured to not respond to ICMP requests). So Windows uses the default. For the most part this doesn’t affect anyone, however if it dos affect you, it really annoys you. Failure of PMTUD will result in some websites not loading correctly, having trouble connecting to normally reliable online services and general Internet weirdness.
本日志由 flyinweb 于 2011-05-10 17:47:22 发表到 Windows 中,目前已经被浏览 970 次,评论 0 次;
作者添加了以下标签: MTU,Maximum Transmission Unit;
首页只显示了部分日志内容,要查看日志的全部内容请阅读全文;
It is quite useful and interesting too.
VIRT 的上限是64G,也就是36位, cat /proc/cpuinfo的结果是:addre
昨天要准备用线程重写webbench,试验了下Fedora Linux 2.6.35.14
不明白您的具体的意思是什么?
已经发送到你QQ邮箱
http://www.2mysite.net/scriptencoder/screnc.asp 站长你好,看
你好,我发现一个问题,就是从mysqld2同步过来的数据,在mysqld1的
晕,我说是怎么回事情,原来我和你一样,忘记设置了活动分区