zoukankan      html  css  js  c++  java
  • 【BBED】编译及基本命令(1)

    BBED】编译及基本命令(1)

    一.1  BLOG文档结构图

    wps854D.tmp 

     

     

    一.2  前言部分

     

    一.2.1  导读和注意事项

    各位技术爱好者,看完本文后,你可以掌握如下的技能,也可以学到一些其它你所不知道的知识,~O(∩_∩)O~:

    BBED的安装(编译)

    ② BBED的基本命令

     

      Tips:

           ① 若文章代码格式有错乱,推荐使用搜狗、QQ360浏览器,也可以下载pdf格式的文档来查看,pdf文档下载地址:http://yunpan.cn/cdEQedhCs2kFz (提取码:ed9b 

           ② 本篇BLOG中命令的输出部分需要特别关注的地方我都用灰色背景和粉红色字体来表示,比如下边的例子中,thread 1的最大归档日志号为33thread 2的最大归档日志号为43是需要特别关注的地方;而命令一般使用黄色背景和红色字体注;对代码或代码输出部分的注释一般采用蓝色字体表示

     

      List of Archived Logs in backup set 11

      Thrd Seq     Low SCN    Low Time            Next SCN   Next Time

      ---- ------- ---------- ------------------- ---------- ---------

      1    32      1621589    2015-05-29 11:09:52 1625242    2015-05-29 11:15:48

      1    33      1625242    2015-05-29 11:15:48 1625293    2015-05-29 11:15:58

      2    42      1613951    2015-05-29 10:41:18 1625245    2015-05-29 11:15:49

      2    43      1625245    2015-05-29 11:15:49 1625253    2015-05-29 11:15:53

     

     

     

    [ZFXXDB1:root]:/>lsvg -o

    T_XDESK_APP1_vg

    rootvg

    [ZFXXDB1:root]:/>

    00:27:22 SQL> alter tablespace idxtbs read write;

     

     

    ====》2097152*512/1024/1024/1024=1G 

     

     

     

     

     

    本文如有错误或不完善的地方请大家多多指正,ITPUB留言或QQ皆可,您的批评指正是我写作的最大动力。

     

     

     

    一.2.2  相关参考文章链接

     

    完整内容参考David Daibloghttp://blog.csdn.net/tianlesoftware/article/details/5006580#

     

     

    一.3  我的一个编译例子

     

     oracle@ZTGXPADDB1:/oracle$ ls -l  $ORACLE_HOME/rdbms/lib/*sbbd*

    -rw-r--r--    1 oracle   dba            1671 May 26 2010  /oracle/app/oracle/product/10.2.0/db/rdbms/lib/sbbdpt.o

    -rw-r--r--    1 oracle   dba             900 May 26 2010  /oracle/app/oracle/product/10.2.0/db/rdbms/lib/ssbbded.o

    oracle@ZTGXPADDB1:/oracle$ ls -l  $ORACLE_HOME/rdbms/mesg/bbed*

    -rw-r--r--    1 oracle   dba            8704 May 27 2010  /oracle/app/oracle/product/10.2.0/db/rdbms/mesg/bbedus.msb

    -rw-r--r--    1 oracle   dba           10270 Jul 25 2000  /oracle/app/oracle/product/10.2.0/db/rdbms/mesg/bbedus.msg

    oracle@ZTGXPADDB1:/oracle$

     

    oracle@ZTGXPADDB1:/oracle$ scp $ORACLE_HOME/rdbms/lib/*sbbd* oracle@22.188.194.64:/oracle/app/oracle/product/11.2.0/db/rdbms/lib/

    The authenticity of host '22.188.194.64 (22.188.194.64)' can't be established.

    RSA key fingerprint is 17:0d:6f:34:a8:0b:15:20:ca:ab:35:83:58:bb:aa:4f.

    Are you sure you want to continue connecting (yes/no)?yes

    Warning: Permanently added '22.188.194.64' (RSA) to the list of known hosts.

    ************************************************************

    *                                                          *

    *                                                          *

    *     ATTENTION:You have logged onto a secured server.     *

    *                                                          *

    *     All accesses logged!                                 *

    *                                                          *

    *                                                          *

    ************************************************************

    oracle@22.188.194.64's password:

    sbbdpt.o                                                                                                                             100% 1671     1.6KB/s   00:00   

    ssbbded.o                                                                                                                            100%  900     0.9KB/s   00:00   

    oracle@ZTGXPADDB1:/oracle$  scp $ORACLE_HOME/rdbms/mesg/bbed* oracle@22.188.194.64:/oracle/app/oracle/product/11.2.0/db/rdbms/mesg/

    ************************************************************

    *                                                          *

    *                                                          *

    *     ATTENTION:You have logged onto a secured server.     *

    *                                                          *

    *     All accesses logged!                                 *

    *                                                          *

    *                                                          *

    ************************************************************

    oracle@22.188.194.64's password:

    bbedus.msb                                                                                                                           100% 8704     8.5KB/s   00:00   

    bbedus.msg                                                                                                                           100%   10KB  10.0KB/s   00:00   

    oracle@ZTGXPADDB1:/oracle$

    [oracle@ZFFR4CB1101:/u01/app/oracle/product/11.2.0/dbhome_1/rdbms/lib]$ cd $ORACLE_HOME/rdbms/lib

    [oracle@ZFFR4CB1101:/u01/app/oracle/product/11.2.0/dbhome_1/rdbms/lib]$ make -f ins_rdbms.mk $ORACLE_HOME/rdbms/lib/bbed

     

    Linking BBED utility (bbed)

            rm -f /u01/app/oracle/product/11.2.0/dbhome_1/rdbms/lib/bbed

            ld -b64 -o /u01/app/oracle/product/11.2.0/dbhome_1/rdbms/lib/bbed -L/u01/app/oracle/product/11.2.0/dbhome_1/rdbms/lib/ -L/u01/app/oracle/product/11.2.0/dbhome_1/lib/ /u01/app/oracle/product/11.2.0/dbhome_1/lib/s0main.o /u01/app/oracle/product/11.2.0/dbhome_1/rdbms/lib/ssbbded.o /u01/app/oracle/product/11.2.0/dbhome_1/rdbms/lib/sbbdpt.o -bI:/usr/lib/aio.exp `cat /u01/app/oracle/product/11.2.0/dbhome_1/lib/ldflags`    -lncrypt11 -lnsgr11 -lnzjs11 -ln11 -lnl11   -ldbtools11  `cat /u01/app/oracle/product/11.2.0/dbhome_1/lib/ldflags`    -lncrypt11 -lnsgr11 -lnzjs11 -ln11 -lnl11 -lnro11 `cat /u01/app/oracle/product/11.2.0/dbhome_1/lib/ldflags`    -lncrypt11 -lnsgr11 -lnzjs11 -ln11 -lnl11 -lnnz11 -lzt11 -lztkg11 -lztkg11 -lclient11 -lnnetd11  -lvsn11  -lcommon11 -lgeneric11 -lmm -lsnls11 -lnls11  -lcore11 -lsnls11  -lnls11 -lcore11 -lsnls11 -lnls11 -lxml11  -lcore11 -lunls11 -lsnls11 -lnls11 -lcore11 -lnls11 `cat /u01/app/oracle/product/11.2.0/dbhome_1/lib/ldflags`    -lncrypt11 -lnsgr11 -lnzjs11 -ln11 -lnl11 -lnro11 `cat /u01/app/oracle/product/11.2.0/dbhome_1/lib/ldflags`    -lncrypt11 -lnsgr11 -lnzjs11 -ln11 -lnl11 -lclient11 -lnnetd11  -lvsn11  -lcommon11 -lgeneric11 -lpls11  -lrt  -lsnls11 -lnls11  -lcore11 -lsnls11  -lnls11 -lcore11 -lsnls11 -lnls11 -lxml11  -lcore11 -lunls11 -lsnls11 -lnls11 -lcore11 -lnls11  -lclient11 -lnnetd11  -lvsn11  -lcommon11 -lgeneric11 -lsnls11 -lnls11  -lcore11 -lsnls11  -lnls11 -lcore11 -lsnls11 -lnls11 -lxml11  -lcore11 -lunls11 -lsnls11 -lnls11 -lcore11 -lnls11  -lld -lm `cat /u01/app/oracle/product/11.2.0/dbhome_1/lib/sysliblist`  -lm   -lsql11  /u01/app/oracle/product/11.2.0/dbhome_1/lib/nautab.o /u01/app/oracle/product/11.2.0/dbhome_1/lib/naeet.o /u01/app/oracle/product/11.2.0/dbhome_1/lib/naect.o /u01/app/oracle/product/11.2.0/dbhome_1/lib/naedhs.o

    ld: 0711-224 WARNING: Duplicate symbol: .aio_nwait_timeout64

    ld: 0711-224 WARNING: Duplicate symbol: aio_nwait_timeout64

    ld: 0711-224 WARNING: Duplicate symbol: .aio_nwait64

    ld: 0711-224 WARNING: Duplicate symbol: aio_nwait64

    ld: 0711-345 Use the -bloadmap or -bnoquiet option to obtain more information.

    ld: 0711-773 WARNING: Object /u01/app/oracle/product/11.2.0/dbhome_1/lib//libgeneric11.a[sdbgrfu.o], imported symbol timezone

            Symbol was expected to be local. Extra instructions

            are being generated to reference the symbol.

    [oracle@ZFFR4CB1101:/u01/app/oracle/product/11.2.0/dbhome_1/rdbms/lib]$

    [oracle@ZFFR4CB1101:/u01/app/oracle/product/11.2.0/dbhome_1/rdbms/lib]$ bbed

    Password:

     

    BBED: Release 2.0.0.0.0 - Limited Production on Wed Mar 23 11:12:18 2016

     

    Copyright (c) 1982, 2011, Oracle and/or its affiliates.  All rights reserved.

     

    ************* !!! For Oracle Internal Use only !!! ***************

     

    BBED>

     

    一.4  我的命令

    ls -l  $ORACLE_HOME/rdbms/lib/*sbbd*

    ls -l  $ORACLE_HOME/rdbms/mesg/bbed*

    chown oracle:dba /u01/app/oracle/product/11.2.0/dbhome_1/rdbms/lib/*sbbd*

    chown oracle:dba /u01/app/oracle/product/11.2.0/dbhome_1/rdbms/mesg/bbed*

     

    --cd $ORACLE_HOME/rdbms/lib

    --make -f ins_rdbms.mk $ORACLE_HOME/rdbms/lib/bbed

     

    --make -f $ORACLE_HOME/rdbms/lib/ins_rdbms.mk $ORACLE_HOME/rdbms/lib/bbed

    make -f $ORACLE_HOME/rdbms/lib/ins_rdbms.mk BBED=$ORACLE_HOME/bin/bbed $ORACLE_HOME/bin/bbed

     

     

     

    一.5  总结

     

    11g以下可以直接编译使用,11g及以后需要从相应平台的10g中拷贝4个文件到11g相应目录,如下,bbedar.msb可以不用拷贝。然后执行编译命令即可,编译的bbed命令可以直接生成在$ORACLE_HOME/bin下,命令为:make -f $ORACLE_HOME/rdbms/lib/ins_rdbms.mk BBED=$ORACLE_HOME/bin/bbed $ORACLE_HOME/bin/bbed

     

    $ORACLE_HOME/rdbms/lib/ssbbded.o

    $ORACLE_HOME/rdbms/lib/sbbdpt.o

    $ORACLE_HOME/rdbms/mesg/bbedus.msb

    $ORACLE_HOME/rdbms/mesg/bbedus.msg

    $ORACLE_HOME/rdbms/mesg/bbedar.msb

     

     

    ------------------------以下是摘自网络内容---------------------------

    第二章  BBED 的安装和使用

           The name bbed is an acronym for Block Browser and Editor and it is shipped with thedatabase. It is intended for Oracle internal use only and the company neverpublishes any details about it. It is a very powerful tool but also extremelydangerous since it can change and/or corrupt data blocks of any Oracledatabase.

           Ifyou use this tool, you do so at your own risk. Any modifications made with thistool render the database unsupported by Oracle.

            BBED(Oracle Block Browerand EDitor Tool),用来直接查看和修改数据文件数据的一个工具,是Oracle一款内部工具,可以直接修改Oracle数据文件块的内容,在一些极端恢复场景下比较有用。该工具不受Oracle支持,所以默认是没有生成可执行文件的,在使用前需要重新连接。

         虽然bbed 可以在db open 状态来进行修改,但是建议在做任何修改操作之前先shutdown db。 这样避免checkpoint 进程重写bbed block 的修改。 也避免oracle bbed 修改完成之前读block 或者申明block corrupt

     

    二.1  BBED 安装

           Oracle8i BBEDwindows 平台下的$ORACLE_HOME/bin下可以找到,9i中似乎未随软件发布,故在windows没有这个工具,在linux上面有,需要编译。

    二.1.1  9i10g

    cd $ORACLE_HOME/rdbms/lib

    make -f ins_rdbms.mk $ORACLE_HOME/rdbms/lib/bbed

    wps855D.tmp 

    [oracle@redhat4 dul]$ cd $ORACLE_HOME/rdbms/lib

    [oracle@redhat4 lib]$ make -f ins_rdbms.mk $ORACLE_HOME/rdbms/lib/bbed

     

    Linking BBED utility (bbed)

    rm -f /u01/app/oracle/product/10.2.0/db_1/rdbms/lib/bbed

    gcc -o /u01/app/oracle/product/10.2.0/db_1/rdbms/lib/bbed -L/u01/app/oracle/product/10.2.0/db_1/rdbms/lib/ -L/u01/app/oracle/product/10.2.0/db_1/lib/ -L/u01/app/oracle/product/10.2.0/db_1/lib/stubs/  /u01/app/oracle/product/10.2.0/db_1/lib/s0main.o /u01/app/oracle/product/10.2.0/db_1/rdbms/lib/ssbbded.o /u01/app/oracle/product/10.2.0/db_1/rdbms/lib/sbbdpt.o `cat /u01/app/oracle/product/10.2.0/db_1/lib/ldflags`    -lnsslb10 -lncrypt10 -lnsgr10 -lnzjs10 -ln10 -lnnz10 -lnl10 /u01/app/oracle/product/10.2.0/db_1/rdbms/lib/defopt.o -ldbtools10 -lclntsh  `cat /u01/app/oracle/product/10.2.0/db_1/lib/ldflags`    -lnsslb10 -lncrypt10 -lnsgr10 -lnzjs10 -ln10 -lnnz10 -lnl10 -lnro10 `cat /u01/app/oracle/product/10.2.0/db_1/lib/ldflags`    -lnsslb10 -lncrypt10 -lnsgr10 -lnzjs10 -ln10 -lnnz10 -lnl10 -lclient10 -lnnetd10  -lvsn10 -lcommon10 -lgeneric10 -lmm -lsnls10 -lnls10  -lcore10 -lsnls10 -lnls10 -lcore10 -lsnls10 -lnls10 -lxml10 -lcore10 -lunls10 -lsnls10 -lnls10 -lcore10 -lnls10 `cat /u01/app/oracle/product/10.2.0/db_1/lib/ldflags`    -lnsslb10 -lncrypt10 -lnsgr10 -lnzjs10 -ln10 -lnnz10 -lnl10 -lnro10 `cat /u01/app/oracle/product/10.2.0/db_1/lib/ldflags`    -lnsslb10 -lncrypt10 -lnsgr10 -lnzjs10 -ln10 -lnnz10 -lnl10 -lclient10 -lnnetd10  -lvsn10 -lcommon10 -lgeneric10   -lsnls10 -lnls10  -lcore10 -lsnls10 -lnls10 -lcore10 -lsnls10 -lnls10 -lxml10 -lcore10 -lunls10 -lsnls10 -lnls10 -lcore10 -lnls10 -lclient10 -lnnetd10  -lvsn10 -lcommon10 -lgeneric10 -lsnls10 -lnls10  -lcore10 -lsnls10 -lnls10 -lcore10 -lsnls10 -lnls10 -lxml10 -lcore10 -lunls10 -lsnls10 -lnls10 -lcore10 -lnls10   `cat /u01/app/oracle/product/10.2.0/db_1/lib/sysliblist` -Wl,-rpath,/u01/app/oracle/product/10.2.0/db_1/lib -lm    `cat /u01/app/oracle/product/10.2.0/db_1/lib/sysliblist` -ldl -lm   -L/u01/app/oracle/product/10.2.0/db_1/lib

     

    然后把这个路径添加到环境变量,注意:aix下为 ~/.profile文件

    cd ~

    vi .bash_profile 

    export PATH=$ORACLE_HOME/bin:$PATH:$ORACLE_HOME/jdk/bin:$ORACLE_HOME/rdbms/lib

    wps855E.tmp 

    source ~/.bash_profile

    oracle@ZTGXPADDB1:/oracle$ .  ~/.profile

    oracle@ZTGXPADDB1:/oracle$ bbed

    Password:

     

    BBED: Release 2.0.0.0.0 - Limited Production on Fri Sep 30 10:42:45 2022

     

    Copyright (c) 1982, 2007, Oracle.  All rights reserved.

     

    ************* !!! For Oracle Internal Use only !!! ***************

     

    BBED>

           以上生成的bbed可执行文件在$ORACLE_HOME/rdbms/lib目录,可以复制到其他位置或者其他同Oracle版本的机器上运行。

    也可通过以下命令将bbed生成到$ORACLE_HOME/bin目录

    [oracle@db2 lib]$ make -f ins_rdbms.mk BBED=$ORACLE_HOME/bin/bbed $ORACLE_HOME/bin/bbed

     

    Linking BBED utility (bbed)

    rm -f /u01/app/oracle/product/10.2.0/db_1/bin/bbed

    gcc -o/u01/app/oracle/product/10.2.0/db_1/bin/bbed-L/u01/app/oracle/product/10.2.0/db_1/rdbms/lib/-L/u01/app/oracle/product/10.2.0/db_1/lib/-L/u01/app/oracle/product/10.2.0/db_1/lib/stubs/ -L/usr/lib -lirc  /u01/app/oracle/product/10.2.0/db_1/lib/s0main.o/u01/app/oracle/product/10.2.0/db_1/rdbms/lib/ssbbded.o/u01/app/oracle/product/10.2.0/db_1/rdbms/lib/sbbdpt.o `cat/u01/app/oracle/product/10.2.0/db_1/lib/ldflags`    -lnsslb10 -lncrypt10 -lnsgr10 -lnzjs10-ln10 -lnnz10 -lnl10 /u01/app/oracle/product/10.2.0/db_1/rdbms/lib/defopt.o-ldbtools10 -lclntsh  `cat/u01/app/oracle/product/10.2.0/db_1/lib/ldflags`    -lnsslb10 -lncrypt10 -lnsgr10 -lnzjs10-ln10 -lnnz10 -lnl10 -lnro10 `cat/u01/app/oracle/product/10.2.0/db_1/lib/ldflags`    -lnsslb10 -lncrypt10 -lnsgr10 -lnzjs10-ln10 -lnnz10 -lnl10 -lclient10 -lnnetd10 -lvsn10 -lcommon10 -lgeneric10 -lmm -lsnls10 -lnls10  -lcore10 -lsnls10 -lnls10 -lcore10 -lsnls10 -lnls10-lxml10 -lcore10 -lunls10 -lsnls10 -lnls10 -lcore10 -lnls10 `cat /u01/app/oracle/product/10.2.0/db_1/lib/ldflags`    -lnsslb10 -lncrypt10 -lnsgr10 -lnzjs10-ln10 -lnnz10 -lnl10 -lnro10 `cat/u01/app/oracle/product/10.2.0/db_1/lib/ldflags`    -lnsslb10 -lncrypt10 -lnsgr10 -lnzjs10-ln10 -lnnz10 -lnl10 -lclient10 -lnnetd10 -lvsn10 -lcommon10 -lgeneric10  -lsnls10 -lnls10  -lcore10-lsnls10 -lnls10 -lcore10 -lsnls10 -lnls10 -lxml10 -lcore10 -lunls10 -lsnls10-lnls10 -lcore10 -lnls10 -lclient10 -lnnetd10 -lvsn10 -lcommon10 -lgeneric10 -lsnls10 -lnls10  -lcore10 -lsnls10 -lnls10 -lcore10 -lsnls10-lnls10 -lxml10 -lcore10 -lunls10 -lsnls10 -lnls10 -lcore10 -lnls10   `cat/u01/app/oracle/product/10.2.0/db_1/lib/sysliblist`-Wl,-rpath,/u01/app/oracle/product/10.2.0/db_1/lib -lm    `cat/u01/app/oracle/product/10.2.0/db_1/lib/sysliblist` -ldl -lm   -L/u01/app/oracle/product/10.2.0/db_1/lib

     

    [oracle@db2 lib]$ ls -lrt bbed

    -rwxr-xr-x 1 oracle oinstall 536161 Aug 1118:30 bbed

    [oracle@db2 lib]$ cd $ORACLE_HOME/bin

    [oracle@db2 bin]$ ls -lrt bbed

    -rwxr-xr-x 1 oracle oinstall 536161 Aug 11 18:33bbed

     

    二.1.2  11g以上

    cd $ORACLE_HOME/rdbms/lib

    make -f ins_rdbms.mk $ORACLE_HOME/rdbms/lib/bbed

    wps856F.tmp 

    [oracle@rhel6_lhr ~]$ cd $ORACLE_HOME/rdbms/lib

    [oracle@rhel6_lhr lib]$ make -f ins_rdbms.mk $ORACLE_HOME/rdbms/lib/bbed

     

    Linking BBED utility (bbed)

    rm -f /u01/app/oracle/product/11.2.0/dbhome_1/rdbms/lib/bbed

    gcc -o /u01/app/oracle/product/11.2.0/dbhome_1/rdbms/lib/bbed -m64 -L/u01/app/oracle/product/11.2.0/dbhome_1/rdbms/lib/ -L/u01/app/oracle/product/11.2.0/dbhome_1/lib/ -L/u01/app/oracle/product/11.2.0/dbhome_1/lib/stubs/  /u01/app/oracle/product/11.2.0/dbhome_1/lib/s0main.o /u01/app/oracle/product/11.2.0/dbhome_1/rdbms/lib/ssbbded.o /u01/app/oracle/product/11.2.0/dbhome_1/rdbms/lib/sbbdpt.o `cat /u01/app/oracle/product/11.2.0/dbhome_1/lib/ldflags`    -lncrypt11 -lnsgr11 -lnzjs11 -ln11 -lnl11 -ldbtools11 -lclntsh  `cat /u01/app/oracle/product/11.2.0/dbhome_1/lib/ldflags`    -lncrypt11 -lnsgr11 -lnzjs11 -ln11 -lnl11 -lnro11 `cat /u01/app/oracle/product/11.2.0/dbhome_1/lib/ldflags`    -lncrypt11 -lnsgr11 -lnzjs11 -ln11 -lnl11 -lnnz11 -lzt11 -lztkg11 -lclient11 -lnnetd11  -lvsn11 -lcommon11 -lgeneric11 -lmm -lsnls11 -lnls11  -lcore11 -lsnls11 -lnls11 -lcore11 -lsnls11 -lnls11 -lxml11 -lcore11 -lunls11 -lsnls11 -lnls11 -lcore11 -lnls11 `cat /u01/app/oracle/product/11.2.0/dbhome_1/lib/ldflags`    -lncrypt11 -lnsgr11 -lnzjs11 -ln11 -lnl11 -lnro11 `cat /u01/app/oracle/product/11.2.0/dbhome_1/lib/ldflags`    -lncrypt11 -lnsgr11 -lnzjs11 -ln11 -lnl11 -lclient11 -lnnetd11  -lvsn11 -lcommon11 -lgeneric11   -lsnls11 -lnls11  -lcore11 -lsnls11 -lnls11 -lcore11 -lsnls11 -lnls11 -lxml11 -lcore11 -lunls11 -lsnls11 -lnls11 -lcore11 -lnls11 -lclient11 -lnnetd11  -lvsn11 -lcommon11 -lgeneric11 -lsnls11 -lnls11  -lcore11 -lsnls11 -lnls11 -lcore11 -lsnls11 -lnls11 -lxml11 -lcore11 -lunls11 -lsnls11 -lnls11 -lcore11 -lnls11   `cat /u01/app/oracle/product/11.2.0/dbhome_1/lib/sysliblist` -Wl,-rpath,/u01/app/oracle/product/11.2.0/dbhome_1/lib -lm    `cat /u01/app/oracle/product/11.2.0/dbhome_1/lib/sysliblist` -ldl -lm   -L/u01/app/oracle/product/11.2.0/dbhome_1/lib

    gcc: /u01/app/oracle/product/11.2.0/dbhome_1/rdbms/lib/ssbbded.o: No such file or directory

    gcc: /u01/app/oracle/product/11.2.0/dbhome_1/rdbms/lib/sbbdpt.o: No such file or directory

    make: *** [/u01/app/oracle/product/11.2.0/dbhome_1/rdbms/lib/bbed] Error 1

     

    AIX下:

    [ZFXDESKDB1:oracle]:/oracle>cd $ORACLE_HOME/rdbms/lib

    [ZFXDESKDB1:oracle]:/oracle/app/oracle/product/11.2.0/db/rdbms/lib>make -f ins_rdbms.mk $ORACLE_HOME/rdbms/lib/bbed

     

    Linking BBED utility (bbed)

            rm -f /oracle/app/oracle/product/11.2.0/db/rdbms/lib/bbed

            ld -b64 -o /oracle/app/oracle/product/11.2.0/db/rdbms/lib/bbed -L/oracle/app/oracle/product/11.2.0/db/rdbms/lib/ -L/oracle/app/oracle/product/11.2.0/db/lib/ /oracle/app/oracle/product/11.2.0/db/lib/s0main.o /oracle/app/oracle/product/11.2.0/db/rdbms/lib/ssbbded.o /oracle/app/oracle/product/11.2.0/db/rdbms/lib/sbbdpt.o -bI:/usr/lib/aio.exp `cat /oracle/app/oracle/product/11.2.0/db/lib/ldflags`    -lncrypt11 -lnsgr11 -lnzjs11 -ln11 -lnl11   -ldbtools11  `cat /oracle/app/oracle/product/11.2.0/db/lib/ldflags`    -lncrypt11 -lnsgr11 -lnzjs11 -ln11 -lnl11 -lnro11 `cat /oracle/app/oracle/product/11.2.0/db/lib/ldflags`    -lncrypt11 -lnsgr11 -lnzjs11 -ln11 -lnl11 -lnnz11 -lzt11 -lztkg11 -lztkg11 -lclient11 -lnnetd11  -lvsn11  -lcommon11 -lgeneric11 -lmm -lsnls11 -lnls11  -lcore11 -lsnls11  -lnls11 -lcore11 -lsnls11 -lnls11 -lxml11  -lcore11 -lunls11 -lsnls11 -lnls11 -lcore11 -lnls11 `cat /oracle/app/oracle/product/11.2.0/db/lib/ldflags`    -lncrypt11 -lnsgr11 -lnzjs11 -ln11 -lnl11 -lnro11 `cat /oracle/app/oracle/product/11.2.0/db/lib/ldflags`    -lncrypt11 -lnsgr11 -lnzjs11 -ln11 -lnl11 -lclient11 -lnnetd11  -lvsn11  -lcommon11 -lgeneric11 -lpls11  -lrt  -lsnls11 -lnls11  -lcore11 -lsnls11  -lnls11 -lcore11 -lsnls11 -lnls11 -lxml11  -lcore11 -lunls11 -lsnls11 -lnls11 -lcore11 -lnls11  -lclient11 -lnnetd11  -lvsn11  -lcommon11 -lgeneric11 -lsnls11 -lnls11  -lcore11 -lsnls11  -lnls11 -lcore11 -lsnls11 -lnls11 -lxml11  -lcore11 -lunls11 -lsnls11 -lnls11 -lcore11 -lnls11  -lld -lm `cat /oracle/app/oracle/product/11.2.0/db/lib/sysliblist`  -lm   -lsql11  /oracle/app/oracle/product/11.2.0/db/lib/nautab.o /oracle/app/oracle/product/11.2.0/db/lib/naeet.o /oracle/app/oracle/product/11.2.0/db/lib/naect.o /oracle/app/oracle/product/11.2.0/db/lib/naedhs.o

    ld: 0706-005 Cannot find or open file: /oracle/app/oracle/product/11.2.0/db/rdbms/lib/ssbbded.o

            ld:open(): A file or directory in the path name does not exist.

    ld: 0706-005 Cannot find or open file: /oracle/app/oracle/product/11.2.0/db/rdbms/lib/sbbdpt.o

            ld:open(): A file or directory in the path name does not exist.

    make: 1254-004 The error code from the last command is 255.

     

     

     

    Stop.

     

     

    需要10g面考:

    sz $ORACLE_HOME/rdbms/lib/ssbbded.o

    sz $ORACLE_HOME/rdbms/lib/sbbdpt.o

    sz $ORACLE_HOME/rdbms/mesg/bbedus.msb

    sz $ORACLE_HOME/rdbms/mesg/bbedus.msg

    sz $ORACLE_HOME/rdbms/mesg/bbedar.msb

    考出来

    wps8570.tmp 

    su – oracle

    export ORACLE_SID=PROD

    pwd

    wps8571.tmp 

    wps8572.tmp 

    administrator下载窗口一定要在/home/oracle路径下(不能在上面的窗口)。

    wps8573.tmp 

    wps8584.tmp 

    点击添加和确定。

    wps8585.tmp 

    wps8586.tmp 

    cp bbedus.msb $ORACLE_HOME/rdbms/mesg

    cp bbedus.msg $ORACLE_HOME/rdbms/mesg

    cp *.o $ORACLE_HOME/rdbms/lib

    再次执行:

    cd $ORACLE_HOME/rdbms/lib

    make -f ins_rdbms.mk $ORACLE_HOME/rdbms/lib/bbed

    wps8596.tmp 

    搞定

    cd /home/oracle

    vi .bash_profile

    export PATH=$ORACLE_HOME/bin:$PATH:$ORACLE_HOME/jdk/bin:/u01/app/oracle/product/11.2.0/db_1/rdbms/lib

    wps8597.tmp 

    source /home/oracle/.bash_profile

     

     

     

    二.3  使用BBED

           一般使用bbed,都是将一些配置信息写入到一个参数文本里,在调用bbed时,指定该参数文件。如:

           $bbed parfile=bbed.par

    bbed help=y

    wps8598.tmp 

     

    这里我们先演示一个示例。

    (1)先获取datafile 的信息

           datafile 的信息写入一个文件,格式为:文件编号  文件名字 文件大小。可以通过如下SQL   获取:

    set line 9999 pagesize 9999

    select file#||' '||name||' '||bytes from v$datafile;

    wps8599.tmp 

           注意,这里的file id。 我们这里的file id oracle 系统内部的file id 相同。 当然这个id 我们也可以自己指定。 当我们在bbed 里设置file id 时,就是根据这个参数文件中的的设置来的。 最好设置为相同,不然以后可能会混淆。

     

    将上面查询出来的datafile信息保存到文本里。

     cd /home/oracle

    vi file.txt

    1 /u01/app/oracle/oradata/PROD/disk3/system01.dbf 340787200

    2 /u01/app/oracle/oradata/PROD/disk4/sysaux01.dbf 340787200

    3 /u01/app/oracle/oradata/PROD/disk5/undotbs01.dbf 209715200

    4 /u01/app/oracle/oradata/PROD/disk3/users01.dbf 524288000

    5 /u01/app/oracle/oradata/PROD/disk3/cuug01.dbf 52428800

    wps85AA.tmp 

    vi bbed.par

    blocksize=8192

    listfile=/home/oracle/file.txt

    mode=edit

    wps85AB.tmp 

    source /home/oracle/.bash_profile

    bbed parfile=/home/oracle/bbed.par

    blockedit

    wps85AC.tmp 

    BBEDOracle 内部使用的命令,所以Oracle 不提供技术支持。 为了安全,BBED设置了口令保护,默认密码为blockedit

    show

    wps85BD.tmp 

    如果没有设置参数文件,显示:

    wps85BE.tmp 

     

    ------------------------以上是摘自网络内容---------------------------

     

    About Me

     

    ...........................................................................................................................................................................................

    本文作者:小麦苗,只专注于数据库的技术,更注重技术的运用

    ITPUB BLOG:http://blog.itpub.net/26736162

    本文地址:http://blog.itpub.net/26736162/viewspace-2075216/

    本文pdf版:http://yunpan.cn/cdEQedhCs2kFz (提取码:ed9b)

    QQ:642808185 若加QQ请注明所正在读的文章标题

    2016-04-04 10:00~ 2016-04-04 19:00 在唐镇完成

    <版权所有,文章允许转载,但须以链接方式注明源地址,否则追究法律责任!>

    ...........................................................................................................................................................................................

  • 相关阅读:
    死工资的缓慢呆板已不能适合这个新型的商业社会。
    java获取前一天时间SimpleDateFormat,java判断某个时间段
    设置 DNS,防止 DNS 污染,清除 DNS 缓存ipconfig /flushdns
    win7 怎么设置开机直接进入桌面? netplwiz 命令
    AWS免费云服务套餐申请步骤及常见问题
    阿里云自定义镜像可以免费保存,ECS实例到期后自定义镜像手动快照不会被删除
    php获取字符串长度函数strlen和mb_strlen
    PHP HTML混写,PHP中把大块HTML文本直接赋值给字符串变量的方法
    人工智能跟脑神经科学没有关系。没有出差错的机会,就没有进化的可能。要想自己把事情做成功,就需要弄清楚事物的本质。
    python GIL 全局锁,多核cpu下的多线程性能究竟如何?
  • 原文地址:https://www.cnblogs.com/lhrbest/p/5353443.html
Copyright © 2011-2022 走看看