~openstack-ubuntu-packagers/swift/diablo

« back to all changes in this revision

Viewing changes to debian/mans/swift/swift-ring-builder.8

  • Committer: Soren Hansen
  • Date: 2011-07-12 12:35:12 UTC
  • mfrom: (5.1.24 zigo)
  • Revision ID: soren@linux2go.dk-20110712123512-w1aas600984pyehn
Merge a whole bunch of changes from Thomas Goirand.

Show diffs side-by-side

added added

removed removed

Lines of Context:
 
1
.TH swift\-ring\-builder 8
 
2
.SH NAME
 
3
swift\-ring\-builder \- Manipulate the swift ring storage devices.
 
4
 
 
5
.SH SYNOPSIS
 
6
.B swift\-ring\-builder
 
7
.B <builder_file>
 
8
.B [ACTION]
 
9
.B [parameters]
 
10
 
 
11
.SH DESCRIPTION
 
12
.B swift\-ring\-builder
 
13
 
 
14
Manipulate the swift ring. Please contribute a better long description!
 
15
 
 
16
.SH PARAMETERS
 
17
 
 
18
The parameter [ACTION] can take one of the following values:
 
19
 
 
20
.B create
 
21
.B search
 
22
.B add
 
23
.B set_weight
 
24
.B set_info
 
25
.B remove
 
26
.B rebalance
 
27
.B validate
 
28
.B write_ring
 
29
.B set_min_part_hours
 
30
 
 
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:
 
35
 
 
36
d<device_id>z<zone>\-<ip>:<port>/<device_name>_<meta>
 
37
 
 
38
Any part is optional, but you must include at least one part. Examples:
 
39
 
 
40
.B d74
 
41
Matches the device id 74
 
42
 
 
43
.B z1
 
44
Matches devices in zone 1
 
45
 
 
46
.B z1-1.2.3.4
 
47
Matches devices in zone 1 with the ip 1.2.3.4
 
48
 
 
49
.B 1.2.3.4
 
50
Matches devices in any zone with the ip 1.2.3.4
 
51
 
 
52
.B z1:5678
 
53
Matches devices in zone 1 using port 5678
 
54
 
 
55
.B :5678
 
56
Matches devices that use port 5678
 
57
 
 
58
.B /sdb1
 
59
Matches devices with the device name sdb1
 
60
 
 
61
.B _shiny
 
62
Matches devices with shiny in the meta data
 
63
 
 
64
.B _"snet: 5.6.7.8"
 
65
Matches devices with snet: 5.6.7.8 in the meta data
 
66
 
 
67
Most specific example: d74z1-1.2.3.4:5678/sdb1_"snet: 5.6.7.8"
 
68
 
 
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
 
71
included.
 
72
 
 
73
.SH CREATE
 
74
.B swift-ring-builder
 
75
.B <builder_file>
 
76
.B create
 
77
.B <part_power>
 
78
.B <replicas>
 
79
.B <min_part_hours>
 
80
 
 
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
 
83
than once.
 
84
 
 
85
.SH SHOW
 
86
.B swift-ring-builder
 
87
.B <builder_file>
 
88
 
 
89
Shows information about the ring and the devices within.
 
90
 
 
91
.SH SEARCH
 
92
.B swift-ring-builder
 
93
.B <builder_file>
 
94
.B search
 
95
.B <search-value>
 
96
 
 
97
Shows information about matching devices.
 
98
 
 
99
.SH ADD
 
100
.B swift-ring-builder
 
101
.B <builder_file>
 
102
.B add
 
103
.B z<zone>-<ip>:<port>/<device_name>_<meta>
 
104
.B <weight>
 
105
 
 
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.
 
109
 
 
110
.SH SET WEIGHT
 
111
.B swift-ring-builder
 
112
.B <builder_file>
 
113
.B set_weight
 
114
.B <search-value>
 
115
.B <weight>
 
116
 
 
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.
 
120
 
 
121
.SH SET INFO
 
122
.B swift-ring-builder
 
123
.B <builder_file>
 
124
.B set_info
 
125
.B <search-value>
 
126
.B <ip>:<port>/<device_name>_<meta>
 
127
 
 
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
 
133
device id 74.
 
134
 
 
135
.SH REMOVE
 
136
.B swift-ring-builder
 
137
.B <builder_file>
 
138
.B remove
 
139
.B <search-value>
 
140
 
 
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.
 
146
 
 
147
.SH REBALANCE
 
148
.B swift-ring-builder
 
149
.B <builder_file>
 
150
.B rebalance
 
151
 
 
152
Attempts to rebalance the ring by reassigning partitions that haven't been
 
153
recently reassigned.
 
154
 
 
155
.SH VALIDATE
 
156
.B swift-ring-builder
 
157
.B <builder_file>
 
158
.B validate
 
159
 
 
160
Just runs the validation routines on the ring.
 
161
 
 
162
.SH WRITE RING
 
163
.B swift-ring-builder
 
164
.B <builder_file>
 
165
.B write_ring
 
166
 
 
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
 
170
device information.
 
171
 
 
172
.SH SET MIN PART HOURS
 
173
.B swift-ring-builder
 
174
.B <builder_file>
 
175
.B set_min_part_hours
 
176
.B <hours>
 
177
 
 
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.