huaweicloud/huaweicloud-skills/huawei-cloud-ascend-remote-connect
Claude Code and agent skill by huaweicloud/huaweicloud-skills
- community
- ext:[{"type":"config","description":"Configuration overrides"}]
Checking that the SKILL.md file is still in the repository.
Provides temporary SSH remote connection for Huawei Cloud Ascend devices with dynamic host/port/user/password input (in-memory only), covering disk management, NPU monitoring, container management, security auditing and log analysis; sensitive operations require user confirmation before execution. Use this skill to remotely connect to Ascend servers, monitor NPU health, manage disks/LVM, or troubleshoot Ascend devices. Triggers include: SSH, remote, Ascend, NPU, 远程连接, 昇腾, NPU监控
Install
npx vskill@latest install huaweicloud/huaweicloud-skills/huawei-cloud-ascend-remote-connectSemi-extensibleMentions customization, but needs skill-specific knowledge. Read the extensible skills standard
SKILL.md
The same SKILL.md was published earlier as huaweicloud/huaweicloud-skills/huawei-cloud-ascend-remote-connect.
Huawei Cloud Ascend Remote Connection
Overview
Provides temporary SSH remote connection capability for Huawei Cloud Ascend devices. Supports simultaneous connection to multiple machines. All sensitive operations (delete, modify, move, etc.) require user confirmation before execution. Passwords are only stored in memory and destroyed after session ends.
Architecture
System Architecture Diagram
Component Relationships
| Component | Responsibility | Key Features | |
|---|---|---|---|
| Session Manager | Manage SSH connections | Connection pooling, timeout management, lifecycle control | |
| Command Executor | Process user commands | Natural language parsing, command routing, result formatting | |
| SSH Client | Establish secure tunnels | paramiko integration, ControlMaster, authentication | |
| Command Validator | Security enforcement | Blocked commands list, confirmation requirements |
Cloud Service Integration
- Ascend NPU Management: Direct access to npu-smi for monitoring and management
- Huawei Cloud Infrastructure: Secure SSH access to cloud servers and containers
- Security Compliance: Memory-only credential storage, session isolation
Prerequisites
System Requirements
- Python 3.8+
- paramiko >= 3.4.0
Environment Check
Prerequisite check: Python3 + paramiko required```bashpython3 --version # Python3 >= 3.8python3 -c "import paramiko; print('OK')" # SSH library```If not installed:pip3 install --user paramiko cryptography
Authentication
Security rules (must be followed):- Prohibited from reading, echoing, or printing password values- Prohibited from asking the user to input passwords directly in the conversation- Only allowed to read credentials from command line arguments- Interactive mode rejects any connection command that embeds a password in the conversation for the same reason; use--passwordor--keyCLI arguments instead- Connection passwords are stored in memory only and cleared when the session ends
Parameter Confirmation
Input Parameters
| Parameter | Required | Description | |
|---|---|---|---|
| host | Yes | Target server IP address (IPv4 only, e.g. 192.168.1.100; domain names are not supported) | |
| port | No | SSH port (default: 22) | |
| user | Yes | SSH username | |
| password | Yes* | SSH password (* required unless --key is provided) | |
| key | No | SSH private key file path (alternative to password) |
Parameter Validation
- IP address format: IPv4 (e.g., 192.168.1.100)
- Port range: 1-65535
- Username: alphanumeric and underscore
- Password must be a non-empty string
Confirmation Requirements
The following operations require explicit user confirmation:
- Delete: rm, rmdir
- Format: mkfs, fdisk -d, parted rm
- Unmount: umount
- Reboot: reboot, shutdown, init 6
- Shutdown: poweroff, halt, init 0
- User delete: userdel, groupdel
- Permission change: chmod -R, chown -R
IAM Permission Policies
Ensure the target server has SSH service enabled and the provided credentials have appropriate permissions.
Minimum required permissions on target server:
- SSH access (port 22 or custom)
- Sudo privileges for system management operations
Core Workflow
Task 1: Establish SSH Connection
Prefer key-based authentication (recommended):
Note: Only IPv4 addresses are supported (e.g.192.168.1.100). Domain names and hostnames are not supported.
Task 2: Interactive Mode
Usage Instructions
Connect to Ascend Server
Execute Commands
NPU Monitoring
System Management
Connection Management
Output Format
Standard Response Format
All command outputs follow a structured format:
Error Response Format
Success Indicators
- Exit Code: 0
- STDOUT: Contains expected output
- STDERR: Empty or contains only warnings
Verification Method
Basic Verification Steps
- Environment Check
``bash python3 --version # Verify Python 3.8+ python3 -c "import paramiko" # Verify paramiko installed ``
- Connection Test
``bash python3 scripts/main.py --host <test-ip> --port 22 --user root --password <test-pwd> --command "echo test" ``
- NPU Monitoring Test
``bash python3 scripts/main.py --host <ascend-ip> --user root --password <pwd> --command "npu-smi info" ``
Expected Results
| Test Case | Expected Output | |
|---|---|---|
| Environment check | Python version >= 3.8, paramiko import success | |
| Connection test | Exit code 0, "test" in stdout | |
| NPU info | NPU device information displayed |
See references/verification-method.md for detailed verification procedures.
Script Files
Entry File
- main.py: Skill entry file (required)
- Function: Provide interactive menu, unified entry point
- Menu options:
- Establish SSH connection
- Execute commands
- Disconnect
Core Scripts
- executor.py: Command executor (main entry)
- Function: Parse user input, dispatch commands to corresponding handlers
- Core methods:
handle_command(text): Command dispatch entry_connect(info): Establish SSH connection_detect_disks(): Detect unmounted disks_handle_auto_mount(text): Configure auto-mount on boot_confirm_disk_merge(info): Disk merge confirmation
- session_manager.py: Session manager
- Function: Manage multiple concurrent SSH sessions
- Core methods:
create_session(host, port, username, password): Create new sessionexecute_command(command): Execute command in active sessionswitch_session(host): Switch to specified host sessionclose_session(): Close current sessionget_session_info(): Get all session information
- ssh_client.py: SSH client
- Function: Low-level SSH connection implementation, supports password and key authentication
- Core methods:
connect(): Establish SSH connectionexec_command(command): Execute remote commandclose(): Close connection
- command_validator.py: Command validator
- Function: Security layer, filter dangerous commands
- Validation rules:
- Blocklist: Direct block (e.g., fork bomb)
- Sensitive: Require confirmation (e.g., rm -rf, reboot)
- Allowlist: Direct execution (e.g., ls, cat, df)
Supported Features
NPU Management
- NPU status monitoring (npu-smi)
- NPU health check
- NPU configuration viewing
Disk Management
- Disk detection
- LVM merging
- Partition mounting
- Auto-mount on boot
- Disk health check
- Free space check
System Management
- CPU/Memory/Disk monitoring
- System updates
- User/permission management
- Cron job management
Network Management
- Port scanning
- Firewall configuration
- Route viewing
- Network interface configuration
- DNS troubleshooting
Container Management
- Docker installation and management
- Image management
- Container management
- Log viewing
- Docker Compose operations
Security Management
- Login auditing
- SSH key management
- High-risk command blocking
Log Management
- System logs
- Application log analysis
- Error troubleshooting
File Operations
- Upload/download
- Copy/transfer
- Change permissions
- Create/delete
Connection Pool Management
Features
- Connection Reuse: Reuse same connection for same target, avoid repeated handshakes
- Auto Disconnect: Auto disconnect after 10 minutes idle (configurable)
- Thread Safe: Support multi-thread concurrent access
- Status Query: View connection pool status and idle time
This is the start of the file. Read the full SKILL.md on GitHub.
Security
- Security scanPassed, 90 of 100Pattern checks on the skill's files.
- Model reviewPassed
Quality evaluation
- Task evaluationNot runNo evaluation yet. Run one in Skill Studio.
Source
- SKILL.md in the repositoryCheckingskills/ai/modelarts/huawei-cloud-ascend-remote-connect/SKILL.md
Popularity
- 7-day trend score
- 5
Not refreshed yet.
Extension points
configConfiguration overrides
Works with
Any agent vskill installs to: 56 targets in all. These 39 have a page on this site.
- Claude Code
- Cursor
- GitHub Copilot
- Windsurf
- Codex
- Gemini CLI
- Cline
- Amp
- Roo Code
- Goose
- Continue
- Kilo Code
- Junie
- Trae
- OpenHands
- Qwen Code
- AI Agent
- Tabnine Chat
- Sourcegraph Cody
- Amazon Q
- Firebase Genkit
- Sweep
- Devin
- Phind
- Mentat
- Claude Desktop
- Aider
- GPT Pilot
- Plandex
- bolt.new
- v0
- Replit Agent
- Anse
- TypingMind
- BetterChatGPT
- LibreChat
- Warp AI
- Pieces
- Fig AI
Embed badge
[](https://verified-skill.com/skills/huaweicloud/huaweicloud-skills/huawei-cloud-ascend-remote-connect)