最近,为地市技术人员做技术支持,碰到一个很奇怪的问题,别人给他提供一个exp的dmp文件,他在本地进行imp的时候报错:IMP-00037:Character set marker unknown
报错信息如下:
C:\Users\localadmin>imp test/oracle file=C:\Users\localadmin\Desktop\jzdjxx.dmp log=C:\Users\localadmin\Deskto
p\jzdjxx.log
Import: Release 11.2.0.1.0 - Production on 星期四 4月 27 11:34:16 2017
Copyright (c) 1982, 2009, Oracle and/or its affiliates. All rights reserved.
连接到: Oracle Database 11g Enterprise Edition Release 11.2.0.1.0 - 64bit Production
With the Partitioning, OLAP, Data Mining and Real Application Testing options
IMP-00037: 未知字符集标记
IMP-00000: 未成功终止导入
C:\Users\localadmin>
经测试,不是expdp导出的dmp文件,测试信息如下:
C:\Users\localadmin>impdp test/oracle directory=MYEXPDP dumpfile=jzdjxx.dmp logfile=jzdjxx.log
Import: Release 11.2.0.1.0 - Production on 星期四 4月 27 11:31:58 2017
Copyright (c) 1982, 2009, Oracle and/or its affiliates. All rights reserved.
连接到: Oracle Database 11g Enterprise Edition Release 11.2.0.1.0 - 64bit Production
With the Partitioning, OLAP, Data Mining and Real Application Testing options
ORA-39001: 参数值无效
ORA-39000: 转储文件说明错误
ORA-31619: 转储文件 "c:\jzdjxx.dmp" 无效
在linux操作系统上,查看该dmp文件的字符集,提示信息如下:
[root@docmaster ~]# cat jzdjxx.dmp |od -x|head -1|awk '{print $2 $3}'|cut -c 3-6
5353
正确的字符集标识应该是
0354
数据库中的字符集对照码验证:
SQL> select nls_charset_name(to_number('5353','xxxx')) from dual;
NLS_CHARSET_NAME(TO_NUMBER('5353','XXXX'
----------------------------------------
SQL> select nls_charset_name(to_number('0354','xxxx')) from dual;
NLS_CHARSET_NAME(TO_NUMBER('0354','XXXX'
----------------------------------------
ZHS16GBK
查询oracle官方metalink,提示exp的dmp文件损坏:
OERR: IMP 37 "Character set marker unknown" (文档 ID 21669.1)
报错信息如下:
C:\Users\localadmin>imp test/oracle file=C:\Users\localadmin\Desktop\jzdjxx.dmp log=C:\Users\localadmin\Deskto
p\jzdjxx.log
Import: Release 11.2.0.1.0 - Production on 星期四 4月 27 11:34:16 2017
Copyright (c) 1982, 2009, Oracle and/or its affiliates. All rights reserved.
连接到: Oracle Database 11g Enterprise Edition Release 11.2.0.1.0 - 64bit Production
With the Partitioning, OLAP, Data Mining and Real Application Testing options
IMP-00037: 未知字符集标记
IMP-00000: 未成功终止导入
C:\Users\localadmin>
经测试,不是expdp导出的dmp文件,测试信息如下:
C:\Users\localadmin>impdp test/oracle directory=MYEXPDP dumpfile=jzdjxx.dmp logfile=jzdjxx.log
Import: Release 11.2.0.1.0 - Production on 星期四 4月 27 11:31:58 2017
Copyright (c) 1982, 2009, Oracle and/or its affiliates. All rights reserved.
连接到: Oracle Database 11g Enterprise Edition Release 11.2.0.1.0 - 64bit Production
With the Partitioning, OLAP, Data Mining and Real Application Testing options
ORA-39001: 参数值无效
ORA-39000: 转储文件说明错误
ORA-31619: 转储文件 "c:\jzdjxx.dmp" 无效
在linux操作系统上,查看该dmp文件的字符集,提示信息如下:
[root@docmaster ~]# cat jzdjxx.dmp |od -x|head -1|awk '{print $2 $3}'|cut -c 3-6
5353
正确的字符集标识应该是
0354
数据库中的字符集对照码验证:
SQL> select nls_charset_name(to_number('5353','xxxx')) from dual;
NLS_CHARSET_NAME(TO_NUMBER('5353','XXXX'
----------------------------------------
SQL> select nls_charset_name(to_number('0354','xxxx')) from dual;
NLS_CHARSET_NAME(TO_NUMBER('0354','XXXX'
----------------------------------------
ZHS16GBK
查询oracle官方metalink,提示exp的dmp文件损坏:
OERR: IMP 37 "Character set marker unknown" (文档 ID 21669.1)
Error: IMP 37
Text: Character set marker unknown
-------------------------------------------------------------------------------
Cause: The export file is corrupted.
Action: Try to obtain an uncorrupted version of the export file.
If the export file is not corrupted, report this as an Import
internal error and submit the export file to customer support.
来自 “ ITPUB博客 ” ,链接:http://blog.itpub.net/29357786/viewspace-2138102/,如需转载,请注明出处,否则将追究法律责任。
转载于:http://blog.itpub.net/29357786/viewspace-2138102/