Description of problem: Either a recent change in logwatch or systemd started producing the warning in the summary in logwatch's report. According to systemctl, lvmetad is indeed running but disabled. As I never configured any of this and have been running with whatever defaults, were installed this is a bit strange, rpm -v lvm2 shows all defaults, and use_lvmetad is set to 1 in lvm.conf Version-Release number of selected component (if applicable): lvm2-2.02.106-1.fc20.x86_64 systemd-208-22.fc20.x86_64 How reproducible: After every boot Steps to Reproduce: 1. Reboot, look in the logs or wait for "next" logwatch report Actual results: Strange warning from LVM Expected results: Additional info: The warning asks to restart lvmetad before enabling, but lvmetad is running and enabed in lvm.conf, maybe not in systemd, but who restarted lvmetad then?
(lvmetad is a LVM cache daemon that speeds up LVM metadata processing by caching them so it's not needed to read the metadata from disk next time.) If use_lvmetad=1 is set in lvm.conf, then there must be a time during boot (or shutdown) when a script overrides this setting to use_lvmetad=0 while lvmetad is already running. The warning is there because if lvmetad is already instantiated and running, then using use_lvmetad=0 will cause LVM commands run under this setting to not notify lvmetad about any changes - therefore lvmetad may miss some information - hence the warning. Simply what happened here is: 1) lvm2-lvmetad.socket systemd unit initialized, waiting for query on lvmetad socket 2) the very first LVM command run with use_lvmetad=1 (which is the default in F20) during boot, it accesses the lvmetad socket, lvmetad is instantiated via systemd (lvm2-lvmetad.service is now active) 3) (more LVM commands can run now, using lvmetad) 4) an LVM command run overriding the default (use_lvmetad=0), hence the warning in the log 5) when system is up and running, LVM commands now uses the use_lvmetad=1 in lvm.conf installed We need to find 4) - where the lvm command is overriding defaults (this must be either '<lvm command> --config "global{use_lvmetad=0}"' or if anyone's using lvm2app library, then overriding this default from there. Just to make sure before analyzing this further - does this happen only during boot sequence or even when the system is already up and running or during shutdown? If only during boot sequence, it must be foreign boot script. If it's during shutdown, it's actually lvm2-monitor.service that must override use_lvmetad to 0, because of systemd bug which is not yet resolved: [0] f20/~ # cat /lib/systemd/system/lvm2-monitor.service | grep -E 'use_lvmetad|bug' # The lvmetad must be disabled here, it needs https://bugzilla.redhat.com/show_bug.cgi?id=843587 to be resolved first. ExecStop=/usr/sbin/lvm vgchange --monitor n --config 'global{use_lvmetad=0}' --ignoreskippedcluster When you look at the logs, is there a message just before the warning like: "systemd[1]: Stopping Monitoring of LVM2 mirrors, snapshots etc. using dmeventd or progress polling..." You can also confirm this by disabling lvm2-monitor.service temporarily: systemctl disable lvm2-monitor.service Then reboot (now the system runs without lvm2-monitor.service), then reboot again (for clean shutdown), and check the logs if it still contains the warning since previous boot. To enable the service again, run: systemctl enable lvm2-monitor.service If this is the case, I'll need to ask systemd team to move along with bug #843587 so we can remove the use_lvmetad=0 override in lvm2-monitor.service.
(In reply to Peter Rajnoha from comment #1) > You can also confirm this by disabling lvm2-monitor.service temporarily: > systemctl disable lvm2-monitor.service > > Then reboot (now the system runs without lvm2-monitor.service), then reboot > again (for clean shutdown), and check the logs if it still contains the > warning since previous boot. > > To enable the service again, run: > systemctl enable lvm2-monitor.service > > If this is the case, I'll need to ask systemd team to move along with bug > #843587 so we can remove the use_lvmetad=0 override in lvm2-monitor.service. I've just checked that - the bug #843587 seems to be handled better now in systemd. So instead, to check if this was the case, you can try editing /lib/systemd/system/lvm2-monitor.service and the replace these lines: # The lvmetad must be disabled here, it needs https://bugzilla.redhat.com/show_bug.cgi?id=843587 to be resolved first. ExecStop=/usr/sbin/lvm vgchange --monitor n --config 'global{use_lvmetad=0}' --ignoreskippedcluster with: ExecStop=/usr/sbin/lvm vgchange --monitor n --ignoreskippedcluster
- Happens at shutdown only. - The line: Stopping Monitoring of LVM2 mirrors, snapshots etc. using dmeventd or progress polling... shows up a few lines before the lvmetad warning (there are a few audit messages in between) - editing lvm2-monitor.service as in comment #2 gets rid of the warning
OK, thanks for the info. So that should be resolved with https://git.fedorahosted.org/cgit/lvm2.git/commit/?id=02628413ca99648e70e38406384be69e20a2a6ce. I'll add this on next lvm2 F20 update.
I don't expect any new updates for F20, marking this bz with CLOSED/NEXTRELEASE.