progetti:cloud-areapd:egi_federated_cloud:onedata
Differences
This shows you the differences between two versions of the page.
| Both sides previous revisionPrevious revisionNext revision | Previous revision | ||
| progetti:cloud-areapd:egi_federated_cloud:onedata [2017/08/03 11:55] – ntritto@infn.it | progetti:cloud-areapd:egi_federated_cloud:onedata [2018/07/24 09:23] (current) – traldi@infn.it | ||
|---|---|---|---|
| Line 1: | Line 1: | ||
| + | ====== OneData deployment ====== | ||
| + | |||
| + | Onedata is avalaible in EgiFedCloud. The storage consists of 2 disk of 7.5 TB in raid 6 configuration | ||
| + | |||
| + | **LAYOUT** | ||
| + | |||
| + | To deploy onedata services are needed 2 host for the configuration chosen, in our case we use: | ||
| + | oneprovider: | ||
| + | onezone: onezone.cloud.cnaf.infn.it | ||
| + | |||
| + | |||
| + | **ONEDATA** | ||
| + | |||
| + | For official references about Onedata see: | ||
| + | https:// | ||
| + | https:// | ||
| + | |||
| + | **Prerequisites** | ||
| + | |||
| + | All scenarios are prepared as Docker Compose configurations. The supported versions of docker engine and compose are equal or greater than: | ||
| + | |||
| + | docker engine 1.11 | ||
| + | docker-compose 1.7 | ||
| + | |||
| + | Install git and clone onedata repository with | ||
| + | |||
| + | git clone https:// | ||
| + | |||
| + | |||
| + | Opening Ports: | ||
| + | |||
| + | If you want (usually you do) your Oneprovider/ | ||
| + | Port Description | ||
| + | |||
| + | 53/TCP DNS (Optional - used for load-balancing) | ||
| + | |||
| + | 53/UDP DNS (Optional - used for load-balancing) | ||
| + | |||
| + | 80/TCP HTTP | ||
| + | |||
| + | 443/TCP HTTPS | ||
| + | |||
| + | 5555/TCP Communication between Oneclient command line tool and Oneprovider service (TCP) | ||
| + | |||
| + | 5556/TCP Communication between Oneprovider services among different sites | ||
| + | |||
| + | 6665/TCP Onedata data transfer channel (RTransfer) | ||
| + | |||
| + | 6666/TCP Onedata data transfer channel (RTransfer) | ||
| + | |||
| + | 7443/TCP Communication between Oneprovider instances and Onezone used to exchange metadata | ||
| + | |||
| + | 8443/TCP REST and CDMI API's (HTTP) | ||
| + | |||
| + | 8876/TCP RTransfer protocol gateway | ||
| + | |||
| + | 8877/TCP RTransfer protocol gateway | ||
| + | |||
| + | 9443/TCP Onepanel web interface | ||
| + | |||
| + | and make sure that there are no intermediate firewalls blocking those ports between machines running Onedata services. More information on firewall setup can be found in documentation https:// | ||
| + | |||
| + | run_onedata.sh script runs in foreground. To run more complex scenarios, you will need multiple terminal windows or terminal multiplexer such as screen or tmux. (see https:// | ||
| + | |||
| + | **ONEDATA SETUP** | ||
| + | |||
| + | As can be seen in the onedata quickstart guide https:// | ||
| + | |||
| + | |||
| + | In our case we used scenario 3_0. | ||
| + | To deploy onezone oneprovider service you have to configure docker-compose-onezone.yml copy the file in / | ||
| + | |||
| + | systemctl restart oneprovider.service | ||
| + | |||
| + | ----------------------------------------------------------------------------------------- | ||
| + | IN ALTERNATIVE MODE (OLD MODE) you can sete hte file and start the script, according to scenario 3_0: | ||
| + | |||
| + | ./ | ||
| + | |||
| + | In our case the host one-data-01 use as onezone the Cnaf zone. We started the service from the directory / | ||
| + | |||
| + | ./ | ||
| + | and wait for successfully started message | ||
| + | |||
| + | ----------------------------------------------------------------------------------------- | ||
| + | |||
| + | The script or the service gets configurations info from docker-compose-oneprovider.yml. Below is reported the configuration file, with some comments added for better explanations. | ||
| + | |||
| + | |||
| + | |||
| + | version: ' | ||
| + | |||
| + | services: | ||
| + | one-data-01.pd.infn.it: | ||
| + | image: onedata/ | ||
| + | hostname: node1.oneprovider.localhost | ||
| + | # dns: 8.8.8.8 # uncomment if container can't ping any domain | ||
| + | container_name: | ||
| + | volumes: | ||
| + | - "/ | ||
| + | # configuration persistence | ||
| + | - " | ||
| + | # data persistence | ||
| + | - "/ | ||
| + | - "/ | ||
| + | #- " | ||
| + | # Oneprovider | ||
| + | #- " | ||
| + | #- " | ||
| + | #- " | ||
| + | #- " | ||
| + | |||
| + | ports: | ||
| + | - " | ||
| + | - " | ||
| + | - " | ||
| + | - " | ||
| + | - " | ||
| + | - " | ||
| + | - " | ||
| + | - " | ||
| + | - " | ||
| + | - " | ||
| + | - " | ||
| + | - " | ||
| + | - " | ||
| + | environment: | ||
| + | # | ||
| + | ONEPANEL_BATCH_MODE: | ||
| + | ONEPROVIDER_CONFIG: | ||
| + | cluster: | ||
| + | domainName: " | ||
| + | nodes: | ||
| + | n1: | ||
| + | hostname: " | ||
| + | managers: | ||
| + | mainNode: " | ||
| + | nodes: | ||
| + | - " | ||
| + | workers: | ||
| + | nodes: | ||
| + | - " | ||
| + | databases: | ||
| + | nodes: | ||
| + | - " | ||
| + | storages: | ||
| + | NFS: | ||
| + | type: " | ||
| + | mountPoint: "/ | ||
| + | oneprovider: | ||
| + | register: true | ||
| + | name: " | ||
| + | redirectionPoint: | ||
| + | geoLatitude: | ||
| + | geoLongitude: | ||
| + | onezone: | ||
| + | domainName: " | ||
| + | onepanel: | ||
| + | users: | ||
| + | " | ||
| + | password: "< | ||
| + | userRole: " | ||
| + | " | ||
| + | password: "< | ||
| + | userRole: " | ||
| + | |||
| + | |||
| + | ---- | ||
| + | **ONEPROVIDER WEB PANEL** | ||
| + | |||
| + | As mentioned before when oneprovider service is up, is active also a web panel interface for the admin user at: | ||
| + | | ||
| + | Here is possible configure storage and give support for spaces created in onezone and want to use INFN-PD as provider. | ||
| + | |||
| + | //MANAGE STORAGE// | ||
| + | |||
| + | From the menu Software-> | ||
| + | |||
| + | For posix storage is enough give a name for storage and a mount point(for the 2 disk in our storage the mount point are / | ||
| + | |||
| + | For ceph you need more parameters, in our case: | ||
| + | |||
| + | clusterName => <<" | ||
| + | |||
| + | //SUPPORT SPACE// | ||
| + | |||
| + | User can ask for support giving a token to the admin, as described in onedata documentation. | ||
| + | The admin has to copy this token in Spaces-> | ||
| + | |||
| + | |||
| + | ===== Onedata rest api ===== | ||
| + | |||
| + | It is possible to use Onedata' | ||
| + | |||
| + | For official reference about Onedata' | ||
| + | |||
| + | https:// | ||
| + | |||
| + | https:// | ||
| + | |||
| + | https:// | ||
| + | |||
| + | Here you can find all the information and explanation about using oneclient rest api and cdmi. | ||
| + | |||
| + | |||
| + | In order to be able to use this API the REST client must be able to authenticate with the Onezone service | ||
| + | |||
| + | As common usecase an user needs to copy files to or from onedata space without using oneclient, in this case can simply use curl commands. | ||
| + | Can be useful export some variable before running the command: | ||
| + | |||
| + | export $ACCESS_TOKEN=< | ||
| + | |||
| + | export $ONEPROVIDER_HOST=https:// | ||
| + | |||
| + | |||
| + | To copy a file in a specific onedata space you can use curl command with this options: | ||
| + | |||
| + | curl -k -H " | ||
| + | |||
| + | To copy the file from onedata space in a local path: | ||
| + | |||
| + | curl -k -H " | ||
| + | |||
| + | or | ||
| + | |||
| + | curl -k -H " | ||
| + | |||
| + | in this case the destination path is not specified so it's better to navigate in the chosen directory and then run the curl command. | ||
| + | |||
| + | |||
