重庆分公司,新征程启航
为企业提供网站建设、域名注册、服务器等服务
这篇文章主要介绍“修改了硬件时间后导致oracle无法正常启动怎么办”,在日常操作中,相信很多人在修改了硬件时间后导致oracle无法正常启动怎么办问题上存在疑惑,小编查阅了各式资料,整理出简单好用的操作方法,希望对大家解答”修改了硬件时间后导致oracle无法正常启动怎么办”的疑惑有所帮助!接下来,请跟着小编一起来学习吧!
我们提供的服务有:成都网站设计、成都网站建设、微信公众号开发、网站优化、网站认证、奉贤ssl等。为千余家企事业单位解决了网站和推广的问题。提供周到的售前咨询和贴心的售后服务,是有科学管理、有技术的奉贤网站制作公司[root@lzr1 ~]# hwclock --set --date="01/19/19 18:06" [root@lzr1 ~]# hwclock --hctosys
修改了下系统时间
然后重启机器
[root@lzr1 ~]# reboot [root@lzr1 ~]# Broadcast message from root@lzr1 (/dev/pts/0) at 18:06 ... The system is going down for reboot NOW!
重启后进入sqlplus
[oracle@lzr1 ~]$ sqlplus / as sysdba SQL*Plus: Release 11.2.0.4.0 Production on Sat Jan 19 18:08:04 2019 Copyright (c) 1982, 2013, Oracle. All rights reserved. Connected to an idle instance. SQL>
发现空实例,startup一下
SQL> startup ORA-01078: failure in processing system parameters ORA-01565: error in identifying file '+DATA01/orcl/spfileorcl.ora' ORA-17503: ksfdopn:2 Failed to open file +DATA01/orcl/spfileorcl.ora ORA-15056: additional error message ORA-17503: ksfdopn:2 Failed to open file +DATA01/orcl/spfileorcl.ora ORA-15001: diskgroup "DATA01" does not exist or is not mounted ORA-06512: at line 4
提示无法识别控制文件和参数文件
先用之前的参数文件启动到nomount状态
[oracle@lzr1 pfile]$ pwd /u01/app/oracle/admin/orcl/pfile [oracle@lzr1 pfile]$ ls init.ora.11142018235636
[oracle@lzr1 pfile]$ sqlplus / as sysdba SQL*Plus: Release 11.2.0.4.0 Production on Sat Jan 19 18:11:19 2019 Copyright (c) 1982, 2013, Oracle. All rights reserved. Connected to an idle instance. SQL> startup nomount pfile='/u01/app/oracle/admin/orcl/pfile/init.ora.11142018235636'; ORACLE instance started. Total System Global Area 1202556928 bytes Fixed Size 2252704 bytes Variable Size 822083680 bytes Database Buffers 369098752 bytes Redo Buffers 9121792 bytes SQL> create spfile from pfile; File created.
再去找一下控制文件cat init.ora.11142018235636
最下面一行是
control_files=("+DATA01/orcl/controlfile/current.260.996015513", "+FRA/orcl/controlfile/current.256.994895415")
进入磁盘中看一下控制文件
[grid@lzr1 ~]$ asmcmd ASMCMD> ls DATA/ DATA01/ FRA/ ASMCMD> cd +DATA01/orcl/controlfile
将DATA01和FRA两个控制文件的文件名修改到pfile参数文件中,保存,再启动数据库即可
注:
不要修改硬件时间,会导致开机时提示
Checking filesystems
/dev/mapper/VolGroup-lv_root: Superblock last mount time (Thu Jul 31 11:12:34 2014,
now = Mon Jul 28 11:15:32 2014) is in the future.
/dev/mapper/VolGroup-lv_root: UNEXPECTED INCONSISTENCY; RUN fsck MANUALLY.
(i .e., without -a or -p options)
[FAILED]
*** An error occurred during the file system check.
*** Dropping you to a shell; the system will reboot
*** when you leave the shell,
*** Warning -- SELinux is active
*** Disabling security enforcement for system recovery.
*** Run *setenforce 1* to reenable.
Give root password for maintenance
(or type Control-D to continue):
上次装载superblock时间和现在时间不一致,磁盘无法正常工作
解决办法:
1. 拿安装盘启动
2. 把日期调到较早的时候
3. 磁盘检查
4. 硬盘启动,把时间改正常
到此,关于“修改了硬件时间后导致oracle无法正常启动怎么办”的学习就结束了,希望能够解决大家的疑惑。理论与实践的搭配能更好的帮助大家学习,快去试试吧!若想继续学习更多相关知识,请继续关注创新互联-成都网站建设公司网站,小编会继续努力为大家带来更多实用的文章!