[oracle@liwei admin]$ sqlplus / as sysdba
SQL*Plus: Release 10.2.0.1.0 - Production on Thu May 1 15:55:18 2008
Copyright (c) 1982, 2005, Oracle. All rights reserved.
Connected to an idle instance.
SQL> quit
Disconnected
[oracle@liwei admin]$ sqlplus "/ as sysdba"
SQL*Plus: Release 10.2.0.1.0 - Production on Thu May 1 15:55:24 2008
Copyright (c) 1982, 2005, Oracle. All rights reserved.
Connected to an idle instance.
SQL> quit
Disconnected
二、Oracle登录认证方式
《Oracle管理与维护.手工创建数据库以及脚本》一文中提到如下一个错误:
[oracle@liwei oracle]$ sqlplus "/ as sysdba"
SQL*Plus: Release 10.2.0.1.0 - Production on Thu May 1 14:51:59 2008
Copyright (c) 1982, 2005, Oracle. All rights reserved.
ERROR:
ORA-01031: insufficient privileges
这个便是登录认证方式的问题了。
Oracle登录认证有两种方式:基于操作系统的登录认证和基于Oracle密码文件的登录认证。
具体方式记录在服务端$ORACLE_HOME/network/admin/sqlnet.ora文件中,不过Windows与
Unix/Linux具体设置是不同的。
(一)
sqlnet.ora文件为空时采用Oracle密码文件验证
SQLNET.AUTHENTICATION_SERVICES= (NTS) 基于操作系统验证;
SQLNET.AUTHENTICATION_SERVICES= (NONE) 基于Oracle密码文件验证
SQLNET.AUTHENTICATION_SERVICES= (NONE,NTS) 二者并存,注意是半角,否则不识别
sqlnet.ora示例一:
# This file is actually generated by netca. But if customers choose to
# install "Software Only", this file wont exist and without the native
# authentication, they will not be able to connect to the database on NT.
#SQLNET.AUTHENTICATION_SERVICES = (NTS)
C:\Documents and Settings\Administrator>sqlplus " / as sysdba"
SQL*Plus: Release 9.2.0.1.0 - Production on Mon May 5 17:54:32 2008
Copyright (c) 1982, 2002, Oracle Corporation. All rights reserved.
ERROR:
ORA-01031: insufficient privileges
sqlnet.ora示例二:
# This file is actually generated by netca. But if customers choose to
# install "Software Only", this file wont exist and without