[swift] Putting Swift storage disks to sleep

Vedartham Bharath vedarthambharath at gmail.com
Wed Dec 19 19:04:18 UTC 2018


Thank you for the reply!
This is what we are attempting to do in our project:
We have a Swift set up with where it stores 3 replicas of each object.
The primary disks(ie disks in the ring) are all HDDs. We want to keep
one of the primary disks of an object write to sleep and write the 3rd
replica to a SSD handoff. After a while, we wake the HDD which was in
sleep and the 3rd replica is put back using the replicator daemon.
Once everything is restored back to the 3rd HDD, we keep the HDD back
to sleep. This cycle continues.

I would love your insight on this.

Bharath

On Wed, Dec 19, 2018 at 9:09 PM John Dickinson <me at not.mn> wrote:
>
> There is no way to use raw disks in Swift. Swift requires drives to have a filesystem that supports (large) xattrs. We strongly recommend using XFS.
>
> I'm not sure why you are trying to sleep the drives; Swift is designed to keep drives spinning all the time (via spreading requests across all drives and continually performing background checks). In fact, oftentimes deployers replace "green" firmware with firmware that does not sleep the drives. If you are trying to simulate failures, unmounting the drives should be sufficient. If you are trying to simply reduce power consumption, temporarily putting drives to sleep is likely to be a lot of work (ie code changes) to do effectively and likely to not yield significant results. For power savings, I'd recommend looking at lower powered CPUs first and switching to lower powered storage (eg flash) second.
>
> --John
>
>
>
> On 18 Dec 2018, at 20:50, Vedartham Bharath wrote:
>
> > Hi all,
> >
> > I am an undergraduate currently working on a research project which
> > involves OpenStack Swift. In my project, I have set up Swift to run on
> > 4 disks. I want to put down one of the hard disks to sleep i.e reduce
> > the spin. I am using the hdparm tool in Linux to do this.
> >
> > The problem is that the disk automatically wakes back up after being
> > put to sleep. I have found out that this is due to the fact that all
> > the storage disks of Swift have to be mounted with XFS and the sync
> > processes of XFS require the disk to wake up. I was wondering if there
> > is a way to use a disk without a filesystem in Swift and if not, are
> > there any other ways of putting storage disks in Swift to sleep? I
> > have made sure the object replicator and object auditor do not wake
> > the disk up. My goal is to be able to control putting the disk to
> > sleep and waking it up when I need.
> >
> > Details of set up:
> > Software: OpenStack Swift Newton with Keystone
> > OS: Ubuntu 16.04
> >
> > Thanks!



More information about the openstack-discuss mailing list