このページは、お客様の言語ではご利用いただけません。Huawei Cloudは、より多くの言語バージョンを追加するために懸命に取り組んでいます。ご協力ありがとうございました。
- Service Overview
- Billing
- Getting Started
-
User Guide
-
HBase User Guide
-
HBase Cluster Management
- Overview
- Managing Clusters
- Preparing an ECS
- Using HBase
- HBase Cold and Hot Data Separation
- HBase Thrift Server
- HBase Security Channel Encryption
- HBase Batch Data Import
- HBase Monitoring Clusters
- Self-Healing from HBase Hotspotting
- Global Secondary Indexes
-
HBase Cluster Management
-
ClickHouse User Guide
-
ClickHouse Cluster Management
- Overview
- Managing ClickHouse Clusters
- Using ClickHouse
- Migrating ClickHouse Data
- ClickHouse User Management
- ClickHouse Role Management
- ClickHouse Slow Query Management
- Configuring Secure Channel Encryption for ClickHouse Clusters
- Application of ClickHouse Cold and Hot Data Separation
- ClickHouse Monitoring Clusters
-
ClickHouse Cluster Management
- Permissions Management
- Audit Logs
- Cluster Log Management
-
HBase User Guide
-
Developer Guide
- HBase Application Development Guide
- ClickHouse Application Development Guide
-
FAQs
-
General
- What Services Does a CloudTable Cluster Provide?
- Why Do I Choose CloudTable Service?
- How Do I Prepare for Creating a CloudTable HBase Cluster?
- What Should I Pay Attention to When Using CloudTable Service?
- What Compression Algorithms Are Supported by CloudTable HBase Clusters?
- Can I Stop CloudTable Service?
- Which Programming Languages Are Supported by HBase External APIs in CloudTable?
- How Do I Determine the Number of Faulty RegionServers?
- What Special Characters Does CloudTable HBase Support?
- What Can I Do If the Index Table Does Not Match the Data Table After CloudTable Data Is Deleted?
- What Should I Do If Concurrent Tasks Run Slowly When Python Accesses CloudTable Through Thrift?
- How do I view the TTL attribute of HBase shell?
- Why Are My Server Resources Released?
- How Do I Delete a Cluster?
- How Do I Stop Services and Release Resources?
-
Connection and Access
- How Do I Access a CloudTable Cluster?
- Can I Use SSH to Access Computing Nodes of CloudTable?
- Why Can't I Access HBase After the ZK Address Is Configured?
- Why Is the Error "Will not attempt to authenticate using SASL (unknown error)" Reported When Connecting to HBase?
- How Do I View the IP Address Corresponding to a Domain Name in a CloudTable Link?
- How Do I Access CloudTable from Other Cloud Services?
- Can I Configure the hbase-site.xml File?
- How Do I Query the Creation Time of a Table in CloudTable HBase?
-
Data Read/Write
- Is Raw Data Stored in CloudTable HBase?
- Why Can't I Write Data to HBase?
- What Is the Maximum Size of Data Written to the HBase Cluster?
- How Do I Check the Daily Incremental Data in HBase Tables?
- What Should I Do If an Error Is Reported When I Access the CloudTable HBase Cluster?
- How Do I Delete the Backup Table of the ZooKeeper Node in the ClickHouse Cluster?
- What Should I Do If a Database Missing Error Occurs When a Table Is Created in the ClickHouse Cluster?
- Billing FAQs
-
General
- General Reference
Show all
Copied.
Introducing HBase Shell Commands
This section describes common HBase shell commands.
- Start the HBase shell.
Go to the HBase directory and run the following command to access the HBase shell:
./bin/hbase shell
- Get help information.
After you run the help command in the HBase shell, all command information as well as common command instructions and use methods will be returned.
hbase(main):001:0> help
- Create a table.
Run the create command to create a table. When creating a table, you must specify the table name and column family name.
hbase(main):007:0> create 'cloudtable','cf' 0 row(s) in 1.5530 seconds => Hbase::Table - cloudtable
- Query a table:
hbase(main):009:0> list TABLE cloudtable 1 row(s) in 0.0060 seconds => ["cloudtable"]
- Insert a piece of record to a table.
Run the put command to insert a piece of record to the specified table. You need to specify the table name, primary key, customized column, and inserted value.
hbase(main):004:0> put 'cloudtable','row1','cf:a','value1' 0 row(s) in 0.2720 seconds
The following describes parameters in the command:
- cloudtable: table name
- row1: primary key
- cf:a: customized column
- value1: inserted value
- Scan records
Run the scan command to scan a table. You need to specify the table name and you can scan a full table or specify a scanning range.
hbase(main):001:0> scan 'cloudtable' ROW COLUMN+CELL row1 column=cf:a, timestamp=1504866237162, value=value1 1 row(s) in 0.2420 seconds
NOTE:
- If the TTL of the cell is set when the data is inserted, the TTL attribute cannot be viewed. You can check whether the TTL configuration is successful.
- If the TTL of the cell is not set when data is inserted, the system automatically inserts the current time as the timestamp.
- Query a single record.
Run the get command to query a single record. The name and primary key of the queried table must be specified.
hbase(main):001:0> get 'cloudtable','row1' COLUMN CELL cf:a timestamp=1504866237162, value=value1 1 row(s) in 0.2280 seconds
- Disable a table.
Before modifying or deleting a table, you need to disable the table. Run the disable command to disable the table. When you perform operations on a disabled table, "ERROR" will be reported, indicating that the table is disabled.
hbase(main):002:0> disable 'cloudtable' 0 row(s) in 2.3550 seconds
- Enable a table.
If you want to use a table that has been disabled, run the enable command to enable the table.
hbase(main):004:0> enable 'cloudtable' 0 row(s) in 1.2500 seconds
- Delete a table.
Run the drop command to delete a table that you do not require anymore. Before deleting a table, disable the table. Otherwise, "ERROR" will be displayed, indicating that the table is enabled. Deleting a table will cause data loss. Therefore, exercise caution when deleting a table.
hbase(main):007:0> disable 'cloudtable' 0 row(s) in 2.2380 seconds hbase(main):008:0> drop 'cloudtable' 0 row(s) in 1.2600 seconds
- Exit the HBase shell.
Run the quit command to exit the HBase shell.
hbase(main):009:0> quit
Feedback
Was this page helpful?
Provide feedbackThank you very much for your feedback. We will continue working to improve the documentation.See the reply and handling status in My Cloud VOC.
For any further questions, feel free to contact us through the chatbot.
Chatbot