Rsync parity: remote shell and connection options #130

Closed
opened 2026-07-21 16:24:05 +02:00 by TapTap · 0 comments
Owner

FastSync supports SSH/TCP auto-detection. Rsync offers several connection flags:

Missing flags

  • -e, --rsh <COMMAND> — specify remote shell (e.g. --rsh='ssh -p 2222 -i key')
  • --rsync-path <PATH> — path to fastsync-server on remote
  • --blocking-io / --no-blocking-io
  • --sockopts <OPTS> — custom TCP options
  • --address <ADDRESS> — bind address for outgoing connections
  • -4, --ipv4 — prefer IPv4
  • -6, --ipv6 — prefer IPv6
  • --password-file <FILE> — read daemon password from file

Current code

  • transport_ssh.c — hardcoded SSH command construction
  • transport_tcp.c — getaddrinfo with AF_UNSPEC
  • config.h — no fields for custom SSH/rsh/address/ipv4/6

Impact

  • --rsh: users need custom SSH ports, keys, jump hosts
  • --rsync-path: binary not in remote $PATH
  • --address/--ipv4/--ipv6: multi-homed hosts or IPv6-only networks

Implementation notes

  • --rsh: replace hardcoded SSH with user command template
  • --rsync-path: prepend to SSH remote argument
  • --ipv4/--ipv6: set ai_family in getaddrinfo
  • --sockopts: parse key=value, call setsockopt
FastSync supports SSH/TCP auto-detection. Rsync offers several connection flags: ## Missing flags - `-e, --rsh <COMMAND>` — specify remote shell (e.g. --rsh='ssh -p 2222 -i key') - `--rsync-path <PATH>` — path to fastsync-server on remote - `--blocking-io` / `--no-blocking-io` - `--sockopts <OPTS>` — custom TCP options - `--address <ADDRESS>` — bind address for outgoing connections - `-4, --ipv4` — prefer IPv4 - `-6, --ipv6` — prefer IPv6 - `--password-file <FILE>` — read daemon password from file ## Current code - `transport_ssh.c` — hardcoded SSH command construction - `transport_tcp.c` — getaddrinfo with AF_UNSPEC - `config.h` — no fields for custom SSH/rsh/address/ipv4/6 ## Impact - `--rsh`: users need custom SSH ports, keys, jump hosts - `--rsync-path`: binary not in remote $PATH - `--address`/`--ipv4`/`--ipv6`: multi-homed hosts or IPv6-only networks ## Implementation notes - `--rsh`: replace hardcoded SSH with user command template - `--rsync-path`: prepend to SSH remote argument - `--ipv4`/`--ipv6`: set ai_family in getaddrinfo - `--sockopts`: parse key=value, call setsockopt
Sign in to join this conversation.
1 Participants
Notifications
Due Date
No due date set.
Dependencies

No dependencies set.

Reference: TapTap/FastSync#130