Ext4 hard disks won't sleep (constant reads)

fraktal

New Member
Jul 25, 2019
16
1
3
119
I have a plex LXC which has some EXT4 hard disks bind-mounted to it. This means they are mounted on the host.

Devices are /dev/sda, /dev/sdb and /dev/sdc. They aren't accessed by any other VM.

None of them will stay parked. I have manually parked them with hdparm -y but they wake up immediately.

This occurs even when the plex VM is off.

I have tracked disk activity (on the host) by doing echo 1 > /proc/sys/vm/block_dump and then reading dmesg -c after just a few seconds and it shows the following:

Code:
# cat dmesglog | grep sd
[84760.247802] vgs(8793): READ block 0 on sda (256 sectors)
[84760.247926] vgs(8793): READ block 0 on sdb (256 sectors)
[84760.247976] vgs(8793): READ block 0 on sdc (256 sectors)
[84760.320031] lvs(8794): READ block 0 on sda (256 sectors)
[84760.320120] lvs(8794): READ block 0 on sdb (256 sectors)
[84760.320152] lvs(8794): READ block 0 on sdc (256 sectors)
[84770.404495] vgs(8811): READ block 0 on sda (256 sectors)
[84770.404582] vgs(8811): READ block 0 on sdb (256 sectors)
[84770.404612] vgs(8811): READ block 0 on sdc (256 sectors)
[84770.460378] lvs(8812): READ block 0 on sda (256 sectors)
[84770.460465] lvs(8812): READ block 0 on sdb (256 sectors)
[84770.460498] lvs(8812): READ block 0 on sdc (256 sectors)
[84780.540668] vgs(8838): READ block 0 on sda (256 sectors)
[84780.540752] vgs(8838): READ block 0 on sdb (256 sectors)
[84780.540784] vgs(8838): READ block 0 on sdc (256 sectors)
[84780.600731] lvs(8839): READ block 0 on sda (256 sectors)
[84780.600819] lvs(8839): READ block 0 on sdb (256 sectors)
[84780.600852] lvs(8839): READ block 0 on sdc (256 sectors)
[84790.685233] vgs(8855): READ block 0 on sda (256 sectors)
[84790.685321] vgs(8855): READ block 0 on sdb (256 sectors)
[84790.685349] vgs(8855): READ block 0 on sdc (256 sectors)
[84790.749130] lvs(8856): READ block 0 on sda (256 sectors)
[84790.749224] lvs(8856): READ block 0 on sdb (256 sectors)
[84790.749252] lvs(8856): READ block 0 on sdc (256 sectors)
[84800.857703] vgs(8878): READ block 0 on sda (256 sectors)
[84800.857785] vgs(8878): READ block 0 on sdb (256 sectors)
[84800.857817] vgs(8878): READ block 0 on sdc (256 sectors)
[84800.921459] lvs(8879): READ block 0 on sda (256 sectors)
[84800.921564] lvs(8879): READ block 0 on sdb (256 sectors)
[84800.921596] lvs(8879): READ block 0 on sdc (256 sectors)
[84810.021962] vgs(8897): READ block 0 on sda (256 sectors)
[84810.022045] vgs(8897): READ block 0 on sdb (256 sectors)
[84810.022078] vgs(8897): READ block 0 on sdc (256 sectors)
[84810.077799] lvs(8898): READ block 0 on sda (256 sectors)
[84810.077887] lvs(8898): READ block 0 on sdb (256 sectors)
[84810.077915] lvs(8898): READ block 0 on sdc (256 sectors)
[84820.173928] vgs(8914): READ block 0 on sda (256 sectors)
[84820.174058] vgs(8914): READ block 0 on sdb (256 sectors)
[84820.174107] vgs(8914): READ block 0 on sdc (256 sectors)
[84820.238098] lvs(8915): READ block 0 on sda (256 sectors)
[84820.238188] lvs(8915): READ block 0 on sdb (256 sectors)
[84820.238220] lvs(8915): READ block 0 on sdc (256 sectors)
[84830.310433] vgs(8931): READ block 0 on sda (256 sectors)
[84830.310520] vgs(8931): READ block 0 on sdb (256 sectors)
[84830.310547] vgs(8931): READ block 0 on sdc (256 sectors)
[84830.382499] lvs(8932): READ block 0 on sda (256 sectors)
[84830.382589] lvs(8932): READ block 0 on sdb (256 sectors)
[84830.382621] lvs(8932): READ block 0 on sdc (256 sectors)
[84840.454413] vgs(8955): READ block 0 on sda (256 sectors)
[84840.454500] vgs(8955): READ block 0 on sdb (256 sectors)
[84840.454529] vgs(8955): READ block 0 on sdc (256 sectors)
[84840.514840] lvs(8956): READ block 0 on sda (256 sectors)
[84840.514933] lvs(8956): READ block 0 on sdb (256 sectors)
[84840.514965] lvs(8956): READ block 0 on sdc (256 sectors)
[84850.603450] vgs(8973): READ block 0 on sda (256 sectors)
[84850.603538] vgs(8973): READ block 0 on sdb (256 sectors)
[84850.603566] vgs(8973): READ block 0 on sdc (256 sectors)
[84850.651191] lvs(8974): READ block 0 on sda (256 sectors)
[84850.651284] lvs(8974): READ block 0 on sdb (256 sectors)
[84850.651312] lvs(8974): READ block 0 on sdc (256 sectors)
[84860.727663] vgs(8996): READ block 0 on sda (256 sectors)
[84860.727750] vgs(8996): READ block 0 on sdb (256 sectors)
[84860.727778] vgs(8996): READ block 0 on sdc (256 sectors)
[84860.791634] lvs(8997): READ block 0 on sda (256 sectors)
[84860.791727] lvs(8997): READ block 0 on sdb (256 sectors)
[84860.791762] lvs(8997): READ block 0 on sdc (256 sectors)
[84870.868371] vgs(9015): READ block 0 on sda (256 sectors)
[84870.868459] vgs(9015): READ block 0 on sdb (256 sectors)
[84870.868492] vgs(9015): READ block 0 on sdc (256 sectors)
[84870.923930] lvs(9016): READ block 0 on sda (256 sectors)
[84870.924012] lvs(9016): READ block 0 on sdb (256 sectors)
[84870.924043] lvs(9016): READ block 0 on sdc (256 sectors)
[84880.996522] vgs(9032): READ block 0 on sda (256 sectors)
[84880.996609] vgs(9032): READ block 0 on sdb (256 sectors)
[84880.996638] vgs(9032): READ block 0 on sdc (256 sectors)
[84881.052302] lvs(9033): READ block 0 on sda (256 sectors)
[84881.052392] lvs(9033): READ block 0 on sdb (256 sectors)
[84881.052424] lvs(9033): READ block 0 on sdc (256 sectors)
[84890.140195] vgs(9047): READ block 0 on sda (256 sectors)
[84890.140276] vgs(9047): READ block 0 on sdb (256 sectors)
[84890.140309] vgs(9047): READ block 0 on sdc (256 sectors)
[84890.196650] lvs(9048): READ block 0 on sda (256 sectors)
[84890.196739] lvs(9048): READ block 0 on sdb (256 sectors)
[84890.196771] lvs(9048): READ block 0 on sdc (256 sectors)
[84900.297362] vgs(9073): READ block 0 on sda (256 sectors)
[84900.297454] vgs(9073): READ block 0 on sdb (256 sectors)
[84900.297482] vgs(9073): READ block 0 on sdc (256 sectors)
[84900.368937] lvs(9074): READ block 0 on sda (256 sectors)
[84900.369025] lvs(9074): READ block 0 on sdb (256 sectors)
[84900.369052] lvs(9074): READ block 0 on sdc (256 sectors)
[84910.433246] vgs(9089): READ block 0 on sda (256 sectors)
[84910.433332] vgs(9089): READ block 0 on sdb (256 sectors)
[84910.433365] vgs(9089): READ block 0 on sdc (256 sectors)
[84910.497323] lvs(9090): READ block 0 on sda (256 sectors)
[84910.497412] lvs(9090): READ block 0 on sdb (256 sectors)
[84910.497443] lvs(9090): READ block 0 on sdc (256 sectors)
[84920.570074] vgs(9115): READ block 0 on sda (256 sectors)
[84920.570164] vgs(9115): READ block 0 on sdb (256 sectors)
[84920.570197] vgs(9115): READ block 0 on sdc (256 sectors)
[84920.621691] lvs(9116): READ block 0 on sda (256 sectors)
[84920.621777] lvs(9116): READ block 0 on sdb (256 sectors)
[84920.621805] lvs(9116): READ block 0 on sdc (256 sectors)
[84930.689669] vgs(9130): READ block 0 on sda (256 sectors)
[84930.689778] vgs(9130): READ block 0 on sdb (256 sectors)
[84930.689806] vgs(9130): READ block 0 on sdc (256 sectors)
[84930.742051] lvs(9131): READ block 0 on sda (256 sectors)
[84930.742145] lvs(9131): READ block 0 on sdb (256 sectors)
[84930.742173] lvs(9131): READ block 0 on sdc (256 sectors)
[84940.818755] vgs(9147): READ block 0 on sda (256 sectors)
[84940.818842] vgs(9147): READ block 0 on sdb (256 sectors)
[84940.818870] vgs(9147): READ block 0 on sdc (256 sectors)
[84940.866455] lvs(9148): READ block 0 on sda (256 sectors)
[84940.866545] lvs(9148): READ block 0 on sdb (256 sectors)
[84940.866577] lvs(9148): READ block 0 on sdc (256 sectors)
[84950.939234] vgs(9166): READ block 0 on sda (256 sectors)
[84950.939324] vgs(9166): READ block 0 on sdb (256 sectors)
[84950.939356] vgs(9166): READ block 0 on sdc (256 sectors)
[84951.002766] lvs(9167): READ block 0 on sda (256 sectors)
[84951.002848] lvs(9167): READ block 0 on sdb (256 sectors)
[84951.002880] lvs(9167): READ block 0 on sdc (256 sectors)
[84960.078573] vgs(9186): READ block 0 on sda (256 sectors)
[84960.078661] vgs(9186): READ block 0 on sdb (256 sectors)
[84960.078687] vgs(9186): READ block 0 on sdc (256 sectors)
[84960.155057] lvs(9187): READ block 0 on sda (256 sectors)
[84960.155150] lvs(9187): READ block 0 on sdb (256 sectors)
[84960.155178] lvs(9187): READ block 0 on sdc (256 sectors)
[84970.236583] vgs(9207): READ block 0 on sda (256 sectors)
[84970.236667] vgs(9207): READ block 0 on sdb (256 sectors)
[84970.236699] vgs(9207): READ block 0 on sdc (256 sectors)
[84970.307481] lvs(9208): READ block 0 on sda (256 sectors)
[84970.307576] lvs(9208): READ block 0 on sdb (256 sectors)
[84970.307624] lvs(9208): READ block 0 on sdc (256 sectors)
[84980.387429] vgs(9232): READ block 0 on sda (256 sectors)
[84980.387516] vgs(9232): READ block 0 on sdb (256 sectors)
[84980.387545] vgs(9232): READ block 0 on sdc (256 sectors)
[84980.455814] lvs(9233): READ block 0 on sda (256 sectors)
[84980.455907] lvs(9233): READ block 0 on sdb (256 sectors)
[84980.455934] lvs(9233): READ block 0 on sdc (256 sectors)
[84990.531908] vgs(9249): READ block 0 on sda (256 sectors)
[84990.531995] vgs(9249): READ block 0 on sdb (256 sectors)
[84990.532057] vgs(9249): READ block 0 on sdc (256 sectors)
[84990.588233] lvs(9250): READ block 0 on sda (256 sectors)
[84990.588322] lvs(9250): READ block 0 on sdb (256 sectors)
[84990.588354] lvs(9250): READ block 0 on sdc (256 sectors)
[85000.668474] vgs(9268): READ block 0 on sda (256 sectors)
[85000.668576] vgs(9268): READ block 0 on sdb (256 sectors)
[85000.668608] vgs(9268): READ block 0 on sdc (256 sectors)
[85000.732598] lvs(9269): READ block 0 on sda (256 sectors)
[85000.732691] lvs(9269): READ block 0 on sdb (256 sectors)
[85000.732742] lvs(9269): READ block 0 on sdc (256 sectors)
[85010.809272] vgs(9289): READ block 0 on sda (256 sectors)
[85010.809366] vgs(9289): READ block 0 on sdb (256 sectors)
[85010.809394] vgs(9289): READ block 0 on sdc (256 sectors)
[85010.868908] lvs(9290): READ block 0 on sda (256 sectors)
[85010.868994] lvs(9290): READ block 0 on sdb (256 sectors)
[85010.869022] lvs(9290): READ block 0 on sdc (256 sectors)
[85020.932939] vgs(9312): READ block 0 on sda (256 sectors)
[85020.933022] vgs(9312): READ block 0 on sdb (256 sectors)
[85020.933054] vgs(9312): READ block 0 on sdc (256 sectors)
[85020.989241] lvs(9313): READ block 0 on sda (256 sectors)
[85020.989331] lvs(9313): READ block 0 on sdb (256 sectors)
[85020.989363] lvs(9313): READ block 0 on sdc (256 sectors)
[85030.061252] vgs(9329): READ block 0 on sda (256 sectors)
[85030.061337] vgs(9329): READ block 0 on sdb (256 sectors)
[85030.061365] vgs(9329): READ block 0 on sdc (256 sectors)
[85030.113669] lvs(9330): READ block 0 on sda (256 sectors)
[85030.113761] lvs(9330): READ block 0 on sdb (256 sectors)
[85030.113793] lvs(9330): READ block 0 on sdc (256 sectors)
[85040.182366] vgs(9354): READ block 0 on sda (256 sectors)
[85040.182458] vgs(9354): READ block 0 on sdb (256 sectors)
[85040.182488] vgs(9354): READ block 0 on sdc (256 sectors)
[85040.261900] lvs(9355): READ block 0 on sda (256 sectors)
[85040.261988] lvs(9355): READ block 0 on sdb (256 sectors)
[85040.262016] lvs(9355): READ block 0 on sdc (256 sectors)
[86331.733867] vgs(21394): READ block 0 on sda (256 sectors)
[86331.733945] vgs(21394): READ block 0 on sdb (256 sectors)
[86331.733974] vgs(21394): READ block 0 on sdc (256 sectors)
[86331.806635] lvs(21395): READ block 0 on sda (256 sectors)
[86331.806718] lvs(21395): READ block 0 on sdb (256 sectors)
[86331.806746] lvs(21395): READ block 0 on sdc (256 sectors)
[86341.906460] vgs(21467): READ block 0 on sda (256 sectors)
[86341.906541] vgs(21467): READ block 0 on sdb (256 sectors)
[86341.906569] vgs(21467): READ block 0 on sdc (256 sectors)
[86341.955000] lvs(21468): READ block 0 on sda (256 sectors)
[86341.955081] lvs(21468): READ block 0 on sdb (256 sectors)
[86341.955109] lvs(21468): READ block 0 on sdc (256 sectors)

I don't know much about what's going on here, but it looks like lvs and vgs are doing some sort of statistical read or activity check or something, which is causing the drives to spin up? There don't appear to be any actual data reads or writes. Any ideas how I stop this from happening so they can get some sleep? Thank you.
 

LnxBil

Well-Known Member
Feb 21, 2015
3,951
367
83
Germany
I don't know much about what's going on here, but it looks like lvs and vgs are doing some sort of statistical read or activity check or something, which is causing the drives to spin up? There don't appear to be any actual data reads or writes. Any ideas how I stop this from happening so they can get some sleep?
AFAIK, sleep mode is not needed anymore and counter productive these days. The spin-up causes more harm than constant spinning. If you're worried about power consumption, I'd recommend SSDs.
 

fraktal

New Member
Jul 25, 2019
16
1
3
119
Noted, but perhaps you could humour me by suggesting why this behaviour is happening anyway?
 

LnxBil

Well-Known Member
Feb 21, 2015
3,951
367
83
Germany
Noted, but perhaps you could humour me by suggesting why this behaviour is happening anyway?
Honestly, I have no clue. Skimming over the lvm.conf, I also did not notice any parameter to change this.

Is your OS also installed on those disks? If so, PVE itself write a lot.
 

fraktal

New Member
Jul 25, 2019
16
1
3
119
Nope, if it was I could understand it. The disks are literally only used by the Plex container, but this happens even when it's off.

I wondered if it's statistics collection for the web console? I did test with no web consoles open and it still happened.
 

LnxBil

Well-Known Member
Feb 21, 2015
3,951
367
83
Germany
I wondered if it's statistics collection for the web console? I did test with no web consoles open and it still happened.
You can try and shutdown all PVE services and see if it still happens. The idea that the statistics collector wakes the disk is pretty good.
 

fraktal

New Member
Jul 25, 2019
16
1
3
119
Well, I stopped everything here plus lxc-monitord and it still did it. [EDIT:WRONG]

then I stopped lxcfs, apparmor and smartmontools and it stopped o_O

My money is on smartmontools. More investigation to follow...
 
Last edited:

fraktal

New Member
Jul 25, 2019
16
1
3
119
My mistake, it stops and starts with the pve-cluster service. So how do I stop pve-cluster reading block 0 of all my disks several times a second?!
 

LnxBil

Well-Known Member
Feb 21, 2015
3,951
367
83
Germany
So how do I stop pve-cluster reading block 0 of all my disks several times a second?!
AFAIK, the cluster service is only used if you have a cluster. Therefore you can just disable it and see if everything works as expected.
 

fraktal

New Member
Jul 25, 2019
16
1
3
119
AFAIK, the cluster service is only used if you have a cluster. Therefore you can just disable it and see if everything works as expected.
Don't think so. From the documentation:
pve-cluster
This service is the heart of any Proxmox VE installation. It provides the Proxmox_Cluster_file_system_(pmxcfs), a database-driven file system for storing configuration files, replicated in real time on all nodes using corosync.

The service makes the data accessible on the normal file system level, mounted at /etc/pve (using fuse). All Proxmox VE related configuration is stored there.

Note: You also need this service if you do not run a cluster.
 

fraktal

New Member
Jul 25, 2019
16
1
3
119
I had not! But now I have....and I *think* it's solved my problem!

May the internet gods bless you (and LnxBil for trying)!
 
  • Like
Reactions: lonsimbt

About

The Proxmox community has been around for many years and offers help and support for Proxmox VE and Proxmox Mail Gateway. We think our community is one of the best thanks to people like you!

Get your subscription!

The Proxmox team works very hard to make sure you are running the best software and getting stable updates and security enhancements, as well as quick enterprise support. Tens of thousands of happy customers have a Proxmox subscription. Get your own in 60 seconds.

Buy now!