【问题标题】:dump file oracle 11 docker转储文件 oracle 11 docker
【发布时间】:2021-04-17 10:52:40
【问题描述】:

我使用了 docker oracle 数据库Oracle Database 11g Express Edition Release 11.2.0.2.0 我尝试导入文件 dmp,但出现以下错误

docker-compose.yml

version: '3'

services:

  oracle:
    image: jaspeen/oracle-xe-11g
    container_name: oracle11g
    volumes:
      - ~/docker/data:/u01/app/oracle jaspeen/oracle-xe-11g
    ports:
      - "1529:1521"
      - "8081:8080"
      - "2222:22"

命令

docker exec -it oracle11g sqlplus
Enter user-name: SYS as SYSDBA
Enter password: oracle

SQL> CREATE TABLESPACE DEV_SPACE DATAFILE 'dev_space.dat' SIZE 500M AUTOEXTEND ON NEXT 10M;
SQL> DEFINE NEW_USER = 'scoemploi';
SQL> CREATE USER &NEW_USER. IDENTIFIED BY "1234";
SQL> GRANT CONNECT, RESOURCE, CREATE JOB, CREATE VIEW, CREATE ANY CONTEXT TO &NEW_USER;
SQL> ALTER USER &NEW_USER QUOTA UNLIMITED ON USERS;
SQL> ALTER USER &NEW_USER DEFAULT TABLESPACE DEV_SPACE;


SQL> CREATE OR REPLACE DIRECTORY docker_vol AS '/u01/app/oracle';
SQL> GRANT READ, WRITE ON DIRECTORY docker_vol TO scoemploi;

sudo docker exec -it oracle11g impdp scoemploi/1234 DUMPFILE=docker_vol:scoemploi2020.DMP FULL=Y


ORA-39001: invalid argument value
ORA-39000: bad dump file specification
ORA-31640: unable to open dump file "/u01/app/oracle/scoemploi2020.DMP" for read
ORA-27037: unable to obtain file status
Linux-x86_64 Error: 2: No such file or directory
Additional information: 3

【问题讨论】:

    标签: oracle impdp


    【解决方案1】:

    您需要在 docker 中安装 scoemploi2020.DMP

    docker cp /hostpath/scoemploi2020.DMP demo1:/u01/app/oracle

    docker exec -it demo1 chmod +rxw /u01/app/oracle/scoemploi2020.DMP

    【讨论】:

    • 错误更改为“ORA-39143:转储文件“/u01/app/oracle/scoemploi2020.DMP”可能是原始导出转储文件”
    • - 那是源数据库的版本?
    • - 你确定它是由 datapump 、 exppd 生成的转储吗?也许这是一个遗留转储?
    • 坦率地说我不知道​​ :( 我能做什么?
    • 字符串 scoemploi2020.DMP 的结果是什么 |头 -3
    猜你喜欢
    • 2018-04-23
    • 1970-01-01
    • 1970-01-01
    • 1970-01-01
    • 1970-01-01
    • 1970-01-01
    • 2020-11-25
    • 2014-03-19
    • 1970-01-01
    相关资源
    最近更新 更多