1
.TH swift\-ring\-builder 8
3
swift\-ring\-builder \- Manipulate the swift ring storage devices.
6
.B swift\-ring\-builder
12
.B swift\-ring\-builder
14
Manipulate the swift ring. Please contribute a better long description!
18
The parameter [ACTION] can take one of the following values:
31
If action is not specified, then swift\-ring\-builder will display all the
32
storage devices. Below is a full description of each individual actions.
33
In each individual action, you may specify a <search\-value>. In that case,
34
then <search\-value> can be of the form:
36
d<device_id>z<zone>\-<ip>:<port>/<device_name>_<meta>
38
Any part is optional, but you must include at least one part. Examples:
41
Matches the device id 74
44
Matches devices in zone 1
47
Matches devices in zone 1 with the ip 1.2.3.4
50
Matches devices in any zone with the ip 1.2.3.4
53
Matches devices in zone 1 using port 5678
56
Matches devices that use port 5678
59
Matches devices with the device name sdb1
62
Matches devices with shiny in the meta data
65
Matches devices with snet: 5.6.7.8 in the meta data
67
Most specific example: d74z1-1.2.3.4:5678/sdb1_"snet: 5.6.7.8"
69
Nerd explanation: All items require their single character prefix except the
70
ip, in which case the - is optional unless the device id or zone is also
81
Creates <builder_file> with 2^<part_power> partitions and <replicas>.
82
<min_part_hours> is number of hours to restrict moving a partition more
89
Shows information about the ring and the devices within.
97
Shows information about matching devices.
100
.B swift-ring-builder
103
.B z<zone>-<ip>:<port>/<device_name>_<meta>
106
Adds a device to the ring with the given information. No partitions will be
107
assigned to the new device until after running 'rebalance'. This is so you can
108
make multiple device changes and rebalance them all just once.
111
.B swift-ring-builder
117
Resets the device's weight. No partitions will be reassigned to or from the
118
device until after running 'rebalance'. This is so you can make multiple device
119
changes and rebalance them all just once.
122
.B swift-ring-builder
126
.B <ip>:<port>/<device_name>_<meta>
128
Resets the device's information. This information isn't used to assign
129
partitions, so you can use 'write_ring' afterward to rewrite the current ring
130
with the newer device information. Any of the parts are optional in the final
131
<ip>:<port>/<device_name>_<meta> parameter; just give what you want to change.
132
For instance set_info d74 _"snet: 5.6.7.8" would just update the meta data for
136
.B swift-ring-builder
141
Removes the device(s) from the ring. This should normally just be used for a
142
device that has failed. For a device you wish to decommission, it's best to set
143
its weight to 0, wait for it to drain all its data, then use this remove
144
command. This will not take effect until after running 'rebalance'. This is so
145
you can make multiple device changes and rebalance them all just once.
148
.B swift-ring-builder
152
Attempts to rebalance the ring by reassigning partitions that haven't been
156
.B swift-ring-builder
160
Just runs the validation routines on the ring.
163
.B swift-ring-builder
167
Just rewrites the distributable ring file. This is done automatically after a
168
successful rebalance, so really this is only useful after one or more
169
set_info calls when no rebalance is needed but you want to send out the new
172
.SH SET MIN PART HOURS
173
.B swift-ring-builder
175
.B set_min_part_hours
178
Changes the <min_part_hours> to the given <hours>. This should be set to
179
however long a full replication/update cycle takes. We're working on a way
180
to determine this more easily than scanning logs.