April 12th, 2008 1,392 Views
最近试用了一下OCFS2,这是一个全新的集群文件系统,有自己的节点管理,心跳等集群中的概念,而且相对OCFS来说,有很大的改进,是一个全新的文件系统,支持较多的Oracle文件,包括OCR和Voting Disk等。
但是和ASM和RAW比起来,还是有一些本质的不同,在网上看到关于这几者之间的一个大讨论,特别深入,转载一下,学习之。 原文地址:http://zhouwf0726.itpub.net/post/9689/221194
先看一下Oracle OCFS2的官方定义:
WHAT IS OCFS2?
OCFS2 is the next generation of the Oracle Cluster File System for Linux. It is an extent based, POSIX compliant file system. Unlike the previous release (OCFS), OCFS2 is a general-purpose file system that can be used for shared Oracle home installations making management of Oracle Real Application Cluster (RAC) installations even easier. Among the new features and benefits are:
* Node and architecture local files using Context Dependent Symbolic Links (CDSL)
* Network based pluggable DLM
* Improved journaling / node recovery using the Linux Kernel “JBD” subsystem
* Improved performance of meta-data operations (space allocation, locking, etc).
* Improved data caching / locking (for files such as oracle binaries, libraries, etc)
这个大讨论是从一个问题引起的:200亿条数据,就是20T吧,用ASM好?还是用OCFS好?还是用RAW好?
阅读全文 »
Share This
归类于 存储 | 就等您评论了 »
January 18th, 2008 2,132 Views
之前好几个同事聊天的时候,说想自己装个RAC玩玩,怎么的也得两个节点吧,不行就整个虚拟机。VM team的同事干脆就用Oracle VM了。其实个人玩RAC也不是不可能,只要解决几个关键的问题就行了,比如双网卡,共享设备等。其中最关键的就是共享设备了,在一个独立硬盘上创建裸设备,作为OCR和Voting DISK甚至ASM的磁盘,下面就介绍一下,在Linux下面如何创建裸设备,也就是create raw device. 大致这么几个步骤:
1. Check iscsi has been autoenable;
using “/sbin/chkconfig –list|grep iscsi”. If it is enabled, using “/sbin/chkconfig –level 2345 iscsi on” to enable it.
2. using “fdisk -l ” to check the partition information;
“/sbin/fdisk -l /dev/sde”, and then use “fdisk” to create new partitions
3. Create “/etc/udev/devices/raw” directory if it does not exist;
4. Create “/dev/raw” directory if it does not exist;
5. Create new raw device on each node, using:
“mknod /etc/udev/devices/raw/name c 162 2″
And then change the device permissions;
6. Edit “/etc/sysconfig/rawdevices” to add new items referring to new partitions on each node; such as “/etc/udev/devices/raw/name /dev/b_name”;
7. run “/sbin/udevstart” and check whether new raw devices have been generate in “/etc/udev/devices/raw” and “/dev/raw/”;
8. Changt the mode and own of the raw devices under “/dev/” directory;
9. service rawdevices restart
至此,就基本可以了,注意OCR和VD只能建在raw device上。
多谢blue_prince指正:其实OCR和VOTING DISK不一定非要在祼设备上面不可,以OCFS或者共享的NFS上面也可以的,只是可靠性不如祼设备那么强而已
Share This
归类于 数据库 | 已经有3 条评论 »
December 18th, 2007 1,234 Views
周日从深圳图书馆淘的一本《使用SAN与NAS》,现在做做读书笔记。
SAN的概念定义:SAN就是两个或者多个设备通过串行SCSI协议进行通信,比如Fibre Channel或者iSCSI。
NAS的概念定义:NAS(网络附属存储)是指通过NFS,CIFS或者DAFS共享文件的计算机(或者设备)。
对比如下:
SAN:
协议: 串行SCSI-3
共享: 原始磁盘或者磁带
允许: 不同的服务器可以访问同一个原始磁盘或者磁带
替代: 替代本地附属磁盘
NAS:
协议: NFS/CIFS
共享: 文件系统
允许: 不同的用户可以访问同一个文件-
替代: 替代NFS/CIFS
先记录这么点,有空再写。
Share This
归类于 存储 | 已经有2 条评论 »
November 11th, 2007 1,006 Views
RAID 4: Independent Data disks with shared Parity disk
Characteristics/Advantages
1. Very high Read data transaction rate
2. Low ratio of ECC (Parity) disks to data disks means high efficiency
3. High aggregate Read transfer rate
Disadvantages
1. Quite complex controller design
2. Worst Write transaction rate and Write aggregate transfer rate
3. Difficult and inefficient data rebuild in the event of disk failure
4. Block Read transfer rate equal to that of a single disk


Each entire block is written onto a data disk. Parity for same rank blocks is generated on Writes, recorded on the parity disk and checked on Reads.
RAID Level 4 requires a minimum of 3 drives to implement
Share This
归类于 存储 | 就等您评论了 »
November 11th, 2007 997 Views
RAID 3: Parallel transfer with parity
Characteristics/Advantages
1. Very high Read data transfer rate
2. Very high Write data transfer rate
3. Disk failure has an insignificant impact on throughput
4. Low ratio of ECC (Parity) disks to data disks means high efficiency
Disadvantages
1. Transaction rate equal to that of a single disk drive at best (if spindles are synchronized)
2. Controller design is fairly complex
3. Very difficult and resource intensive to do as a “software” RAID
Recommended Applications
1. Video Production and live streaming
2. Image Editing
3. Video Editing
4. Prepress Applications
5. Any application requiring high throughput


The data block is subdivided (”striped”) and written on the data disks. Stripe parity is generated on Writes, recorded on the parity disk and checked on Reads.
RAID Level 3 requires a minimum of 3 drives to implement
Share This
归类于 存储 | 就等您评论了 »
November 11th, 2007 1,187 Views
RAID 2: Hamming Code ECC
Characteristics/Advantages
1. “On the fly” data error correction
2. Extremely high data transfer rates possible
3. The higher the data transfer rate required, the better the ratio of data disks to ECC disks
4. Relatively simple controller design compared to RAID levels 3,4 & 5
Disadvantages
1. Very high ratio of ECC disks to data disks with smaller word sizes - inefficient
2. Entry level cost very high - requires very high transfer rate requirement to justify
3. Transaction rate is equal to that of a single disk at best (with spindle synchronization)
4. No commercial implementations exist / not commercially viable

Each bit of data word is written to a data disk drive (4 in this example: 0 to 3). Each data word has its Hamming Code ECC word recorded on the ECC disks. On Read, the ECC code verifies correct data or corrects single disk errors.
Share This
归类于 存储 | 就等您评论了 »
November 11th, 2007 887 Views
RAID1: Mirroring and Duplexing
Characteristics/Advantages
1. One Write or two Reads possible per mirrored pair
2. Twice the Read transaction rate of single disks, same Write transaction rate as single disks
3. 100% redundancy of data means no rebuild is necessary in case of a disk failure, just a copy to the replacement disk
4. Transfer rate per block is equal to that of a single disk
5. Under certain circumstances, RAID 1 can sustain multiple simultaneous drive failures
6. Simplest RAID storage subsystem design
Disadvantages
1. Highest disk overhead of all RAID types (100%) - inefficient
2. Typically the RAID function is done by system software, loading the CPU/Server and possibly degrading throughput at high activity levels. Hardware implementation is strongly recommended
3. May not support hot swap of failed disk when implemented in “software”
Recommended Applications
1. Accounting
2. Payroll
3. Financial
4. Any application requiring very high availability
For Highest performance, the controller must be able to perform two concurrent separate Reads per mirrored pair or two duplicate Writes per mirrored pair.

RAID Level 1 requires a minimum of 2 drives to implement
Share This
归类于 存储 | 就等您评论了 »
November 11th, 2007 914 Views
对存储的初步认识还是加入oracle以后的事情,毕竟这是一个非常专业的领域,到现在还一直对存储的概念有点点模糊:光线通道,FC,SCSII,NAS,SAN, DAS,LUN,冗余,容灾,镜像,控制器等等等等。这些概念正在慢慢慢慢清晰,今天又发现一个系列的RAID的专题文章,转载一下,学习中。。。
RAID 0: Striped Disk Array without Fault Tolerance
Characteristics/Advantages
1. RAID 0 implements a striped disk array, the data is broken down into blocks and each block is written to a separate disk drive
2. I/O performance is greatly improved by spreading the I/O load across many channels and drives
3. Best performance is achieved when data is striped across multiple controllers with only one drive per controller
4. No parity calculation overhead is involved
5. Very simple design
6. Easy to implement
Disadvantages
1. Not a “True” RAID because it is NOT fault-tolerant
2. The failure of just one drive will result in all data in an array being lost
3. Should never be used in mission critical environments
Recommended Applications
1. Video Production and Editing
2. Image Editing
3. Pre-Press Applications
4. Any application requiring high bandwidth

RAID Level 0 requires a minimum of 2 drives to implement
Share This
归类于 存储 | 就等您评论了 »