The Globus Command Line Interface (CLI) is an alternative to the Globus website which enables one to interact with Globus (endpoints, tasks, etc.) using the command line.
This can be done by following these instructions. We recommend that you install pipx and Globus CLI in a virtual environment.
If you do choose to use a virtualenv, remember to activate it before trying to use any
globuscommands and deactivate it when you are done.
Here is an example of a file transfer that uses a virtualenv (which has already been set up):
$ source "$HOME/.globus-cli-virtualenv/bin/activate"
$ globus login
After entering the
globus logincommand, copy the supplied url into a browser, click 'Continue', click 'Allow', copy and paste the authorization code, and hit enter. You should then see something like this:
You have successfully logged in to the Globus CLI!
You can check your primary identity with
For information on which of your identities are in session use
globus session show
Logout of the Globus CLI with
Before you make the transfer, you need to find the IDs of the source and destination endpoints. This can be done with the following command (or a variation of it):
$ globus endpoint search --filter-scope administered-by-me
ID | Owner | Display Name
------------------------------------ | ------------------- | ------------------------------
ddb59aef-6d04-11e5-ba46-22000b92c6ec | [email protected] | BrownU_OscarGrouch_GDrive
ddb59af0-6d04-11e5-ba46-22000b92c6ec | [email protected] | BrownU_IrrelevantEndpoint
cf9bcaa5-6d04-11e5-ba46-22000b92c6ec | [email protected] | BrownU_CCV_Oscar
The final term of this command can be any of the following:
Once you find the endpoints you need (in this case we want to transfer a file from
BrownU_CCV_Oscar), set up your
dest_epvalues using the IDs of the endpoints (these IDs are fake, so be sure to copy from the system output):
Finally, transfer the file using the following command:
$ globus transfer $source_ep:/folder1/file1.txt $dest_ep:/home/thegrouch/mynewfile.txt
This command transfers a file named
file1.txtto the destination endpoint (its name in the destination will be
In order to have the timestamp for mynewfile.txt match the latest modification of
file1.txtrather than the time of the transfer, you can add
--preserve-mtimeto the end of the line (run the line below instead of the one above):
$ globus transfer $source_ep:/folder1/file1.txt $dest_ep:/home/thegrouch/mynewfile.txt --preserve-mtime
Finally, deactivate the virtualenv: