conn username/password 方式连接的时候,会碰到这样的错误问题

oracle@prd:/home/oracle/impdir$sqlplus /nolog
SQL*Plus: Release 11.2.0.4.0 Production on Mon Mar 21 00:14:52 2022
Copyright (c) 1982, 2013, Oracle. All rights reserved.
SQL> conn myuser/abc123456
ERROR:
ORA-00942: table or view does not exist
Error accessing PRODUCT_USER_PROFILE
Warning: Product user profile information not loaded!
You may need to run PUPBLD.SQL as SYSTEM
//提示错误,这种提示有的话,你导入,导出也会发生错误。 impdp myuser/abc123456 ......... 
解决方法: 需要使用system用户登陆,并执行pupbld.sql脚本,不能用sysdba。
每个人安装目录不同,可能pupbld.sql位置不确定,你可以locate pupbld.sql 查找一下他的位置。
[oracle@prd:/home/oracle/impdir$sqlplus /nolog
SQL*Plus: Release 11.2.0.4.0 Production on Mon Mar 21 00:14:52 2022
Copyright (c) 1982, 2013, Oracle. All rights reserved.
SQL> conn system/abc123456
Connected.
SQL>@/u01/oracle/product/11.2.0/sqlplus/admin/pupbld.sql
.....
.....
//执行过程省略,执行完之后你再重新登录
oracle@prd:/home/oracle/impdir$sqlplus /nolog
SQL*Plus: Release 11.2.0.4.0 Production on Mon Mar 21 00:14:52 2022
Copyright (c) 1982, 2013, Oracle. All rights reserved.
SQL> conn myuser/abc123456
Connected. //就会ok

1、conn username/password@servicename   //连接某实例

oracle@prd:/home/oracle/impdir$sqlplus /nolog
SQL*Plus: Release 11.2.0.4.0 Production on Mon Mar 21 00:14:52 2022
Copyright (c) 1982, 2013, Oracle. All rights reserved.
SQL> conn sh3/ab123@fp
Connected.
//这里fp是servicename

SQL> conn sh3/abc123@fp3  //我故意把fp写错,注意fp就是在tnsnames.ora里面设置的
  ERROR:
  ORA-12154: TNS:could not resolve the connect identifier specified

Warning: You are no longer connected to ORACLE.

2、conn system/Shfpbi    //连接某账户

oracle@prd:/home/oracle/impdir$sqlplus /nolog
SQL*Plus: Release 11.2.0.4.0 Production on Mon Mar 21 00:14:52 2022
Copyright (c) 1982, 2013, Oracle. All rights reserved.
SQL> conn shfpfpmai/Shfpbi12@fpmai
Connected.
SQL> conn sh3/abc123@fpmai2
ERROR:
ORA-12154: TNS:could not resolve the connect identifier specified
Warning: You are no longer connected to ORACLE.

3、导入导出

 expdp sh3/abc123  dumpfile=SH3.dmp directory=EXPDIR logfile=sh3export.log
impdp sh3/abc123 dumpfile=SH3.dmp directory=IMPDIR logfile=sh3import.log

最新文章

  1. 宏定义#define的用法
  2. SQL Server中截取字符串常用函数
  3. 将公司的主要项目从eclipse迁移到android studio for mac环境(2)
  4. 关于Android Force Close 出现的原因 以及解决方法
  5. StatisticalOutlierRemoval源码
  6. oracle17 视图
  7. Apache Struts2存在S2-045
  8. 51Nod 1293 球与切换器 DP分类
  9. Express4.x API (四):Router (译)
  10. Oracle Inventory Management Application Program Interface ( APIs)
  11. Encryption and decryption、Steganography、Decryption Tools
  12. Centos7中一键安装zabbix
  13. 类型限定词——const
  14. RMQ st算法 区间最值模板
  15. gnuradio 初次使用
  16. FOJ有奖月赛-2016年8月(daxia专场之过四题方有奖)
  17. DS1-2
  18. Linux 实现与宿主机共享文件夹 Centos7
  19. 素数回文(hdu1431)
  20. UrlRewriter && IIS7

热门文章

  1. freeswitch tts_commandline模块介绍
  2. C#+SQL Server的数据库管理系统常用的代码
  3. 服务器中一个进程kill不掉,如何处理?
  4. OpenCv基础_四
  5. 阿里云镜像站DNS——Chrome配置方法
  6. ansible 二主机和组
  7. Mycat+MySql 主从复制-读写分离 看这一篇就够了
  8. Java9至17的新特性总结
  9. Redis数据库的初步认识(二)-C/C++连接redis数据库
  10. HashMap?ConcurrentHashMap?