oracle11g中asm磁盘组基本操作-凯发app官方网站

凯发app官方网站-凯发k8官网下载客户端中心 | | 凯发app官方网站-凯发k8官网下载客户端中心
  • 博客访问: 76864
  • 博文数量: 12
  • 博客积分: 0
  • 博客等级: 民兵
  • 技术积分: 2
  • 用 户 组: 普通用户
  • 注册时间: 2015-07-09 10:39
文章分类
文章存档

2017年(1)

2016年(5)

2015年(6)

我的朋友
相关博文
  • ·
  • ·
  • ·
  • ·
  • ·
  • ·
  • ·
  • ·
  • ·
  • ·

分类: oracle

2017-03-01 14:47:55

磁盘组操作,grid用户下:

sqlplus /nolog

sql> conn / as sysasm
查询现有磁盘组及磁盘信息:

sql> select group_number gno,name,state,type,total_mb,free_mb,required_mirror_free_mb rmfmb,usable_file_mb ufmb from v$asm_diskgroup;

       gno name    state                  type           total_mb    free_mb      rmfmb       ufmb
---------- ------------------------------ ------------ ---------- ---------- ---------- ----------
         1 dg1     mounted                normal             4076        575        879       -152
         2 dg2     mounted                normal             4076       3531        139       1696
sql> 
sql> col name format a10
sql> col fgno format a20
sql> select group_number gno,name,failgroup fgno,state,total_mb,free_mb,header_status from v$asm_disk;
       gno name       fgno                 state              total_mb    free_mb header_status
---------- ---------- -------------------- ---------------- ---------- ---------- ------------------------
         0                                 normal                    0          0 provisioned
         0                                 normal                    0          0 provisioned
         1 vol1       vol1                 normal                 1019        141 member
         1 vol2       vol2                 normal                 1019        144 member
         1 vol3       vol3                 normal                 1019        140 member
         1 vol4       vol4                 normal                 1019        150 member
         2 vol5       vol5                 normal                 1019        880 member
         2 vol6       vol6                 normal                 1019        883 member
         2 vol7       vol7                 normal                 1019        885 member
         2 vol8       vol8                 normal                 1019        883 member
10 rows selected.
--创建磁盘组

sql> create diskgroup dg3 normal redundancy disk 'orcl:vol9','orcl:vol10';

diskgroup created.
或:
sql> create diskgroup dg3 normal redundancy disk 'orcl:vol9' disk 'orcl:vol10';
diskgroup created.
--添加磁盘
sql> alter diskgroup dg1 add disk 'orcl:vol9';
diskgroup altered.
--删除磁盘
sql> alter diskgroup dg1 drop disk vol9;
diskgroup altered.
sql> select group_number gno,name,failgroup fgno,state,total_mb,free_mb,header_status from v$asm_disk;
       gno name                           fgno                 state              total_mb    free_mb header_status
---------- ------------------------------ -------------------- ---------------- ---------- ---------- ------------------------
         0                                                     normal                    0          0 former
         1 vol1                           vol1                 normal                 1019        284 member
         1 vol2                           vol2                 normal                 1019        286 member
         1 vol3                           vol3                 normal                 1019        284 member
         1 vol4                           vol4                 normal                 1019        287 member
         2 vol5                           vol5                 normal                 1019        880 member
         2 vol6                           vol6                 normal                 1019        883 member
         2 vol7                           vol7                 normal                 1019        885 member
         2 vol8                           vol8                 normal                 1019        883 member
         1 vol9                           vol9                 dropping               1019        451 member
10 rows selected.

--取消删除

alter diskgroup dg1 undrop disks;
--调整大小


alter diskgroup dg1 resize disk vol4 size 1024 m


--unmount和mount磁盘组


sql> alter diskgroup dg3 dismount;
diskgroup altered.
sql> select group_number gno,name,state,type,total_mb,free_mb,required_mirror_free_mb rmfmb,usable_file_mb ufmb from v$asm_diskgroup;
       gno name                           state                  type                             total_mb    free_mb      rmfmb       ufmb
---------- ------------------------------ ---------------------- ------------------------------ ---------- ---------- ---------- ----------
         1 dg1                            mounted                normal                               4076        575        879       -152
         2 dg2                            mounted                normal                               4076       3531        139       1696
         0 dg3                            dismounted 
         
sql> alter diskgroup dg3 mount;  
diskgroup altered.


阅读(2041) | 评论(0) | 转发(0) |
0

上一篇:oracle的几类约束介绍!

下一篇:没有了

给主人留下些什么吧!~~
")); function link(t){ var href= $(t).attr('href'); href ="?url=" encodeuricomponent(location.href); $(t).attr('href',href); //setcookie("returnouturl", location.href, 60, "/"); }
网站地图