Пример #1
0
    def _get_pdu_opts(cls):
        return [
            cfg.Opt(
                name="pdu_servers",
                type=types.Dict(
                    value_type=types.String(),
                ),
                help="A mapping between PDU names and their endpoint "
                     "(IP/FQDN)",
                sample_default=(
                    "[my_data_puller]\n"
                    "#pdu_servers=PDU_1:127.0.0.1,PDU_2:192.168.1.1")
            ),
            cfg.MultiOpt(
                name="mapping",
                item_type=types.Dict(
                    value_type=types.List(
                        bounds=True,
                        item_type=types.Dict(
                            value_type=types.Integer()
                        ),
                    ),
                ),
                help="Each entry specified here should be an entry mapping a "
                     "PDU name to a list of servers. Each server is a pair "
                     "between its endpoint and its related outlet ID.",
                sample_default=(
                    "[my_data_puller]\n"
                    "#mapping = PDU_1:[serv1.hostname:1,serv2.hostname:2]\n"
                    "#mapping = PDU_2:[serv3.hostname:1,serv4.hostname:2]"
                ),

            ),
        ]
Пример #2
0
 def get_plugin_opts(cls):
     opts = []
     exchanges = cls._get_notification_exchanges()
     if exchanges:
         defaults = " ".join("<notifications_topic>,%s" % i
                             for i in exchanges)
         opts.append(cfg.MultiOpt(
             'notifications_topics_exchanges',
             item_type=types.MultiString(),
             help='Override default topic,exchange pairs. '
                  'Defaults to %s' % defaults,
             default=[]))
     return opts
Пример #3
0
 cfg.BoolOpt('list-dependencies',
             short='l',
             help='Show image dependencies (filtering supported)'),
 cfg.BoolOpt('list-images',
             help='Show all available images (filtering supported)'),
 cfg.StrOpt('namespace',
            short='n',
            default='kolla',
            help='The Docker namespace name'),
 cfg.BoolOpt('cache',
             default=True,
             help='Use the Docker cache when building'),
 cfg.MultiOpt('profile',
              types.String(),
              short='p',
              help=('Build a pre-defined set of images, see [profiles]'
                    ' section in config. The default profiles are:'
                    ' {}'.format(', '.join(
                        [opt.name for opt in _PROFILE_OPTS])))),
 cfg.BoolOpt('push', default=False, help='Push images after building'),
 cfg.IntOpt('push-threads',
            default=1,
            min=1,
            help=('The number of threads to user while pushing'
                  ' Images. Note: Docker can not handle threading'
                  ' push properly')),
 cfg.IntOpt('retries',
            short='r',
            default=3,
            min=0,
            help='The number of times to retry while building'),
Пример #4
0
        default=None,
        help='HTTP IPA Kerberos service name (e.g. [email protected])'),
    cfg.StrOpt('cacert',
               default='/etc/ipa/ca.crt',
               help='CA certificate for use with https to IPA'),
    cfg.StrOpt('domain', default='test', help='Domain for new hosts'),
    cfg.IntOpt('connect_retries',
               default=1,
               help='How many times to attempt to retry '
               'the connection to IPA before giving up'),
    cfg.StrOpt('json_rpc_version', default='2.65',
               help='IPA RPC JSON version'),
    cfg.MultiOpt(
        'inject_files',
        item_type=types.String(),
        default=[],
        help=
        'Files to inject into the new VM.  Specify as /path/to/file/on/host[ /path/to/file/in/vm/if/different]'
    )
])

CONF(['--config-file', '/etc/nova/ipaclient.conf'])

LOG = logging.getLogger(__name__)


class IPABaseError(Exception):
    error_code = 500
    error_type = 'unknown_ipa_error'
    error_message = None
    errors = None
Пример #5
0
               help='The number of retry when there is a '
               'connection error.'),
    cfg.BoolOpt('auto_commit',
                default=False,
                help='If automatically commmit when consume '
                'messages.'),
    cfg.BoolOpt('async', default=True, help='The type of posting.'),
    cfg.BoolOpt('compact',
                default=True,
                help=('Specify if the message received should be parsed.'
                      'If True, message will not be parsed, otherwise '
                      'messages will be parsed.')),
    cfg.MultiOpt('partitions',
                 item_type=types.Integer(),
                 default=0,
                 help='The partitions this connection should '
                 'listen for messages on. Currently does not '
                 'support multiple partitions. '
                 'Default is to listen on partition 0.'),
    cfg.BoolOpt('drop_data',
                default=False,
                help=('Specify if received data should be simply dropped. '
                      'This parameter is only for testing purposes.')),
]

kafka_group = cfg.OptGroup(name='kafka', title='title')
cfg.CONF.register_group(kafka_group)
cfg.CONF.register_opts(kafka_opts, kafka_group)

influxdb_opts = [
    cfg.StrOpt('database_name'),
Пример #6
0
                     'this option to be a regular expression which will be '
                     'applied to the names of objects from the storage '
                     'backend which represent pools in Cinder. This option '
                     'is only utilized when the storage protocol is '
                     'configured to use iSCSI or FC.')),
]

netapp_replication_opts = [
    cfg.MultiOpt('netapp_replication_aggregate_map',
                 item_type=types.Dict(),
                 help="Multi opt of dictionaries to represent the aggregate "
                 "mapping between source and destination back ends when "
                 "using whole back end replication. For every "
                 "source aggregate associated with a cinder pool (NetApp "
                 "FlexVol), you would need to specify the destination "
                 "aggregate on the replication target device. A "
                 "replication target device is configured with the "
                 "configuration option replication_device. Specify this "
                 "option as many times as you have replication devices. "
                 "Each entry takes the standard dict config form: "
                 "netapp_replication_aggregate_map = "
                 "backend_id:<name_of_replication_device_section>,"
                 "src_aggr_name1:dest_aggr_name1,"
                 "src_aggr_name2:dest_aggr_name2,..."),
    cfg.IntOpt(
        'netapp_snapmirror_quiesce_timeout',
        min=0,
        default=3600,  # One Hour
        help='The maximum time in seconds to wait for existing '
        'SnapMirror transfers to complete before aborting '
        'during a failover.'),
]
Пример #7
0
               help="Timeout in seconds to wait for a share to become"
               "available."),
    cfg.BoolOpt("suppress_errors_in_cleanup",
                default=False,
                help="Whether to suppress errors with clean up operation "
                "or not. There are cases when we may want to skip "
                "such errors and catch only test errors."),
    cfg.MultiOpt("security_service",
                 item_type=types.Dict(),
                 secret=True,
                 help="This option enables specifying security service "
                 "parameters needed to create security services "
                 "dynamically in order to run the tempest tests. "
                 "The configured security service must be reachable by "
                 "the project share networks created by the tests. So, "
                 "ideally project networks must be able to route to the "
                 "network where the pre-existing security services has "
                 "been deployed. The set of parameters that can be "
                 "configured is the same used in the security service "
                 "creation. You can repeat this option many times, and "
                 "each entry takes the standard dict config parameters: "
                 "security_service = "
                 "ss_type:<ldap, kerberos or active_directory>, "
                 "ss_dns_ip:value, ss_user:value, ss_password=value, "
                 "ss_domain:value, ss_server:value"),

    # Switching ON/OFF test suites filtered by features
    cfg.BoolOpt("run_quota_tests",
                default=True,
                help="Defines whether to run quota tests or not."),
    cfg.BoolOpt("run_extend_tests",
                default=True,
Пример #8
0
from manila.i18n import _
from manila.share import driver
from manila.share.drivers.huawei import constants

huawei_opts = [
    cfg.StrOpt('manila_huawei_conf_file',
               default='/etc/manila/manila_huawei_conf.xml',
               help='The configuration file for the Manila Huawei driver.'),
    cfg.BoolOpt('local_replication',
                default=False,
                help='The replication type of backend Huawei storage.'),
    cfg.MultiOpt('metro_info',
                 item_type=types.Dict(),
                 secret=True,
                 help='Multi opt of dictionaries to represent a hypermetro '
                 'target device. This option may be specified multiple '
                 'times in a single config section to specify multiple '
                 'hypermetro target devices. Each entry takes the '
                 'standard dict config form: hypermetro_device = '
                 'key1:value1,key2:value2...'),
]

CONF = cfg.CONF
CONF.register_opts(huawei_opts)
LOG = log.getLogger(__name__)


class HuaweiNasDriver(driver.ShareDriver):
    """Huawei Share Driver.

    Executes commands relating to Shares.
Пример #9
0
        default=False,
        mutable=True,
        help=_('Option to cause the conductor to not fallback to '
               'an un-hashed version of the rescue password, '
               'permitting rescue with older ironic-python-agent '
               'ramdisks.')),
    cfg.StrOpt('bootloader',
               mutable=True,
               help=_('Glance ID, http:// or file:// URL of the EFI system '
                      'partition image containing EFI boot loader. This image '
                      'will be used by ironic when building UEFI-bootable ISO '
                      'out of kernel and ramdisk. Required for UEFI boot from '
                      'partition images.')),
    cfg.MultiOpt('clean_step_priority_override',
                 item_type=types.Dict(),
                 default={},
                 help=_('Priority to run automated clean steps for both '
                        'in-band and out of band clean steps, provided in '
                        'interface.step_name:priority format, e.g. '
                        'deploy.erase_devices_metadata:123. The option can '
                        'be specified multiple times to define priorities '
                        'for multiple steps. If set to 0, this specific step '
                        'will not run during cleaning. If unset for an '
                        'inband clean step, will use the priority set in the '
                        'ramdisk.')),
]


def register_opts(conf):
    conf.register_opts(opts, group='conductor')
Пример #10
0
  agent disabled. When used with libvirt the instance mode should be
  configured as HVM.
 """)

reserved_huge_pages = cfg.MultiOpt(
    "reserved_huge_pages",
    item_type=types.Dict(),
    help="""Reserves a number of huge/large memory pages per NUMA host cells

Possible values:

* A list of valid key=value which reflect NUMA node ID, page size
  (Default unit is KiB) and number of pages to be reserved.

    reserved_huge_pages = node:0,size:2048,count:64
    reserved_huge_pages = node:1,size:1GB,count:1

  In this example we are reserving on NUMA node 0 64 pages of 2MiB
  and on NUMA node 1 1 page of 1GiB.

Services which consume this:

* nova-compute

Related options:

* None""")

ALL_OPTS = [
    vcpu_pin_set, compute_driver, default_ephemeral_format, preallocate_images,
    use_cow_images, vif_plugging_is_fatal, vif_plugging_timeout,
Пример #11
0
            'expired cache leads to refreshing it.'),
 cfg.BoolOpt('netapp_enable_flexgroup',
             default=False,
             help='Specify if the FlexGroup pool is enabled. When it is '
             'enabled, the driver will report a single pool '
             'representing all aggregates (ONTAP chooses on which the '
             'share will be allocated). If you want to Manila control '
             'the aggregate selection, you can configure its custom '
             'FlexGroup pools through netapp_flexgroup_pools option. '
             'The FlexGroup placement is done either by ONTAP or '
             'Manila, not both.'),
 cfg.MultiOpt('netapp_flexgroup_pools',
              item_type=types.Dict(value_type=types.String()),
              default={},
              help="Multi opt of dict to represent the FlexGroup pools. "
              "A FlexGroup pool is configured with its name and its "
              "list of aggregates. Specify this option as many times "
              "as you have FlexGroup pools. Each entry takes the "
              "dict config form: "
              "netapp_flexgroup_pools = "
              "<pool_name>: <aggr_name1> <aggr_name2> .."),
 cfg.BoolOpt('netapp_flexgroup_pool_only',
             default=False,
             help='Specify if the FlexVol pools must not be reported when '
             'the netapp_enable_flexgroup is enabled.'),
 cfg.IntOpt(
     'netapp_flexgroup_volume_online_timeout',
     min=60,
     default=360,  # Default to six minutes
     help='Sets time in seconds to wait for a FlexGroup volume '
     'create to complete and go online.'),
 cfg.IntOpt(
Пример #12
0
def get_conf():
    conf = cfg.ConfigOpts()

    _kolla_profile_opts = [
        cfg.ListOpt('infra',
                    default=[
                        'ceph', 'data', 'mariadb', 'haproxy', 'keepalived',
                        'kolla-ansible', 'memcached', 'mongodb', 'openvswitch',
                        'rabbitmq', 'rsyslog'
                    ]),
        cfg.ListOpt('main',
                    default=[
                        'cinder', 'ceilometer', 'glance', 'heat', 'horizon',
                        'keystone', 'neutron', 'nova', 'swift'
                    ]),
        cfg.ListOpt('aux',
                    default=[
                        'aodh', 'designate', 'gnocchi', 'ironic', 'magnum',
                        'mistral', 'trove,'
                        'zaqar'
                    ]),
        cfg.ListOpt('default',
                    default=[
                        'data', 'kolla-ansible', 'glance', 'haproxy', 'heat',
                        'horizon', 'keepalived', 'keystone', 'memcached',
                        'mariadb', 'neutron', 'nova', 'openvswitch',
                        'rabbitmq', 'rsyslog'
                    ]),
        cfg.ListOpt('gate',
                    default=[
                        'ceph', 'cinder', 'data', 'dind', 'glance', 'haproxy',
                        'heat', 'horizon', 'keepalived', 'keystone',
                        'kolla-ansible', 'mariadb', 'memcached', 'neutron',
                        'nova', 'openvswitch', 'rabbitmq', 'rsyslog'
                    ])
    ]

    _kolla_cli_opts = [
        cfg.StrOpt('base',
                   short='b',
                   default='centos',
                   deprecated_group='kolla-build',
                   help='The base distro to use when building'),
        cfg.StrOpt('base_tag',
                   default='latest',
                   deprecated_group='kolla-build',
                   help='The base distro image tag'),
        cfg.BoolOpt('debug',
                    short='d',
                    default=False,
                    deprecated_group='kolla-build',
                    help='Turn on debugging log level'),
        cfg.StrOpt('include-header',
                   short='i',
                   deprecated_group='kolla-build',
                   help=('Path to custom file to be added at '
                         'beginning of base Dockerfile')),
        cfg.StrOpt('include-footer',
                   short='I',
                   deprecated_group='kolla-build',
                   help=('Path to custom file to be added at '
                         'end of Dockerfiles for final images')),
        cfg.BoolOpt('keep',
                    default=False,
                    deprecated_group='kolla-build',
                    help='Keep failed intermediate containers'),
        cfg.StrOpt('namespace',
                   short='n',
                   default='kollaglue',
                   deprecated_group='kolla-build',
                   help='The Docker namespace name'),
        cfg.BoolOpt(
            'cache',
            default=True,
            help='Use the Docker cache when building',
        ),
        cfg.BoolOpt('no-cache',
                    default=False,
                    help='Do not use the Docker cache when building',
                    deprecated_for_removal=True),
        cfg.MultiOpt(
            'profile',
            types.String(),
            short='p',
            deprecated_group='kolla-build',
            help=('Build a pre-defined set of images, see [profiles]'
                  ' section in {}. The default profiles are:'
                  ' {}'.format(
                      find_config_file('kolla-build.conf'),
                      ', '.join([opt.name for opt in _kolla_profile_opts])))),
        cfg.BoolOpt('push',
                    default=False,
                    deprecated_group='kolla-build',
                    help='Push images after building'),
        cfg.IntOpt('push-threads',
                   default=1,
                   min=1,
                   deprecated_group='kolla-build',
                   help=('The number of threads to user while pushing'
                         ' Images. Note: Docker can not handle threading'
                         ' push properly.')),
        cfg.IntOpt('retries',
                   short='r',
                   default=3,
                   min=0,
                   deprecated_group='kolla-build',
                   help='The number of times to retry while building'),
        cfg.MultiOpt('regex',
                     types.String(),
                     positional=True,
                     help=('Build only images matching regex and its'
                           ' dependencies')),
        cfg.StrOpt('registry',
                   deprecated_group='kolla-build',
                   help=('The docker registry host. The default registry host'
                         ' is Docker Hub')),
        cfg.StrOpt('type',
                   short='t',
                   default='binary',
                   choices=INSTALL_TYPE_CHOICES,
                   dest='install_type',
                   deprecated_group='kolla-build',
                   help=('The method of the Openstack install. The valid'
                         ' types are: {}'.format(
                             ', '.join(INSTALL_TYPE_CHOICES)))),
        cfg.IntOpt('threads',
                   short='T',
                   default=8,
                   min=1,
                   deprecated_group='kolla-build',
                   help=('The number of threads to use while building.'
                         ' (Note: setting to one will allow real time'
                         ' logging.)')),
        cfg.StrOpt('tag',
                   default=get_kolla_version(),
                   deprecated_group='kolla-build',
                   help='The Docker tag'),
        cfg.BoolOpt('template-only',
                    default=False,
                    deprecated_group='kolla-build',
                    help=("Don't build images. Generate Dockerfile only")),
    ]

    _kolla_base_opts = [
        cfg.StrOpt('maintainer',
                   deprecated_group='kolla-build',
                   default='Kolla Project (https://launchpad.net/kolla)',
                   help='The MAINTAINER field'),
        cfg.ListOpt('rpm_setup_config',
                    default=[DELOREAN, DELOREAN_DEPS],
                    deprecated_group='kolla-build',
                    help=('Comma separated list of .rpm or .repo file(s)'
                          'or URL(s) to install before building containers'))
    ]
    conf.register_cli_opts(_kolla_cli_opts)
    conf.register_opts(_kolla_profile_opts, group='profiles')
    conf.register_opts(_kolla_base_opts)
    conf(sys.argv[1:],
         default_config_files=[find_config_file('kolla-build.conf')])
    return conf
Пример #13
0
                              'queue.'), cfg.IntOpt('ack_time', default=20,
                                                    help='The ack time back '
                                                         'to kafka.'),
              cfg.IntOpt('max_retry', default=3,
                         help='The number of retry when there is a '
                              'connection error.'),
              cfg.BoolOpt('auto_commit', default=False,
                          help='If automatically commmit when consume '
                               'messages.'),
              cfg.BoolOpt('async', default=True, help='The type of posting.'),
              cfg.BoolOpt('compact', default=True, help=(
                  'Specify if the message received should be parsed.'
                  'If True, message will not be parsed, otherwise '
                  'messages will be parsed.')),
              cfg.MultiOpt('partitions', item_type=types.Integer(),
                           default=[0],
                           help='The sleep time when no messages on kafka '
                                'queue.'),
              cfg.BoolOpt('drop_data', default=False, help=(
                  'Specify if received data should be simply dropped. '
                  'This parameter is only for testing purposes.')), ]

kafka_group = cfg.OptGroup(name='kafka', title='title')
cfg.CONF.register_group(kafka_group)
cfg.CONF.register_opts(kafka_opts, kafka_group)

influxdb_opts = [cfg.StrOpt('database_name'), cfg.StrOpt('ip_address'),
                 cfg.StrOpt('port'), cfg.StrOpt('user'),
                 cfg.StrOpt('password')]

influxdb_group = cfg.OptGroup(name='influxdb', title='influxdb')
cfg.CONF.register_group(influxdb_group)
Пример #14
0
* A comma-separated list of physical CPU numbers that virtual CPUs can be
  allocated to by default. Each element should be either a single CPU number,
  a range of CPU numbers, or a caret followed by a CPU number to be
  excluded from a previous range. For example:

    vcpu_pin_set = "4-12,^8,15"
"""),
    cfg.MultiOpt('reserved_huge_pages',
                 item_type=types.Dict(),
                 help="""
Number of huge/large memory pages to reserved per NUMA host cell.

Possible values:

* A list of valid key=value which reflect NUMA node ID, page size
  (Default unit is KiB) and number of pages to be reserved.

    reserved_huge_pages = node:0,size:2048,count:64
    reserved_huge_pages = node:1,size:1GB,count:1

  In this example we are reserving on NUMA node 0 64 pages of 2MiB
  and on NUMA node 1 1 page of 1GiB.
"""),
    cfg.IntOpt('reserved_host_disk_mb',
               min=0,
               default=0,
               help="""
Amount of disk resources in MB to make them always available to host. The
disk usage gets reported back to the scheduler from nova-compute running
on the compute nodes. To prevent the disk resources from being considered
as available, this option can be used to reserve disk space for that host.
Пример #15
0
            deprecated_name='hp3par_san_ip'),
 cfg.StrOpt('hpe3par_san_login',
            default='',
            help="Username for SAN controller",
            deprecated_name='hp3par_san_login'),
 cfg.StrOpt('hpe3par_san_password',
            default='',
            help="Password for SAN controller",
            secret=True,
            deprecated_name='hp3par_san_password'),
 cfg.PortOpt('hpe3par_san_ssh_port',
             default=22,
             help='SSH port to use with SAN',
             deprecated_name='hp3par_san_ssh_port'),
 cfg.MultiOpt('hpe3par_fpg',
              item_type=FPG(min_ip=0, max_ip=FPG.MAX_SUPPORTED_IP_PER_VFS),
              help="The File Provisioning Group (FPG) to use",
              deprecated_name='hp3par_fpg'),
 cfg.BoolOpt('hpe3par_fstore_per_share',
             default=False,
             help="Use one filestore per share",
             deprecated_name='hp3par_fstore_per_share'),
 cfg.BoolOpt('hpe3par_require_cifs_ip',
             default=False,
             help="Require IP access rules for CIFS (in addition to user)"),
 cfg.BoolOpt('hpe3par_debug',
             default=False,
             help="Enable HTTP debugging to 3PAR",
             deprecated_name='hp3par_debug'),
 cfg.StrOpt('hpe3par_cifs_admin_access_username',
            default='',
            help="File system admin user name for CIFS.",
Пример #16
0
            default='kolla',
            deprecated_group='kolla-build',
            help='The Docker namespace name'),
 cfg.BoolOpt(
     'cache',
     default=True,
     help='Use the Docker cache when building',
 ),
 cfg.BoolOpt('no-cache',
             default=False,
             help='Do not use the Docker cache when building',
             deprecated_for_removal=True),
 cfg.MultiOpt('profile',
              types.String(),
              short='p',
              deprecated_group='kolla-build',
              help=('Build a pre-defined set of images, see [profiles]'
                    ' section in config. The default profiles are:'
                    ' {}'.format(', '.join(
                        [opt.name for opt in _PROFILE_OPTS])))),
 cfg.BoolOpt('push',
             default=False,
             deprecated_group='kolla-build',
             help='Push images after building'),
 cfg.IntOpt('push-threads',
            default=1,
            min=1,
            deprecated_group='kolla-build',
            help=('The number of threads to user while pushing'
                  ' Images. Note: Docker can not handle threading'
                  ' push properly.')),
 cfg.IntOpt('retries',
Пример #17
0
def register_volume():
    volume_opts = [
        cfg.IntOpt(
            'num_shell_tries',
            default=3,
            help='Number of times to attempt to run flakey shell commands'),
        cfg.IntOpt('reserved_percentage',
                   default=0,
                   min=0,
                   max=100,
                   help='The percentage of backend capacity is reserved'),
        cfg.StrOpt('iscsi_target_prefix',
                   default='iqn.2010-10.org.openstack:',
                   help='Prefix for iSCSI volumes'),
        cfg.StrOpt(
            'iscsi_ip_address',
            default='$my_ip',
            help='The IP address that the iSCSI daemon is listening on'),
        cfg.ListOpt(
            'iscsi_secondary_ip_addresses',
            default=[],
            help='The list of secondary IP addresses of the iSCSI daemon'),
        cfg.PortOpt('iscsi_port',
                    default=3260,
                    help='The port that the iSCSI daemon is listening on'),
        cfg.IntOpt('num_volume_device_scan_tries',
                   default=3,
                   help='The maximum number of times to rescan targets'
                   ' to find volume'),
        cfg.StrOpt('volume_backend_name',
                   help='The backend name for a given driver implementation'),
        cfg.BoolOpt(
            'use_multipath_for_image_xfer',
            default=False,
            help='Do we attach/detach volumes in cinder using multipath '
            'for volume to image and image to volume transfers?'),
        cfg.BoolOpt('enforce_multipath_for_image_xfer',
                    default=False,
                    help='If this is set to True, attachment of volumes for '
                    'image transfer will be aborted when multipathd is not '
                    'running. Otherwise, it will fallback to single path.'),
        cfg.StrOpt('volume_clear',
                   default='zero',
                   choices=['none', 'zero', 'shred'],
                   help='Method used to wipe old volumes'),
        cfg.IntOpt(
            'volume_clear_size',
            default=0,
            help='Size in MiB to wipe at start of old volumes. 0 => all'),
        cfg.StrOpt('volume_clear_ionice',
                   help='The flag to pass to ionice to alter the i/o priority '
                   'of the process used to zero a volume after deletion, '
                   'for example "-c3" for idle only priority.'),
        cfg.StrOpt(
            'iscsi_helper',
            default='tgtadm',
            choices=[
                'tgtadm', 'lioadm', 'scstadmin', 'iseradm', 'iscsictl',
                'ietadm', 'fake'
            ],
            help='iSCSI target user-land tool to use. tgtadm is default, '
            'use lioadm for LIO iSCSI support, scstadmin for SCST '
            'target support, iseradm for the ISER protocol, ietadm '
            'for iSCSI Enterprise Target, iscsictl for Chelsio iSCSI '
            'Target or fake for testing.'),
        cfg.StrOpt('volumes_dir',
                   default='$state_path/volumes',
                   help='Volume configuration file storage '
                   'directory'),
        cfg.StrOpt('iet_conf',
                   default='/etc/iet/ietd.conf',
                   help='IET configuration file'),
        cfg.StrOpt('chiscsi_conf',
                   default='/etc/chelsio-iscsi/chiscsi.conf',
                   help='Chiscsi (CXT) global defaults configuration file'),
        cfg.StrOpt('iscsi_iotype',
                   default='fileio',
                   choices=['blockio', 'fileio', 'auto'],
                   help=('Sets the behavior of the iSCSI target '
                         'to either perform blockio or fileio '
                         'optionally, auto can be set and Cinder '
                         'will autodetect type of backing device')),
        cfg.StrOpt('volume_dd_blocksize',
                   default='1M',
                   help='The default block size used when copying/clearing '
                   'volumes'),
        cfg.StrOpt('volume_copy_blkio_cgroup_name',
                   default='cinder-volume-copy',
                   help='The blkio cgroup name to be used to limit bandwidth '
                   'of volume copy'),
        cfg.IntOpt('volume_copy_bps_limit',
                   default=0,
                   help='The upper limit of bandwidth of volume copy. '
                   '0 => unlimited'),
        cfg.StrOpt('iscsi_write_cache',
                   default='on',
                   choices=['on', 'off'],
                   help='Sets the behavior of the iSCSI target to either '
                   'perform write-back(on) or write-through(off). '
                   'This parameter is valid if iscsi_helper is set '
                   'to tgtadm or iseradm.'),
        cfg.StrOpt('iscsi_target_flags',
                   default='',
                   help='Sets the target-specific flags for the iSCSI target. '
                   'Only used for tgtadm to specify backing device flags '
                   'using bsoflags option. The specified string is passed '
                   'as is to the underlying tool.'),
        cfg.StrOpt('iscsi_protocol',
                   default='iscsi',
                   choices=['iscsi', 'iser'],
                   help='Determines the iSCSI protocol for new iSCSI volumes, '
                   'created with tgtadm or lioadm target helpers. In '
                   'order to enable RDMA, this parameter should be set '
                   'with the value "iser". The supported iSCSI protocol '
                   'values are "iscsi" and "iser".'),
        cfg.StrOpt(
            'driver_client_cert_key',
            help='The path to the client certificate key for verification, '
            'if the driver supports it.'),
        cfg.StrOpt('driver_client_cert',
                   help='The path to the client certificate for verification, '
                   'if the driver supports it.'),
        cfg.BoolOpt('driver_use_ssl',
                    default=False,
                    help='Tell driver to use SSL for connection to backend '
                    'storage if the driver supports it.'),
        cfg.FloatOpt(
            'max_over_subscription_ratio',
            default=3.0,
            help='Float representation of the over subscription ratio '
            'when thin provisioning is involved. Default ratio is '
            '3.0, meaning provisioned capacity can be 3 times of '
            'the total physical capacity. If the ratio is 10.5, it '
            'means provisioned capacity can be 10.5 times of the '
            'total physical capacity. A ratio of 1.0 means '
            'provisioned capacity cannot exceed the total physical '
            'capacity. The ratio has to be a minimum of 1.0.'),
        cfg.StrOpt('scst_target_iqn_name',
                   help='Certain ISCSI targets have predefined target names, '
                   'SCST target driver uses this name.'),
        cfg.StrOpt('scst_target_driver',
                   default='iscsi',
                   help='SCST target implementation can choose from multiple '
                   'SCST target drivers.'),
        cfg.BoolOpt('use_chap_auth',
                    default=False,
                    help='Option to enable/disable CHAP authentication for '
                    'targets.',
                    deprecated_opts=deprecated_use_chap_auth_opts),
        cfg.StrOpt('chap_username',
                   default='',
                   help='CHAP user name.',
                   deprecated_opts=deprecated_chap_username_opts),
        cfg.StrOpt('chap_password',
                   default='',
                   help='Password for specified CHAP account name.',
                   deprecated_opts=deprecated_chap_password_opts,
                   secret=True),
        cfg.StrOpt('driver_data_namespace',
                   help='Namespace for driver private data values to be '
                   'saved in.'),
        cfg.StrOpt('filter_function',
                   help='String representation for an equation that will be '
                   'used to filter hosts. Only used when the driver '
                   'filter is set to be used by the Cinder scheduler.'),
        cfg.StrOpt('goodness_function',
                   help='String representation for an equation that will be '
                   'used to determine the goodness of a host. Only used '
                   'when using the goodness weigher is set to be used by '
                   'the Cinder scheduler.'),
        cfg.BoolOpt(
            'driver_ssl_cert_verify',
            default=False,
            help='If set to True the http client will validate the SSL '
            'certificate of the backend endpoint.'),
        cfg.StrOpt('driver_ssl_cert_path',
                   help='Can be used to specify a non default path to a '
                   'CA_BUNDLE file or directory with certificates of '
                   'trusted CAs, which will be used to validate the backend'),
        cfg.ListOpt('trace_flags',
                    help='List of options that control which trace info '
                    'is written to the DEBUG log level to assist '
                    'developers. Valid values are method and api.'),
        cfg.MultiOpt(
            'replication_device',
            item_type=types.Dict(),
            secret=True,
            help="Multi opt of dictionaries to represent a replication "
            "target device.  This option may be specified multiple "
            "times in a single config section to specify multiple "
            "replication target devices.  Each entry takes the "
            "standard dict config form: replication_device = "
            "target_device_id:<required>,"
            "key1:value1,key2:value2..."),
        cfg.BoolOpt('image_upload_use_cinder_backend',
                    default=False,
                    help='If set to True, upload-to-image in raw format will '
                    'create a cloned volume and register its location to '
                    'the image service, instead of uploading the volume '
                    'content. The cinder backend and locations support '
                    'must be enabled in the image service, and '
                    'glance_api_version must be set to 2.'),
        cfg.BoolOpt('image_upload_use_internal_tenant',
                    default=False,
                    help='If set to True, the image volume created by '
                    'upload-to-image will be placed in the internal tenant. '
                    'Otherwise, the image volume is created in the current '
                    'context\'s tenant.'),
        cfg.BoolOpt('image_volume_cache_enabled',
                    default=False,
                    help='Enable the image volume cache for this backend.'),
        cfg.IntOpt(
            'image_volume_cache_max_size_gb',
            default=0,
            help='Max size of the image volume cache for this backend in '
            'GB. 0 => unlimited.'),
        cfg.IntOpt(
            'image_volume_cache_max_count',
            default=0,
            help='Max number of entries allowed in the image volume cache. '
            '0 => unlimited.'),
        cfg.BoolOpt(
            'report_discard_supported',
            default=False,
            help='Report to clients of Cinder that the backend supports '
            'discard (aka. trim/unmap). This will not actually '
            'change the behavior of the backend or the client '
            'directly, it will only notify that it can be used.'),
    ]

    # _option_group = 'oslo_reports'
    # conf.register_opts(_options, group=_option_group)
    CONF.register_opts(volume_opts, group="normal")