zoukankan      html  css  js  c++  java
  • 表空间(系统表空间)不足的解决办法实例

    GPS平台、网站建设、软件开发、系统运维,找森大网络科技!
    https://cnsendnet.taobao.com
    来自森大科技官方博客
    http://www.cnsendblog.com/index.php/?p=1531

    2016年1月11日,我发现香港平台pl/sql登录不了,报如下错

    网上查了一下,是系统表空间不足,后来zhangnd给系统表空间加了一个文件解决了此问题

    Oracle表空间不足报ORA-00604、ORA-01653、ORA-02002错误

    在用sqlplus user/password@truth登录数据库时报如下错误:
    ORA-00604: error occurred at recursive SQL level 1
    ORA-01653: unable to extend table SYS.AUD$ by 8192 in tablespace SYSTEM
    ORA-02002: error while writing to audit trail
    ORA-00604: error occurred at recursive SQL level 1
    ORA-01653: unable to extend table SYS.AUD$ by 8192 in tablespace SYSTEM

    ORA-00604: error occurred at recursive SQL level 1的错误指的是内部的SQL语句执行失败
    ORA-01653: unable to extend table SYS.AUD$ by 8192 in tablespace SYSTEM 意思是表空间已满
    以sqlplus / as sysdba 登录数据库
    首先用下列SQL语句查看表空间的使用情况,查看各个用户使用的缺省表空间
    select   username,default_tablespace,temporary_tablespace   from   dba_users
    where   (default_tablespace='SYSTEM'   or   temporary_tablespace='SYSTEM')   and   username   not   in   ('SYSTEM','SYS');

    用上述语句,就是看看那些用户使用了system表空间,如下图所示

    用以下语句查询表空间占用的磁盘空间
    select tablespace_name,(bytes/1024/1024) M from dba_data_files;

    用以下语句可以查询表空间有哪些数据文件

    SELECT * FROM dba_data_files where tablespace_name='TS_GIS_PLAT';

    2种方法处理表空间已满。
    (1)更改system表空间的数据文件SYSTEM.dbf分配空间
    alter database datafile '/u04/oradata/truth/system01.dbf' resize 5524M;
    (2)为system表空间另外新增一个数据文件

    语法:

    alter tablespace 表空间名称

      add datafile 表空间存放路径  size 表空间大小 autoextend on next 增长的大小 maxsize 空间最大值(如果不限制空间最大值就用unlimited)

      例如:

        alter tablespace vgsm
        add datafile 'c:oracleproduct10.2.0oradatavgsmvgsm_01.dbf'
        size 1024M autoextend on next 50M maxsize unlimited;
    (3)把system表空间中的表移到非系统表空间
    检查下是否有其他非系统表放在系统表空间下,
    要是有的话,可以移到非系统表空间
    alter table move tablespace tablespace_name

    GPS平台、网站建设、软件开发、系统运维,找森大网络科技!
    https://cnsendnet.taobao.com
    来自森大科技官方博客
    http://www.cnsendblog.com/index.php/?p=1531

  • 相关阅读:
    详解objc_msgSend
    shell变量类型
    web ssh vnc备忘录
    内存对齐
    vim ctags
    vim csupport 代码 快捷键
    程序在内存中的地址映射
    nginx+php配置
    tmux 复制
    sqlite insert select 联合使用
  • 原文地址:https://www.cnblogs.com/cnsend/p/13893936.html
Copyright © 2011-2022 走看看