database Oracle 数据库的默认用户名和密码
声明:本页面是StackOverFlow热门问题的中英对照翻译,遵循CC BY-SA 4.0协议,如果您需要使用它,必须同样遵循CC BY-SA许可,注明原文地址和作者信息,同时你必须将它归于原作者(不是我):StackOverFlow
原文地址: http://stackoverflow.com/questions/25741027/
Warning: these are provided under cc-by-sa 4.0 license. You are free to use/share it, But you must attribute it to the original authors (not me):
StackOverFlow
Default username and password for Oracle database
提问by javabeginner
I forgot to feed sys, system and hr password while Oracle DB installation and hit OK but now for SQ*Plus it needs those credentials for login in command prompt.How to get default user name and password?
我忘记在 Oracle DB 安装时输入 sys、system 和 hr 密码并点击 OK 但现在对于 SQ*Plus 它需要这些凭据才能在命令提示符下登录。如何获取默认用户名和密码?
采纳答案by Lalit Kumar B
You can simply login as :
您可以简单地登录为:
sqlplus / as sysdba
Then give password to the respective users :
然后将密码提供给相应的用户:
ALTER USER <username> IDENTIFIED BY <password>;
You can do that for all the three users.
您可以为所有三个用户执行此操作。
I hope you are not on 12c. Else, you need to mention which CONTAINER are you working with. For example, if you are working on pluggable database, let's say PDBORCL, you need to do following steps :
我希望你不是在 12c。否则,您需要提及您正在使用哪个 CONTAINER。例如,如果您正在处理可插拔数据库,比如说 PDBORCL,您需要执行以下步骤:
connect / as sysdba;
alter session to set the container of which the respective users are a part of.
alter session set container=PDBORCL;
Then follow the same steps to change the passwords for the users.
connect / as sysdba;
更改会话以设置相应用户所属的容器。
alter session set container=PDBORCL;
然后按照相同的步骤更改用户的密码。
回答by Swapnil Boralkar
CHANGE_ON_INSTALL is default password for sys and system.
CHANGE_ON_INSTALL 是 sys 和 system 的默认密码。
You can directly login to database as sysdba from host machine and using installation user of oracle and execute below command to change system or sys password.
您可以直接从主机以sysdba身份登录数据库,并使用oracle的安装用户并执行以下命令来更改系统或sys密码。
sqlplus "/as sysdba"
sqlplus "/as sysdba"
alter user sys identified by passwd;
更改由 passwd 标识的用户 sys;
Alternatively you can create password file to from host server
或者,您可以从主机服务器创建密码文件
go to directory $ORACLE_HOME\database (windows) $ORACLE_HOME\dbs (unix\linux)
转到目录 $ORACLE_HOME\database (windows) $ORACLE_HOME\dbs (unix\linux)
and execute
并执行
orapwd password=password file=orapwSID force=y entries=5
orapwd 密码=密码文件=orapwSID force=y 条目=5
and login to database .
并登录到数据库。