Exadata VM CELL 上添加新磁盘--扩充空间

  近日在Exadata VM上测试IORM,发现CELL的磁盘空间不够了,没有办法,自己给CELL添加新磁盘,并创建新的Lun,celldisk和griddisk.  
  (Exadata VM Template可以在http://edelivery.oracle.com下载)    
  先描述一下我的测试环境    
一个DELL台式机,部署了六个服务器,一个DNS,两个compute node和三个Cell,就是一个Quarter Rack配置    

[root@cnexa1 ~]# xm list 
Name                                        ID   Mem VCPUs      State   Time(s) 
Domain-0                                     0   567     4     r-----  63820.0 
dns01                                        2  1024     1     -b----   6731.3 
qr01cel01                                    1  2240     1     -b---- 317517.7 
qr01cel02                                    7  2240     1     -b---- 101918.5 
qr01cel03                                    6  2240     1     -b---- 140451.8 
qr01db01                                    13  3360     1     -b----  20109.5 
qr01db02                                    14  3360     1     -b----  18151.4

查看一下VM配置  

[root@cnexa1 ~]# cd /OVS/running_pool/ 
[root@cnexa1 running_pool]# ls 
dns01  qr01cel01  qr01cel02  qr01cel03  qr01db01  qr01db02 
[root@cnexa1 running_pool]# cd qr01db01/ 
[root@cnexa1 qr01db01]# more vm.cfg 
# Automatically generated xen config file 
name = "qr01db01" 
memory = "3360" 
disk = [ 'file:/OVS/running_pool/qr01db01/system.img,xvda,w', 
         'file:/OVS/running_pool/qr01db01/u01.img,xvdb,w', 
         'file:/OVS/running_pool/qr01db01/swap_4g.img,xvdd,w', ] 
vif = [ 'mac=00:16:3e:01:01:04, ip=192.0.2.14, bridge=xenbr0', 
        'mac=00:16:3e:01:01:14, ip=192.168.1.14',] 
vfb = ["type=vnc,vncunused=1,vnclisten=0.0.0.0"] 
bootloader="/usr/bin/pygrub" 
vcpus=1 
on_reboot   = 'restart' 
on_crash    = 'restart' 
[root@cnexa1 qr01db01]# more ../qr01cel01/vm.cfg 
name = "qr01cel01" 
memory = "2240" 
disk = [ 'file:/OVS/running_pool/qr01cel01/system.img,xvda,w', 
         'file:/OVS/running_pool/qr01cel01/u01.img,xvdb,w', 
         'file:/OVS/running_pool/qr01cel01/u02.img,xvdc,w', 
         'file:/OVS/running_pool/qr01cel01/swap_4g.img,xvdd,w',]           
vif = [ 'mac=00:16:3e:01:01:01, ip=192.0.2.11, bridge=xenbr0', 
        'mac=00:16:3e:01:01:11, ip=192.168.1.11',] 
vfb = ["type=vnc,vncunused=1,vnclisten=0.0.0.0"] 
bootloader="/usr/bin/pygrub" 
vcpus=1 
on_reboot   = 'restart' 
on_crash    = 'restart' 
[root@cnexa1 qr01db01]#

我就在qr01cel01上增加新的磁盘,下面开始实验

1.首先要给qr01cel01虚拟机在VM层面添加新的磁盘设备,通过dd命令来实现,增加一个10G的文件  

dd if=/dev/zero of=/OVS/running_pool/qr01cel01/test.img bs=1G count=10

2.查看vm.cfg文件    

[root@cnexa1 qr01cel01]# ls 
swap_4g.img  system.img  system.img.bak  test.img  u01.img  u02.img  vm.cfg 
[root@cnexa1 qr01cel01]# more vm.cfg 
name = "qr01cel01" 
memory = "2240" 
disk = [ 'file:/OVS/running_pool/qr01cel01/system.img,xvda,w', 
         'file:/OVS/running_pool/qr01cel01/u01.img,xvdb,w', 
         'file:/OVS/running_pool/qr01cel01/u02.img,xvdc,w', 
         'file:/OVS/running_pool/qr01cel01/swap_4g.img,xvdd,w',] 
vif = [ 'mac=00:16:3e:01:01:01, ip=192.0.2.11, bridge=xenbr0', 
        'mac=00:16:3e:01:01:11, ip=192.168.1.11',] 
vfb = ["type=vnc,vncunused=1,vnclisten=0.0.0.0"] 
bootloader="/usr/bin/pygrub" 
vcpus=1 
on_reboot   = 'restart' 
on_crash    = 'restart'

3.修改vm.cfg文件,并重新启动主机

[root@cnexa2 qr01cel01]# dd if=/dev/zero of=/OVS/running_pool/qr01cel01/test.img bs=1G count=10
1+0 records in 
1+0 records out 
1073741824 bytes (1.1 GB) copied, 7.23592 seconds, 148 MB/s
[root@cnexa2 qr01cel01]# xm create vm.cfg
Using config file "./vm.cfg". 
Started domain qr01cel01 (id=3)
[root@cnexa1 qr01cel01]# more vm.cfg
name = "qr01cel01" 
memory = "2240" 
disk = [ 'file:/OVS/running_pool/qr01cel01/system.img,xvda,w', 
         'file:/OVS/running_pool/qr01cel01/u01.img,xvdb,w', 
         'file:/OVS/running_pool/qr01cel01/u02.img,xvdc,w', 
         'file:/OVS/running_pool/qr01cel01/swap_4g.img,xvdd,w', 
         'file:/OVS/running_pool/qr01cel01/test.img,xvde,w!',]       <<<<<<<<<<<<<<已经添加磁盘设备条目 
vif = [ 'mac=00:16:3e:01:01:01, ip=192.0.2.11, bridge=xenbr0', 
        'mac=00:16:3e:01:01:11, ip=192.168.1.11',] 
vfb = ["type=vnc,vncunused=1,vnclisten=0.0.0.0"] 
bootloader="/usr/bin/pygrub" 
vcpus=1 
on_reboot   = 'restart' 
on_crash    = 'restart' 
[root@cnexa1 qr01db01]#

4.可以通过过vncviewer连接到VM内的主机  
      cnexa1:1    
连接到虚拟机图形化以后,需要更改该虚拟机的IP和hostname,这样后续就可以用ssh连接虚拟机。  

5.在/etc/xen下创建一个软连接到你需要连接的guest下的vm.cfg文件,这样就可以通过xm create qr01cel01的方式启动虚拟机,而不是需要cd到需要启动的目录下启动xm create vm.cfg  

[root@cnexa1 xen]# pwd 
/etc/xen 
[root@cnexa1 xen]# ll 
total 140 
drwxr-xr-x 2 root root  4096 Mar 25  2010 auto 
lrwxrwxrwx 1 root root    30 Sep 23  2012 dns01 -> /OVS/running_pool/dns01/vm.cfg 
lrwxrwxrwx 1 root root    31 Mar 31  2012 host01 -> /OVS/running_pool/host01/vm.cfg 
lrwxrwxrwx 1 root root    31 Mar 31  2012 host02 -> /OVS/running_pool/host02/vm.cfg 
lrwxrwxrwx 1 root root    31 Mar 31  2012 host03 -> /OVS/running_pool/host03/vm.cfg 
-rwxr-xr-x 1 root root   840 May 19  2009 qemu-ifup 
lrwxrwxrwx 1 root root    34 Apr  1  2012 qr01cel01 -> /OVS/running_pool/qr01cel01/vm.cfg 
lrwxrwxrwx 1 root root    34 Apr  1  2012 qr01cel02 -> /OVS/running_pool/qr01cel02/vm.cfg 
lrwxrwxrwx 1 root root    34 Apr  1  2012 qr01cel03 -> /OVS/running_pool/qr01cel03/vm.cfg 
lrwxrwxrwx 1 root root    33 Apr  1  2012 qr01db01 -> /OVS/running_pool/qr01db01/vm.cfg 
lrwxrwxrwx 1 root root    33 Apr  1  2012 qr01db02 -> /OVS/running_pool/qr01db02/vm.cfg

至此,VM上硬件层面需要的准备已经完成,下面看是CELL内部的工作。

6.Cell上查看磁盘  

[root@qr01cel01 ~]# fdisk -l
Disk /dev/xvda: 14.6 GB, 14664202240 bytes
255 heads, 63 sectors/track, 1782 cylinders 
Units = cylinders of 16065 * 512 = 8225280 bytes
    Device Boot      Start         End      Blocks   Id  System
/dev/xvda1   *           1          12       96358+  83  Linux 
/dev/xvda2              13        1782    14217525   83  Linux
Disk /dev/xvdb: 16.7 GB, 16777216000 bytes
255 heads, 63 sectors/track, 2039 cylinders 
Units = cylinders of 16065 * 512 = 8225280 bytes
    Device Boot      Start         End      Blocks   Id  System
/dev/xvdb1               1         159     1277136   83  Linux 
/dev/xvdb2             160         318     1277167+  83  Linux 
/dev/xvdb3             319         477     1277167+  83  Linux 
/dev/xvdb4             478        2039    12546765    5  Extended 
/dev/xvdb5             478         636     1277136   83  Linux 
/dev/xvdb6             637         795     1277136   83  Linux 
/dev/xvdb7             796         954     1277136   83  Linux 
/dev/xvdb8             955        1113     1277136   83  Linux 
/dev/xvdb9            1114        1272     1277136   83  Linux 
/dev/xvdb10           1273        1431     1277136   83  Linux 
/dev/xvdb11           1432        1590     1277136   83  Linux 
/dev/xvdb12           1591        1749     1277136   83  Linux 
/dev/xvdb13           1750        1908     1277136   83  Linux 
/dev/xvdb14           1909        1922      112423+  83  Linux 
/dev/xvdb15           1923        1936      112423+  83  Linux
Disk /dev/xvdc: 2097 MB, 2097152000 bytes
255 heads, 63 sectors/track, 254 cylinders 
Units = cylinders of 16065 * 512 = 8225280 bytes
    Device Boot      Start         End      Blocks   Id  System
/dev/xvdc1               1          14      112423+  83  Linux 
/dev/xvdc2              15          28      112455   83  Linux 
/dev/xvdc3              29          42      112455   83  Linux 
/dev/xvdc4              43         254     1702890    5  Extended 
/dev/xvdc5              43          56      112423+  83  Linux 
/dev/xvdc6              57          70      112423+  83  Linux 
/dev/xvdc7              71          84      112423+  83  Linux 
/dev/xvdc8              85          98      112423+  83  Linux 
/dev/xvdc9              99         112      112423+  83  Linux 
/dev/xvdc10            113         126      112423+  83  Linux 
/dev/xvdc11            127         140      112423+  83  Linux 
/dev/xvdc12            141         154      112423+  83  Linux 
/dev/xvdc13            155         168      112423+  83  Linux 
/dev/xvdc14            169         182      112423+  83  Linux 
/dev/xvdc15            183         196      112423+  83  Linux
Disk /dev/xvdd: 4294 MB, 4294967296 bytes                         
255 heads, 63 sectors/track, 522 cylinders 
Units = cylinders of 16065 * 512 = 8225280 bytes
Disk /dev/xvdd doesn't contain a valid partition table
Disk /dev/xvde: 10.7 GB, 10737418240 bytes                  <<<<<<<<<<<这部分才是我们刚刚创建的磁盘
255 heads, 63 sectors/track, 1305 cylinders 
Units = cylinders of 16065 * 512 = 8225280 bytes
Disk /dev/xvde doesn't contain a valid partition table

7.通过fdisk /dev/xvde划分了8分逻辑分区,划分之后,需要创建lun,其实lun的创建非常简单,就是在路径/opt/oracle/cell11.2.2.4.0_LINUX.X64_110929/disks/raw/下创建一个软链接到/dev/xvd*.  
当cell扫描磁盘的时候告诉真实的磁盘位置。

[root@qr01cel01 raw]# ln -sf /dev/xvde11  DISK13
[root@qr01cel01 raw]# ln -sf /dev/xvde12  DISK14 
[root@qr01cel01 raw]# ln -sf /dev/xvde5  DISK15 
[root@qr01cel01 raw]# ln -sf /dev/xvde6  DISK16 
[root@qr01cel01 raw]# ln -sf /dev/xvde7  DISK17 
[root@qr01cel01 raw]# ln -sf /dev/xvde8  DISK18 
[root@qr01cel01 raw]# ln -sf /dev/xvde9  DISK19
查看软链接
[root@qr01cel01 raw]# ll 
total 112 
lrwxrwxrwx 1 root root 10 Nov 29  2010 DISK00 -> /dev/xvdb1 
lrwxrwxrwx 1 root root 10 Nov 29  2010 DISK01 -> /dev/xvdb2 
lrwxrwxrwx 1 root root 10 Nov 29  2010 DISK02 -> /dev/xvdb3 
lrwxrwxrwx 1 root root 10 Nov 29  2010 DISK03 -> /dev/xvdb5 
lrwxrwxrwx 1 root root 10 Nov 29  2010 DISK04 -> /dev/xvdb6 
lrwxrwxrwx 1 root root 10 Nov 29  2010 DISK05 -> /dev/xvdb7 
lrwxrwxrwx 1 root root 10 Nov 29  2010 DISK06 -> /dev/xvdb8 
lrwxrwxrwx 1 root root 10 Nov 29  2010 DISK07 -> /dev/xvdb9 
lrwxrwxrwx 1 root root 11 Nov 29  2010 DISK08 -> /dev/xvdb10 
lrwxrwxrwx 1 root root 11 Nov 29  2010 DISK09 -> /dev/xvdb11 
lrwxrwxrwx 1 root root 11 Nov 29  2010 DISK10 -> /dev/xvdb12 
lrwxrwxrwx 1 root root 11 Nov 29  2010 DISK11 -> /dev/xvdb13 
lrwxrwxrwx 1 root root 11 Apr 18 18:25 DISK12 -> /dev/xvde10   <<<<<< 
lrwxrwxrwx 1 root root 11 Apr 18 18:25 DISK13 -> /dev/xvde11 
lrwxrwxrwx 1 root root 11 Apr 18 18:25 DISK14 -> /dev/xvde12 
lrwxrwxrwx 1 root root 10 Apr 18 18:25 DISK15 -> /dev/xvde5 
lrwxrwxrwx 1 root root 10 Apr 18 18:25 DISK16 -> /dev/xvde6 
lrwxrwxrwx 1 root root 10 Apr 18 18:25 DISK17 -> /dev/xvde7 
lrwxrwxrwx 1 root root 10 Apr 18 18:25 DISK18 -> /dev/xvde8 
lrwxrwxrwx 1 root root 10 Apr 18 18:25 DISK19 -> /dev/xvde9    <<<<<< 
lrwxrwxrwx 1 root root 11 Nov 29  2010 FLASH00 -> /dev/xvdb14 
lrwxrwxrwx 1 root root 11 Nov 29  2010 FLASH01 -> /dev/xvdb15 
lrwxrwxrwx 1 root root 10 Nov 29  2010 FLASH02 -> /dev/xvdc1 
lrwxrwxrwx 1 root root 10 Nov 29  2010 FLASH03 -> /dev/xvdc2 
lrwxrwxrwx 1 root root 10 Nov 29  2010 FLASH04 -> /dev/xvdc3 
lrwxrwxrwx 1 root root 10 Nov 29  2010 FLASH05 -> /dev/xvdc5 
lrwxrwxrwx 1 root root 10 Nov 29  2010 FLASH06 -> /dev/xvdc6 
lrwxrwxrwx 1 root root 10 Nov 29  2010 FLASH07 -> /dev/xvdc7 
lrwxrwxrwx 1 root root 10 Nov 29  2010 FLASH08 -> /dev/xvdc8 
lrwxrwxrwx 1 root root 10 Nov 29  2010 FLASH09 -> /dev/xvdc9 
lrwxrwxrwx 1 root root 11 Nov 29  2010 FLASH10 -> /dev/xvdc10 
lrwxrwxrwx 1 root root 11 Nov 29  2010 FLASH11 -> /dev/xvdc11 
lrwxrwxrwx 1 root root 11 Nov 29  2010 FLASH12 -> /dev/xvdc12 
lrwxrwxrwx 1 root root 11 Nov 29  2010 FLASH13 -> /dev/xvdc13 
lrwxrwxrwx 1 root root 11 Nov 29  2010 FLASH14 -> /dev/xvdc14 
lrwxrwxrwx 1 root root 11 Nov 29  2010 FLASH15 -> /dev/xvdc15


8.查看LUN  

[root@qr01cel01 raw]# cellcli 
CellCLI: Release 11.2.2.4.0 - Production on Thu Apr 18 14:26:06 EDT 2013
Copyright (c) 2007, 2011, Oracle.  All rights reserved.
Cell Efficiency Ratio: 1,216 
                                                                              
CellCLI> list lun 
         /opt/oracle/cell11.2.2.4.0_LINUX.X64_110929/disks/raw/DISK00    /opt/oracle/cell11.2.2.4.0_LINUX.X64_110929/disks/raw/DISK00    normal 
         /opt/oracle/cell11.2.2.4.0_LINUX.X64_110929/disks/raw/DISK01    /opt/oracle/cell11.2.2.4.0_LINUX.X64_110929/disks/raw/DISK01    normal 
         /opt/oracle/cell11.2.2.4.0_LINUX.X64_110929/disks/raw/DISK02    /opt/oracle/cell11.2.2.4.0_LINUX.X64_110929/disks/raw/DISK02    normal 
         /opt/oracle/cell11.2.2.4.0_LINUX.X64_110929/disks/raw/DISK03    /opt/oracle/cell11.2.2.4.0_LINUX.X64_110929/disks/raw/DISK03    normal 
         /opt/oracle/cell11.2.2.4.0_LINUX.X64_110929/disks/raw/DISK04    /opt/oracle/cell11.2.2.4.0_LINUX.X64_110929/disks/raw/DISK04    normal 
         /opt/oracle/cell11.2.2.4.0_LINUX.X64_110929/disks/raw/DISK05    /opt/oracle/cell11.2.2.4.0_LINUX.X64_110929/disks/raw/DISK05    normal 
         /opt/oracle/cell11.2.2.4.0_LINUX.X64_110929/disks/raw/DISK06    /opt/oracle/cell11.2.2.4.0_LINUX.X64_110929/disks/raw/DISK06    normal 
         /opt/oracle/cell11.2.2.4.0_LINUX.X64_110929/disks/raw/DISK07    /opt/oracle/cell11.2.2.4.0_LINUX.X64_110929/disks/raw/DISK07    normal 
         /opt/oracle/cell11.2.2.4.0_LINUX.X64_110929/disks/raw/DISK08    /opt/oracle/cell11.2.2.4.0_LINUX.X64_110929/disks/raw/DISK08    normal 
         /opt/oracle/cell11.2.2.4.0_LINUX.X64_110929/disks/raw/DISK09    /opt/oracle/cell11.2.2.4.0_LINUX.X64_110929/disks/raw/DISK09    normal 
         /opt/oracle/cell11.2.2.4.0_LINUX.X64_110929/disks/raw/DISK10    /opt/oracle/cell11.2.2.4.0_LINUX.X64_110929/disks/raw/DISK10    normal 
         /opt/oracle/cell11.2.2.4.0_LINUX.X64_110929/disks/raw/DISK11    /opt/oracle/cell11.2.2.4.0_LINUX.X64_110929/disks/raw/DISK11    normal 
         /opt/oracle/cell11.2.2.4.0_LINUX.X64_110929/disks/raw/DISK12    /opt/oracle/cell11.2.2.4.0_LINUX.X64_110929/disks/raw/DISK12    normal 
         /opt/oracle/cell11.2.2.4.0_LINUX.X64_110929/disks/raw/DISK13    /opt/oracle/cell11.2.2.4.0_LINUX.X64_110929/disks/raw/DISK13    normal 
         /opt/oracle/cell11.2.2.4.0_LINUX.X64_110929/disks/raw/DISK14    /opt/oracle/cell11.2.2.4.0_LINUX.X64_110929/disks/raw/DISK14    normal 
         /opt/oracle/cell11.2.2.4.0_LINUX.X64_110929/disks/raw/DISK15    /opt/oracle/cell11.2.2.4.0_LINUX.X64_110929/disks/raw/DISK15    normal 
         /opt/oracle/cell11.2.2.4.0_LINUX.X64_110929/disks/raw/DISK16    /opt/oracle/cell11.2.2.4.0_LINUX.X64_110929/disks/raw/DISK16    normal 
         /opt/oracle/cell11.2.2.4.0_LINUX.X64_110929/disks/raw/DISK17    /opt/oracle/cell11.2.2.4.0_LINUX.X64_110929/disks/raw/DISK17    normal 
         /opt/oracle/cell11.2.2.4.0_LINUX.X64_110929/disks/raw/DISK18    /opt/oracle/cell11.2.2.4.0_LINUX.X64_110929/disks/raw/DISK18    normal 
         /opt/oracle/cell11.2.2.4.0_LINUX.X64_110929/disks/raw/DISK19    /opt/oracle/cell11.2.2.4.0_LINUX.X64_110929/disks/raw/DISK19    normal 
         /opt/oracle/cell11.2.2.4.0_LINUX.X64_110929/disks/raw/FLASH00   /opt/oracle/cell11.2.2.4.0_LINUX.X64_110929/disks/raw/FLASH00   normal 
         /opt/oracle/cell11.2.2.4.0_LINUX.X64_110929/disks/raw/FLASH01   /opt/oracle/cell11.2.2.4.0_LINUX.X64_110929/disks/raw/FLASH01   normal 
         /opt/oracle/cell11.2.2.4.0_LINUX.X64_110929/disks/raw/FLASH02   /opt/oracle/cell11.2.2.4.0_LINUX.X64_110929/disks/raw/FLASH02   normal 
         /opt/oracle/cell11.2.2.4.0_LINUX.X64_110929/disks/raw/FLASH03   /opt/oracle/cell11.2.2.4.0_LINUX.X64_110929/disks/raw/FLASH03   normal 
         /opt/oracle/cell11.2.2.4.0_LINUX.X64_110929/disks/raw/FLASH04   /opt/oracle/cell11.2.2.4.0_LINUX.X64_110929/disks/raw/FLASH04   normal 
         /opt/oracle/cell11.2.2.4.0_LINUX.X64_110929/disks/raw/FLASH05   /opt/oracle/cell11.2.2.4.0_LINUX.X64_110929/disks/raw/FLASH05   normal 
         /opt/oracle/cell11.2.2.4.0_LINUX.X64_110929/disks/raw/FLASH06   /opt/oracle/cell11.2.2.4.0_LINUX.X64_110929/disks/raw/FLASH06   normal 
         /opt/oracle/cell11.2.2.4.0_LINUX.X64_110929/disks/raw/FLASH07   /opt/oracle/cell11.2.2.4.0_LINUX.X64_110929/disks/raw/FLASH07   normal 
         /opt/oracle/cell11.2.2.4.0_LINUX.X64_110929/disks/raw/FLASH08   /opt/oracle/cell11.2.2.4.0_LINUX.X64_110929/disks/raw/FLASH08   normal 
         /opt/oracle/cell11.2.2.4.0_LINUX.X64_110929/disks/raw/FLASH09   /opt/oracle/cell11.2.2.4.0_LINUX.X64_110929/disks/raw/FLASH09   normal 
         /opt/oracle/cell11.2.2.4.0_LINUX.X64_110929/disks/raw/FLASH10   /opt/oracle/cell11.2.2.4.0_LINUX.X64_110929/disks/raw/FLASH10   normal 
         /opt/oracle/cell11.2.2.4.0_LINUX.X64_110929/disks/raw/FLASH11   /opt/oracle/cell11.2.2.4.0_LINUX.X64_110929/disks/raw/FLASH11   normal 
         /opt/oracle/cell11.2.2.4.0_LINUX.X64_110929/disks/raw/FLASH12   /opt/oracle/cell11.2.2.4.0_LINUX.X64_110929/disks/raw/FLASH12   normal 
         /opt/oracle/cell11.2.2.4.0_LINUX.X64_110929/disks/raw/FLASH13   /opt/oracle/cell11.2.2.4.0_LINUX.X64_110929/disks/raw/FLASH13   normal 
         /opt/oracle/cell11.2.2.4.0_LINUX.X64_110929/disks/raw/FLASH14   /opt/oracle/cell11.2.2.4.0_LINUX.X64_110929/disks/raw/FLASH14   normal 
         /opt/oracle/cell11.2.2.4.0_LINUX.X64_110929/disks/raw/FLASH15   /opt/oracle/cell11.2.2.4.0_LINUX.X64_110929/disks/raw/FLASH15   normal

9.创建Celldisk  

CellCLI> create celldisk all 
CellDisk CD_DISK12_qr01cel01 successfully created 
CellDisk CD_DISK13_qr01cel01 successfully created 
CellDisk CD_DISK14_qr01cel01 successfully created 
CellDisk CD_DISK15_qr01cel01 successfully created 
CellDisk CD_DISK16_qr01cel01 successfully created 
CellDisk CD_DISK17_qr01cel01 successfully created 
CellDisk CD_DISK18_qr01cel01 successfully created 
CellDisk CD_DISK19_qr01cel01 successfully created
CellCLI> list celldisk
         CD_00_qr01cel01         normal 
         CD_01_qr01cel01         normal 
         CD_02_qr01cel01         normal 
         CD_03_qr01cel01         normal 
         CD_04_qr01cel01         normal 
         CD_05_qr01cel01         normal 
         CD_06_qr01cel01         normal 
         CD_07_qr01cel01         normal 
         CD_08_qr01cel01         normal 
         CD_09_qr01cel01         normal 
         CD_10_qr01cel01         normal 
         CD_11_qr01cel01         normal 
         CD_DISK12_qr01cel01     normal 
         CD_DISK13_qr01cel01     normal 
         CD_DISK14_qr01cel01     normal 
         CD_DISK15_qr01cel01     normal 
         CD_DISK16_qr01cel01     normal 
         CD_DISK17_qr01cel01     normal 
         CD_DISK18_qr01cel01     normal 
         CD_DISK19_qr01cel01     normal 
         FD_00_qr01cel01         normal 
         FD_01_qr01cel01         normal 
         FD_02_qr01cel01         normal 
         FD_03_qr01cel01         normal 
         FD_04_qr01cel01         normal 
         FD_05_qr01cel01         normal 
         FD_06_qr01cel01         normal 
         FD_07_qr01cel01         normal 
         FD_08_qr01cel01         normal 
         FD_09_qr01cel01         normal 
         FD_10_qr01cel01         normal 
         FD_11_qr01cel01         normal 
         FD_12_qr01cel01         normal 
         FD_13_qr01cel01         normal 
         FD_14_qr01cel01         normal 
         FD_15_qr01cel01         normal

10.查看当前的griddisk  

CellCLI> list griddisk  
         DATA_QR01_CD_00_qr01cel01       active  
         DATA_QR01_CD_01_qr01cel01       active  
         DATA_QR01_CD_02_qr01cel01       active  
         DATA_QR01_CD_03_qr01cel01       active  
         DATA_QR01_CD_04_qr01cel01       active  
         DATA_QR01_CD_05_qr01cel01       active  
         DATA_QR01_CD_06_qr01cel01       active  
         DATA_QR01_CD_07_qr01cel01       active  
         DATA_QR01_CD_08_qr01cel01       active  
         DATA_QR01_CD_09_qr01cel01       active  
         DATA_QR01_CD_10_qr01cel01       active  
         DATA_QR01_CD_11_qr01cel01       active  
         DBFS_DG_CD_00_qr01cel01         active  
         DBFS_DG_CD_01_qr01cel01         active  
         DBFS_DG_CD_02_qr01cel01         active  
         DBFS_DG_CD_03_qr01cel01         active  
         DBFS_DG_CD_04_qr01cel01         active  
         DBFS_DG_CD_05_qr01cel01         active  
         DBFS_DG_CD_06_qr01cel01         active  
         DBFS_DG_CD_07_qr01cel01         active  
         DBFS_DG_CD_08_qr01cel01         active  
         DBFS_DG_CD_09_qr01cel01         active  
         DBFS_DG_CD_10_qr01cel01         active  
         DBFS_DG_CD_11_qr01cel01         active  
         RECO_QR01_CD_00_qr01cel01       active  
         RECO_QR01_CD_01_qr01cel01       active  
         RECO_QR01_CD_02_qr01cel01       active  
         RECO_QR01_CD_03_qr01cel01       active  
         RECO_QR01_CD_04_qr01cel01       active  
         RECO_QR01_CD_05_qr01cel01       active  
         RECO_QR01_CD_06_qr01cel01       active  
         RECO_QR01_CD_07_qr01cel01       active  
         RECO_QR01_CD_08_qr01cel01       active  
         RECO_QR01_CD_09_qr01cel01       active  
         RECO_QR01_CD_10_qr01cel01       active  
         RECO_QR01_CD_11_qr01cel01       active

11.创建griddisk        

CellCLI> create griddisk all prefix=data 
Cell disks were skipped because they had no freespace for grid disks: CD_00_qr01cel01, CD_01_qr01cel01, CD_02_qr01cel01, CD_03_qr01cel01, CD_04_qr01cel01, CD_05_qr01cel01, CD_06_qr01cel01, CD_07_qr01cel01, CD_08_qr01cel01, CD_09_qr01cel01, CD_10_qr01cel01, CD_11_qr01cel01, FD_00_qr01cel01, FD_01_qr01cel01, FD_02_qr01cel01, FD_03_qr01cel01, FD_04_qr01cel01, FD_05_qr01cel01, FD_06_qr01cel01, FD_07_qr01cel01, FD_08_qr01cel01, FD_09_qr01cel01, FD_10_qr01cel01, FD_11_qr01cel01, FD_12_qr01cel01, FD_13_qr01cel01, FD_14_qr01cel01, FD_15_qr01cel01. 
GridDisk data_CD_DISK12_qr01cel01 successfully created 
GridDisk data_CD_DISK13_qr01cel01 successfully created 
GridDisk data_CD_DISK14_qr01cel01 successfully created 
GridDisk data_CD_DISK15_qr01cel01 successfully created 
GridDisk data_CD_DISK16_qr01cel01 successfully created 
GridDisk data_CD_DISK17_qr01cel01 successfully created 
GridDisk data_CD_DISK18_qr01cel01 successfully created 
GridDisk data_CD_DISK19_qr01cel01 successfully created
===============================================================
注意:我由于只想将磁盘添加到data磁盘组,如果将一个celldisk分成data、reco和dbfs三个磁盘组的话,需要按照这个方法批量去做(注意命令执行先后顺序,先创建的磁盘组,会在磁盘外圈开始分配空间,后面创建的依次创建) 
CellCLI> CREATE GRIDDISK ALL PREFIX=DATA, size=<desired size>;  <<<<<<根据原有data diskgroup大小设置size, 
CellCLI> CREATE GRIDDISK ALL PREFIX=RECO, size=<desired size>;
CellCLI> CREATE GRIDDISK ALL PREFIX=DBFS;             <<<<<<<<<<<<<<<<<<将剩余的磁盘空间全部使用
===============================================================


12.查看当前的griddisk  

CellCLI> list griddisk 
         data_CD_DISK12_qr01cel01        active 
         data_CD_DISK13_qr01cel01        active 
         data_CD_DISK14_qr01cel01        active 
         data_CD_DISK15_qr01cel01        active 
         data_CD_DISK16_qr01cel01        active 
         data_CD_DISK17_qr01cel01        active 
         data_CD_DISK18_qr01cel01        active 
         data_CD_DISK19_qr01cel01        active 
         DATA_QR01_CD_00_qr01cel01       active 
         DATA_QR01_CD_01_qr01cel01       active 
         DATA_QR01_CD_02_qr01cel01       active 
         DATA_QR01_CD_03_qr01cel01       active 
         DATA_QR01_CD_04_qr01cel01       active 
         DATA_QR01_CD_05_qr01cel01       active 
         DATA_QR01_CD_06_qr01cel01       active 
         DATA_QR01_CD_07_qr01cel01       active 
         DATA_QR01_CD_08_qr01cel01       active 
         DATA_QR01_CD_09_qr01cel01       active 
         DATA_QR01_CD_10_qr01cel01       active 
         DATA_QR01_CD_11_qr01cel01       active 
         DBFS_DG_CD_00_qr01cel01         active 
         DBFS_DG_CD_01_qr01cel01         active 
         DBFS_DG_CD_02_qr01cel01         active 
         DBFS_DG_CD_03_qr01cel01         active 
         DBFS_DG_CD_04_qr01cel01         active 
         DBFS_DG_CD_05_qr01cel01         active 
         DBFS_DG_CD_06_qr01cel01         active 
         DBFS_DG_CD_07_qr01cel01         active 
         DBFS_DG_CD_08_qr01cel01         active 
         DBFS_DG_CD_09_qr01cel01         active 
         DBFS_DG_CD_10_qr01cel01         active 
         DBFS_DG_CD_11_qr01cel01         active 
         RECO_QR01_CD_00_qr01cel01       active 
         RECO_QR01_CD_01_qr01cel01       active 
         RECO_QR01_CD_02_qr01cel01       active 
         RECO_QR01_CD_03_qr01cel01       active 
         RECO_QR01_CD_04_qr01cel01       active 
         RECO_QR01_CD_05_qr01cel01       active 
         RECO_QR01_CD_06_qr01cel01       active 
         RECO_QR01_CD_07_qr01cel01       active 
         RECO_QR01_CD_08_qr01cel01       active 
         RECO_QR01_CD_09_qr01cel01       active 
         RECO_QR01_CD_10_qr01cel01       active 
         RECO_QR01_CD_11_qr01cel01       active

13.我们创建了下面几个Griddisk

data_CD_DISK12_qr01cel01        active
data_CD_DISK13_qr01cel01        active
data_CD_DISK14_qr01cel01        active
data_CD_DISK15_qr01cel01        active
data_CD_DISK16_qr01cel01        active
data_CD_DISK17_qr01cel01        active
data_CD_DISK18_qr01cel01        active
data_CD_DISK19_qr01cel01        active

   到这里就完成了,当griddisk创建成功后,cellsrv就能正常识别并且告诉compute node,然后就可以公共ASM磁盘组添加磁盘来使用新增加的磁盘设备

本文出自 “小小狗窝” 博客,谢绝转载!

你可能感兴趣的:(cell,exadata,celldisk,griddisk)