The dCap
protocol, similiar to FTP
, uses a control channel
to request a transfer which is subsequently done through data
channels. Per default, the data channel is initiated by the
server, connecting to an open port in the client library. This
is commonly known as active transfer. Starting with dCache
1.7.0 the dCap
protocol supports passive transfer mode as
well, which consequently means that the client connects to the
server pool to initiate the data channel. This is essential to
support dCap
clients running behind firewalls and within
private networks.
The port(s), the server pools should listens on, can be
specified by the
org.dcache.net.tcp.portrange
variable, as
part of the ’java_options’ directive in the
config/dCacheSetup
configuration file. A
range has to be given if pools are split amoung multiple
JVMs. E.g:
java_options="-server ... -Dorg.dcache.dcap.port=0 -Dorg.dcache.net.tcp.portrange=33115:33145"
Note
The commonly used expression ’passive’ is seen from the server perspective and actually means ’server passive’. From the client perspective this is of course ’active’. Both means that the client connects to the server to establish the data connection. This mode is supported by the server starting with 1.7.0 and dccp with 1-2-40 (included in 1.7.0)
The following dCap
API call switches all subsequent dc_open
calls to server-passive mode if this mode is supported by the
corresponding door. (dCache Version >= 1.7.0).
void dc_setClientActive()
The environment variable DCACHE_CLIENT_ACTIVE
switches the dCap
library to server-passive. This is true
for dCap
, dCap
preload and dccp.
dccp switches to server-passive when issuing the -A command line option.