Juju Charm - Swift storage
You can not select more than 25 topics Topics must start with a letter or number, can include dashes ('-') and can be up to 35 characters long.
 
 
 
Alex Kavanagh 19d5010902 Hotfix charmhelpers sync for local_address() fix 1 month ago
actions Sync libraries & common files prior to freeze 5 months ago
charmhelpers Hotfix charmhelpers sync for local_address() fix 1 month ago
files Add monitoring for object-replicator logs disappearing 7 months ago
hooks Monitor Swift Object/Container/Account API availability 6 months ago
lib Sync libraries & common files prior to freeze 5 months ago
templates Ensure lockup_timeout is never < 2*rsync_timeout 7 months ago
tests Add Groovy to the test gate 3 months ago
unit_tests Sync libraries & common files prior to freeze 5 months ago
.gitignore Add support for block device encryption 2 years ago
.gitreview OpenDev Migration Patch 1 year ago
.project Resynced helpers 7 years ago
.pydevproject Enable xenial/queens amulet testing 3 years ago
.stestr.conf Replace ostestr with stestr in testing framework. 2 years ago
.zuul.yaml Switch to Ussuri jobs 1 year ago
LICENSE Re-license charm as Apache-2.0 4 years ago
Makefile Sync helpers for 20.05 9 months ago
README.md Review and improve README 1 year ago
actions.yaml Action Managed Upgrades 5 years ago
charm-helpers-hooks.yaml Sync charm/ceph helpers, tox, and requirements 1 year ago
config.yaml Ensure lockup_timeout is never < 2*rsync_timeout 7 months ago
copyright Re-license charm as Apache-2.0 4 years ago
hardening.yaml Add hardening support 4 years ago
icon.svg Update charm icon 3 years ago
metadata.yaml Remove Disco and Eoan bits 1 month ago
requirements.txt Sync release-tools 2 months ago
revision Remove debug. 7 years ago
setup.cfg Add Python 3 Train unit tests 1 year ago
test-requirements.txt Updates for testing period for 20.01 release 1 month ago
tox.ini Sync release-tools 2 months ago

README.md

Overview

OpenStack Swift is a highly available, distributed, eventually consistent object/blob store.

The swift-storage charm deploys Swift's storage component. The charm's basic function is to initialise storage devices and manage the container, object, and account services. It works in tandem with the swift-proxy charm, which is used to add proxy nodes.

Usage

Configuration

This section covers common configuration options. See file config.yaml for the full list of options, along with their descriptions and default values.

zone

The zone option assigns a storage zone (an integer) to a storage node. A zone is associated with data replicas.

block-device

The block-device option specifies the device(s) that will be used on all machines associated with the application. Value types include:

  • an actual block device (e.g. 'sdb' or '/dev/sdb'). A space-separated list is used for multiple devices.
  • a path to a local file with the size appended after a pipe (e.g. '/etc/swift/storagedev1.img|5G'). The file will be created if necessary and be mapped to a loopback device. This is intended for development and testing purposes.

The resulting block device(s) will be XFS-formatted and use /srv/node/<device-name> as a mount point.

storage-region

The storage-region option specifies a storage region (an integer). It is used only for multi-region (global) clusters.

Deployment

Let file swift.yaml contain the deployment configuration:

    swift-proxy:
        zone-assignment: manual
        replicas: 3
    swift-storage-zone1:
        zone: 1
        block-device: /dev/sdb
    swift-storage-zone2:
        zone: 2
        block-device: /dev/sdb
    swift-storage-zone3:
        zone: 3
        block-device: /dev/sdb

Deploy the proxy and storage nodes:

juju deploy --config swift.yaml swift-proxy
juju deploy --config swift.yaml swift-storage swift-storage-zone1
juju deploy --config swift.yaml swift-storage swift-storage-zone2
juju deploy --config swift.yaml swift-storage swift-storage-zone3

Add relations between the proxy node and all storage nodes:

juju add-relation swift-proxy:swift-storage swift-storage-zone1:swift-storage
juju add-relation swift-proxy:swift-storage swift-storage-zone2:swift-storage
juju add-relation swift-proxy:swift-storage swift-storage-zone3:swift-storage

This will result in a three-zone cluster, with each zone consisting of a single storage node, thereby satisfying the replica requirement of three.

Storage capacity is increased by adding swift-storage units to a zone. For example, to add two storage nodes to zone '3':

juju add-unit -n 2 swift-storage-zone3

Note: When scaling out ensure the candidate machines are equipped with the block devices currently configured for the associated application.

This charm will not balance the storage ring until there are enough storage zones to meet its minimum replica requirement, in this case three.

Appendix Swift usage in the OpenStack Charms Deployment Guide offers in-depth guidance for deploying Swift with charms. In particular, it shows how to set up a multi-region (global) cluster.

Actions

This section covers Juju actions supported by the charm. Actions allow specific operations to be performed on a per-unit basis.

  • openstack-upgrade
  • pause
  • resume

To display action descriptions run juju actions swift-storage.

Bugs

Please report bugs on Launchpad.

For general charm questions refer to the OpenStack Charm Guide.