Rings connect the account, container, and object services. Rings also provide load balancing and failover for services that are running on multiple nodes.
Procedure
- If you are logged out, log back in to the controller01 node.
- Using SSH, log in to the VMware Integrated OpenStack manager.
- From the VMware Integrated OpenStack manager, use SSH to log in to the controller01 node.
- Switch to root user.
sudo su -
- Create the account, container, and object rings.
cd /etc/swift swift-ring-builder account.builder create 18 3 1 swift-ring-builder container.builder create 18 3 1 swift-ring-builder object.builder create 18 3 1
- Add a storage device to each ring.
swift-ring-builder account.builder add --region 1 --zone 1 --ip controller01_node_IP_address \ --port 6002 --device sdb --weight 100 swift-ring-builder account.builder add --region 1 --zone 1 --ip controller01_node_IP_address \ --port 6002 --device sdc --weight 100 swift-ring-builder account.builder add --region 1 --zone 1 --ip controller01_node_IP_address \ --port 6002 --device sdd --weight 100 swift-ring-builder container.builder add --region 1 --zone 1 --ip controller01_node_IP_address \ --port 6001 --device sdb --weight 100 swift-ring-builder container.builder add --region 1 --zone 1 --ip controller01_node_IP_address \ --port 6001 --device sdc --weight 100 swift-ring-builder container.builder add --region 1 --zone 1 --ip controller01_node_IP_address \ --port 6001 --device sdd --weight 100 swift-ring-builder object.builder add --region 1 --zone 1 --ip controller01_node_IP_address \ --port 6000 --device sdb --weight 100 swift-ring-builder object.builder add --region 1 --zone 1 --ip controller01_node_IP_address \ --port 6000 --device sdc --weight 100 swift-ring-builder object.builder add --region 1 --zone 1 --ip controller01_node_IP_address \ --port 6000 --device sdd --weight 100
- Verify the ring contents for each ring.
swift-ring-builder account.builder swift-ring-builder container.builder swift-ring-builder object.builder
- Rebalance the rings.
swift-ring-builder account.builder rebalance swift-ring-builder container.builder rebalance swift-ring-builder object.builder rebalance
- Ensure that the swift user owns all of the configuration files.
chown -R swift:swift /etc/swift