大家可以发现,此时的口令文件中是不能添加用户的。
Connected to: Oracle9i Enterprise Edition Release 9.2.0.3.0 - Production With the Partitioning, OLAP and Oracle Data Mining options JServer Release 9.2.0.3.0 - Production
Database closed. Database dismounted. ORACLE instance shut down. SQL> ! [oracle@jumper dbs]$ ls hsjf initdw.ora inithsjf.ora init.ora lkHSJF orapwhsjf spfilehsjf.ora [oracle@jumper dbs]$ mv orapwhsjf orapwhsjf.bak [oracle@jumper dbs]$ exit exit
ORACLE instance started.
Fixed Size 451236 bytes Variable Size 201326592 bytes Database Buffers 33554432 bytes Redo Buffers 667648 bytes ORA-01990: error opening password file '/opt/oracle/product/9.2.0/dbs/orapw' --它是最后查找的文件 ORA-27037: unable to obtain file status Linux Error: 2: No such file or directory Additional information: 3 建立orapw口令文件,此时可以打开数据库。
[oracle@jumper dbs]$ ls hsjf initdw.ora inithsjf.ora init.ora lkHSJF orapwhsjf.bak spfilehsjf.ora [oracle@jumper dbs]$ cp orapwhsjf.bak orapw [oracle@jumper dbs]$ exit exit
------------------------------------ ----------- --------------- remote_login_passwordfile string SHARED SQL>
很多人可能会产生有这样的疑问,多个Exclusive的数据库是否可以共享一个口令文件(orapw)呢?
------------------------------------ ----------- --------------- remote_login_passwordfile string SHARED
[oracle@jumper dbs]$ strings orapw ]\[Z ORACLE Remote Password file INTERNAL AB27B53EDC5FEF41 8A8F025737A9097A
ORACLE instance started.
Fixed Size 451236 bytes Variable Size 201326592 bytes Database Buffers 33554432 bytes Redo Buffers 667648 bytes Database mounted. Database opened. SQL> !
[oracle@jumper dbs]$ strings orapw ]\[Z ORACLE Remote Password file HSJF INTERNAL AB27B53EDC5FEF41 8A8F025737A9097A [oracle@jumper dbs]$ exit exit
注意此处,以EXCLUSIVE方式启动以后,实例名称信息就会被写入口令文件.
SQL> select * from v$pwfile_users;USERNAME SYSDB SYSOP ------------------------------ ----- ----- SYS TRUE TRUE
------------------------------ ----- ----- SYS TRUE TRUE EYGLE TRUE FALSE
[oracle@jumper bin]$ cd $ORACLE_HOME/dbs [oracle@jumper dbs]$ strings orapw ]\[Z ORACLE Remote Password file HSJF INTERNAL AB27B53EDC5FEF41 8A8F025737A9097A >EYGLE B726E09FE21F8E83
在此处我们可以增加SYSDBA用户,并且这些信息可以被写入到口令文件。
file - name of password file (mand), password - password for SYS (mand), entries - maximum number of distinct DBA and OPERs (opt), There are no spaces around the equal-to (=) character. |