Configure and mount storage devices#
The first step in the process of installing Object Storage for RPCO is configuring and mounting the storage devices. Object Storage for RPCO requires a minimum of three object storage devices with mounted storage drives.
The example commands in this procedure assume that the storage devices are
labeled sdc
through sdg
.
Determine the storage devices on the node to use for Object Storage.
Format each of these devices with XFS. While formatting the devices, add a unique label for each device.
Note
Without labels, a failed drive can cause mount points to shift and data to become inaccessible.
For example, create the file systems on the devices by using the mkfs command:
$ apt-get install xfsprogs $ mkfs.xfs -f -i size=1024 -L sdc /dev/sdc $ mkfs.xfs -f -i size=1024 -L sdd /dev/sdd $ mkfs.xfs -f -i size=1024 -L sde /dev/sde $ mkfs.xfs -f -i size=1024 -L sdf /dev/sdf $ mkfs.xfs -f -i size=1024 -L sdg /dev/sdg
Add the mount locations to the
/etc/fstab
file so that the storage devices are remounted on boot. The following example mount options are recommended when using XFS.Note
Finish all modifications to the
/etc/fstab
file before mounting the new file systems created within the storage devices.LABEL=sdc /srv/node/sdc xfs noatime,nodiratime,nobarrier,logbufs=8,nobootwait 0 0 LABEL=sdd /srv/node/sdd xfs noatime,nodiratime,nobarrier,logbufs=8,nobootwait 0 0 LABEL=sde /srv/node/sde xfs noatime,nodiratime,nobarrier,logbufs=8,nobootwait 0 0 LABEL=sdf /srv/node/sdf xfs noatime,nodiratime,nobarrier,logbufs=8,nobootwait 0 0 LABEL=sdg /srv/node/sdg xfs noatime,nodiratime,nobarrier,logbufs=8,nobootwait 0 0
Create the mount points for the devices by using the mkdir command:
$ mkdir -p /srv/node/sdc $ mkdir -p /srv/node/sdd $ mkdir -p /srv/node/sde $ mkdir -p /srv/node/sdf $ mkdir -p /srv/node/sdg
The mount point is referenced as the
mount_point
parameter in theswift.yml
file (/etc/openstack_deploy/conf.d/swift.yml
).Mount the storage devices by using the mount command:
$ mount /srv/node/sdc $ mount /srv/node/sdd $ mount /srv/node/sde $ mount /srv/node/sdf $ mount /srv/node/sdg
To view an annotated example of the swift.yml
file, see
Object Storage configuration files.
For the devices mounted in the preceding steps, the mount locations would be as follows:
Device |
Mount location |
---|---|
/dev/sdc |
/srv/node/sdc |
/dev/sdd |
/srv/node/sdd |
/dev/sde |
/srv/node/sde |
/dev/sdf |
/srv/node/sdf |
/dev/sdg |
/srv/node/sdg |
The entry in the swift.yml
for the mounted devices would be as follows:
# drives:
# - name: sdc
# - name: sdd
# - name: sde
# - name: sdf
# - name: sdg
# mount_point: /srv/node