Oracle_11g_R2中解决scott用户被锁的方法
2014-07-01 08:57
477 查看
在安装完Oracle11g和创建完Oracle数据库之后,想用数据库自带的用户scott登录,看看能否连接成功。
![](http://s3.51cto.com/wyfs02/M00/37/F8/wKioL1OyCDDTQPj1AABmrCeedEA113.jpg)
![](http://s3.51cto.com/wyfs02/M02/37/F8/wKioL1OyCC-CGqxzAADCjnu4vL0422.jpg)
显示用户已更改,(cloudar为新的密码)
![](http://s3.51cto.com/wyfs02/M01/37/F9/wKiom1OyCF7DDS6QAAAfnaSr-H4706.jpg)
这样就OK了,测试一下scott/cloudar能否成功登录
SQL> conn scott/cloudar
显示已连接。
![](http://s3.51cto.com/wyfs02/M00/37/F9/wKiom1OyCF6RPa0gAAASCEwJm_o512.jpg)
sqlplus 用户名/密码
如:sqlplusscott/tiger;(tiger为系统默认的密码)
在SQLPlus 中输入conn可以连接数据库,其格式为:
SQL> conn 用户名/密码
如:connscott/tiger;
在SQLPlus修改普通用户密码,其格式为:
aler user 用户名 identified by 密码
如:alteruser scott identified by cloudar;
Oracle中给用户加锁与解锁的命令格式:
SQL> alter user 用户名 account lock;(加锁)
SQL> alter user 用户名 account unlock;(解锁)
本文出自 “范式鱼” 博客,请务必保留此出处http://ciiiso.blog.51cto.com/8779682/1432869
1.Scott用户被锁
在cmd命令中,用“sqlplus scott/ tiger”登录时,老是提示如下信息: ERROR:ORA-28000:账户已被锁定。![](http://s3.51cto.com/wyfs02/M00/37/F8/wKioL1OyCDDTQPj1AABmrCeedEA113.jpg)
2.解决方法
在cmd命令提示符中可直接登录oracle,输入如下命令:sqlplus / as sysdba;接着执行如下命令:SQL> alteruser scott account unlock; 显示用户已更改,这样就完成解锁的操作。![](http://s3.51cto.com/wyfs02/M02/37/F8/wKioL1OyCC-CGqxzAADCjnu4vL0422.jpg)
3.重置密码
还可以重新给scott这个用户设定密码。修改scott的登录密码SQL> alter user scottidentified by cloudar;显示用户已更改,(cloudar为新的密码)
![](http://s3.51cto.com/wyfs02/M01/37/F9/wKiom1OyCF7DDS6QAAAfnaSr-H4706.jpg)
这样就OK了,测试一下scott/cloudar能否成功登录
SQL> conn scott/cloudar
显示已连接。
![](http://s3.51cto.com/wyfs02/M00/37/F9/wKiom1OyCF6RPa0gAAASCEwJm_o512.jpg)
附:常用基础
在cmd命令中输入sqlplus可以连接数据库,其格式为:sqlplus 用户名/密码
如:sqlplusscott/tiger;(tiger为系统默认的密码)
在SQLPlus 中输入conn可以连接数据库,其格式为:
SQL> conn 用户名/密码
如:connscott/tiger;
在SQLPlus修改普通用户密码,其格式为:
aler user 用户名 identified by 密码
如:alteruser scott identified by cloudar;
Oracle中给用户加锁与解锁的命令格式:
SQL> alter user 用户名 account lock;(加锁)
SQL> alter user 用户名 account unlock;(解锁)
本文出自 “范式鱼” 博客,请务必保留此出处http://ciiiso.blog.51cto.com/8779682/1432869
相关文章推荐
- Oracle 11gR2中启动Scott用户的方法(推荐)
- Oracle 11gR2中启动Scott用户的方法
- Oracle_11g中解决被锁定的scott用户的方法(转载)
- Oracle_11g中解决被锁定的scott用户的方法
- oracle忘记sys/system/scott用户密码的解决方法
- Oracle 11G R2 用exp无法导出空表解决方法
- Oracle 11G R2 用exp无法导出空表解决方法
- Oracle 11g R2 用exp无法导出空表解决方法
- Centos 7安装oracle 11g R2问题及解决方法汇总
- Centos 7安装oracle 11g R2问题及解决方法汇总
- oracle忘记sys/system/scott用户密码的解决方法
- oracle 11g R2中exp不能导出空表的解决方法
- Oracle 11G R2 用exp无法导出空表解决方法
- [原]安装Oracle 11g R2 遇到的两个小问题及解决方法
- Oracle 11g R2 忘记用户密码的解决办法
- 安装Oracle 11g R2后,EM登陆界面显示乱码解决方法
- oracle 11g 没有scott用户下emp的创建方法
- Oracle 11g R2 忘记用户密码的解决办法
- Oracle 12c 数据库中scott用户不存在的解决方法
- Centos7 安装Oracle 11g R2完整手册及问题解决方法