How to duplicate or multiplex control files on ASM ?(复制控制文件)

ON single-instance 1, make sure asm diskgroup is avaliable Select name,total_mb,free_mb from v$asm_diskgroup where state=’CONNECTED’; 2, check current controlfile and using spfile show parameter control_files show parameter pfile 3, add new controlfile to spfile alter system set control_files='[original file]’,'[asm diskgroup name where new control file will stored]’ scope=spfile ; for example: alter system set control_files=’+OLD/ANBOB/controlfile/current.258.798205861′,’+NEW_DATA’ … Read more

RedHat(RHEL)6 support ASMLIB (RHEL6支持asmlib)

With the annoucement of Oracle’s database support on RHEL6 and OEL6, they have decided to stop making ASMLIB for RHEL compatible kernels. ASMLIB is now only available if you are using Oracle Unbreakable Linux Kernel.But Recent events enabled Red Hat and Oracle to work togethe. Oracle ASMLib availability and support on Red Hat Enterprise Linux 6.

Script:List all SQL in the library cache cursor referencing a given table .(列出指定表上所有相关SQL)

PROMPT List all SQL in the library cache cursor referencing a given table — Author: weejar — — you need to run this script either as SYS or — need to have relevant X$ proxy views created — I tested in oracle 11g it worked . undefine owner undefine table_name prompt accept owner prompt ‘Please … Read more

MySql 5.5 tar安装及sysbench 配置

Next, let’s create the mysql user and group: groupadd mysql useradd -g mysql mysql create mysql soft and data files store dictroy. and install mysql mkdir -p /data/mysql tar zxvf mysql-5.5.36-linux2.6-x86_64.tar.gz mv mysql-5.5.36-linux2.6-x86_64 /data/mysql/ cd /usr/local ln -s /data/mysql/mysql-5.5.36-linux2.6-x86_64/ mysql scripts/mysql_install_db –user=mysql or (./mysql_install_db –user=mysql –basedir=/usr/local/mysql –datadir=/usr/local/mysql/data) Modify File and Directory Permissions cd /data/mysql/ chown … Read more

Recovery Loss Of Datafile For Which No Backup Is Available(恢复没有备份的数据文件)

来模拟一种刚建的表空间,还没来的及备份,数据文件被删除,但archive log 都在时的恢复。 sys@ANBOB>create tablespace tbs_rm datafile ‘/oradata/anbob/tbs_rm01.dbf’ size 10m; Tablespace created. sys@ANBOB>conn anbob Enter password: Connected. anbob@ANBOB>create table test_rm tablespace tbs_rm as select rownum id from dual connect by levelselect * from test_rm; ID ——————– 1 … 9 10 破坏数据文件,使用mv [oracle@db231 ~]$ mv /oradata/anbob/tbs_rm01.dbf /oradata/anbob/tbs_rm01_dbf sys@ANBOB>alter system flush buffer_cache; System altered. anbob@ANBOB>select * from … Read more

AWR Formatter (一个不错的AWR报告格式化google chrome 插件)

一个不错的oracle AWR 报告本地文件格式化chrome浏览器插件,看似用js完成,有一些特性非常不错,拿出来分享,作者Tyler Muth –观看 需要翻墙 视频介绍 下载 下载地址1 下载地址2 安装方法 1,下载AWR-Format.crx文件 2,打开chrome 谷歌浏览器,我这里版本是28,点击右上角的按钮或显示菜单,找工具–扩展程序 打开扩展程序页面 3,用鼠标把1 下载的文件托进浏览器的这个页面,增加插件,默认是启用,勾选插件下的“允许访问文件网址” 4,右击本地的AWR html文件,使用google chrome 打开,体验一下吧