在plsql developer中以scott/tiger登陆时提示ora-28000 the account is locked。sql
新装完Oracle10g后,用scott/tiger测试,会出现如下错误提示:
oracle10g the account is locked
oracle10g the password has expired
缘由:默认Oracle10g的scott不能登录数据库
第一种解决办法:oracle
第一步:使用PL/SQL,登陆名为system,数据库名称不变,选择类型的时候把Normal修改成Sysdba;
第二步:选择myobject,查看users;
第三步:选择scott用户,右击点击“编辑”;
第四步:修改密码,把“账户被锁住”的勾去掉;
第五步:点击“应用”再点击“关闭”;
第六步:从新登陆就能够经过验证了;ide
第二种解决方法:测试
直接以system用户登陆,ui
执行SQL:.net
ALTER USER scott ACCOUNT UNLOCK;orm
第三种方法:ip
(1)conn sys/sys as sysdba; //以DBA的身份登陆
(2)alter user scott account unlock;// 而后解锁
(3)conn scott/tiger //弹出一个修改密码的对话框,修改一下密码就能够了get
打开cmd在DOS模式下输入sqlplus,以system用户名登陆,密码是刚装oracle时本身填写的密码orcl,登陆进去之后。
SQL> conn sys/sys as sysdba; (分号是必须的可是我是以system登陆的所在这不该该写conn sys/sys as sysdba应该写conn system/orcl as sysdba;)
Connected.
SQL> alter user scott account unlock;
User altered.
SQL> commit;
Commit complete.
SQL> conn scott/tiger//请输入新密码,并确认后OK
Password changed
Connected.
这时再到plsql developer里面以scott/tiger登陆就能够了
再讲一下Oracle 10g 默认安装时三个常见的用户名/密码
Username Password Description See Also
SYS
CHANGE_ON_INSTALL
The account used to perform database administration tasks
Oracle Database Administrator's Guide
SYSMAN
CHANGE_ON_INSTALL
The account used to perform Oracle Enterprise Manager database administration tasks. Note that SYS and SYSTEM can also perform these tasks.
Oracle Enterprise Manager Grid Control Installation and Basic Configuration
SYSTEM MANAGER Another account used to perform database administration tasks