Oracle密碼文件 |
發(fā)布時(shí)間: 2012/9/13 16:50:21 |
創(chuàng)建Oracle密碼文件的命令 orapwd file=<> password=<> entries=最大數(shù)目 這里的file命名規(guī)則在unix/linux下orapw<Oracle_SID>,在windows下為 pwd<SID>.ora
Administrator's Reference 10g Release 2 (10.2) for UNIX-Based Operating Systems. 1. Log in as the Oracle software owner. (以O(shè)racle管理員身份登入) 2. Use the orapwd utility to create the password file as follows(使用orapwd功能創(chuàng)建密碼文件): $ $Oracle_HOME/bin/orapwd file=filename password=password entries=max_users filename The name of the file in which password information is written(filename指密碼信息保存文件的文件名) The name of the file must be orapwsid, and you must supply the full path name. Its contents are encrypted. Typically,the password file is created in the $Oracle_HOME/dbs directory.(文件名必須為orapwsid,并需要提供完整路徑,內(nèi)容是加密的,通常情況下,密碼文件被創(chuàng)建在$ORACLE_HOME/dbs路徑下。) 請(qǐng)注意,unix環(huán)境中,password file一定是要用 orapw<SID>,沒(méi)有例外。
Platform. Guide 10g Release 2 (10.2) for Microsoft Windows (32-Bit)
C:> orapwd FILE=pwdsid.ora PASSWORD=password ENTRIES=max_users where | FILE specifies the password filename. | SID identifies the database instance. | PASSWORD sets the password for account SYS. | ENTRIES sets maximum number of entries in password file. This corresponds to maximum number of distinct users allowed to connect to the database simultaneously with either the SYSDBA or the SYSOPER DBA privilege.
In search of the password file,Oracle Database looks in the registry for the value of parameter ORA_SID_PWFILE. If no value is specified, then it looks in the registry for the value of parameter ORA_PWFILE, which points to a file containing usernames, passwords, and privileges. If that is not set, then it uses the default: Oracle_BASEORACLE_HOMEDATABASEPWDsid.ORA. The default value is shared. 請(qǐng)注意,windows環(huán)境中,很大的部分是基于registry中變量ora_sid_pwfile 或者 ora_pwfile的設(shè)置, 缺省的值是 pwd<SID>.ora (unix中是沒(méi)有這個(gè).ora后綴的)。
1.這是因?yàn)镺racle采用了OS認(rèn)證的方式,具體的可以查看 sqlnet.ora具體同容如下 SQLNET.AUTHENTICATION_SERVICES=(NTS) 將其改成SQLNET.AUTHENTICATION_SERVICES=(NONE) 這樣就是Oracle認(rèn)證方式了 2.因?yàn)橛玫腛S認(rèn)證方式,可以在操作系統(tǒng)->控制面版->計(jì)算機(jī)管理->用戶將當(dāng)前用戶的屬性組 ORA_DBA去掉,這時(shí)如果沒(méi)有用戶名及密碼則不可以。 如下: SQL> connect /as sysdba ERROR:ORA-01031: insufficient privileges SQL> connect sys/Oracle as sysdba 已連接。
利用 orapwd重新創(chuàng)建一個(gè)就可以了。 本文出自:億恩科技【1tcdy.com】 服務(wù)器租用/服務(wù)器托管中國(guó)五強(qiáng)!虛擬主機(jī)域名注冊(cè)頂級(jí)提供商!15年品質(zhì)保障!--億恩科技[ENKJ.COM] |