Comments (4)
Hello Youssef !
Fpsync starts ssh commands in the background through a non-interactive shell, thus stdin is redirected from /dev/null (at least on FreeBSD) and I don't know how sshpass can cope with that. The best way to connect passwordless is probably to use a ssh key (playing with a ssh_config(5) file) but if you want to try to hack around ssh calls, check the SSH_BIN variable (https://github.com/martymac/fpart/blob/master/tools/fpsync#L1104). You may want to initialize it with sshpass instead of ssh and add a SSH_OPTS variable. Something like :
SSH_BIN="$(command -v sshpass)"
SSH_OPTS="$(command -v ssh)"
and then add ${SSH_OPTS} to ${SSH_BIN} calls later in the code.
Tell me how it goes, those two variables could become new options to fpsync :)
from fpart.
Hello @martymac, thank you for the quick reply. Just to be clear about my use case, I'm not trying to use sshpass for Fpsync SSH workers. I'm trying to use it only for the SSH session of Rsync itself.
I'll mess around with the script and see how things goes, and report back.
from fpart.
@martymac I've managed to make it work as I wanted
- create a simple shell script rsync.sh
#!/usr/bin/env bash
sshpass -e rsync "$@"
- run fpsync like this:
SSHPASS=somepassword fpsync -n 4 -f 3 -T /path/to/rsync.sh src/ server:dst/
from fpart.
Wow, perfect ! And thanks for your feedback :)
Cheers,
Ganael.
from fpart.
Related Issues (20)
- Throttle fpsync transfer rate HOT 1
- Add multi-thread support while crawling the file system HOT 3
- Single files support HOT 5
- fpart: incomplete partitions on sshfs HOT 9
- Meaning of 0th partition file in different modes is confusing HOT 23
- Format change for '-S' output HOT 7
- sorting with mathematical function HOT 1
- Problem running fpsync with GNU parallel or in background from the shell, the process will go in STOP state HOT 11
- fpart/fsync is slowly when reading files names from S3 or similiar object file system HOT 1
- Status / percentage complete / progress bar? HOT 1
- Sub-directories and files are not getting copied to the destination HOT 8
- fpsync status/progress reporting does not work correctly HOT 4
- fpsync does not provide a way to specify number of file parts HOT 4
- How to sync local directory to a remote directory by fpsync HOT 1
- fpsync: job control error running under cron HOT 3
- How to burn the partition content to DVD / Blu-ray? HOT 1
- How can I create partitions respecting the directory name in alphabatical order? HOT 1
- Incompatible option(s) detected within toolopts (option -o) HOT 1
- having issues with excluding directories or files, macOS HOT 8
Recommend Projects
-
React
A declarative, efficient, and flexible JavaScript library for building user interfaces.
-
Vue.js
🖖 Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.
-
Typescript
TypeScript is a superset of JavaScript that compiles to clean JavaScript output.
-
TensorFlow
An Open Source Machine Learning Framework for Everyone
-
Django
The Web framework for perfectionists with deadlines.
-
Laravel
A PHP framework for web artisans
-
D3
Bring data to life with SVG, Canvas and HTML. 📊📈🎉
-
Recommend Topics
-
javascript
JavaScript (JS) is a lightweight interpreted programming language with first-class functions.
-
web
Some thing interesting about web. New door for the world.
-
server
A server is a program made to process requests and deliver data to clients.
-
Machine learning
Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.
-
Visualization
Some thing interesting about visualization, use data art
-
Game
Some thing interesting about game, make everyone happy.
Recommend Org
-
Facebook
We are working to build community through open source technology. NB: members must have two-factor auth.
-
Microsoft
Open source projects and samples from Microsoft.
-
Google
Google ❤️ Open Source for everyone.
-
Alibaba
Alibaba Open Source for everyone
-
D3
Data-Driven Documents codes.
-
Tencent
China tencent open source team.
from fpart.