How would it affect performance of the whole lvm2 pool if different physical volumes have had different speed properties?

I'm speaking foremost in the AWS/EC2 context. If I have one physical volume which is 1TB (3000 IOps), the other is 100GB (300 IOps), would it degrade the whole LVM volume group to just 300 IOps?

Based on this answer it seems that LVM is:

really just a table lookup in a fairly small table that block X is actually block Y on device Z.

Hence if I write one bunch of small files, which just happen to be mapped to the speedier physical volume, the whole transaction must be quicker than if that it was mapped to the slower drive?

How does it work in general?


Don't do it. Performance will be unpredictable, which is worse than being slow. PVs with the same size and speed is easier to understand.

Further, on linear volumes, it will use one PV at a time. Once extents start writing to the slow PV, that chunk of data will be slow.

There are ways to tier or cache on a Linux storage stack. For example, lvmcache and bcache.

All fast disk is simplest for consistent performance, at a higher cost.

  • Thanks for mentioning lvmcache as this may lead to reconsidering a cheaper backing space storage, but I'm pretty sure that random access time with the large volumes of data an enormous number of files will be crap. In my case performance will be (kind of) predictable either way, as I have continuously growing data, hence with 900 GB and 100 GB PVs only 10% of the latest files will be slow, which is acceptable. LVM has been chosen as it allows to grow file system without any downtime. – NarūnasK Nov 14 '16 at 11:26
  • On a good storage system, random access response will be consistent. Whether that average is good enough depends on requirements, such as how fast a database must respond. Something like tiering is necessary to get hot data to move to the faster storage. I don't see the point of striping LVM volumes of vastly different speeds (or sizes), you don't control what goes on which. – John Mahowald Nov 15 '16 at 0:38

Your Answer

By clicking “Post Your Answer”, you agree to our terms of service, privacy policy and cookie policy

Not the answer you're looking for? Browse other questions tagged or ask your own question.