153.The database instance has the following parameter setting:
OS_AUTHENT_PREFIX = OPS$
OS_ROLES = FALSE
REMOTE_OS_AUTHENT = FALSE
REMOTE_OS_ROLES = FALSE
TIMED_OS_STATISTICS = 0
You have a local operating system user SKD. You create a database user OPS$SKD, and then assign
external authentication. The user OPS$SKD has the CREATE SESSION privilege. What would you
achieve by the above process?
A.The database user OPS$SKD will be able to administer the database.
B.The authentication detail for the database user OPS$SKD is recorded in the password file.
C.The local operating system user SKD will be able to access the database instance without specifying the username and password.
D.The database user OPS$SKD has to login with the password of the local operating system user SKD to access the database instance.
答案:C
解析:参考34题
OS_AUTHENT_PREFIX:用户前缀,比如你的前缀是OPS$,你的系统账号为oracle,那么你的数据库账号就应该是OPS$ORACLE
OS_ROLES:对用户的角色是通过操作系统管理还是oracle自身管理
REMOTE_OS_AUTHENT:Oracle用户通过外部验证的方式登录数据库,默认只允许本机的用户采用外部验证登录到数据库中。
当设置为true时允许客户端采用外部验证的方式登录到数据库中
REMOTE_OS_ROLES:表示操作系统的角色是否对远程用户起作用,默认false
TIMED_OS_STATISTICS:指定当一个客户端进行请求或者一个请求完成后,oracle收集os系统的统计信息的时间间隔
这里其实主要考察的REMOTE_OS_AUTHENT和OS_AUTHENT_PREFIX
由于这里的REMOTE_OS_AUTHENT为false,所以其实是没有启动了,说明还是需要帐号密码的,我们进行测试
SQL> show parameter os --先看下配置
NAME TYPE VALUE
------------------------------------ ----------- ------------------------------
os_authent_prefix string ops$
os_roles boolean FALSE
remote_os_authent boolean TRUE --这里是true
remote_os_roles boolean FALSE
timed_os_statistics integer 0
[oracle@wahaha3 ~]$ echo $USER
oracle
[oracle@wahaha3 ~]$ sqlplus /@wahaha3 --这里模拟远程登陆
SQL> show user
USER is "OPS$ORACLE"
[oracle@wahaha3 ~]$ sqlplus / --本地登陆
SQL> show user
USER is "OPS$ORACLE"
--现在我们修改remote_os_authent为false,看看会是什么情况
SQL> alter system set remote_os_authent=false scope=spfile;
System altered.
SQL> startup force;
[oracle@wahaha3 ~]$ sqlplus /@wahaha3
SQL*Plus: Release 11.2.0.3.0 Production on Sat Jul 30 10:03:07 2016
Copyright (c) 1982, 2011, Oracle. All rights reserved.
ERROR:
ORA-01017: invalid username/password; logon denied
Enter user-name:
[oracle@wahaha3 ~]$ sqlplus / --本地登陆验证
SQL> show user
USER is "OPS$ORACLE" --登陆成功
说明只要配置了OS_AUTHENT_PREFIX,那么存在对应的数据库账户就不需要输入密码,但是远程访问不可以,
如果我们删除这个账户的话,应该就登陆不了了
SQL> drop user ops$oracle cascade;
[oracle@wahaha3 ~]$ sqlplus /
SQL*Plus: Release 11.2.0.3.0 Production on Sat Jul 30 10:43:16 2016
Copyright (c) 1982, 2011, Oracle. All rights reserved.
ERROR:
ORA-01017: invalid username/password; logon denied
Enter user-name:
因此如果是本地登陆的话,即使REMOTE_OS_AUTHENT=false也没有关系,所以C正确
OS_AUTHENT_PREFIX = OPS$
OS_ROLES = FALSE
REMOTE_OS_AUTHENT = FALSE
REMOTE_OS_ROLES = FALSE
TIMED_OS_STATISTICS = 0
You have a local operating system user SKD. You create a database user OPS$SKD, and then assign
external authentication. The user OPS$SKD has the CREATE SESSION privilege. What would you
achieve by the above process?
A.The database user OPS$SKD will be able to administer the database.
B.The authentication detail for the database user OPS$SKD is recorded in the password file.
C.The local operating system user SKD will be able to access the database instance without specifying the username and password.
D.The database user OPS$SKD has to login with the password of the local operating system user SKD to access the database instance.
答案:C
解析:参考34题
OS_AUTHENT_PREFIX:用户前缀,比如你的前缀是OPS$,你的系统账号为oracle,那么你的数据库账号就应该是OPS$ORACLE
OS_ROLES:对用户的角色是通过操作系统管理还是oracle自身管理
REMOTE_OS_AUTHENT:Oracle用户通过外部验证的方式登录数据库,默认只允许本机的用户采用外部验证登录到数据库中。
当设置为true时允许客户端采用外部验证的方式登录到数据库中
REMOTE_OS_ROLES:表示操作系统的角色是否对远程用户起作用,默认false
TIMED_OS_STATISTICS:指定当一个客户端进行请求或者一个请求完成后,oracle收集os系统的统计信息的时间间隔
这里其实主要考察的REMOTE_OS_AUTHENT和OS_AUTHENT_PREFIX
由于这里的REMOTE_OS_AUTHENT为false,所以其实是没有启动了,说明还是需要帐号密码的,我们进行测试
SQL> show parameter os --先看下配置
NAME TYPE VALUE
------------------------------------ ----------- ------------------------------
os_authent_prefix string ops$
os_roles boolean FALSE
remote_os_authent boolean TRUE --这里是true
remote_os_roles boolean FALSE
timed_os_statistics integer 0
[oracle@wahaha3 ~]$ echo $USER
oracle
[oracle@wahaha3 ~]$ sqlplus /@wahaha3 --这里模拟远程登陆
SQL> show user
USER is "OPS$ORACLE"
[oracle@wahaha3 ~]$ sqlplus / --本地登陆
SQL> show user
USER is "OPS$ORACLE"
--现在我们修改remote_os_authent为false,看看会是什么情况
SQL> alter system set remote_os_authent=false scope=spfile;
System altered.
SQL> startup force;
[oracle@wahaha3 ~]$ sqlplus /@wahaha3
SQL*Plus: Release 11.2.0.3.0 Production on Sat Jul 30 10:03:07 2016
Copyright (c) 1982, 2011, Oracle. All rights reserved.
ERROR:
ORA-01017: invalid username/password; logon denied
Enter user-name:
[oracle@wahaha3 ~]$ sqlplus / --本地登陆验证
SQL> show user
USER is "OPS$ORACLE" --登陆成功
说明只要配置了OS_AUTHENT_PREFIX,那么存在对应的数据库账户就不需要输入密码,但是远程访问不可以,
如果我们删除这个账户的话,应该就登陆不了了
SQL> drop user ops$oracle cascade;
[oracle@wahaha3 ~]$ sqlplus /
SQL*Plus: Release 11.2.0.3.0 Production on Sat Jul 30 10:43:16 2016
Copyright (c) 1982, 2011, Oracle. All rights reserved.
ERROR:
ORA-01017: invalid username/password; logon denied
Enter user-name:
因此如果是本地登陆的话,即使REMOTE_OS_AUTHENT=false也没有关系,所以C正确