- Fixes bug 1092538.
Change-Id: Id9eb9446b32a800b1c7e0ef72882747424c65b6e
| ... | ... |
@@ -99,7 +99,7 @@ function configure_swift() {
|
| 99 | 99 |
# changing the permissions so we can run it as our user. |
| 100 | 100 |
|
| 101 | 101 |
USER_GROUP=$(id -g) |
| 102 |
- sudo mkdir -p ${SWIFT_DATA_DIR}/drives
|
|
| 102 |
+ sudo mkdir -p ${SWIFT_DATA_DIR}/{drives,cache}
|
|
| 103 | 103 |
sudo chown -R $USER:${USER_GROUP} ${SWIFT_DATA_DIR}
|
| 104 | 104 |
|
| 105 | 105 |
# Create a loopback disk and format it to XFS. |
| ... | ... |
@@ -273,16 +273,22 @@ EOF |
| 273 | 273 |
swift_node_config=${SWIFT_CONFIG_DIR}/object-server/${node_number}.conf
|
| 274 | 274 |
cp ${SWIFT_DIR}/etc/object-server.conf-sample ${swift_node_config}
|
| 275 | 275 |
generate_swift_config ${swift_node_config} ${node_number} $[OBJECT_PORT_BASE + 10 * (node_number - 1)]
|
| 276 |
+ iniset ${swift_node_config} filter:recon recon_cache_path ${SWIFT_DATA_DIR}/cache
|
|
| 277 |
+ # Using a sed and not iniset/iniuncomment because we want to a global |
|
| 278 |
+ # modification and make sure it works for new sections. |
|
| 279 |
+ sed -i -e "s,#[ ]*recon_cache_path .*,recon_cache_path = ${SWIFT_DATA_DIR}/cache," ${swift_node_config}
|
|
| 276 | 280 |
|
| 277 | 281 |
swift_node_config=${SWIFT_CONFIG_DIR}/container-server/${node_number}.conf
|
| 278 | 282 |
cp ${SWIFT_DIR}/etc/container-server.conf-sample ${swift_node_config}
|
| 279 | 283 |
generate_swift_config ${swift_node_config} ${node_number} $[CONTAINER_PORT_BASE + 10 * (node_number - 1)]
|
| 280 | 284 |
iniuncomment ${swift_node_config} app:container-server allow_versions
|
| 281 | 285 |
iniset ${swift_node_config} app:container-server allow_versions "true"
|
| 286 |
+ sed -i -e "s,#[ ]*recon_cache_path .*,recon_cache_path = ${SWIFT_DATA_DIR}/cache," ${swift_node_config}
|
|
| 282 | 287 |
|
| 283 | 288 |
swift_node_config=${SWIFT_CONFIG_DIR}/account-server/${node_number}.conf
|
| 284 | 289 |
cp ${SWIFT_DIR}/etc/account-server.conf-sample ${swift_node_config}
|
| 285 | 290 |
generate_swift_config ${swift_node_config} ${node_number} $[ACCOUNT_PORT_BASE + 10 * (node_number - 1)]
|
| 291 |
+ sed -i -e "s,#[ ]*recon_cache_path .*,recon_cache_path = ${SWIFT_DATA_DIR}/cache," ${swift_node_config}
|
|
| 286 | 292 |
done |
| 287 | 293 |
|
| 288 | 294 |
swift_log_dir=${SWIFT_DATA_DIR}/logs
|