[20171109]数据库与asm实例的通讯问题.txt

简介: [20171109]数据库与asm实例的通讯问题.txt http://www.toadworld.com/platforms/oracle/b/weblog/archive/2017/11/07/solving-communication-problems-bet...
[20171109]数据库与asm实例的通讯问题.txt

http://www.toadworld.com/platforms/oracle/b/weblog/archive/2017/11/07/solving-communication-problems-between-db-and-asm-instances

--//摘要其中的段落:
--//建立新表空间报如下错误:

A long time ago I received a call from a customer saying that there were some errors in the database instance. Well,
interestingly the databases were executing DMLs properly without any issue. I asked the customer if these errors
appeared only with one specific operation like an Insert, or like a CREATE <something>, etc.; and he said that he was
running a script received from the application team to create several tablespaces with its datafiles.  When he was
running the script he was receiving the following errors:

ORA-01119: error in creating database file '+DATA'
ORA-17502: ksfdcre:4 Failed to create file +DATA
ORA-27300: OS system dependent operation:open failed with status: 2
ORA-27301: OS failure message: No such file or directory
ORA-27302: failure occurred at: sskgmsmr_7

--//有人意外删除 $ORACLE_HOME/dbs/ab_<ASM SID>.dat.注意是grid用户下dbs目录.
# locate ab_+ASM1.dat
/u01/app/11.2.0/grid/dbs/ab_+ASM1.dat


First, you can see that the set of errors says that there is a directory or file that don't exist in the OS on the other
hand, it points to the ASM disk group, which in this case is "+DATA". So this is confusing, because either the file that
the database is looking for is in ASM or it is in the OS.  I did a quick check of the database instance and it was OK.
There were no errors in the alert log, all the disks were healthy. On the database side, however, there seemed to be
some issues, specifically with the sentences "CREATE TABLESPACE" which the customer had in the script provided by the
application team.

So, the clues were:

    No issues with the ASM Instance
    DMLs were being executed successfully in the database instance.
    CREATE TABLESPACE statements fail in the database instance.
    ASM and OS are both involved in a "file" or "directory" that doesn't exist.

With these four clues to go by, you should be on the right track if your concepts are solid. The root cause you would be
thinking about would involve the file that the database instance uses to communicate with the ASM instance This file is
named "ab_<ASM SID>.dat" and it is located in the $ORACLE_HOME/dbs. You need to know about the existence of this file
and what its function is.This file rarely has issues, or rarely causes problems…but sometimes it happens,

Let's define this file:

What is the "ab_<ASM SID>.dat" file? This file is used by the database instance to message an ASM instance. When the
database instance needs to send a message to the ASM instance, the database instance reads this file in order to find
out the information required for getting connected to the ASM instance. This file is in $ORACLE_HOME/dbs. If this file
doesn't exist the database will not be able to connect to the ASM instance and you will receive an error. This file is
important because it is involved in the database instance work.

Some time ago I wrote an article with several tests of where this file is required to execute some sentences in the
database and in which sentences the file is not required. You can read the details here.

The conclusion of that earlier article indicates:

    Tablespace creation – required
    Datafile creation – required
    Table creation – not required
    DML operations – not required
    Drop tablespace – not required
    Delete datafile – not required
    Startup database instance – required
    Shutdown database instance – not required

Well, taking that into account, to solve this customer's issue, I listed all the files in $ORACLE_HOME/dbs and the root
cause was confirmed. The file "ab_<ASM SID>.dat" did not exist in the directory. I asked the customer if he had moved
the file somewhere else or if he'd deleted it and he said that the day before the junior DBA was "cleaning" logs and
traces that were using space and that could be deleted. I think that one of those files that "could be deleted" was
"ab_<ASM SID>.dat". As I said before, this situation happens rarely. Solving the problem is not a big deal; what we have
to do is reboot the ASM instance, but in order to do that we have to reboot the database instance as well.  After
rebooting the ASM instance the file was recreated and the database was able to use it. The script that the customer had
was executed successfully and all the CREATE TABLESPACE operations were success.

Conclusion

Sometimes there are issues whose root cause is very rare, and in order to determine it quickly we have to have all our
concepts solid; otherwise, we might spend several hours trying to figure out what's going on, reading notes and so on.

In this case, it was very important to identify the clues. We had four clues here which pointed us to the right root
cause.  Sometimes the customer is stressed and under pressure and wants us to fix the problem fast, but DBAs have to
stay calm, we have to extract the clues (syntomps), to think about the root cause,  to create an hypothesis and work to
prove it. To shorten diagnostic time make sure you're on solid ground conceptually, which you can do by practicing
various scenarios while you are getting prepared for a certification.

目录
相关文章
|
3月前
|
存储 监控 安全
数据库多实例的部署与配置方法
【10月更文挑战第23天】数据库多实例的部署和配置需要综合考虑多个因素,包括硬件资源、软件设置、性能优化、安全保障等。通过合理的部署和配置,可以充分发挥多实例的优势,提高数据库系统的运行效率和可靠性。在实际操作中,要不断总结经验,根据实际情况进行调整和优化,以适应不断变化的业务需求。
|
3月前
|
负载均衡 网络协议 数据库
选择适合自己的数据库多实例负载均衡技术
【10月更文挑战第23天】选择适合自己的数据库多实例负载均衡技术需要全面考虑多种因素。通过深入的分析和评估,结合自身的实际情况,能够做出明智的决策,为数据库系统的高效运行提供有力保障。
153 61
|
3月前
|
存储 负载均衡 监控
数据库多实例的深入解析
【10月更文挑战第24天】数据库多实例是一种重要的数据库架构方式,它为数据库的高效运行和灵活管理提供了多种优势。在实际应用中,需要根据具体的业务需求和技术环境,合理选择和配置多实例,以充分发挥其优势,提高数据库系统的性能和可靠性。随着技术的不断发展和进步,数据库多实例技术也将不断完善和创新,为数据库管理带来更多的可能性和便利。
161 57
|
3月前
|
缓存 负载均衡 监控
数据库多实例的负载均衡技术深入
【10月更文挑战第23天】数据库多实例负载均衡技术是确保数据库系统高效运行的重要手段。通过合理选择负载均衡策略、实时监控实例状态、不断优化调整,能够实现资源的最优分配和系统性能的提升。在实际应用中,需要根据具体情况灵活运用各种负载均衡技术,并结合其他相关技术,以满足不断变化的业务需求。
|
4月前
|
存储 Oracle 关系型数据库
数据库数据恢复—Oracle ASM磁盘组故障数据恢复案例
Oracle数据库数据恢复环境&故障: Oracle ASM磁盘组由4块磁盘组成。Oracle ASM磁盘组掉线 ,ASM实例不能mount。 Oracle数据库故障分析&恢复方案: 数据库数据恢复工程师对组成ASM磁盘组的磁盘进行分析。对ASM元数据进行分析发现ASM存储元数据损坏,导致磁盘组无法挂载。
|
3月前
|
关系型数据库 MySQL 数据库
【赵渝强老师】启动与关闭MySQL数据库实例
MySQL数据库安装完成后,可以通过命令脚本启动、查看状态、配置开机自启、查看自启列表及关闭数据库。本文提供了详细的操作步骤和示例代码,并附有视频讲解。
|
4月前
|
关系型数据库 MySQL Java
Django学习二:配置mysql,创建model实例,自动创建数据库表,对mysql数据库表已经创建好的进行直接操作和实验。
这篇文章是关于如何使用Django框架配置MySQL数据库,创建模型实例,并自动或手动创建数据库表,以及对这些表进行操作的详细教程。
166 0
Django学习二:配置mysql,创建model实例,自动创建数据库表,对mysql数据库表已经创建好的进行直接操作和实验。
|
4月前
|
SQL Shell 数据库
在TDengine容器中创建初始化数据库的Shell命令实例
以上就是在Docker容器环境中部署并初始化TDengine数据库的全过程,希望对你有所帮助。
150 0
|
6月前
|
SQL Java 关系型数据库
应用DriverManager类创建sqlserver数据库连接实例 JSP中使用数据库
该博客文章介绍了在JSP中使用JDBC连接SQL Server数据库的方法,包括加载数据库驱动、建立数据库连接的过程,并提供了一个使用DriverManager类创建数据库连接的Java示例代码。
|
7月前
|
存储 关系型数据库 分布式数据库
PolarDB产品使用问题之如何将数据库从一个PolarDB实例导入到另一个PolarDB实例
PolarDB产品使用合集涵盖了从创建与管理、数据管理、性能优化与诊断、安全与合规到生态与集成、运维与支持等全方位的功能和服务,旨在帮助企业轻松构建高可用、高性能且易于管理的数据库环境,满足不同业务场景的需求。用户可以通过阿里云控制台、API、SDK等方式便捷地使用这些功能,实现数据库的高效运维与持续优化。

热门文章

最新文章