oracle change password method

Modify the oracle user's password has the following methods:

general user

Mode (1) be modified by alter user syntax, which is the most common:
http://img.blog.itpub.net/blog/2019/06/06/72d7cc8a5eb5f0fe.png?x-oss-process=style/ BB
(2) the second way is to modify the password command:
http://img.blog.itpub.net/blog/2019/06/06/041fe0b0d8ae0c7c.png?x-oss-process=style/bb
from security point of view, we recommend to modify the user password via the second way, which prevents the clear text password leakage.

sys user

Also on the sys user password, do not use the password to modify and alter user mode, the following main reasons:

(1) When REMOTE_LOGIN_PASSWORDFILE parameter is set to shared, we use the alter user sys modify the password, it will be reported

ORA-28046: Password change for SYS disallowed error.

Tests are as follows:
http://img.blog.itpub.net/blog/2019/06/06/250ba0601abec7ab.png?x-oss-process=style/bb

(2) Most internal use recursive SQL SYS user. So, if you attempt to change this password using the ALTER USER statement when the database is open, it may lead to a deadlock.

Therefore, we need to use for the sys user orapwd be modified:

[Oracle @ orcl dbs] $ orapwd file = 'orapworcl' entries = 5 force = y Note here that equals approximately no spaces;

About orapwd description quoted the official website, as follows:

Argument Description
FILE Name to assign to the password file. You must supply a complete path. If you supply only a file name, the file is written to the current directory.
ENTRIES (Optional) Maximum number of entries (user accounts) to permit in the file.
FORCE (Optional) If y , permits overwriting an existing password file.
IGNORECASE (Optional) If y , passwords are treated as case-insensitive.

FILE
This argument sets the name of the password file being created. You must specify the full path name for the file. This argument is mandatory.

The file name required for the password file is operating system specific. Some operating systems require the password file to adhere to a specific format and be located in a specific directory. Other operating systems allow the use of environment variables to specify the name and location of the password file.

Table 1-1 lists the required name and location for the password file on the UNIX, Linux, and Windows platforms. For other platforms, consult your platform-specific documentation.

Table 1-1 Required Password File Name and Location on UNIX, Linux, and Windows

Platform Required Name Required Location)
UNIX and Linux

orapw ORACLE_SID

ORACLE_HOME /dbs

Windows

PWD ORACLE_SID .ora

ORACLE_HOME \database

郑州不孕不育医院×××:http://www.zzchyy110.com/zztjyy/
For example, for a database instance with the SID orcldw , the password file must be named orapworcldw on Linux and PWDorcldw.ora on Windows.

In an Oracle Real Application Clusters environment on a platform that requires an environment variable to be set to the path of the password file, the environment variable for each instance must point to the same password file.
郑州妇科医院:http://jbk.39.net/yiyuanzaixian/sysdfkyy/
Caution:
It is critically important to the security of your system that you protect your password file and the environment variables that identify the location of the password file. Any user with access to these could potentially compromise the security of the connection.
ENTRIES
This argument specifies the number of entries that you require the password file to accept. This number corresponds to the number of distinct users allowed to connect to the database as SYSDBA or SYSOPER . The actual number of allowable entries can be higher than the number of users, because the ORAPWD utility continues to assign password entries until an operating system block is filled. For example, if your operating system block size is 512 bytes, it holds four password entries. The number of password entries allocated is always a multiple of four.

Entries can be reused as users are added to and removed from the password file. If you intend to specify REMOTE_LOGIN_PASSWORDFILE=EXCLUSIVE , and to allow the granting of SYSDBA and SYSOPER privileges to users, this argument is required.

Caution:
When you exceed the allocated number of password entries, you must create a new password file. To avoid this necessity, allocate more entries than you think you will ever need.
FORCE
This argument, if set to Y , enables you to overwrite an existing password file. An error is returned if a password file of the same name already exists and this argument is omitted or set to N .

IGNORECASE
If this argument is set to y , passwords are case-insensitive. That is, case is ignored when comparing the password that the user supplies during login with the password in the password file.

Guess you like

Origin blog.51cto.com/14337216/2406428