修改 oracle 数据库的 sys 账号密码,alter user sys identified by Aa123456@#_# * ERROR at line 1: ORA-01034: ORACLE not available Process ID: 0 Session ID: 0 Serial number: 0

 

挺久没有登录的 oracle 数据库,因为公司要求加固密码,登录后修改失败

  修改 oracle 数据库的 sys 账号密码,alter user sys identified by Aa123456@#_# * ERROR at line 1: ORA-01034: ORACLE not available Process ID: 0 Session ID: 0 Serial number: 0

 

1、启动数据库的同时启动控制文件、数据文件,提示:cannot mount database in EXCLUSIVE mode

2、启动数据库的同时启动控制文件、不启动数据文件,提示:database not mounted

3、关闭数据库

  修改 oracle 数据库的 sys 账号密码,alter user sys identified by Aa123456@#_# * ERROR at line 1: ORA-01034: ORACLE not available Process ID: 0 Session ID: 0 Serial number: 0

 

4、去到安装目录下的~/dbs 目录找到 lk+数据库实例的文件。我的数据库实例是ORCL

  修改 oracle 数据库的 sys 账号密码,alter user sys identified by Aa123456@#_# * ERROR at line 1: ORA-01034: ORACLE not available Process ID: 0 Session ID: 0 Serial number: 0

 

5、查看该文件:fuser -u lkORCL

  修改 oracle 数据库的 sys 账号密码,alter user sys identified by Aa123456@#_# * ERROR at line 1: ORA-01034: ORACLE not available Process ID: 0 Session ID: 0 Serial number: 0

 

 6、kill 掉lkORCL中的内容: fuser -k + lkORCL

  修改 oracle 数据库的 sys 账号密码,alter user sys identified by Aa123456@#_# * ERROR at line 1: ORA-01034: ORACLE not available Process ID: 0 Session ID: 0 Serial number: 0

 

 7、重启数据库

   修改 oracle 数据库的 sys 账号密码,alter user sys identified by Aa123456@#_# * ERROR at line 1: ORA-01034: ORACLE not available Process ID: 0 Session ID: 0 Serial number: 0

 

 

 

8、修改 sys 密码:alter user sys identified by 密码;

   修改 oracle 数据库的 sys 账号密码,alter user sys identified by Aa123456@#_# * ERROR at line 1: ORA-01034: ORACLE not available Process ID: 0 Session ID: 0 Serial number: 0

 

  修改成功!

 

修改 oracle 数据库的 sys 账号密码,alter user sys identified by Aa123456@#_# * ERROR at line 1: ORA-01034: ORACLE not available Process ID: 0 Session ID: 0 Serial number: 0

上一篇:mysql 分列或取子串


下一篇:P6087 [JSOI2015]送礼物 [单调队列+01分数规划]