Oracle 12C 中,想通过操作系统认证登录Oracle 数据库,有一些要注意的地方。不然就会遇到

ORA-01017:invalid username/password; logon denied

 

用户想要在操作系统登录数据库 有两种方法:通过tns ,一种修改用户名。

一、通过tns登录

  tns 的配置这里不做介绍。做Oracle 这一行,这是基本知识。

  

// 不通过tns登录会报错
SQL> conn scott/tiger
ERROR:
ORA-01017: invalid username/password; logon denied
// 通过tns 可以正常登录
SQL> conn scott/tiger@pdbboss
Connected.

 

二、调整用户名

  在Oracle 12C 中,想要在操作系统上直接进行操作系统认证登录数据库,用户名需要以" C##" 开头。示例如下:

  

SQL> create user c##test identified by test;

User created.

SQL> grant connect,resource to c##test;

Grant succeeded.

SQL> conn c##test/test;
Connected.

 

相关文章:

  • 2022-12-23
  • 2021-10-22
  • 2022-12-23
  • 2021-06-21
  • 2022-12-23
  • 2022-12-23
  • 2021-12-19
猜你喜欢
  • 2021-12-08
  • 2021-08-31
  • 2021-06-16
  • 2022-12-23
  • 2022-12-23
  • 2022-12-23
  • 2022-12-23
相关资源
相似解决方案