ORA-19502: write error on file "xxxxx", block number xxxx
在ORACLE 11g下执行下述命令
1、创建数据文件
CREATE TABLESPACE OAPF_ITRAVEL_DATA LOGGING DATAFILE '/data/oracle/oradata/tablespace/oapf_itravel_data.dbf'
SIZE 500M AUTOEXTEND ON NEXT 10240K MAXSIZE UNLIMITED
Extent Management Local Segment Space Management Auto;
错误提示:
ERROR at line 1:
ORA-19502: write error on file
"/data/oracle/oradata/tablespace/oapf_itravel_data.dbf", block number 7808
(block size=8192)
ORA-27072: File I/O error
Additional information: 4
Additional information: 7808
Additional information: 532480
错误原因:
从报错信息来看应该是写文件时遇到I/O错误,一般是磁盘空间不足导致。用df命令查看磁盘空间
联系DBA,检查下数据库是否开启归档,检查归档的文件
归档路径:/data/oracle/oraarch,定期清理归档文件
常用查询语句
--阻塞会话
select /*+ rule */ * from v$session a where sid in(select distinct sid from v$lock b where block=1);
--被阻塞会话
select * from v$session where blocking_session is not null;