0

0

如何重命名asm中的磁盘组

php中文网

php中文网

发布时间:2016-06-07 15:54:13

|

1178人浏览过

|

来源于php中文网

原创

今天是2014-03-24,介绍一个重命名oracle asm 磁盘组的工具renamedg The renamedg tool enables you to change the name of a cloned disk group. The disk group must be dismounted on all nodes in the cluster before running renamedg on the disk grou

今天是2014-03-24,介绍一个重命名oracle asm 磁盘组的工具renamedg

The renamedg tool enables you to change the name of a cloned disk group. The disk group must be dismounted on all nodes in the cluster before running renamedg on the disk group.

renamedg renames a disk group using a two-step process:

Phase one

This phase generates a configuration file to be used in phase two.

Phase two

This phase uses the configuration file to perform the renaming of the disk group.

The syntax is:

百度AI开放平台
百度AI开放平台

百度提供的综合性AI技术服务平台,汇集了多种AI能力和解决方案

下载


renamedg {-help | help=true}

renamedg
[phase={ one|two |both } ] dgname=diskgroup
newdgname=newdiskgroup [config=configfile]
[ asm_diskstring=discoverystring, discoverystring ... ]
[ clean={true|false} ] [ check={true|false} ]
[ confirm={true|false}] [ verbose={ true|false} ]
[ keep_voting_files={true|false}]

  1. phase={one|two|both}

    注意:

     

    Applies to:
    Oracle Server - Enterprise Edition - Version: 10.1.0.2 to 11.2.0.0
    Information in this document applies to any platform.

    Goal
    The purpose of this document is to provide information about rename diskgroup in 10g and 11gR1 release

    Solution
    rename diskgroup option is a new feature of 11gR2 .

    You can use this tool to rename your 10g or 11gR1 ASM diskgroup

    you need to just install 11gR2 SIHA Grid Infrastructure software only installation.

    cd /bin
    renamedg

    use renamedg tool to rename 10g or 11gR1 diskgroup.

    Diskgroup cannot be renamed under following conditions :

    - the Diskgroup is mounted
    - the Diskgroup is being used by CSS
    - Diskgroup contains offline disks

    eg:

    -bash-4.1$ sqlplus / as sysasm
    
    SQL*Plus: Release 11.2.0.4.0 Production on Mon Mar 24 15:33:16 2014
    
    Copyright (c) 1982, 2013, Oracle.  All rights reserved.
    
    
    Connected to:
    Oracle Database 11g Enterprise Edition Release 11.2.0.4.0 - 64bit Production
    With the Automatic Storage Management option
    
    SQL> alter diskgroup new_datagroup2 dismount;
    
    Diskgroup altered.
    
    SQL> 
    SQL> 
    SQL> exit
    
    -bash-4.1$ 
    -bash-4.1$ renamedg -help
    NOTE: No asm libraries found in the system
    
    Parsing parameters..
    phase                           Phase to execute, 
                                    (phase=ONE|TWO|BOTH), default BOTH
    
    dgname                          Diskgroup to be renamed
    
    newdgname                       New name for the diskgroup
    
    config                          intermediate config file
    
    check                           just check-do not perform actual operation,
                                    (check=TRUE/FALSE), default FALSE
    
    confirm                         confirm before committing changes to disks,
                                    (confirm=TRUE/FALSE), default FALSE
    
    clean                           ignore errors,
                                    (clean=TRUE/FALSE), default TRUE
    
    asm_diskstring                  ASM Diskstring (asm_diskstring='discoverystring',
                                    'discoverystring1' ...)
    
    verbose                         verbose execution, 
                                    (verbose=TRUE|FALSE), default FALSE
    
    keep_voting_files               Voting file attribute, 
                                    (keep_voting_files=TRUE|FALSE), default FALSE
    
    -bash-4.1$ renamedg dgname=NEW_DATAGROUP2 newdgname=datagroup2 asm_diskstring='/dev/oracleasm/disks/*' verbose=true
    NOTE: No asm libraries found in the system
    
    Parsing parameters..
    
    Parameters in effect:
    
             Old DG name       : NEW_DATAGROUP2 
             New DG name          : DATAGROUP2 
             Phases               :
                     Phase 1
                     Phase 2
             Discovery str        : /dev/oracleasm/disks/* 
             Clean              : TRUE
             Raw only           : TRUE
    renamedg operation: dgname=NEW_DATAGROUP2 newdgname=datagroup2 asm_diskstring=/dev/oracleasm/disks/* verbose=true
    Executing phase 1
    Discovering the group
    Performing discovery with string:/dev/oracleasm/disks/*
    Identified disk UFS:/dev/oracleasm/disks/ASMDISK5 with disk number:0 and timestamp (33001227 75905024)
    Identified disk UFS:/dev/oracleasm/disks/ASMDISK6 with disk number:1 and timestamp (33001227 75905024)
    Identified disk UFS:/dev/oracleasm/disks/ASMDISK7 with disk number:2 and timestamp (33001227 75905024)
    Identified disk UFS:/dev/oracleasm/disks/ASMDISK8 with disk number:5 and timestamp (33001229 -598404096)
    Identified disk UFS:/dev/oracleasm/disks/ASMDISK9 with disk number:3 and timestamp (33001229 -678575104)
    Identified disk UFS:/dev/oracleasm/disks/ASMDISK10 with disk number:4 and timestamp (33001229 -678575104)
    Checking for hearbeat...
    Re-discovering the group
    Performing discovery with string:/dev/oracleasm/disks/*
    Identified disk UFS:/dev/oracleasm/disks/ASMDISK5 with disk number:0 and timestamp (33001227 75905024)
    Identified disk UFS:/dev/oracleasm/disks/ASMDISK6 with disk number:1 and timestamp (33001227 75905024)
    Identified disk UFS:/dev/oracleasm/disks/ASMDISK7 with disk number:2 and timestamp (33001227 75905024)
    Identified disk UFS:/dev/oracleasm/disks/ASMDISK8 with disk number:5 and timestamp (33001229 -598404096)
    Identified disk UFS:/dev/oracleasm/disks/ASMDISK9 with disk number:3 and timestamp (33001229 -678575104)
    Identified disk UFS:/dev/oracleasm/disks/ASMDISK10 with disk number:4 and timestamp (33001229 -678575104)
    Checking if the diskgroup is mounted or used by CSS 
    Checking disk number:0
    Checking disk number:1
    Checking disk number:2
    Checking disk number:5
    Checking disk number:3
    Checking disk number:4
    Generating configuration file..
    Completed phase 1
    Executing phase 2
    Looking for /dev/oracleasm/disks/ASMDISK5
    Modifying the header
    Looking for /dev/oracleasm/disks/ASMDISK6
    Modifying the header
    Looking for /dev/oracleasm/disks/ASMDISK7
    Modifying the header
    Looking for /dev/oracleasm/disks/ASMDISK8
    Modifying the header
    Looking for /dev/oracleasm/disks/ASMDISK9
    Modifying the header
    Looking for /dev/oracleasm/disks/ASMDISK10
    Modifying the header
    Completed phase 2
    Terminating kgfd context 0x7f57a379b0a0
    -bash-4.1$ sqlplus / as sysasm
    
    SQL*Plus: Release 11.2.0.4.0 Production on Mon Mar 24 15:35:04 2014
    
    Copyright (c) 1982, 2013, Oracle.  All rights reserved.
    
    
    Connected to:
    Oracle Database 11g Enterprise Edition Release 11.2.0.4.0 - 64bit Production
    With the Automatic Storage Management option
    
    SQL> select name,state from v$asm_diskgroup;
    
    NAME                           STATE
    ------------------------------ -----------
    DATAGROUP1                     MOUNTED
    DATAGROUP2                     DISMOUNTED
    
    SQL> alter diskgroup datagroup2 mount;
    
    Diskgroup altered.
    
    SQL> select name,state from v$asm_diskgroup;
    
    NAME                           STATE
    ------------------------------ -----------
    DATAGROUP1                     MOUNTED
    DATAGROUP2                     MOUNTED
    
    SQL> exit
    Disconnected from Oracle Database 11g Enterprise Edition Release 11.2.0.4.0 - 64bit Production
    With the Automatic Storage Management option
    -bash-4.1$ crsctl stat res -t
    --------------------------------------------------------------------------------
    NAME           TARGET  STATE        SERVER                   STATE_DETAILS       
    --------------------------------------------------------------------------------
    Local Resources
    --------------------------------------------------------------------------------
    ora.DATAGROUP1.dg
                   ONLINE  ONLINE       oracle-one                                   
    ora.DATAGROUP2.dg
                   ONLINE  ONLINE       oracle-one                                   
    ora.LISTENER.lsnr
                   ONLINE  ONLINE       oracle-one                                   
    ora.NEW_DATAGROUP2.dg
                   OFFLINE OFFLINE      oracle-one                                   
    ora.asm
                   ONLINE  ONLINE       oracle-one               Started             
    ora.ons
                   OFFLINE OFFLINE      oracle-one                                   
    --------------------------------------------------------------------------------
    Cluster Resources
    --------------------------------------------------------------------------------
    ora.cssd
          1        ONLINE  ONLINE       oracle-one                                   
    ora.diskmon
          1        OFFLINE OFFLINE                                                   
    ora.evmd
          1        ONLINE  ONLINE       oracle-one                                   
    ora.rhys.db
          1        OFFLINE OFFLINE                               Instance Shutdown   
    -bash-4.1$ srvctl remove diskgroup -g new_datagroup2
    -bash-4.1$ crsctl status res -t
    --------------------------------------------------------------------------------
    NAME           TARGET  STATE        SERVER                   STATE_DETAILS       
    --------------------------------------------------------------------------------
    Local Resources
    --------------------------------------------------------------------------------
    ora.DATAGROUP1.dg
                   ONLINE  ONLINE       oracle-one                                   
    ora.DATAGROUP2.dg
                   ONLINE  ONLINE       oracle-one                                   
    ora.LISTENER.lsnr
                   ONLINE  ONLINE       oracle-one                                   
    ora.asm
                   ONLINE  ONLINE       oracle-one               Started             
    ora.ons
                   OFFLINE OFFLINE      oracle-one                                   
    --------------------------------------------------------------------------------
    Cluster Resources
    --------------------------------------------------------------------------------
    ora.cssd
          1        ONLINE  ONLINE       oracle-one                                   
    ora.diskmon
          1        OFFLINE OFFLINE                                                   
    ora.evmd
          1        ONLINE  ONLINE       oracle-one                                   
    ora.rhys.db
          1        OFFLINE OFFLINE                               Instance Shutdown   
    

     

    热门AI工具

    更多
    DeepSeek
    DeepSeek

    幻方量化公司旗下的开源大模型平台

    豆包大模型
    豆包大模型

    字节跳动自主研发的一系列大型语言模型

    通义千问
    通义千问

    阿里巴巴推出的全能AI助手

    腾讯元宝
    腾讯元宝

    腾讯混元平台推出的AI助手

    文心一言
    文心一言

    文心一言是百度开发的AI聊天机器人,通过对话可以生成各种形式的内容。

    讯飞写作
    讯飞写作

    基于讯飞星火大模型的AI写作工具,可以快速生成新闻稿件、品宣文案、工作总结、心得体会等各种文文稿

    即梦AI
    即梦AI

    一站式AI创作平台,免费AI图片和视频生成。

    ChatGPT
    ChatGPT

    最最强大的AI聊天机器人程序,ChatGPT不单是聊天机器人,还能进行撰写邮件、视频脚本、文案、翻译、代码等任务。

    相关专题

    更多
    Python 序列化
    Python 序列化

    本专题整合了python序列化、反序列化相关内容,阅读专题下面的文章了解更多详细内容。

    0

    2026.02.02

    AO3官网入口与中文阅读设置 AO3网页版使用与访问
    AO3官网入口与中文阅读设置 AO3网页版使用与访问

    本专题围绕 Archive of Our Own(AO3)官网入口展开,系统整理 AO3 最新可用官网地址、网页版访问方式、正确打开链接的方法,并详细讲解 AO3 中文界面设置、阅读语言切换及基础使用流程,帮助用户稳定访问 AO3 官网,高效完成中文阅读与作品浏览。

    91

    2026.02.02

    主流快递单号查询入口 实时物流进度一站式追踪专题
    主流快递单号查询入口 实时物流进度一站式追踪专题

    本专题聚合极兔快递、京东快递、中通快递、圆通快递、韵达快递等主流物流平台的单号查询与运单追踪内容,重点解决单号查询、手机号查物流、官网入口直达、包裹进度实时追踪等高频问题,帮助用户快速获取最新物流状态,提升查件效率与使用体验。

    27

    2026.02.02

    Golang WebAssembly(WASM)开发入门
    Golang WebAssembly(WASM)开发入门

    本专题系统讲解 Golang 在 WebAssembly(WASM)开发中的实践方法,涵盖 WASM 基础原理、Go 编译到 WASM 的流程、与 JavaScript 的交互方式、性能与体积优化,以及典型应用场景(如前端计算、跨平台模块)。帮助开发者掌握 Go 在新一代 Web 技术栈中的应用能力。

    11

    2026.02.02

    PHP Swoole 高性能服务开发
    PHP Swoole 高性能服务开发

    本专题聚焦 PHP Swoole 扩展在高性能服务端开发中的应用,系统讲解协程模型、异步IO、TCP/HTTP/WebSocket服务器、进程与任务管理、常驻内存架构设计。通过实战案例,帮助开发者掌握 使用 PHP 构建高并发、低延迟服务端应用的工程化能力。

    5

    2026.02.02

    Java JNI 与本地代码交互实战
    Java JNI 与本地代码交互实战

    本专题系统讲解 Java 通过 JNI 调用 C/C++ 本地代码的核心机制,涵盖 JNI 基本原理、数据类型映射、内存管理、异常处理、性能优化策略以及典型应用场景(如高性能计算、底层库封装)。通过实战示例,帮助开发者掌握 Java 与本地代码混合开发的完整流程。

    5

    2026.02.02

    go语言 注释编码
    go语言 注释编码

    本专题整合了go语言注释、注释规范等等内容,阅读专题下面的文章了解更多详细内容。

    62

    2026.01.31

    go语言 math包
    go语言 math包

    本专题整合了go语言math包相关内容,阅读专题下面的文章了解更多详细内容。

    55

    2026.01.31

    go语言输入函数
    go语言输入函数

    本专题整合了go语言输入相关教程内容,阅读专题下面的文章了解更多详细内容。

    27

    2026.01.31

    热门下载

    更多
    网站特效
    /
    网站源码
    /
    网站素材
    /
    前端模板

    精品课程

    更多
    相关推荐
    /
    热门推荐
    /
    最新课程
    C# 教程
    C# 教程

    共94课时 | 8.4万人学习

    ASP 教程
    ASP 教程

    共34课时 | 4.4万人学习

    SQL 教程
    SQL 教程

    共61课时 | 3.7万人学习

    关于我们 免责申明 举报中心 意见反馈 讲师合作 广告合作 最新更新
    php中文网:公益在线php培训,帮助PHP学习者快速成长!
    关注服务号 技术交流群
    PHP中文网订阅号
    每天精选资源文章推送

    Copyright 2014-2026 https://www.php.cn/ All Rights Reserved | php.cn | 湘ICP备2023035733号