lftp -u user, password -p 2121 -e 'set net:timeout 10; set net:reconnect-interval-base 1; set net:max-retries 1; mirror -R --use-pget-n=10 -v -c /home/[username]/files/sync/. /' {$v[ip]}
I have a script that grabs the ip of everything connected to the network and attempts to push a file to it. There will be things on the network that won't allow a connection. There's no way to know in advance what will be on the network and what wont, and I need to find a way for lftp to not hang on a failed connection so the script can move into the next ip/hostname.