Hbase VS Oracle

Source: Internet
Author: User
Tags columnar database

Hbase VS Oracle

1. Hbase is suitable for a large number of inserts and reads at the same time. Enter a Key to get a value or enter some key to get some value.

2. the bottleneck of Hbase is the hard disk transmission speed. Hbase operations, which can insert or update some data into the data, but update is actually insert, just insert a row of A New timestamp. Delete data is also insert, but only insert a row with the delete mark. All Hbase operations are append insert operations. Hbase is a log set database. It is stored in the same way as a log file. It is a mass write to the hard disk, usually in the form of files. The read/write speed depends on the speed of transmission between the hard disk and the machine.

The bottleneck of Oracle is the hard disk seeking time. It often reads and writes data randomly. To update a piece of data, you must first find the block in the hard disk, then read it into the memory, modify it in the cache in the memory, and write it back later. Because the block you are looking for is different, there is a random read. The hard drive tracing time is mainly determined by the speed. However, the tracing time and technology have not changed, which forms a tracing time bottleneck.

3. Hbase data can be stored in many versions with different timestamps (that is, the same data can be copied to many different versions, allowing data redundancy is also an advantage ). Data is sorted by time, so Hbase is particularly suitable for scenarios where Top n is searched by time. Find out the messages that a person recently browsed, N recently written blogs, N kinds of behaviors, and so on. Therefore, there are a lot of Hbase applications on the Internet.

4. Limitations of Hbase. You can only perform simple Key-value queries. It is suitable for operation scenarios with high-speed inserts and a large number of reads. This scenario is extremely challenging, and not every company has this need. In some companies, it is common OLTP (online transaction processing) random read/write. In this case, Oracle is more responsible for the reliability of the system than Hbase. In addition, Hbase only has primary key indexes, so it encountered problems during modeling. For example, in a table, I want to query many columns with certain conditions. However, you can only create a quick query on the primary key. Therefore, we cannot say in general that technology has advantages.

5. Oracle is a row-based database, while Hbase is a column-based database. The advantage of a column-based database is data analysis. The difference between data analysis and traditional OLTP. Data analysis usually uses a column as the query condition, and the returned results are usually some columns, not all columns. In this case, the response performance of the row-based database is very inefficient.

Row-based database: Oracle is used as an example. The basic unit of data files is block/page. The data in the block is written by one row. This has a problem. When we want to read some columns in a block, we cannot read these columns only. We must read the entire block into the memory, then read the content of these columns. In other words, to read certain columns in a table, you must read all the rows in the table before reading these columns. This is the worst part of the row database.

Columnar Database: stores columns as elements. The elements of the same column will be squeezed into a block. When you want to read some columns, you only need to read the relevant column blocks to the memory, so that the read IO volume will be much less. Generally, data elements in the same column are in similar formats. This means that when the data format is similar, the data can be greatly compressed. Therefore, columnar databases have great advantages in data compression. Compression not only saves storage space, but also saves I/O. (This can be used to optimize data queries when the data reaches the level of millions or tens of millions. This improves performance and determines the scenario)

Hadoop + HBase cloud storage creation summary PDF

Regionserver startup failed due to inconsistent time between HBase nodes

Hadoop + ZooKeeper + HBase cluster configuration

Hadoop cluster Installation & HBase lab environment setup

HBase cluster configuration based on Hadoop cluster'

Hadoop installation and deployment notes-HBase full distribution mode installation

Detailed tutorial on creating HBase environment for standalone Edition

HBase details: click here
HBase: click here

This article permanently updates the link address:

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.