1.用Xshell远程连接安装数据库的服务器,切换到安装oracle数据库的用户下,(我的oracle数据库就安装在oracle用户下)
命令: su - oracle;
2.进入oracle控制台
命令: sqlplus /nolog; 以dba角色进入 命令: conn /as sysdba;
3.连接成功后,查看用户列表
命令: select username from dba_user;
4.若修改某一个用户密码,修改用户口令格式为: alter user username identified by newpassword;
例如修改用户demo的密码: 命令: alter user demo identified by demo123;
5.修改成功
以下为修改详细过程:
Xshell for Xmanager Enterprise 4 (Build 0182)Copyright (c) 2002-2011 NetSarang Computer, Inc. All rights reserved.Type `help' to learn how to use Xshell prompt.Xshell:\> Connecting to 192.168.1.24:22...Connection established.Escape character is '^@]'.Last login: Sun Oct 9 09:09:31 2016 from 172.16.5.212[root@kdyd01 ~]# SU - oracle-bash: SU: command not found[root@kdyd01 ~]# su - oracle[oracle@kdyd01 ~]$ sqlplus /nologSQL*Plus: Release 11.2.0.4.0 Production on Thu Oct 20 13:45:13 2016Copyright (c) 1982, 2013, Oracle. All rights reserved.SQL> conn /as sysdbaConnected.SQL> select username from dba_users;USERNAME------------------------------DSGTMRPLATFORMSDQNSYSSYSTEMBJUSERFLOWS_FILESMDSYSORDSYSEXFSYSUSERNAME------------------------------DBSNMPSCOTTWMSYSORACLE_OCMAPPQOSSYSXS$NULLAPEX_030200OWBSYS_AUDITMDDATAORDDATACTXSYSUSERNAME------------------------------ANONYMOUSOUTLNDIPAPEX_PUBLIC_USERSYSMANXDBSPATIAL_CSW_ADMIN_USRSPATIAL_WFS_ADMIN_USRORDPLUGINSOWBSYSMGMT_VIEWUSERNAME------------------------------SI_INFORMTN_SCHEMAOLAPSYS35 rows selected.SQL> alter user bjuser identified by BJUser;User altered.SQL> exit;Disconnected from Oracle Database 11g Enterprise Edition Release 11.2.0.4.0 - 64bit ProductionWith the Partitioning, OLAP, Data Mining and Real Application Testing options[oracle@kdyd01 ~]$ sqlplus bjuser/BJUserSQL*Plus: Release 11.2.0.4.0 Production on Thu Oct 20 14:02:44 2016Copyright (c) 1982, 2013, Oracle. All rights reserved.Connected to:Oracle Database 11g Enterprise Edition Release 11.2.0.4.0 - 64bit ProductionWith the Partitioning, OLAP, Data Mining and Real Application Testing optionsSQL>