A bbftpPRO Practical Networking Guide
This guide is written from the perspective of an xsync.perl user who would want to know how to alter defaults.
xsync does a fast "rsync -auv" kind of transfer and it has therefore two mandatory parameters, firstly the source and secondly the destination, both with syntax ‹user›@‹host›:‹path›.
Only the ‹path› part is required, the others default to current user and localhost respectively.
Both source and destination ‹user› and/or ‹host› can be different (and from the current user or localhost), meaning that third-party transfers between two remote hosts are allowed.
With no extra switches appended, xsync assumes authentication against permanently running bbftpPRO servers that listen for control connections on port 5021, a default number of parallel data streams (25), and no verbosity.
Here is a non-exhaustive list of bbftpPRO switches that could be appended at the end, with various effects:
- "-V", "-W" to increase verbosity; "-V" is recommended.
- "-p ‹# of data streams›", e.g. "-p 8", to use a desired number of data streams, no more than 255, as long as bbftpPRO's server upper limit is not exceeded.
At start-up, server's default (25) can be reset with switch "-m ‹# of data streams›", e.g. "-m 50".
Note that in order to really go overboard here, you might need to increase kernel.shmmax in /etc/sysctl.conf, e.g. "kernel.shmmax=67108864", at both client and server sides.
- "-s" to exchange authentication with an ad hoc remotely ssh spawned bbftpPRO server.
The eventual permanent server is ignored and a new bbftpPRO server will be started by the client.
No port collision will happen because the new server listens by default on port 5022.
To fully control the new server initialization, affix its desired start-up line to switch "-s", with no white space in between, e.g. -s\"bin/bbftpd -s -e -m 50 -l information\"
- "-D" to set the bbftpPRO client in passive mode, i.e. as listener for data connections.
A range of ports can be specified, regardless of the actual number of data streams, by affixing it with no white space in between to switch "-D", e.g. "-D4000:4100".
Note that a single port can be specified, e.g. "-D4000:4000".
- For pre lite+ versions, -a ‹IP address or name› should be used with switches -s and -D in case of a client host behind a NAT router or multihomed, in order to specify its public name or IP address, e.g. "-s -D4000:4000 -a 64.236.29.120".
- With the lite+ version, switch -a has been removed and replaced with switch
-n ‹NAT-name-or-address›, at either the client or/and the server command line,
to let the data connection listening side to advertise its (public) name.
- "-g" to change authentication to GSI instead of default RSA; could be affixed with a service name, again with no white space in between.
- "-h" to trigger (RC4) encryption of transferred data.
- "-c" to (gzip) compress the transferred data.
A special significance, for a client that spawns (via ssh) its own bbftpPRO server or for the launcher of the system-wide permanent bbftpPRO server, has server switch "-e".
If used, it sets a range of data ports a server listens for data connections in the default client active mode, e.g. "-e3900:3950".
The range could be a single port, e.g. "-e3900:3900", different from the control port number, or even the same port used for control connections, in which case no range has to be affixed, e.g. "-e".
Both server switch "-e" and similarly, client switch "-D", make bbftpPRO firewall friendly.
Note that both the ssh spawned and the permanent bbftpPRO server can authenticate clients based on pairs of public and private RSA keys, the very same used by the normal ssh mechanism. The key format should be legacy PEM, though! (ssh-keygen -t rsa -m PEM). This facilitates processing without password typing-in (provided that the passphrase is also omitted).
Finally, fine tuning of send/receive buffers can be done by editing into file ~/.bbftprc the commands "setsendwinsize", "setrecvwinsize" and "setbuffersize", e.g. "setsendwinsize 32; setrecvwinsize 32; setbuffersize 8192", where the numeric parameter is expressed in KB (default is 256).
« bbftpPRO Homepage