[英]cant connect to oracle - ora-01017
i installed Oracle 11.2.0 64bit & Oracle SQL developer 2.1.1.64 on Windows-7 64bit 我在Windows-7 64位上安装了Oracle 11.2.0 64位和Oracle SQL Developer 2.1.1.64
i try to connect to database like this: 我尝试像这样连接到数据库:
username: scott
password: tiger
role : sysdba
hostname: localhost
port : 1521
sid : ORCL
and i got this error: ora-01017 invalid username/password; logon denied
我收到此错误:
ora-01017 invalid username/password; logon denied
ora-01017 invalid username/password; logon denied
what can be the problem ? 可能是什么问题? what to check ?
要检查什么?
thanks in advance 提前致谢
11g允许使用区分大小写的密码,因此首先检查密码TIGER(可能是Tiger)
since the database is on your local machine, easiest is to connect to it using os authentication and reset the password to a known value and then use that to connect using the tool you want. 由于数据库位于您的本地计算机上,所以最简单的方法是使用os身份验证连接到该数据库并将密码重置为一个已知值,然后使用该数据库通过所需的工具进行连接。 On windows you can do this in the *nix style.
在Windows上,您可以使用* nix样式执行此操作。 First find where your oracle rdbms installation is located and assign that value to the ORACLE_HOME environment variable.
首先找到oracle rdbms安装的位置,然后将该值分配给ORACLE_HOME环境变量。 Use the commandline tool.
使用命令行工具。
ORACLE_HOME=d:\somwehere\on\your\disk
PATH=%ORACLE_HOME%\bin
ORACLE_SID=ORCL
sqlplus "/ as sysdba"
alter user scott identified by koffie;
(make sure you remember the password this time, including case as since 11g passwords are case sensitive.) sqlplus should be in %ORACLE_HOME%\\bin. (确保这次记住密码,包括大小写,因为11g密码区分大小写。)sqlplus应该位于%ORACLE_HOME%\\ bin中。 Check this before.
之前检查一下。
I hope this helps. 我希望这有帮助。
Is the account unlocked? 帐户是否已解锁? As a privileged (SYS account) try running:
作为特权用户(SYS帐户),尝试运行:
SELECT USERNAME, ACCOUNT_STATUS
FROM DBA_USERS
WHERE USERNAME = 'SCOTT';
If the account is locked, try: 如果该帐户已锁定,请尝试:
ALTER USER SCOTT ACCOUNT UNLOCK;
Also it appears you are trying to connect to the database as SYSDBA using the SCOTT account. 同样,您似乎正在尝试使用SCOTT帐户以SYSDBA身份连接到数据库。 I believe by default this schema lacks the necessary account privileges.
我认为默认情况下,该架构缺少必要的帐户特权。 Try logging in as SCOTT/TIGER connecting as "normal", not "sysdba".
尝试以SCOTT / TIGER的身份以“普通”而非“ sysdba”的身份登录。
-CJ -CJ
Use: orapwd file=$ORACLE_HOME/dbs/orapw$ORACLE_SID password=Euro2016 entries=5 grant sysdba to scott; 使用:orapwd文件= $ ORACLE_HOME / dbs / orapw $ ORACLE_SID密码= Euro2016条目= 5将sysdba授予scott;
Now you can connect... 现在您可以连接...
声明:本站的技术帖子网页,遵循CC BY-SA 4.0协议,如果您需要转载,请注明本站网址或者原文地址。任何问题请咨询:yoyou2525@163.com.