Performs a third-party file transfer using GridFTP.
gd_transferfile(host1,host2,remotefile1,remotefile2)
gd_transferfile(host2,host2,remotefile1,remotefile2, filetype)
gd_transferfile(host1,host2,remotefile1,remotefile2, filetype,host1listen)
gd_transferfile(host1,host2,remotefile1,remotefile2) transfers the file specified by the string remotefile1 on the GridFTP server host1 to the file specified by remotefile2 on host2.
gd_transferfile(host1,host2,remotefile1,remotefile2, filetype) as above except the string filetype sets the file transfer type. When filetype = 'ASCII' the file transfer type will be ASCII (this is the default setting), alternatively when filetype = 'binary' the file transfer type is set to binary.
gd_transferfile(host1,host2,remotefile1,remotefile2, filetype,host1listen) as above, except when host1listen is true host1 will listen for a data connection from host2 (i.e. host2 is the passive FTP client to host1). Otherwise host2 will listen for a data connection from host1 (this is the default behaviour).
Configuring this setting may be useful to negotiate third party file transfers through a firewall. For example, if host2 is within a filewall which blocks inbound connections setting host1listen = 1 may enable a third party file transfer from host1.
The following command will transfer a file called '/tmp/test1' from 'server1' to a file called '/tmp/test2' on 'server2' in ASCII mode,:
gd_transferfile('server1.domain.com','server2.domain.com', '/tmp/test1','/tmp/test2')
gd_putfile, gd_getfile, gd_createproxy
Copyright © 2007, The Geodise Project, University of Southampton