orapwd 工具建立密码文件遵守的命名方法
上一篇 / 下一篇 2008-07-28 15:09:51 / 个人分类:数据库维护
orapwd 工具建立建立的密码文件 一定要orapw+实例名吗ITPUB个人空间%Wh7O)V7Pd
ITPUB个人空间 ?E-_Qt9SN3}n
我在11g和10g 测试是必须要 orapw+实例名 才能登录成功ITPUB个人空间,~f[\E1q
以下是验证过程
ITPUB个人空间2sK%md2\#r
[oracle@asm dbs]$ rm orapwasmITPUB个人空间YO,z/ro
[oracle@asm dbs]$ orapwd file=orapwdasm password=abcdefg entries=10
f \MM(w{ {.x0[oracle@asm dbs]$ sqlplus /nologITPUB个人空间 z4|+KR*ku*j*czp
ITPUB个人空间8L)dt3H
X^P
SQL*Plus: Release 10.2.0.1.0 - Production on Sat Jul 26 17:24:07 2008
EOCji$Mpo0
!Ju(h'T4x|'eZc)g+I0Copyright (c) 1982, 2005, Oracle. All rights reserved.
B+Z N7@
cwb'R)[0
,q4B:`Ed:M4EdQ5E0SQL> conn sys/abcdefg@asm as sysdba
5\X wnV&`D*ATF.R0ERROR:ITPUB个人空间X4V
x4[*Z2G
ORA-01031: insufficient privileges
ig\
M"u6|0ITPUB个人空间v._cIlXZwf8I5m
KO^.E9P%A&Y0SQL> exit
;M-A?"Y{Te0[oracle@asm dbs]$ lsITPUB个人空间+x!~G5NK&e9o
ab_+ASM.dat hc_+ASM.dat initdw.ora lkASM orapw+ASM spfile+ASM.oraITPUB个人空间)L9weC%npN
hc_asm.dat initasm.ora init.ora lk+ASM orapwdasm sqlnet.log
$X;n+j!ZI0[oracle@asm dbs]$ rm orapwdasmITPUB个人空间K`jKo8r|
[oracle@asm dbs]$ lsITPUB个人空间how6{$SF9xR
ab_+ASM.dat hc_+ASM.dat initdw.ora lkASM orapw+ASM sqlnet.log
EJj0AMuM0hc_asm.dat initasm.ora init.ora lk+ASM spfile+ASM.oraITPUB个人空间0k;V&K(@2Cv4I
tb5s0Z
[oracle@asm dbs]$ orapwd file=orapwasm password=abcdefg entries=10
*g0r Wv^5KHh!Q0[oracle@asm dbs]$ lsITPUB个人空间3d$P(_6IO A;FV,|d:p
ab_+ASM.dat hc_+ASM.dat initdw.ora lkASM orapwasm spfile+ASM.ora
c4U*hG#q0hc_asm.dat initasm.ora init.ora lk+ASM orapw+ASM sqlnet.log
^R;Eqx2PnKej0[oracle@asm dbs]$ sqlplus /nolog
Y!s |w~ x-N0ITPUB个人空间G;ZM;h;nA|R&|v3Q
SQL*Plus: Release 10.2.0.1.0 - Production on Sat Jul 26 17:25:03 2008
J9W$~/g,S%Ypis0ITPUB个人空间h$E
}Jd'lup
Copyright (c) 1982, 2005, Oracle. All rights reserved.ITPUB个人空间j3w+oteoo(~4?
mvE/b*G2Q&QZ[0SQL> conn sys/abcdefg@asm as sysdba ITPUB个人空间2NOFhF(C+nE9vL
m
Connected.
-kk!hr7oR.}0SQL>ITPUB个人空间uI!v;R s4Y7U
1. unix 环境:
.?~F*v@Bf0ITPUB个人空间&P:vb}C{C"q
查了Administrator’s Reference 10g Release 2 (10.2) for UNIX-Based Operating Systems.
6wI+GkR"Z0 ITPUB个人空间c+^[*}
[H8G.N3|ux
1. Log in as the Oracle software owner.ITPUB个人空间}I7|,Ym:s!nz
2. Use the orapwd utility to create the password file as follows:
!c-E[/N(jP0$ $ORACLE_HOME/bin/orapwd file=filename password=password entries=max_users
z;nP1eX F0...
I;q
m&I*G&?x0ITPUB个人空间)rN4S}6H Z
filename The name of the file in which password information is written
+O\:h{.k\s L0
W)G!O]"N-O)k0The name of the file must be orapwsid, and you must supply the fullITPUB个人空间*ut7xo`!o.A3p(rI
path name.Its contents are encrypted. Typically, the password file isITPUB个人空间3W7UG4x4o#}
created in the $ORACLE_HOME/dbs directory.
j [g,DPv1VG0
+\
O#|'L0sZ9c+sF0请注意黑体字, 所以unix环境中, password file 一定是要用 orapw<SID>, 没有例外.ITPUB个人空间3?4X,@5zNNX3vR#wU@
ITPUB个人空间n0I ?Y/[
2. windows 环境:
3dY
B1VbB0查了Platform. Guide 10g Release 2 (10.2) for Microsoft Windows (32-Bit)(没查64-bit)
)X/M$B-W(QIF0ITPUB个人空间 WL`
Z YL4J
To create and populate a password file:ITPUB个人空间 S8o ET?%MqwS7q
1. Create a password file with the Password Utility:ITPUB个人空间:VU-L6s7m'H9mzD
C:> orapwd FILE=PWDsid.ora PASSWORD=password ENTRIES=max_users
C(m*i|0ECiU0whereITPUB个人空间'U%bYTb5mP%[i
¦ FILE specifies the password filename.ITPUB个人空间c{@+_5ys
¦ SID identifies the database instance.
G'WB%j#_&jG%{+E
b0¦ PASSWORD sets the password for account SYS.ITPUB个人空间-V,vr'uvQ g dEM
¦ ENTRIES sets maximum number of entries in password file. This corresponds
|zH
^vJqS&K1kga/Q0to maximum number of distinct users allowed to connect to the database
;Ob(far0simultaneously with either the SYSDBA or the SYSOPER DBA privilege.ITPUB个人空间vjxk%C^Y2V
}O%n&P4J&f
K3O.e02. Set initialization parameter file parameter REMOTE_LOGIN_PASSWORDFILE toITPUB个人空间#kA%S M'M ~Y_
exclusive, shared, or none.
/?3kN7c3l(qg0
V4b/@w:r
@#?KG3M;B0In search of the password file, Oracle Databaselooks in the registryfor the value of parameter
u0G*I
r!snW#Y
Q0ORA_SID_PWFILE. If no value is specified, then it looks in the registry for the
0iv)n$J`)iy P0value of parameterORA_PWFILE, which points to a file containing usernames,ITPUB个人空间-xW1u+d"n$Y
passwords, and privileges. If that is not set, then it uses the default:
oD?1R)N6b9jj*[P0ORACLE_BASEORACLE_HOMEDATABASEPWDsid.ORA.
d;| um;A(~&?8@0The default value is shared.