Comparison between Oracle and SQL Server database images

Source: Internet
Author: User

  LieHuo. Net database integrationOracle and Microsoft are both major database manufacturers, and there are also a lot of enterprises adopting the two products. This article compares Oracle and SQLServer images.

Database images are used to move database transactions from one database to another in different environments. An image copy is a backup copy and cannot be accessed directly. It is used only when an error is restored. Oracle databases differ significantly from MSSQL data operations, but there is an analogy in image operations. This article describes how MSSQL database images are implemented in Oracle databases. What are the differences between them.

First, the image database in Microsoft SQL database is similar to the backup database in Oracle Database. I'm just talking about something similar. Specifically, we need to consider the differences between different databases in our system. MSSQL acts as an instance. An Instance contains several databases. You must first log on to an instance and then select the database to act on. In Oracle databases, the simple mode (ignoring RAC) only has one database associated with one instance. Therefore, in Oracle databases, the standby database is a snapshot of the primary database. In MSSQL, the image database is only the backup of the selected database, but does not include the proxy, login, task (these or more database projects need to be created or copied separately on the database image) these external data items.

In terms of the number of servers, the configuration of the Oracle master database and the backup database requires at least two. In MSSQL, the minimum data size is 2 or 3, depending on the high availability, high security, and high performance mode you choose.

High Availability mode: this operation mode allows you to synchronize transaction writes on two servers and supports automatic error recovery. To use this option, you must also use a witness server.

High protection mode: This option allows you to synchronize transaction writes on two servers, but error recovery is manual. Because automatic error recovery is not part of this option, it does not use the witness server.

High Performance Mode: This option does not care whether the write operations on the two servers are synchronized, so the performance is improved. When using this option, you can only assume that everything on the backup storage is successfully completed. This option only allows manual error recovery, so it does not use the witness server.

To ensure automatic fault recovery, you need a third server, which can be called an witness (the other two are the primary database and the Image Database). You can treat this witness as a member of the cluster. It provides a 2-to-1 voting capability. When one of my components cannot be reached, it requires error recovery. The witness server must be used only when you want to enable automatic error recovery.

In a transaction of Oracle data, the log buffer is refreshed or written to the redo log before the waste data is written to the data file (ignore write-ahead. This refresh or write to the redo log is necessary, such as when an event such as an instance failure (using the rollback and Rollback Recovery processes) occurs. MSSQL also acknowledges the importance of writing the log buffer to the disk. However, this is called hardening ). First, write the transaction log buffer information to the disk or harden, and then send the log record block to the image database. After the image database receives the log record block, it stores it in a buffer, and then harden the log block in sequence.

When data changes, how does the MSSQL database maintain consistency between the primary database and the backup database?

Oracle users are very familiar with SCN, while MSSQL users use the mongoing_failover_lsn mechanism (roughly speaking, it is a log serial number ). Unlike Oracle, MSSQL separates transactions (two transactions are on two machines), rather than a distributed transaction (you need to wait for the transaction to be committed remotely before committing itself ).

Another similarity, but slightly distorted reflection is the redo log and transaction log. In Oracle, the completed redo log is sent to a remote server and applied to the backup data. In MSSQL, transaction logs are not transmitted, but as I mentioned above, the log buffer data is sent to the network. This leads to another image reflection: backup and recovery modes.

  • 2 pages in total:
  • Previous Page
  • 1
  • 2
  • Next Page

Related Article

Contact Us

The content source of this page is from Internet, which doesn't represent Alibaba Cloud's opinion; products and services mentioned on that page don't have any relationship with Alibaba Cloud. If the content of the page makes you feel confusing, please write us an email, we will handle the problem within 5 days after receiving your email.

If you find any instances of plagiarism from the community, please send an email to: info-contact@alibabacloud.com and provide relevant evidence. A staff member will contact you within 5 working days.

A Free Trial That Lets You Build Big!

Start building with 50+ products and up to 12 months usage for Elastic Compute Service

  • Sales Support

    1 on 1 presale consultation

  • After-Sales Support

    24/7 Technical Support 6 Free Tickets per Quarter Faster Response

  • Alibaba Cloud offers highly flexible support services tailored to meet your exact needs.