Compute
Elastic Cloud Server
Huawei Cloud Flexus
Bare Metal Server
Auto Scaling
Image Management Service
Dedicated Host
FunctionGraph
Cloud Phone Host
Huawei Cloud EulerOS
Networking
Virtual Private Cloud
Elastic IP
Elastic Load Balance
NAT Gateway
Direct Connect
Virtual Private Network
VPC Endpoint
Cloud Connect
Enterprise Router
Enterprise Switch
Global Accelerator
Management & Governance
Cloud Eye
Identity and Access Management
Cloud Trace Service
Resource Formation Service
Tag Management Service
Log Tank Service
Config
OneAccess
Resource Access Manager
Simple Message Notification
Application Performance Management
Application Operations Management
Organizations
Optimization Advisor
IAM Identity Center
Cloud Operations Center
Resource Governance Center
Migration
Server Migration Service
Object Storage Migration Service
Cloud Data Migration
Migration Center
Cloud Ecosystem
KooGallery
Partner Center
User Support
My Account
Billing Center
Cost Center
Resource Center
Enterprise Management
Service Tickets
HUAWEI CLOUD (International) FAQs
ICP Filing
Support Plans
My Credentials
Customer Operation Capabilities
Partner Support Plans
Professional Services
Analytics
MapReduce Service
Data Lake Insight
CloudTable Service
Cloud Search Service
Data Lake Visualization
Data Ingestion Service
GaussDB(DWS)
DataArts Studio
Data Lake Factory
DataArts Lake Formation
IoT
IoT Device Access
Others
Product Pricing Details
System Permissions
Console Quick Start
Common FAQs
Instructions for Associating with a HUAWEI CLOUD Partner
Message Center
Security & Compliance
Security Technologies and Applications
Web Application Firewall
Host Security Service
Cloud Firewall
SecMaster
Anti-DDoS Service
Data Encryption Workshop
Database Security Service
Cloud Bastion Host
Data Security Center
Cloud Certificate Manager
Edge Security
Managed Threat Detection
Blockchain
Blockchain Service
Web3 Node Engine Service
Media Services
Media Processing Center
Video On Demand
Live
SparkRTC
MetaStudio
Storage
Object Storage Service
Elastic Volume Service
Cloud Backup and Recovery
Storage Disaster Recovery Service
Scalable File Service Turbo
Scalable File Service
Volume Backup Service
Cloud Server Backup Service
Data Express Service
Dedicated Distributed Storage Service
Containers
Cloud Container Engine
SoftWare Repository for Container
Application Service Mesh
Ubiquitous Cloud Native Service
Cloud Container Instance
Databases
Relational Database Service
Document Database Service
Data Admin Service
Data Replication Service
GeminiDB
GaussDB
Distributed Database Middleware
Database and Application Migration UGO
TaurusDB
Middleware
Distributed Cache Service
API Gateway
Distributed Message Service for Kafka
Distributed Message Service for RabbitMQ
Distributed Message Service for RocketMQ
Cloud Service Engine
Multi-Site High Availability Service
EventGrid
Dedicated Cloud
Dedicated Computing Cluster
Business Applications
Workspace
ROMA Connect
Message & SMS
Domain Name Service
Edge Data Center Management
Meeting
AI
Face Recognition Service
Graph Engine Service
Content Moderation
Image Recognition
Optical Character Recognition
ModelArts
ImageSearch
Conversational Bot Service
Speech Interaction Service
Huawei HiLens
Video Intelligent Analysis Service
Developer Tools
SDK Developer Guide
API Request Signing Guide
Terraform
Koo Command Line Interface
Content Delivery & Edge Computing
Content Delivery Network
Intelligent EdgeFabric
CloudPond
Intelligent EdgeCloud
Solutions
SAP Cloud
High Performance Computing
Developer Services
ServiceStage
CodeArts
CodeArts PerfTest
CodeArts Req
CodeArts Pipeline
CodeArts Build
CodeArts Deploy
CodeArts Artifact
CodeArts TestPlan
CodeArts Check
CodeArts Repo
Cloud Application Engine
MacroVerse aPaaS
KooMessage
KooPhone
KooDrive
Help Center/ Huawei Cloud Flexus_Huawei Cloud Flexus RDS/ Getting Started/ Buying and Connecting to a FlexusRDS for PostgreSQL Instance

Buying and Connecting to a FlexusRDS for PostgreSQL Instance

Updated on 2025-01-26 GMT+08:00

This section describes how to purchase a FlexusRDS for PostgreSQL instance and how to connect to it using Data Admin Service (DAS).

Preparations

  1. Sign up for a HUAWEI ID and enable Huawei Cloud services.
  2. Before purchasing DB instances, ensure that your account balance is sufficient. Top up your account if required.
  3. For fine-grained permissions management, create an Identity and Access Management (IAM) user and user group on the IAM console and grant the user specific operation permissions. For details, see Creating a User and Granting Permissions.

Step 1: Create a FlexusRDS for PostgreSQL Instance

  1. Go to the FlexusRDS console.
  2. If this is your first time to create a FlexusRDS for PostgreSQL instance, click Buy.
  3. Configure the instance information and click Buy.
    Figure 1 Selecting an instance class
    Figure 2 Selecting the required duration

    Parameter

    Example Value

    Description

    Region

    CN-Hong Kong

    The region where your resources are located.

    NOTE:

    Products in different regions cannot communicate with each other through a private network. After a DB instance is created, the region cannot be changed. Therefore, exercise caution when selecting a region.

    DB Engine

    PostgreSQL 16

    The DB engine version.

    Instance Class

    Standard 2U4G

    The vCPU and memory of an instance.

    DB Instance Type

    Single

    The architecture type of an instance.

    • Single: A single-node architecture. It is less expensive than a primary/standby DB pair.
    • Primary/Standby: An HA architecture. In a primary/standby pair, each instance has the same instance class. When a primary instance is being created, a standby instance is provisioned along with it to provide data redundancy. The standby instance is invisible to you after being created.

    Storage

    120 GB

    The storage space of an instance.

    Network

    vpc-default-smb

    subnet-default-smb

    A Virtual Private Cloud (VPC) is a virtual network in which your instance is located. A VPC can isolate networks for different workloads.

    A subnet provides dedicated network resources that are logically isolated from other networks for security purposes.

    For details about how to create a VPC and subnet, see Creating a VPC and Subnet.

    DB Instance Name

    flexusrds-1234

    The instance name must start with a letter and consist of 4 to 64 characters. Only letters (case-sensitive), digits, hyphens (-), underscores (_), and periods (.) are allowed.

    If you buy multiple DB instances at a time, they will be named instance-0001, instance-0002, and so on. (instance indicates the DB instance name you specify.)

    Required Duration

    1 year

    The system will automatically calculate the configuration fee based on the selected required duration. The longer the required duration is, the larger discount you will enjoy.

    Auto-renew

    Disabled

    • This option is not selected by default.
    • If you select this option, the auto-renew cycle is determined by the selected required duration.

    Quantity

    1

    The number of instances to be purchased in a batch.

  4. Confirm the order and click Pay Now.
    Figure 3 Order confirmation
  5. Select a payment method and complete the payment.
  6. View the purchased instance.
    • Administrator account: root
    • Password of the administrator account: The password is randomly set by the system. You need to reset the password when using the account.
    Figure 4 Instance successfully purchased

Step 2: Connect to the FlexusRDS for PostgreSQL Instance

  1. In the instance list, locate the instance and click Reset Password in the Operation column.
    Figure 5 Instance list
  2. Enter a new password, confirm the password, and click OK.
    Figure 6 Resetting a password
  3. In the instance list, locate the instance and click Log In in the Operation column.
    Figure 7 Instance list
  4. Enter username root and its password, and click Log In.
    Figure 8 Instance login
  5. Choose SQL Operations > SQL Query.
    Figure 9 SQL Query
  6. Create a database named test1.

    CREATE DATABASE test1;

    Figure 10 Creating a database
  7. Switch to test1 and create a schema named schema1 in the database.
    Figure 11 Switching to the database

    CREATE SCHEMA schema1;

    Figure 12 Creating a schema
  8. Switch to schema1 and create a table named mytable with only one column. Specify the column name as firstcol and the column type as integer.

    CREATE TABLE schema1.mytable (firstcol int);

    Figure 13 Creating a table
  9. Insert data to the table.

    INSERT INTO schema1.mytable values (100);

    Figure 14 Inserting data

    Query data in the table.

    SELECT * FROM "schema1"."mytable"

    Figure 15 Querying data
  10. In the upper part of the page, choose Account Management > Role Management.
    Figure 16 Role management
  11. Click Create Role and complete basic settings. user1 is used as an example.
    Figure 17 Creating a role
  12. Click the Permissions tab and grant user1 the permissions to perform operations on databases, schemas, and tables.
    Figure 18 Granting permissions
  13. On the Development Tool page, click Add Login and log in to the database as user1.
    Figure 19 Adding login
  14. Create schema2 in test1 to verify that user1 has the CREATE permission.
    CREATE SCHEMA schema2;
    Figure 20 Verifying permissions

We use cookies to improve our site and your experience. By continuing to browse our site you accept our cookie policy. Find out more

Feedback

Feedback

Feedback

0/500

Selected Content

Submit selected content with the feedback