微信公众号搜"智元新知"关注
微信扫一扫可直接关注哦!

在11g安装 XML DB 组件

昨晚做全库impdp导入时,发现有些表使用了xml的存放。导致导入的时候表都无法创建。

因dbca建库的只安装了jvm组件,所以需要安装XML DB组件。

安装步骤如下:

  1. Confirm XML DB is not already installed.
    • SELECT username FROM DBA_USERS where username = 'XDB'; returns 0 rows.
    • DESCRIBE RESOURCE_VIEW fails.
  2. As SYS,perform the XML DB installation - Note: this will not be a complete build due to Oracle Bug 9818995:
    • @?/rdbms/admin/catqm.sql xdb <xml db tablespace> <xdb temp tablespace> <use secure files yes|no>
  3. As SYS,grant the relevent permissions to the XDB user:
    • GRANT EXECUTE ON utl_file TO xdb;
    • GRANT EXECUTE ON dbms_lob TO xdb;
  4. As SYS,ensure their are no invalid objects:
    • @?/rdbms/admin/utlrp.sql
  5. Assuming an spfile is in use,as SYS configure the XDB dispatcher:
    • ALTER SYstem SET disPATCHERS="(PROTOCOL=TCP)(SERVICE=<SID>XDB)" ScopE=both;
    • If init.ora is in use,edit the init.ora file instead.
  6. As SYS,install the missing contents caused by Oracle Bug 9818995:
    • SHUTDOWN IMMEDIATE;
    • STARTUP UPGRADE
    • @?/rdbms/admin/xsdbmig.sql
    • SHUTDOWN IMMEDIATE;
    • STARTUP
  7. As SYS,ensure their are no invalid objects:
    • @?/rdbms/admin/utlrp.sql
  8. As SYS,confirm the XML DB is Now fully installed by running the following query and returning the following output:

   
   
SELECT 
   object_value
FROM 
   xdb.xs$securityclass
WHERE 
   EXTRACTVALUE(object_value,'/securityClass/@targetNamespace')='http://xmlns.oracle.com/plsql'
AND
   EXTRACTVALUE(object_value,'/securityClass/@name')='network'
/
 
OBJECT_VALUE
--------------------------------------------------------------------------------
<securityClass xmlns="http://xmlns.oracle.com/xs" xmlns:dav="DAV:" xmlns:plsql="

版权声明:本文内容由互联网用户自发贡献,该文观点与技术仅代表作者本人。本站仅提供信息存储空间服务,不拥有所有权,不承担相关法律责任。如发现本站有涉嫌侵权/违法违规的内容, 请发送邮件至 dio@foxmail.com 举报,一经查实,本站将立刻删除。

相关推荐


php输出xml格式字符串
J2ME Mobile 3D入门教程系列文章之一
XML轻松学习手册
XML入门的常见问题(一)
XML入门的常见问题(三)
XML轻松学习手册(2)XML概念
xml文件介绍及使用
xml编程(一)-xml语法
XML文件结构和基本语法
第2章 包装类