secrt怎么查询oracle数据库,查看entry和测试wallet

一、查看entry  1.#这里看到我们增加一个数据进来就会增加3个entries。

2.#分别是一个连接符,一个用户名,一个密码。

3.#当我们增加了很多数据库与用户进来后,数据库与用户还有密码他们是怎么关联的呢?其实他们就是通过后面的这个数字来关键的。

4.[oracle@test db_1]$ mkstore -wrl  /u01/app/oracle/product/11.2.0/db_1/wallet -list

5.Oracle Secret Store Tool : Version 11.2.0.2.0 - Production

6.Copyright (c) 2004, 2010, Oracle and/or its affiliates. All rights reserved.

7.

8.Enter wallet password:

9.

10.Oracle Secret Store entries:

11.oracle.security.client.connect_string1

12.oracle.security.client.password1

13.oracle.security.client.username1

二、增加数据库到wallet中去,并测试是否成功  1.3.1#增加net service为htz scott为用户 oracle为用户的密码。

2.#建议密码用''引起来,因为在生产环境中的密码基本上都是特殊字符的。

3.[oracle@test db_1]$ mkstore -wrl  /u01/app/oracle/product/11.2.0/db_1/wallet -createCredential htz scott 'oracle'

4.Oracle Secret Store Tool : Version 11.2.0.2.0 - Production

5.Copyright (c) 2004, 2010, Oracle and/or its affiliates. All rights reserved.

6.

7.Enter wallet password:

8.

9.Create credential oracle.security.client.connect_string1

10.3.2 #查看是否增加成功。

11.[oracle@test db_1]$ mkstore -wrl  /u01/app/oracle/product/11.2.0/db_1/wallet -listCredential

12.Oracle Secret Store Tool : Version 11.2.0.2.0 - Production

13.Copyright (c) 2004, 2010, Oracle and/or its affiliates. All rights reserved.

14.

15.Enter wallet password:

16.

17.List credential (index: connect_string username)

18.1: htz scott

19.3.3 测试是否可以实现无需要输入用户与密码登陆

20.[oracle@test db_1]$ sqlplus /@htz

21.

22.SQL*Plus: Release 11.2.0.2.0 Production on Sat Sep 8 09:19:15 2012

23.

24.Copyright (c) 1982, 2010, Oracle.  All rights reserved.

25.

26.

27.Connected to:

28.Oracle Database 11g Enterprise Edition Release 11.2.0.3.0 - 64bit Production

29.With the Partitioning, OLAP, Data Mining and Real Application Testing options

30.#显示的是scott,成功了。

31.SQL> show user;

32.USER is "SCOTT"

33.SQL> exit

34.Disconnected from Oracle Database 11g Enterprise Edition Release 11.2.0.3.0 - 64bit Production

35.With the Partitioning, OLAP, Data Mining and Real Application Testing options

三、创建默认用户与密码  这样可以实现,登陆所以的数据库都可以使用默认的用户与密码

1.6.1 #创建默认的用户。

2.[oracle@test db_1]$ mkstore -wrl  /u01/app/oracle/product/11.2.0/db_1/wallet -createEntry  oracle.security.client.default_username scott

3.Oracle Secret Store Tool : Version 11.2.0.2.0 - Production

4.Copyright (c) 2004, 2010, Oracle and/or its affiliates. All rights reserved.

5.

6.Enter wallet password:

7.6.2 #创建默认用户的密码。

8.[oracle@test db_1]$ mkstore -wrl  /u01/app/oracle/product/11.2.0/db_1/wallet -createEntry  oracle.security.client.default_password oracle

9.Oracle Secret Store Tool : Version 11.2.0.2.0 - Production

10.Copyright (c) 2004, 2010, Oracle and/or its affiliates. All rights reserved.

11.

12.Enter wallet password:

13.6.3 #查看是否创建成功

14.[oracle@test db_1]$ mkstore -wrl  /u01/app/oracle/product/11.2.0/db_1/wallet -list

15.Oracle Secret Store Tool : Version 11.2.0.2.0 - Production

16.Copyright (c) 2004, 2010, Oracle and/or its affiliates. All rights reserved.

17.

18.Enter wallet password:

19.

20.Oracle Secret Store entries:

21.oracle.security.client.connect_string1

22.oracle.security.client.default_password

23.oracle.security.client.default_username

24.oracle.security.client.password1

25.oracle.security.client.username1

评论
添加红包

请填写红包祝福语或标题

红包个数最小为10个

红包金额最低5元

当前余额3.43前往充值 >
需支付:10.00
成就一亿技术人!
领取后你会自动成为博主和红包主的粉丝 规则
hope_wisdom
发出的红包
实付
使用余额支付
点击重新获取
扫码支付
钱包余额 0

抵扣说明:

1.余额是钱包充值的虚拟货币,按照1:1的比例进行支付金额的抵扣。
2.余额无法直接购买下载,可以购买VIP、付费专栏及课程。

余额充值