This section presents you various set of Mock Tests related to HBase. You can download these sample mock tests at your local machine and solve offline at your convenience. Every mock test is supplied with a mock test key to let you verify the final score and grade yourself.
Q 1 - If we choose the rowkey to be a timestamp then inserting data to such a Hbase table will be
A - Faster than a numeric rowkey data
B - Slower than a numeric rowkey data
If the rowkey is made as timestamp then it will always be written to a specific region and at the end of the table, overloading just one machine holding that region. SO it will be slower than other type of rowkey.
Q 2 - Which of the following pair is an option for effectively distributing the data across multiple regions?
Hashing the rowkeys gives randomly distributed values and salting involves adding a random number to the rowkey. Both these options create a good distribution of keys to be used across multiple regions.
Q 3 - In the standalone mode Hbase runs on
In standalone mode Hbase runs only on the local file system.
Q 4 - In the pseudo-distributed mode, Hbase runs on
In pseudo-distributed mode Hbase can run on either local file system or HDFS but not both.
Q 5 - The property which enables a fully distributed mode for Hbase is
A - hbase-cluster.distributed-all
B - hbase-cluster.distributed-enable
By default HBase runs in standalone mode. For a fully distributed configuration set the hbase-cluster.distributed property to true.
Q 6 - A namespace in Hbase is analogous to which data base object in a relational system?
A namespace is analogous to a database in relational syetm as it holds the tables.
Q 7 - The two predefined namespace in Hbase are
The toe predefined namespace in Hbase are – habse and default. Habse contains internal tables and default contains the tables which are not qualified with any namespace.
Q 8 - Which of the following is declared during the schema definition creation?
The column families are declared upfront during the schema definition creation. But the column names can be declared anytime when the Table is up and running.
Q 9 - The tuple which specifies a cell in Hbase is
The tuple row, column and version defines a cell. Here row indicates the rowkey.
Q 10 - While rows and columns keys are expressed as bytes, version is specified as
the version is specified using a long integer. Typically this long contains time instances such as those returned by java.util.Date.getTime()
Q 11 - What does the following command do?
hbase> alter ‘t1′, NAME => ‘f1′, VERSIONS => 5
A - All the columns in the column family f1 of table t1 can have minimum 5 versions.
B - All the columns in the column family f1 of table t1 can have maximum 5 versions.
C - Creates 5 versions of the column family named f1 in table t1.
The command keeps a maximum of 5 versions of all columns in column family f1.
Q 12 - What does the following command do?
hbase> alter ‘t1′, NAME => ‘f1′, MIN_VERSIONS => 2
A - All the columns in the column family f1 of table t1 can have minimum 2 versions.
B - All the columns in the column family f1 of table t1 can have maximum 2 versions.
C - Creates 2 versions of the column family named f1 in table t1.
The command keeps a minimum of 2 versions of all columns in column family f1.
Q 13 - How many types of delete markers are used by Hbase for deleting columns?
The three different types of column deletes in Hbase are
Delete − for a specific version of a column.
Delete column: for all versions of a column.
Delete family − for all columns of a particular ColumnFamily
Q 14 - All data returned from a Hbase query is sorted. They are sorted by
A - rowkey, ColumnFamily,, Column qualifier, timestamp
B - ColumnFamily,, Column qualifier, rowkey,,timestamp
They result from Hbase is sorted by
ColumnFamily,,Column qualifier, rowkey,,timestamp
Q 15 - The schema level changes to table or column families(like region size, block size etc) are reflected
A - Immediately after the changes
B - Only after a major compaction
Only after a major compaction and the StoreFiles get re-written the schema level changes are available.
Q 16 - When a large amount of client requests are directed to a very few nodes in a cluster, it is known as
many client requests landing in only a few nodes is called Hotspotting.
Q 17 - The length of the name of the column family should be
The colun family name should be ideally one character so that metadata associated with a cell is minimum.
Q 18 - The rowkeys in Hbase are immutable. The only way they can be changed is
B - Updating them at a pre-defined interval
The row key gets removed when a row is deleted and a new one is created when a row is inserted.
Q 19 - Hbase can store
Hbase can store any data that can be converted to bytes.
Q 20 - Hbase can automatically delete rows by using
Using TTL Hbase will delte all the rows that has reached the expiration time.
Q 21 - Which filter acts on column family?
The Family filter in Hbase works on a a column family rather than on a column.
Q 22 - Which filer accepts the pagesize as a parameter?
This filter gives the query result in different pages using Pagesize parameter.
Q 23 - Which filter accepts chance as a parameter?
The Random filter which returns a random row uses the chance parameter. Example- RandomRowFilter(float chance)
Q 24 - A new counter created in Hbase has the value
When a counter is initialized, its value depends on what is specified during its creation. Only if no specific value is mentioned it will initialize to zero.
Q 25 - You can process an arbitrary code on a region server using
A coprocessor enables you to run arbitrary code directly on each region server.
Question Number | Answer Key |
---|---|
1 | B |
2 | A |
3 | A |
4 | C |
5 | D |
6 | D |
7 | B |
8 | A |
9 | A |
10 | B |
11 | B |
12 | B |
13 | B |
14 | A |
15 | B |
16 | C |
17 | B |
18 | D |
19 | D |
20 | C |
21 | C |
22 | C |
23 | B |
24 | D |
25 | B |