karbor/doc/source/install/common_prerequisites.rst
Yuval Brik 516becff81 Docs: Arrange Install Guide
Change-Id: I422cfc64479907caeefd836f18e8d303d1bca521
2017-07-25 16:32:03 +03:00

5.6 KiB

Prerequisites

Before you install and configure Data Protection service, you must create a database, service credentials, and API endpoints. Data Protection service also requires additional information in the Identity service.

  1. To create the database, complete these steps:

    • Use the database access client to connect to the database server as the root user:

      $ mysql -u root -p
    • Create the karbor database:

      CREATE DATABASE karbor;
    • Grant proper access to the karbor database:

      GRANT ALL PRIVILEGES ON karbor.* TO 'karbor'@'localhost' IDENTIFIED BY 'KARBOR_DBPASS';
      GRANT ALL PRIVILEGES ON karbor.* TO 'karbor'@'%' IDENTIFIED BY 'KARBOR_DBPASS';

      Replace KARBOR_DBPASS with a suitable password.

    • Exit the database access client.

  2. Source the admin credentials to gain access to admin-only CLI commands:

    $ . admin-openrc
  3. To create the service credentials, complete these steps:

    • Create the karbor user:

      $ openstack user create --domain default --password-prompt karbor
      User Password:
      Repeat User Password:
      +-----------+----------------------------------+
      | Field     | Value                            |
      +-----------+----------------------------------+
      | domain_id | e0353a670a9e496da891347c589539e9 |
      | enabled   | True                             |
      | id        | ca2e175b851943349be29a328cc5e360 |
      | name      | karbor                           |
      +-----------+----------------------------------+
    • Add the admin role to the karbor user:

      $ openstack role add --project service --user karbor admin

      Note

      This command provides no output.

    • Create the karbor service entities:

      $ openstack service create --name karbor --description "Application Data Protection Service" data-protect
      +-------------+-------------------------------------+
      | Field       | Value                               |
      +-------------+-------------------------------------+
      | description | Application Data Protection Service |
      | enabled     | True                                |
      | id          | 727841c6f5df4773baa4e8a5ae7d72eb    |
      | name        | karbor                              |
      | type        | data-protect                        |
      +-------------+-------------------------------------+
  4. Create the Data Protection service API endpoints:

    $ openstack endpoint create --region RegionOne data-protect public http://controller:8799/v1/%\(project_id\)s
    +--------------+------------------------------------------+
    | Field        | Value                                    |
    +--------------+------------------------------------------+
    | enabled      | True                                     |
    | id           | 3f4dab34624e4be7b000265f25049609         |
    | interface    | public                                   |
    | region       | RegionOne                                |
    | region_id    | RegionOne                                |
    | service_id   | 727841c6f5df4773baa4e8a5ae7d72eb         |
    | service_name | karbor                                   |
    | service_type | data-protect                             |
    | url          | http://controller:8799/v1/%(project_id)s |
    +--------------+------------------------------------------+
    
    $ openstack endpoint create --region RegionOne data-protect internal http://controller:8799/v1/%\(project_id\)s
    +--------------+------------------------------------------+
    | Field        | Value                                    |
    +--------------+------------------------------------------+
    | enabled      | True                                     |
    | id           | 3f4dab34624e4be7b000265f25049609         |
    | interface    | internal                                 |
    | region       | RegionOne                                |
    | region_id    | RegionOne                                |
    | service_id   | 727841c6f5df4773baa4e8a5ae7d72eb         |
    | service_name | karbor                                   |
    | service_type | data-protect                             |
    | url          | http://controller:8799/v1/%(project_id)s |
    +--------------+------------------------------------------+
    
    $ openstack endpoint create --region RegionOne data-protect admin http://controller:8799/v1/%\(project_id\)s
    +--------------+------------------------------------------+
    | Field        | Value                                    |
    +--------------+------------------------------------------+
    | enabled      | True                                     |
    | id           | 3f4dab34624e4be7b000265f25049609         |
    | interface    | admin                                    |
    | region       | RegionOne                                |
    | region_id    | RegionOne                                |
    | service_id   | 727841c6f5df4773baa4e8a5ae7d72eb         |
    | service_name | karbor                                   |
    | service_type | data-protect                             |
    | url          | http://controller:8799/v1/%(project_id)s |
    +--------------+------------------------------------------+