rea
Reverse engineer anything with agents, from app behavior down to native binaries.
- 472k
- TypeScript
- MIT
- 30 min ago
A high-performance parallel SSH command execution tool for cluster management
Repo lablup/bssh, read from GitHub 1 min ago. lablup has not joined Take My Repo.
lablup/bssh is a public repo on GitHub by lablup. A high-performance parallel SSH command execution tool for cluster management. It declares the Apache-2.0 license on GitHub. It is written mainly in Rust, has 71 stars and last changed on 2026-11-19. Nobody has reviewed it on Take My Repo yet, which says nothing about its quality. Read from GitHub on 2026-11-21.
In the maintainer's words. Shown from GitHub; Take My Repo does not keep a copy.
A high-performance SSH client with SSH-compatible syntax for both single-host and parallel cluster operations, built with Rust and russh.
Developed and maintained as part of the Backend.AI project.
v3.1.2 (2026/11/10): Fixed the server password verifier so unusable or malformed stored hashes take the same dummy-hash path as unknown users, and added a load-time warning for users whose hash format cannot log in (SHA-crypt, /etc/shadow values).
v3.1.1 (2026/11/05): Fixed cluster and --hosts commands containing spaces or shell syntax being parsed as SSH destinations, upgraded to russh 0.65.1 with its security fixes and staged host-key verification, and sent session-bind@openssh.com on agent connections.
v3.1.0 (2026/10/23): Added FIDO security-key authentication and enrollment, direct ICMP network ping, host-certificate verification and Unix-socket forwarding; fixed upload backpressure, enabled macOS Keychain support, and hardened SSH command expansion.
v3.0.1 (2026/09/01): Replaced developer-only tracking and historical-version references in active help, runtime warnings, manpages, current release notes, and public documentation with behavior-focused guidance. Added rendered-help regression checks for all three binaries. Runtime behavior was unchanged.
v3.0.0 (2026/09/01): Made single-destination sessions byte-transparent, applied SSH configuration at runtime, added OpenSSH configuration, session, forwarding, and multiplexing options, and restored seven colliding short flags to their OpenSSH meanings. The pinned OpenSSH suite passes 60 tests on macOS and 61 on Ubuntu.
v2.4.3 (2026/08/24): Fix bssh-to-bssh SFTP downloads above 255 KiB, upgrade to russh 0.63.1 with two security fixes and host-certificate refusal, sync bssh-russh-sftp 2.4.0, and repair release automation for API-key notarization and Homebrew updates.
v2.4.2 (2026/08/14): Republish the macOS binaries with a Developer ID signature and Apple notarization. The v2.4.1 and earlier macOS builds are killed on launch and deleted by macOS because their signing certificate was revoked. No source changes.
v2.4.1 (2026/08/03): Close the four host key and forwarding known issues from v2.4.0: accept-new no longer disables verification without a home directory or an unusable known_hosts file, first-use recording is serialized across processes, @cert-authority lines can be rejected, forwarding targets keep their hostnames for the server to resolve, SOCKS4 honors -4/-6, and SOCKS5 accepts IPv6 destination literals.
v2.4.0 (2026/08/03): Implement real TOFU verification for the default accept-new host key mode, make bssh ping report a 0/1/255 exit code, wire up the -4/-6 flags and ssh_config AddressFamily across connect, forwarding, and jump chains, resolve ssh_config settings per target host, and accept bracketed IPv6 host literals.
v2.3.1 (2026/07/29): Restore keyboard protocols leaked by disconnected PTY applications, preserve an outer TUI's keyboard state, raise the MSRV and Debian/Launchpad toolchain to Rust 1.96, and make Homebrew formula updates safer.
v2.3.0 (2026/07/18): Roughly double bssh-server SFTP write throughput, fix the paramiko prefetch deadlock (with TCP_NODELAY), make sftp.root/scp.root chroot usable, make server SSH compression configurable, and drop the vendored bssh-russh fork for upstream russh 0.62.1.
v2.2.3 (2026/05/25): Sync both internal russh forks to upstream stable and patch RUSTSEC-2026-0009 (a time stack-exhaustion DoS), raising the minimum supported Rust to 1.88.
v2.2.2 (2026/05/25): Keep idle SSH sessions alive by lowering the default --server-alive-interval to 30s and leaving the client inactivity timeout disabled.
v2.2.1 (2026/05/19): Dependency upgrade pass and russh fork sync picking up both halves of CVE-2026-46673, plus a bssh-russh dev-deps fix so its inline tests compile.
v2.2.0 (2026/05/18): Collect --password once and share it across parallel tasks, add BSSH_PASSWORD, resolve all cargo-audit findings, and drop five redundant dependencies.
v2.1.4 (2026/05/10): Stream SFTP transfers in 255 KiB chunks (~160x lower memory, ~11x faster 1 GiB upload) and pipeline up to 64 concurrent requests.
v2.1.3 (2026/04/30): Fix SCP/SFTP path doubling and chroot config, vendor russh-sftp with a serde_bytes perf fix (+29% upload), and forward-port unreleased upstream russh fixes.
See CHANGELOG.md for the complete version history.
-J)node[1-5], rack[1-2]-node[1-3]) for compact host specification--fail-fast (-k remains available only in pdsh compatibility mode)--connect-timeout) and command execution timeout (--timeout) with support for unlimited execution--server-alive-interval, --server-alive-count-max) to prevent idle connection timeouts--use-agent), PTY-based interactive sessions, and every CLI feature documented here.bssh crate does not build for a Windows target today because of unconditional Unix-only dependencies (nix, signal-hook, libc) and un-gated PTY/agent code; there is no Windows CI job or release artifact. Use WSL2 to run bssh on Windows.The easiest way to install bssh on macOS and Linux is through Homebrew:
brew tap lablup/tap brew install bssh
For Ubuntu users, bssh is available through the official PPA:
# Add the PPA repository sudo add-apt-repository ppa:lablup/backend-ai sudo apt update # Install bssh sudo apt install bssh
For Debian and other Debian-based distributions, download the .deb package from the releases page:
# Download the latest .deb package (replace VERSION with the actual version) wget https://github.com/lablup/bssh/releases/download/vVERSION/bssh_VERSION_OS_ARCH.deb # Example: bssh_0.4.0_ubuntu24.04.noble_amd64.deb # Install the package sudo dpkg -i bssh_VERSION_OS_ARCH.deb # If there are dependency issues, fix them with: sudo apt-get install -f
Download the latest release from the GitHub releases page:
$PATHcargo build --release sudo cp target/release/bssh /usr/local/bin/
The 3.0 command-line contract gives these seven letters their OpenSSH meanings. Existing bssh scripts must use the corresponding long option for the displaced bssh feature; see the 3.0 short-flag migration guide.
| Short flag | OpenSSH-compatible meaning | Long option for the former bssh meaning |
|---|---|---|
-N |
Do not execute a remote command | --no-prefix |
-f |
Go to the background after authentication | --filter |
-C |
Enable SSH compression | --cluster |
-A |
Enable authentication-agent forwarding | --use-agent |
-S path |
Select the multiplexing ControlPath |
--sudo-password |
-k |
Disable GSSAPI credential delegation | --fail-fast |
-b address |
Bind the client to a source address | --batch |
# Connect to a host (just like SSH!) bssh user@hostname # Execute a command bssh user@hostname "uptime" # With specific port and key bssh -p 2222 -i ~/.ssh/key.pem admin@server.com # Using SSH options bssh -o StrictHostKeyChecking=no user@host # Query SSH capabilities bssh -Q cipher
PTY Session Escape Sequences:
Like OpenSSH, bssh supports escape sequences in PTY sessions. These must be typed at the beginning of a line (after pressing Enter):
| Escape | Description |
|---|---|
~. |
Disconnect from the remote host |
# Local port forwarding (-L) # Forward local port 8080 to example.com:80 via SSH bssh -N -L 8080:example.com:80 user@host # Remote port forwarding (-R) # Forward remote port 8080 to localhost:80 bssh -N -R 8080:localhost:80 user@host # Dynamic port forwarding / SOCKS proxy (-D) # Create SOCKS5 proxy on local port 1080 bssh -N -D 1080 user@host # Multiple port forwards bssh -N -L 3306:db:3306 -R 80:web:80 -D 1080 user@host # Bind to specific address bssh -N -L 127.0.0.1:8080:web:80 user@host # Local only bssh -N -L *:8080:web:80 user@host # All interfaces # SOCKS4 proxy (specify version) bssh -N -D 1080/4 user@host # SOCKS4 bssh -N -D *:1080/5 user@host # SOCKS5 on all interfaces # Unix-domain socket forwarding (any field containing a slash is a socket path) bssh -N -L /tmp/db.sock:db:3306 user@host # local socket → remote TCP bssh -N -R /var/run/app.sock:/var/run/local.sock user@host # remote socket → local socket # Port forwarding with command execution bssh -L 5432:postgres:5432 user@host "psql -h localhost" # Port forwarding without opening a remote shell bssh -N -L 8080:internal:80 user@gateway
# Connect through a single jump host (bastion) bssh -J jump@bastion.example.com user@internal-server # Multiple jump hosts (connection chain) bssh -J "jump1@proxy1,jump2@proxy2" user@final-destination # Jump host with custom port bssh -J admin@bastion:2222 user@internal-host # IPv6 jump host bssh -J "[2001:db8::1]:22" user@destination # Combine with cluster operations bssh -J bastion.example.com --cluster production "uptime" # File transfer through jump host bssh -J bastion.example.com -H internal-server upload app.tar.gz /opt/ bssh -J admin@bastion:2222 --cluster production download /etc/config ./backups/ # Interactive mode through jump hosts bssh -J bastion.example.com user@internal-server bssh -J "jump1,jump2" --cluster production interactive # Multi-hop with file transfer bssh -J "bastion1,bastion2,bastion3" -H target upload -r ./app/ /opt/app/
# Execute commands on multiple hosts (automatic command execution) bssh -H "user1@host1.com,user2@host2.com:2222" "uptime" # Using cluster from config bssh --cluster production "df -h" # Hostlist expressions (pdsh-style range expansion) bssh -H "node[1-5]" "uptime" # node1, node2, node3, node4, node5 bssh -H "node[01-05]" "df -h" # Zero-padded: node01, node02, ... bssh -H "node[1,3,5]" "ps aux" # Specific values: node1, node3, node5 bssh -H "rack[1-2]-node[1-3]" "uptime" # Cartesian product: 6 hosts bssh -H "web[1-3].example.com" "nginx -v" # With domain suffix bssh -H "admin@db[01-03]:5432" "psql --version" # With user and port bssh -H "^/etc/hosts.cluster" "uptime" # Read hosts from file # Filter specific hosts with pattern matching bssh -H "web1,web2,db1,db2" --filter "web*" "systemctl status nginx" bssh --cluster production --filter "db*" "pg_dump --version" bssh -H "node[1-10]" --filter "node[1-5]" "uptime" # Filter with hostlist expression # Exclude specific hosts from execution bssh -H "node1,node2,node3" --exclude "node2" "uptime" bssh --cluster production --exclude "db*" "systemctl restart nginx" bssh -H "node[1-10]" --exclude "node[3-5]" "uptime" # Exclude with hostlist expression # With custom SSH key bssh --cluster staging -i ~/.ssh/custom_key "systemctl status nginx" # Use SSH agent for authentication bssh --use-agent --cluster production "systemctl status nginx" # Use password authentication (will prompt for password) bssh --password -H "user@host.com" "uptime" # Use sudo password for privileged commands (prompts securely) bssh --sudo-password --cluster production "sudo apt update && sudo apt upgrade -y" # Combine sudo password with SSH agent authentication bssh --use-agent --sudo-password --cluster production "sudo systemctl restart nginx" # Use encrypted SSH key (will prompt for passphrase) bssh -i ~/.ssh/encrypted_key --cluster production "df -h" # Limit parallel connections bssh --cluster production --parallel 5 "apt update" # Set command timeout (10 seconds) bssh --cluster production --timeout 10 "quick-check" # No timeout (unlimited execution time) bssh --cluster staging --timeout 0 "long-running-backup" # Set connection timeout (default: 30 seconds) bssh --cluster production --connect-timeout 10 "uptime" # Different timeouts for connection and command bssh --cluster production --connect-timeout 5 --timeout 600 "long-running-job" # Configure SSH keepalive (prevent idle connection timeouts) bssh --cluster production --server-alive-interval 30 "long-running-job" # Disable keepalive (set interval to 0) bssh --cluster production --server-alive-interval 0 "quick-job" # Keepalive with custom max retries (default: 3) bssh --cluster production --server-alive-interval 30 --server-alive-count-max 5 "long-running-job" # Fail-fast mode: stop immediately on any failure bssh --fail-fast -H "web1,web2,web3" "deploy.sh" bssh --fail-fast --cluster production "critical-script.sh" # Combine fail-fast with require-all-success for critical operations bssh --fail-fast --require-all-success --cluster production "service-restart.sh"
bssh automatically selects the best output mode based on your environment:
Interactive Terminal UI with real-time monitoring - automatically enabled when running in an interactive terminal.
# TUI mode automatically activates for multi-node commands bssh --cluster production "apt-get update" # Features: # - Summary view: All nodes at a glance with progress bars # - Detail view: Full output from specific node with scrolling # - Split view: Monitor 2-4 nodes simultaneously in panes # - Diff view: Compare output from two nodes side-by-side # - Auto-scroll: Automatic following of new output # - Progress detection: Percentage, fraction, apt/dpkg indicators # - Real-time updates: Output streams in real-time (50ms polling) # - Memory protection: 10MB buffer per node with graceful overflow
TUI View Modes:
| View Mode | Description | Access Key |
|---|---|---|
| Summary | All nodes overview with status, progress bars, and recent output | Default view |
| Detail | Full output from a single node with scrollback | 1-9 (node number) |
| Split | Side-by-side display of 2-4 nodes (last 20 lines each) | s |
| Diff | Compare two nodes line-by-line | d |
Keyboard Shortcuts:
| Key | Context | Action |
|---|---|---|
| Global Keys (work in any view) | ||
q |
Any view | Quit TUI |
Ctrl+C |
Any view | Quit TUI |
? |
Any view | Toggle help overlay |
Esc |
Any view | Return to summary view (or close help) |
l |
Any view | Toggle log panel visibility |
| Summary View | ||
1-9 |
Summary | Jump to detail view for node N |
s |
Summary | Enter split view (first 2-4 nodes) |
d |
Summary | Enter diff view (first 2 nodes) |
| Detail View | ||
↑ |
Detail | Scroll up 1 line |
↓ |
Detail | Scroll down 1 line |
← |
Detail | Switch to previous node |
→ |
Detail | Switch to next node |
PgUp |
Detail | Scroll up 10 lines |
PgDn |
Detail | Scroll down 10 lines |
Home |
Detail | Jump to top of output |
End |
Detail | Jump to bottom (re-enables follow mode) |
f |
Detail | Toggle auto-scroll (follow mode) |
1-9 |
Detail | Jump to specific node N |
| Split View | ||
1-4 |
Split | Focus on specific node (switch to detail view) |
| Diff View | ||
↑/↓ |
Diff | Scroll* |
| Log Panel (when visible) | ||
j |
Log panel | Scroll log up |
k |
Log panel | Scroll log down |
+ |
Log panel | Increase log panel height |
- |
Log panel | Decrease log panel height |
t |
Log panel | Toggle timestamps |
*Note: Diff view scroll is planned but not yet implemented.
Log Panel:
The TUI includes an in-app log panel that captures error and warning messages without breaking the alternate screen. This prevents log messages from corrupting the TUI display during execution.
l keyBSSH_TUI_LOG_MAX_ENTRIES environment variable (default: 1000, max: 10000)TUI Activation:
| tee, >)CI=true)--stream, --output-dir)# Enable stream mode explicitly bssh --cluster production --stream "tail -f /var/log/syslog" # Output: # [node1] Oct 30 10:15:23 systemd[1]: Started nginx.service # [node2] Oct 30 10:15:24 kernel: [UFW BLOCK] IN=eth0 OUT= # [node1] Oct 30 10:15:25 nginx: Configuration test successful # Stream mode without hostname prefix (pdsh -N compatibility) bssh --cluster production --stream --no-prefix "uname -a" # Output (no [node] prefixes): # Linux node1 5.15.0-generic # Linux node2 5.15.0-generic
# Save each node's output to timestamped files bssh --cluster production --output-dir ./logs "ps aux" # Creates: # ./logs/node1_20251030_101523.stdout # ./logs/node2_20251030_101523.stdout # ./logs/node1_20251030_101523.stderr (if there are errors)
# Automatically used when output is piped or redirected bssh --cluster production "uptime" | tee results.txt bssh --cluster production "df -h" > disk-usage.log # Manually disable TUI in terminals CI=true bssh --cluster production "command"
bssh provides two modes for handling Ctrl+C during parallel execution:
Default (Two-Stage):
Batch Mode (--batch):
# Default behavior (two-stage Ctrl+C) bssh --cluster production "long-running-command" # Ctrl+C once: shows status # Ctrl+C again (within 1s): terminates # Batch mode (immediate termination) bssh --cluster production --batch "long-running-command" # Ctrl+C once: immediately terminates all jobs # Useful for automation bssh -H nodes --batch --stream "deployment-script.sh"
bssh supports pdsh compatibility mode, enabling it to act as a drop-in replacement for pdsh. This allows seamless migration from pdsh without modifying existing scripts.
📖 Complete Documentation:
1. Binary symlink (recommended for full compatibility):
# Create symlink (done automatically by Homebrew) sudo ln -sf "$(which bssh)" /usr/local/bin/pdsh # Now pdsh commands use bssh pdsh -w host1,host2 "uptime"
2. Environment variable:
BSSH_PDSH_COMPAT=1 bssh -w host1,host2 "uptime"3. CLI flag:
bssh --pdsh-compat -w host1,host2 "uptime"4. Shell alias:
# Add to ~/.bashrc or ~/.zshrc alias pdsh='bssh --pdsh-compat'
| pdsh option | bssh equivalent | Description |
|---|---|---|
-w hosts |
-H hosts |
Target hosts (comma-separated) |
-x hosts |
--exclude hosts |
Exclude hosts from target list |
-f N |
--parallel N |
Fanout (parallel connections, default: 32) |
-l user |
-l user |
Remote username |
-t N |
--connect-timeout N |
Connection timeout in seconds |
-u N |
--timeout N |
Command timeout in seconds |
-N |
--no-prefix |
Disable hostname prefix in output |
-b |
--batch |
Batch mode (single Ctrl+C terminates) |
-k |
--fail-fast |
Stop on first failure |
-q |
(query mode) | Show target hosts and exit |
-S |
--any-failure |
Return largest exit code from any node |
# Basic command execution pdsh -w node1,node2,node3 "uptime" # With fanout limit pdsh -w nodes -f 10 "df -h" # Exclude specific hosts pdsh -w node[1-5] -x node3 "hostname" # Query mode: show target hosts without executing pdsh -w host1,host2,host3 -x host2 -q # Output: # host1 # host3 # Combine multiple options pdsh -w servers -f 20 -l admin -t 30 -N "systemctl status nginx" # Fail fast mode pdsh -w nodes -k "critical-operation.sh"
Query mode (-q) supports glob pattern matching for exclusions:
# Exclude hosts matching a pattern pdsh -w web1,web2,db1,db2 -x "db*" -q # Output: # web1 # web2 # Use wildcards in exclusion pdsh -w node1,node2,backup1,backup2 -x "*backup*" -q # Output: # node1 # node2
# Test connectivity to hosts bssh --cluster production ping bssh -H "host1,host2" ping # Test direct ICMP reachability (alias: nping) bssh --cluster production network-ping bssh -6 -H "host1,host2" network-ping --count 10 --timeout 1 --interval 0.5 # List configured clusters bssh list # Interactive mode (single or multiplexed) bssh --cluster production interactive bssh -H "host1,host2" interactive # File transfer operations bssh --cluster production upload local.txt /tmp/ bssh -H "host1,host2" download /etc/hosts ./backups/
network-ping (alias nping) measures direct ICMP reachability without logging in over SSH. It sends four requests per host by default, waits up to two seconds per reply, spaces requests by at least 0.2 seconds, uses the global --parallel limit, and reports the selected IP plus received/sent, loss, and min/avg/max/population-stddev statistics. --count and --timeout are intentionally long-only because OpenSSH-compatible root -c and -W remain the cipher and stdio-forward options; --interval is long-only.
Host aliases are expanded through ssh_config HostName, and the first resolver-order address allowed by -4, -6, or AddressFamily is probed and shown. ICMP originates on the local machine: ProxyJump, ProxyCommand, SSH authentication, TUI/stream output, and output directories are not used. The command never silently falls back to TCP or HTTP, so success proves only that the selected address replied to ICMP; failure can also mean that ICMP is filtered.
The command prefers unprivileged ICMP datagram sockets. Linux installations may need an appropriate net.ipv4.ping_group_range for the process group or CAP_NET_RAW if datagram sockets are restricted; macOS normally permits ping sockets without elevation. Socket permission failures are reported explicitly. Exit status is 0 when every host answers at least once, 1 for mixed reachability, and 255 when none answers or setup fails; command-line parse errors retain clap's exit status 2.
network-ping(nping)은 SSH 로그인 없이 로컬 머신에서 대상 주소로 ICMP echo를 직접 전송합니다. 기본값은 호스트당 4회, 응답별 제한 시간 2초, 전송 간격 0.2초이며 전역 --parallel 제한을 사용합니다. 선택된 IP, 수신/송신 수, 손실률, min/avg/max/모집단 표준편차를 출력합니다. OpenSSH 호환 루트 -c와 -W는 각각 cipher와 stdio-forward 의미를 유지하므로 요청 횟수와 제한 시간은 긴 옵션 --count, --timeout만 제공합니다.
ssh_config의 HostName 별칭을 적용하고 -4, -6, AddressFamily에 맞는 DNS 결과 중 resolver 순서상 첫 주소를 사용합니다. ProxyJump와 ProxyCommand는 ICMP를 중계하지 않으며 TCP/HTTP로 자동 대체하지 않습니다. 따라서 성공은 선택한 주소의 제한적인 ICMP 응답만 의미하고, 실패는 방화벽의 ICMP 차단 때문일 수도 있습니다. 권한 없이 사용할 수 있는 ICMP 데이터그램 소켓을 우선 사용하며, Linux에서 제한된 경우 프로세스 그룹에 맞는 net.ipv4.ping_group_range 또는 CAP_NET_RAW가 필요할 수 있습니다. macOS에서는 일반적으로 별도의 권한 없이 ping 소켓을 사용할 수 있고, 소켓 권한 오류는 명시적으로 보고합니다. 종료 코드는 전체 응답 0, 일부 응답 1, 전부 미응답 또는 준비 실패 255이며 인자 파싱 오류는 2입니다.
By default, bssh returns the main rank's exit code, matching MPI-oriented
tools such as mpirun, srun, and mpiexec. Choose an explicit strategy
when a workflow must account for every node.
| Strategy | Behavior | Use case |
|---|---|---|
| Default | Return the main rank's actual exit code | MPI workloads and CI/CD |
--require-all-success |
Return 0 only when every node succeeds; otherwise return 1 | Health checks |
--check-all-nodes |
Return the main rank's code, or 1 if the main rank succeeds but another node fails | Cluster validation |
# Preserve the main rank's actual exit status. bssh -H "node[1-8]" "mpirun ./simulation" # Fail the health check if any node fails. bssh --require-all-success -H "node[1-8]" "health-check"
See examples/mpi_exit_code.sh and examples/health_check.sh for detailed examples.
bssh supports multiple authentication methods:
~/.ssh/id_ed25519, ~/.ssh/id_ed25519_sk, ~/.ssh/id_rsa, ~/.ssh/id_ecdsa, ~/.ssh/id_ecdsa_sk, ~/.ssh/id_dsa (the *_sk FIDO keys sign with an attached authenticator through the built-in SecurityKeyProvider internal, or an sk-api library if configured; on Linux the user needs access to the /dev/hidraw* device, usually through the FIDO udev rules of the libfido2 packages; CTAP 2.1 biometric UV tokens are supported, and Windows needs an sk-api library)bssh-keygen -t ed25519-sk or -t ecdsa-sk creates OpenSSH keys using the built-in USB HID provider. Add -O resident -O application=ssh:work -O user=alice for a resident credential, -O verify-required for PIN verification on use, or -O no-touch-required where supported. Download resident keys with bssh-keygen -K into the current directory; this prompts for the authenticator PIN. Select an external OpenSSH sk-api library with -w /path/to/provider.so, or an environment-configured provider with -w '$SSH_SK_PROVIDER'. The key file contains an opaque credential handle; the authenticator is still required for signing. Enrollment supports -O device=PATH and -O challenge=FILE (1 byte–1 MiB). Resident filenames use portable escaping and numeric suffixes to keep duplicate application/user credentials distinct. Attestation-file output is not supported. Built-in resident enrollment requires a PIN and CTAP2 credential management (credMgmt or credentialMgmtPreview) to check for an existing application/user credential. Resident and verify-required enrollment also require credProtect; unsupported authenticators fail explicitly.-i flag to specify a key fileSSH_AUTH_SOCK is set--use-agent to force SSH agent authentication--password to enable password authenticationBSSH_PASSWORD in the environment (not recommended; see security notes in the Sudo Password section)# Use default SSH key (auto-detect) bssh -H "user@host" "uptime" # Use specific SSH key (prompts for passphrase if encrypted) bssh -i ~/.ssh/custom_key --cluster production "df -h" # Use SSH agent bssh --use-agent --cluster production "systemctl status" # Use password authentication bssh --password -H "user@host" "ls -la" # Authentication through jump hosts bssh --use-agent -J bastion.example.com user@internal-server "uptime" bssh -i ~/.ssh/prod_key -J "jump1,jump2" --cluster production "df -h"
bssh supports automatic sudo password injection for commands that require elevated privileges. When enabled, bssh will:
# Basic sudo command (will prompt for sudo password) bssh --sudo-password --cluster production "sudo apt update" # Combine with SSH agent authentication bssh --use-agent --sudo-password --cluster production "sudo systemctl restart nginx" # Multiple sudo commands in a single session bssh --sudo-password --cluster production "sudo apt update && sudo apt upgrade -y" # Sudo with specific SSH key bssh -i ~/.ssh/admin_key --sudo-password --cluster production "sudo reboot"
Environment Variable Alternative:
For automation scenarios, you can use the BSSH_SUDO_PASSWORD environment variable:
# NOT RECOMMENDED for security reasons export BSSH_SUDO_PASSWORD="your-password" bssh --sudo-password --cluster production "sudo apt update"
Security Warnings:
--sudo-password option with secure prompt is the recommended approachzeroizebssh supports configuration via environment variables:
BSSH_MAX_JUMP_HOSTS: Maximum number of jump hosts allowed in a chain
BSSH_MAX_JUMP_HOSTS=20 bssh -J host1,host2,...,host20 targetBACKENDAI_CLUSTER_HOSTS: Comma-separated list of all cluster nodesBACKENDAI_CLUSTER_HOST: Current node hostnameBACKENDAI_CLUSTER_ROLE: Node role (main/sub)SSH_AUTH_SOCK: SSH agent socket path (Unix-like systems)BSSH_PASSWORD: SSH password for automated password authentication
--password is set and BSSH_PASSWORD is non-empty; skips the interactive prompt--password prompt instead for security-sensitive operationsBSSH_PASSWORD=secret bssh --password -H "user@host" "uptime"BSSH_SUDO_PASSWORD: Sudo password for automated sudo authentication
--sudo-password option with secure prompt insteadBSSH_SUDO_PASSWORD=password bssh --sudo-password --cluster prod "sudo apt update"bssh loads configuration from the following sources in priority order:
./config.yaml)$XDG_CONFIG_HOME/bssh/config.yaml or ~/.config/bssh/config.yaml)--config flag, default: ~/.config/bssh/config.yaml)When running inside a Backend.AI multi-node session, bssh automatically detects cluster configuration from environment variables. No manual configuration or cluster specification needed!
Backend.AI environment variables used:
BACKENDAI_CLUSTER_HOSTS: Comma-separated list of all node hostnamesBACKENDAI_CLUSTER_HOST: Current node's hostnameBACKENDAI_CLUSTER_ROLE: Current node's role (main or sub)Note: Backend.AI multi-node clusters use SSH port 2200 by default, which is automatically configured.
Automatic Detection:
When these environment variables are set, bssh automatically creates a "backendai" cluster and uses it by default when no -c or -H options are specified.
Example:
# Inside Backend.AI multi-node session, just run: bssh "uptime" # Automatically executes on all cluster nodes # Or specify a command explicitly: bssh "nvidia-smi" # Check GPU status on all nodes # Interactive mode also works automatically: bssh interactive # Opens interactive session with all Backend.AI nodes # You can still override with explicit options if needed: bssh --cluster other-cluster "command" # Use a different cluster bssh -H specific-host "command" # Use specific host
Create a configuration file at any of these locations:
./config.yaml (current directory)~/.config/bssh/config.yaml (user config directory)~/.bssh/config.yaml (default location)defaults: user: admin port: 22 ssh_key: ~/.ssh/id_rsa parallel: 10 timeout: 300 # Command timeout in seconds (0 for unlimited) jump_host: bastion.example.com # Global default jump host (optional) server_alive_interval: 30 # SSH keepalive interval in seconds (0 to disable) server_alive_count_max: 3 # Max keepalive messages without response # Global interactive mode settings (optional) interactive: default_mode: multiplex # single_node or multiplex prompt_format: "[{node}] $ " # Variables: {node}, {user}, {host}, {pwd} history_file: ~/.bssh_history show_timestamps: false # Show timestamps in output work_dir: /home/admin # Initial working directory broadcast_prefix: "!all " # Prefix for broadcasting to all nodes node_switch_prefix: "!" # Prefix for special commands colors: # Node-specific colors in output node1: red node2: blue node3: green keybindings: switch_node: "Ctrl+N" broadcast_toggle: "Ctrl+B" quit: "Ctrl+Q" clusters: production: nodes: - web1.example.com - web2.example.com - user@web3.example.com:2222 ssh_key: ~/.ssh/prod_key timeout: 600 # Override default timeout for this cluster jump_host: prod-bastion.example.com # Cluster-specific jump host # Cluster-specific interactive settings (overrides global) interactive: default_mode: single_node prompt_format: "prod> " work_dir: /var/www staging: nodes: - host: staging1.example.com port: 2200 user: deploy jump_host: staging-bastion:2222 # Node-specific jump host - staging2.example.com user: staging_user jump_host: "" # Explicitly disable jump host for this cluster
bssh supports configuring jump hosts at three levels in your configuration file, with environment variable support:
Priority Order (highest to lowest):
-J option - Always takes precedencejump_host in detailed node configjump_host in cluster defaultsjump_host in top-level defaultsExample:
defaults: jump_host: ${BASTION_HOST} # Environment variables supported clusters: production: nodes: - host: prod1.internal - host: prod2.internal jump_host: "" # Explicitly disable for this node jump_host: prod-bastion.example.com direct-access: nodes: - host: direct.example.com jump_host: "" # Empty string disables inheritance
Notes:
"") explicitly disables jump host inheritance at any level${VAR} or $VAR) are expanded in jump_host valuesImportant: Username Handling
The user field in config applies only to destination nodes, not to jump hosts:
clusters: internal: nodes: - 192.168.0.100 user: admin # Used for destination (192.168.0.100) jump_host: bai@bastion # User 'bai' for bastion (jump host)
bai@bastion:4300 → uses "bai" for bastionbastion:4300 → uses your current local username (like OpenSSH)If jump host authentication fails due to username mismatch, specify the username explicitly in the jump_host field.
bssh reads OpenSSH-style configuration through -F or the default locations (~/.ssh/config, /etc/ssh/ssh_config), including certificate authentication and forwarding directives. Runtime support is tracked per keyword; accepted but unimplemented directives emit explicit warnings. See the compatibility status ledger for remaining semantic and protocol gaps.
These options enable enterprise-grade PKI authentication using SSH certificates:
| Option | Description | Example |
|---|---|---|
| CertificateFile | SSH certificate file for PKI authentication (max 100 files) | CertificateFile ~/.ssh/id_rsa-cert.pub |
| CASignatureAlgorithms | CA signature algorithms for certificate validation (max 50) | CASignatureAlgorithms ssh-ed25519,rsa-sha2-512 |
| HostbasedAuthentication | Enable host-based authentication (yes/no) | HostbasedAuthentication yes |
| HostbasedAcceptedAlgorithms | Algorithms for host-based auth (max 50) | HostbasedAcceptedAlgorithms ssh-ed25519,rsa-sha2-512 |
These options provide fine-grained control over SSH port forwarding:
| Option | Description | Example |
|---|---|---|
| GatewayPorts | Control remote port forwarding (yes/no/clientspecified) | GatewayPorts clientspecified |
| ExitOnForwardFailure | Terminate connection if port forwarding fails (yes/no) | ExitOnForwardFailure yes |
| PermitRemoteOpen | Allowed destinations for remote forwarding (max 1000) | PermitRemoteOpen localhost:8080 |
These options control SSH proxy connection behavior:
| Option | Description | Example |
|---|---|---|
| ProxyCommand | Run a shell command whose stdin/stdout carry the SSH transport; supports %%, %h, %k, %n, %p, and %r |
ProxyCommand nc %h %p |
| ProxyUseFdpass | Request descriptor passing from ProxyCommand (recognized but not supported by bssh) | ProxyUseFdpass no |
ProxyCommand uses the user's shell so OpenSSH-style quoting, redirection, and pipelines work. ProxyCommand none explicitly selects a direct connection. ProxyCommand and ProxyJump follow OpenSSH's first-obtained ssh_config rule, while command-line -J takes precedence over both.
Endpoint data for %h, %n, %r, and %k is checked before starting any ProxyCommand, including data from CLI arguments, YAML inventory, environment expansion, and library callers. Only values actually substituted into the command are checked; unused fields and escaped literal tokens such as %%h are unrestricted. Substituted values must be nonempty and contain only ASCII letters, digits, ., _, :, @, or -, with no leading -. Whitespace, shell substitutions, wildcards, quotes, and non-ASCII characters are rejected even when the template quotes the token. Use ASCII/punycode names and unbracketed IPv6 literals; scoped IPv6 (%zone) and raw bracketed literals are unsupported at this boundary. Normal aliases and authored quoting, redirection, and pipelines continue to work. ProxyCommand templates (including nested shells or eval) remain trusted executable code; endpoint data must never be used as code deliberately by a template.
%h, %n, %r, %k의 값은 CLI, YAML, 환경 변수 및 라이브러리 입력 경로 모두에서 ProxyCommand 실행 전에 검증됩니다. 실제로 치환되는 값만 검증하며 사용하지 않는 필드와 %%h 같은 리터럴 토큰은 제한하지 않습니다. 비어 있지 않은 ASCII 영문자·숫자와 ., _, :, @, -만 허용하며 첫 문자는 -일 수 없습니다. 공백, 셸 치환, 와일드카드 및 비ASCII 문자는 따옴표 안에서도 거부됩니다. IPv6는 대괄호와 영역 식별자 없이 사용하고 국제화 호스트명은 punycode를 사용하세요. 별칭과 명령에 직접 작성한 인용·리다이렉션·파이프라인은 계속 지원됩니다. 명령 템플릿 자체는 신뢰할 수 있는 코드여야 합니다.
Note: ProxyUseFdpass yes is rejected with an actionable error before the command starts. Use a streaming ProxyCommand without -F, or set ProxyUseFdpass no.
These options enable powerful automation workflows and command execution features:
| Option | Description | Example |
|---|---|---|
| PermitLocalCommand | Allow local command execution after connection (yes/no, default: no) | PermitLocalCommand yes |
| LocalCommand | Execute local command after successful connection (supports tokens: %h, %H, %n, %p, %r, %u) | LocalCommand rsync -av ~/project/ %h:~/project/ |
| RemoteCommand | Execute command on remote host instead of shell | RemoteCommand tmux attach -t dev || tmux new -s dev |
| KnownHostsCommand | Command to fetch host keys dynamically (supports tokens) | KnownHostsCommand /usr/local/bin/fetch-host-key %H |
| ForkAfterAuthentication | Fork to background after authentication (yes/no) | ForkAfterAuthentication yes |
| SessionType | Session type: none/subsystem/default | SessionType none |
| StdinNull | Redirect stdin from /dev/null (yes/no) | StdinNull yes |
Token Substitution: LocalCommand and KnownHostsCommand support the following tokens:
%h - Remote hostname (from config)%H - Remote hostname (as specified on command line)%n - Original hostname%p - Remote port%r - Remote username%u - Local username%% - Literal percent signThese options provide enhanced security and host key management features:
| Option | Description | Example |
|---|---|---|
| NoHostAuthenticationForLocalhost | Skip host key verification for localhost (yes/no, default: no) | NoHostAuthenticationForLocalhost yes |
| HashKnownHosts | Hash hostnames in known_hosts file for security (yes/no, default: no) | HashKnownHosts yes |
| CheckHostIP | Check host IP address in known_hosts (yes/no, deprecated in OpenSSH 8.5+) | CheckHostIP no |
| VisualHostKey | Display ASCII art of host key fingerprint (yes/no, default: no) | VisualHostKey yes |
| HostKeyAlias | Alias for host key lookup in known_hosts | HostKeyAlias lb.example.com |
| VerifyHostKeyDNS | Verify host keys using DNS SSHFP records (yes/no/ask, default: no) | VerifyHostKeyDNS ask |
| UpdateHostKeys | Accept updated host keys from server (yes/no/ask, default: no) | UpdateHostKeys ask |
These options provide fine-grained control over authentication behavior:
| Option | Description | Example |
|---|---|---|
| NumberOfPasswordPrompts | Password retry attempts (1-10, default: 3) | NumberOfPasswordPrompts 1 |
| EnableSSHKeysign | Enable ssh-keysign for host-based auth (yes/no, default: no) | EnableSSHKeysign yes |
These options control network-level connection behavior:
| Option | Description | Example |
|---|---|---|
| BindInterface | Bind connection to specific network interface | BindInterface tun0 |
| IPQoS | Set IP QoS/DSCP values (interactive bulk) | IPQoS lowdelay throughput |
| RekeyLimit | Control SSH session key renegotiation (data time) | RekeyLimit 1G 1h |
These options control X11 display forwarding behavior:
| Option | Description | Example |
|---|---|---|
| ForwardX11Timeout | Timeout for untrusted X11 forwarding (0 = no timeout) | ForwardX11Timeout 1h |
| ForwardX11Trusted | Enable trusted X11 forwarding (yes/no, default: no) | ForwardX11Trusted yes |
These options provide essential authentication management, security enforcement, and user convenience features:
| Option | Description | Example |
|---|---|---|
| IdentitiesOnly | Only use identity files specified in config, ignore SSH agent (yes/no) | IdentitiesOnly yes |
| AddKeysToAgent | Auto-add keys to SSH agent (yes/no/ask/confirm) | AddKeysToAgent yes |
| UseKeychain | [macOS only] Use macOS Keychain for SSH key passphrases (yes/no) | UseKeychain yes |
| IdentityAgent | Custom SSH agent socket path or "none" | IdentityAgent ~/.1password/agent.sock |
| PubkeyAcceptedAlgorithms | Restrict allowed public key algorithms (max 50) | PubkeyAcceptedAlgorithms ssh-ed25519,rsa-sha2-512 |
| RequiredRSASize | Minimum RSA key size in bits (1024-16384, warns <2048) | RequiredRSASize 2048 |
| FingerprintHash | Fingerprint hash algorithm (md5/sha256) | FingerprintHash sha256 |
Key Benefits:
Platform Notes:
bssh-ssh-key-passphrase Keychain service. Apple's /usr/bin/ssh uses an entitlement-protected access group, so entries created by ssh-add --apple-use-keychain cannot be read directly by third-party binaries and the first bssh connection may still prompt once.IgnoreUnknown UseKeychain to prevent errors on non-macOS systems# ~/.ssh/config # Production servers with certificate authentication Host *.prod.example.com User admin CertificateFile ~/.ssh/prod-user-cert.pub CertificateFile ~/.ssh/prod-host-cert.pub CASignatureAlgorithms ssh-ed25519,rsa-sha2-512,rsa-sha2-256 HostbasedAuthentication yes HostbasedAcceptedAlgorithms ssh-ed25519,rsa-sha2-512
# Secure hosts with restricted port forwarding Host *.secure.prod.example.com GatewayPorts clientspecified ExitOnForwardFailure yes PermitRemoteOpen localhost:8080 PermitRemoteOpen db.internal:5432 PermitRemoteOpen cache.internal:6379
# HTTP CONNECT proxy Host internal-server ProxyCommand nc -X connect -x proxy.example.com:1080 %h %p # SOCKS proxy with netcat Host *.internal.example.com ProxyCommand nc -x socks.example.com:1080 %h %p
# Development server with automatic file synchronization Host dev-server User developer PermitLocalCommand yes LocalCommand rsync -av ~/project/ %h:~/project/ # Auto-attach to tmux session on connection Host project-server RemoteCommand tmux attach -t project || tmux new -s project RequestTTY yes # Cloud instances with dynamic host key fetching Host *.cloud.example.com KnownHostsCommand /usr/local/bin/fetch-cloud-key %H StrictHostKeyChecking accept-new # Background SSH tunnel for port forwarding Host tunnel ForkAfterAuthentication yes SessionType none LocalForward 8080 internal-server:80 StdinNull yes
# Local development environment - skip localhost verification Host localhost 127.0.0.1 ::1 NoHostAuthenticationForLocalhost yes NumberOfPasswordPrompts 1 # Security-hardened configuration with host key protection Host *.secure.example.com HashKnownHosts yes VisualHostKey yes VerifyHostKeyDNS ask UpdateHostKeys ask CheckHostIP no # Load-balanced service with shared host key Host lb-node-* HostKeyAlias lb.example.com # Multi-homed host with specific interface binding Host vpn-only BindInterface tun0 IPQoS lowdelay throughput # High-security session with frequent rekeying Host sensitive-data RekeyLimit 500M 30m # X11 forwarding with timeout and trust for graphics workstation Host graphics-workstation ForwardX11 yes ForwardX11Trusted yes ForwardX11Timeout 2h
# Multi-account setup - prevent agent key conflicts Host work HostName work.example.com IdentityFile ~/.ssh/work_rsa IdentitiesOnly yes Host personal HostName github.com User git IdentityFile ~/.ssh/personal_ed25519 IdentitiesOnly yes # Auto-add keys to SSH agent for convenience Host * AddKeysToAgent yes # macOS-specific: Use Keychain for SSH key passphrases # For cross-platform configs, add IgnoreUnknown to prevent errors on non-macOS systems Host * IgnoreUnknown UseKeychain UseKeychain yes # Custom SSH agent integration (1Password, gpg-agent) Host secure-* IdentityAgent ~/.1password/agent.sock # Disable SSH agent for specific hosts Host no-agent-host IdentityAgent none # Security-hardened production servers Host *.prod.example.com # Only allow modern, secure algorithms PubkeyAcceptedAlgorithms ssh-ed25519,rsa-sha2-512,rsa-sha2-256 # Enforce strong RSA keys RequiredRSASize 2048 # Use modern fingerprint hashing FingerprintHash sha256 # Legacy system compatibility Host legacy.example.com # Allow older RSA keys RequiredRSASize 1024 # Use MD5 for legacy fingerprint verification FingerprintHash md5
# Base security settings Host * HostbasedAuthentication no ExitOnForwardFailure no PermitLocalCommand no # Production certificate configuration Host *.prod.example.com CertificateFile ~/.ssh/prod-cert.pub CASignatureAlgorithms ssh-ed25519,rsa-sha2-512 HostbasedAuthentication yes # Match directive for secure hosts Match host *.secure.prod.example.com GatewayPorts clientspecified ExitOnForwardFailure yes PermitRemoteOpen localhost:8080 # Development hosts with automation Match host *.dev.example.com PermitLocalCommand yes LocalCommand notify-send "Connected to %h" # Specific host overrides Host web.secure.prod.example.com User webadmin Port 443 CertificateFile ~/.ssh/web-specific-cert.pub
# Use default SSH config (~/.ssh/config) bssh user@host.prod.example.com # Use custom SSH config file bssh -F ~/custom-ssh-config user@host.prod.example.com # SSH config works with cluster operations bssh --cluster production "uptime" # Config options apply to all cluster nodes bssh -F ~/.ssh/prod-config --cluster production upload app.tar.gz /opt/
Options:
-H, --hosts <HOSTS> Comma-separated list of hosts (user@host:port format)
-C Enable SSH compression
-f Go to background after authentication
--cluster <CLUSTER> Cluster name from configuration file
--filter <PATTERN> Filter hosts by pattern (supports wildcards like 'web*')
--exclude <HOSTS> Exclude hosts from target list (comma-separated, supports wildcards)
--config <CONFIG> Configuration file path [default: ~/.config/bssh/config.yaml]
-u, --user <USER> Default username for SSH connections
-i, --identity <IDENTITY> SSH private key file path (prompts for passphrase if encrypted)
-A Enable authentication-agent forwarding
--use-agent Use SSH agent for authentication (Unix/Linux/macOS only)
--password Use password authentication (will prompt for password)
-S <CONTROL_PATH> Multiplexing control socket path
--sudo-password Prompt for sudo password to auto-respond to sudo prompts
-N Do not execute a remote command
-k Disable GSSAPI credential delegation
-b <BIND_ADDRESS> Bind to a local source address
-J, --jump-host <JUMP_HOSTS> Jump hosts: [user@]host[:port],... (uses local user if not specified)
-L, --local-forward <SPEC> Local port forwarding [bind_address:]port:host:hostport
-R, --remote-forward <SPEC> Remote port forwarding [bind_address:]port:host:hostport
-D, --dynamic-forward <SPEC> Dynamic port forwarding (SOCKS) [bind_address:]port[/version]
--strict-host-key-checking <MODE> Host key checking mode (yes/no/accept-new) [default: accept-new]
--parallel <PARALLEL> Maximum parallel connections [default: 10]
--timeout <TIMEOUT> Command timeout in seconds (0 for unlimited) [default: 300]
--connect-timeout <SECONDS> SSH connection timeout in seconds (minimum: 1) [default: 30]
--server-alive-interval <SECONDS> SSH keepalive interval in seconds (0 to disable) [default: 30]
--server-alive-count-max <COUNT> Max keepalive messages without response [default: 3]
--output-dir <OUTPUT_DIR> Output directory for command results
--no-prefix Disable hostname prefix in output
--fail-fast Stop on the first failed node
--batch Terminate all jobs on the first Ctrl+C
-v, --verbose Increase verbosity (-v, -vv, -vvv)
-h, --help Print help
-V, --version Print version
# Inside Backend.AI session - automatic cluster detection bssh "hostname" # Shows hostnames of all nodes bssh "nvidia-smi --query-gpu=name,memory.total --format=csv" # GPU info bssh "python train.py --distributed" # Run distributed training
bssh --cluster production "sudo apt update && sudo apt upgrade -y"bssh -H "server1,server2,server3" "df -h | grep -E '^/dev/'"
bssh --cluster webservers "sudo systemctl restart nginx"bssh --cluster production --output-dir ./logs "tail -n 100 /var/log/syslog"# Set 30 minute timeout for backup operations bssh --cluster production --timeout 1800 "backup-database.sh" # No timeout for data migration (may take hours) bssh --cluster production --timeout 0 "migrate-data.sh" # Quick health check with 5 second timeout bssh --cluster monitoring --timeout 5 "health-check.sh"
Start an interactive shell session on cluster nodes:
# Interactive session on all nodes (multiplex mode - default) bssh --cluster production interactive # Interactive session on a single node bssh --cluster production interactive --single-node # Custom prompt format bssh -H server1,server2 interactive --prompt-format "{user}@{host}> " # Set initial working directory bssh --cluster staging interactive --work-dir /var/www # Interactive mode with keepalive for long-running sessions (e.g., tmux) bssh --cluster production --server-alive-interval 30 --server-alive-count-max 5 interactive
Interactive mode can be configured in your config.yaml file with both global and per-cluster settings. CLI arguments always override configuration file settings.
Global Configuration (applies to all clusters unless overridden):
interactive: default_mode: multiplex # or single_node prompt_format: "[{node}] $ " history_file: ~/.bssh_history show_timestamps: true # Add timestamps to output work_dir: /home/user broadcast_prefix: "!all " # Custom prefix for broadcast commands node_switch_prefix: "!" # Custom prefix for special commands
Per-Cluster Configuration (overrides global settings):
clusters: production: interactive: default_mode: single_node # Different mode for this cluster prompt_format: "PROD> " work_dir: /var/app
Configuration Priority:
In multiplex mode, commands are sent to active nodes with visual indicators:
[● ● ●] bssh> uptime
[node1] 10:23:45 up 5 days, 2:14, 1 user, load average: 0.15, 0.12, 0.09
[node2] 10:23:45 up 3 days, 4:22, 2 users, load average: 0.23, 0.19, 0.17
[node3] 10:23:45 up 7 days, 1:45, 1 user, load average: 0.08, 0.11, 0.10
[● ● ●] bssh> exit
Interactive mode supports special commands for node management. By default, these commands start with ! but the prefix can be customized in the configuration file.
| Command | Description |
|---|---|
!all |
Activate all connected nodes |
!broadcast <cmd> |
Execute command on all nodes temporarily (without changing active nodes) |
!node<N> or !n<N> |
Switch to node N (e.g., !node1, !n2) |
!list or !nodes |
List all nodes with their connection status |
!status |
Show currently active nodes |
!help or !? |
Show help for special commands |
exit |
Exit interactive mode |
Note: The ! prefix and !broadcast command can be customized via configuration:
interactive: node_switch_prefix: "@" # Use @ instead of ! broadcast_prefix: "@all " # Use @all instead of !broadcast
The prompt shows node status with visual indicators:
● Active node (commands will be executed)○ Inactive node (connected but not receiving commands)· Disconnected nodeExamples:
[● ● ●] bssh> - All 3 nodes active[● ○ ○] bssh> - Only first node active[1 · ·] (1/3) bssh> - Node 1 active, nodes 2 and 3 inactiveFor large clusters (>10 nodes), the prompt uses a compact format:
[All 50/50] bssh> - All 50 nodes active[None 0/50] bssh> - No nodes active[Nodes 1,2,3... +47] (50/50) bssh> - Specific nodes active$ bssh --cluster production interactive Connected to 3 nodes [● ● ●] bssh> !status Active nodes: node1.example.com, node2.example.com, node3.example.com [● ● ●] bssh> !node1 Switched to node 1 [● ○ ○] (1/3) bssh> hostname [node1] node1.example.com [● ○ ○] (1/3) bssh> !broadcast date Broadcasting command to all connected nodes... [node1] Thu Aug 22 10:30:00 UTC 2025 [node2] Thu Aug 22 10:30:00 UTC 2025 [node3] Thu Aug 22 10:30:00 UTC 2025 [● ○ ○] (1/3) bssh> !all All nodes activated [● ● ●] bssh> df -h / [node1] Filesystem Size Used Avail Use% Mounted on [node1] /dev/sda1 20G 5.5G 14G 30% / [node2] Filesystem Size Used Avail Use% Mounted on [node2] /dev/sda1 20G 7.2G 12G 38% / [node3] Filesystem Size Used Avail Use% Mounted on [node3] /dev/sda1 20G 4.1G 15G 22% / [● ● ●] bssh> exit Goodbye!
When using the --output-dir option, bssh saves command outputs to structured files:
lablup/bssh is a public repo on GitHub by lablup. A high-performance parallel SSH command execution tool for cluster management.
It declares the Apache-2.0 license on GitHub.
Its maker has not tagged a system, so it is unknown here. Its README says what it needs.
Open "Take it" on its page: Take My Repo writes an install plan for your machine and hands it to your AI agent (Claude Code, Codex or Cursor), which asks you before each step. Take My Repo has not tested it on any machine.
Its last change on GitHub was on 2026-11-19. Take My Repo does not judge from that whether it is maintained.
Nobody has reviewed it on Take My Repo yet, which says nothing about its quality.
Reverse engineer anything with agents, from app behavior down to native binaries.
Linux命令大全搜索工具,内容包含Linux命令手册、详解、学习、搜集。https://git.io/linux

The agent harness performance optimization system. Skills, instincts, memory, security, and research-first development for Claude Code, Codex, Opencode, Cursor and beyond.
Fair-code workflow automation platform with native AI capabilities. Combine visual building with custom code, self-host or cloud, 400+ integrations.

一款轻量级、高性能、功能强大的内网穿透代理服务器。支持tcp、udp、socks5、http等几乎所有流量转发,可用来访问内网网站、本地支付接口调试、ssh访问、远程桌面,内网dns解析、内网socks5代理等等……,并带有功能强大的web管理端。a lightweight, high-performance, powerful intranet penetration proxy server, with a powerful web management terminal.
Makes your AI agent think like the laziest senior dev in the room. The best code is the code you never wrote.
Backend.AI is a streamlined, container-based computing cluster platform that hosts popular computing/ML frameworks and diverse programming languages, with pluggable heterogeneous accelerator support including CUDA GPU, ROCm GPU, Gaudi NPU, Google TPU, GraphCore IPU and other NPUs.
High-performance LLM, VLM, embedding, reranking, and audio inference for Apple Silicon, NVIDIA CUDA and AMD ROCm systems.

Backend.AI Web UI for web / desktop app (Windows/Linux/macOS). Backend.AI Web UI provides a convenient environment for users, while allowing various commands to be executed without CLI. It also provides some visual features that are not provided by the CLI, such as dashboards and statistics.
Repository of Backend.AI-enabled container recipes
This page is also available as structured data, with the same sources and dates.
/api/v1/resources/gh/lablup/bsshTake My Repo has not tested this on your machine. Requirements come from the project's own documentation.