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

ADB (Intranet)

Updated on 2023-10-11 GMT+08:00

When you connect to a cloud phone through a private network, create an ECS in your VPC as the jump server for connecting to the cloud phone. If you do not customize the network when buying a cloud phone server, create a VPC peering connection between your existing VPC and the VPC where the cloud phone server is located, as shown in Figure 1. The ECS can run either the Windows or Linux. This topic uses the Windows as an example.

Figure 1 Using ADB to access a cloud phone over an Intranet

Constraints and Limitations

  • You cannot establish a peering connection between the VPC of a tenant who has not purchased a server with the VPC where a purchased server is located. For example, in Figure 1, the tenant VPC and the VPC where the server resides belong to account A. A VPC peering connection across accounts cannot be created.
  • The CIDR block of your VPC cannot overlap with 172.31.0.0/16 and 10.237.0.0/16. Otherwise, the VPC peering connection may be invalid.
  • If multiple VPC peering connections are established between your VPC and the VPC where the cloud phone server resides, only one of the peering connections is automatically accepted.

Prerequisites

  • The cloud phone must be in the Running state.
  • The inbound rules configured for your VPC allow traffic from the IP address and port of the cloud phone to be accessed.

    To obtain the IP address and port number of a cloud phone, go to its details page and obtain the server listening address in the Application Port area.

    Figure 2 Application Port
  • A Windows ECS is available in your VPC.
  • If you want to use an IPv6 address to connect to a dual-stack cloud phone, ensure that your environment, such as your ECS, supports IPv6 addresses.

Step 1: Create a VPC Peering Connection (Only When the Jump Server and the Cloud Phone Are in Different VPCs)

  1. Log in to the management console.
  2. On the Service List page, choose Compute > Cloud Phone Host.

    The CPH console is displayed.

  3. In the navigation pane on the left, choose Servers. In the upper part of the server list, click Configure Route.
  4. In the right pane, record the project ID, VPC ID, and CIDR Block that will be required for creating a VPC peering connection.
    Figure 3 Information collection
  5. If there is no Accepted peering connection available, click VPC console to create a VPC peering connection.

    The VPC Peering page is displayed.

    NOTE:

    If a VPC peering connection in the Accepted state exists, perform the following operations to go to the VPC Peering page:

    1. Choose Service List > Network > Virtual Private Cloud.
    2. In the navigation pane on the left, click VPC Peering.
  6. In the upper right corner, click Create VPC Peering Connection.
  7. Set parameters as prompted. Set Account to Another account, Peer Project ID to the project ID recorded in 4, and Peer VPC ID to the VPC ID recorded in 4. Click OK.
    Figure 4 Create VPC Peering Connection
  8. Wait for about 5 minutes until the VPC peering connection state changes to Accepted.
  9. Add routes for the VPC peering connection. For details, see Step 3: Add Routes for the VPC Peering Connection. In some regions, you cannot visit the route table module directly from the navigation pane on the left of the network console. In this case, add routes for the VPC peering connection by referring to Step 3: Add Routes for the VPC Peering Connection.

    When adding a route, set Destination to the CIDR block recorded in 4. After the route is added, the two VPCs can communicate with each other.

  10. (Optional) If you want to forward all outbound traffic of all of your cloud phones to the created VPC peering connection, perform operations by referring to Configuring a Route.

Step 2 Access the Cloud Phone Through ADB

  1. Log in to the ECS.
  2. Download ADB from the local PC and upload it to the ECS.

    Visit https://developer.android.com/studio/releases/platform-tools, switch the language to English in the upper right corner, and choose Download SDK Platform-Tools for Windows.

    Figure 5 Downloading ADB

    In the displayed dialog box, select the I have read and agree with the above terms and conditions check box, and click DOWNLOAD ANDROID SDK PLATFORM-TOOLS FOR WINDOWS.

  3. Decompress the ADB installation package (for example, platform-tools_r29.0.5-windows.zip) to the specified directory (PATH) on the ECS.
  4. Go to the PATH\platform-tools directory.
  5. Run the following ADB command to access the cloud phone:

    adb connect Listening IP address of the server: Listening port number of the server

    To obtain the listening IP address and port number of the server, perform the following steps:

    1. On the Instances page, click the name of the target cloud phone.
    2. In the Application Port area, obtain the listening IP address of the cloud phone server.
      Figure 6 Application Port

    Take the information in Figure 6 as an example. Run the following ADB command:

    adb connect 172.31.248.213:4673

    If you select Automatically-assigned IPv6 address when purchasing a cloud phone server, the system will allocate an IPv4 address and an IPv6 address to both the cloud phone and the server, as shown in Figure 7. The listening ports of the cloud phone's IPv4 and IPv6 addresses are the same, so are the listening ports of the cloud phone server.

    To use the IPv6 address to connect to the cloud phone, run the following ADB command:

    adb connect [2409:8c85:80:32:cb7e:97e3:e424:1286]:4615

    (Make sure you use square brackets to enclose the IPv6 address.)

    Figure 7 Application Port
  6. Run the adb devices command to check whether the current port is connected.

    If information similar to the following is displayed, the connection is successful:

    List of devices attached
    172.31.248.213:4673  device
  7. Run other ADB commands to operate the cloud phone.

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