* [linux-lvm] Again: duplicate PVs - filter rules
@ 2017-01-14 5:41 knebb
2017-01-14 9:26 ` Zdenek Kabelac
0 siblings, 1 reply; 3+ messages in thread
From: knebb @ 2017-01-14 5:41 UTC (permalink / raw)
To: linux-lvm
Hi all,
I thought my filter rules where fine now. But they are not.
I have in /etc/lvm/lvm.conf:
filter = [ "r|/dev/sdb|","r|/dev/sdc|" ]
I scan my PVs:
[root@backuppc ~]# pvscan --cache
WARNING: PV AvK0Vn-vAdJ-K4nf-0N1x-u1fR-dlWG-dJezdg on /dev/sdc was
already found on /dev/drbd1.
WARNING: Disabling lvmetad cache which does not support duplicate PVs.
WARNING: Not using lvmetad because duplicate PVs were found.
[root@backuppc ~]# pvscan
WARNING: PV AvK0Vn-vAdJ-K4nf-0N1x-u1fR-dlWG-dJezdg on /dev/sdc was
already found on /dev/drbd1.
WARNING: Disabling lvmetad cache which does not support duplicate PVs.
WARNING: Not using lvmetad because duplicate PVs were found.
PV /dev/sda2 VG cl lvm2 [15,00 GiB / 0 free]
PV /dev/drbd1 VG test lvm2 [3,00 GiB / 0 free]
Total: 2 [17,99 GiB] / in use: 2 [17,99 GiB] / in no VG: 0 [0 ]
So question again, why does it accept my /dev/sdc as PV discarding
filter rules?
/Greetings
Christian
^ permalink raw reply [flat|nested] 3+ messages in thread
* Re: [linux-lvm] Again: duplicate PVs - filter rules
2017-01-14 5:41 [linux-lvm] Again: duplicate PVs - filter rules knebb
@ 2017-01-14 9:26 ` Zdenek Kabelac
2017-01-14 9:50 ` knebb
0 siblings, 1 reply; 3+ messages in thread
From: Zdenek Kabelac @ 2017-01-14 9:26 UTC (permalink / raw)
To: LVM general discussion and development
Dne 14.1.2017 v 06:41 knebb@knebb.de napsal(a):
> Hi all,
>
> I thought my filter rules where fine now. But they are not.
>
> I have in /etc/lvm/lvm.conf:
>
> filter = [ "r|/dev/sdb|","r|/dev/sdc|" ]
>
> I scan my PVs:
>
> [root@backuppc ~]# pvscan --cache
> WARNING: PV AvK0Vn-vAdJ-K4nf-0N1x-u1fR-dlWG-dJezdg on /dev/sdc was
> already found on /dev/drbd1.
> WARNING: Disabling lvmetad cache which does not support duplicate PVs.
> WARNING: Not using lvmetad because duplicate PVs were found.
> [root@backuppc ~]# pvscan
> WARNING: PV AvK0Vn-vAdJ-K4nf-0N1x-u1fR-dlWG-dJezdg on /dev/sdc was
> already found on /dev/drbd1.
> WARNING: Disabling lvmetad cache which does not support duplicate PVs.
> WARNING: Not using lvmetad because duplicate PVs were found.
> PV /dev/sda2 VG cl lvm2 [15,00 GiB / 0 free]
> PV /dev/drbd1 VG test lvm2 [3,00 GiB / 0 free]
> Total: 2 [17,99 GiB] / in use: 2 [17,99 GiB] / in no VG: 0 [0 ]
>
> So question again, why does it accept my /dev/sdc as PV discarding
> filter rules?
'pvscan --cache' is different from other lvm commands - it controls filling
of 'lvmetad' from udev rules.
So if you plan to use lvmetad - you need to have uniqueness on 'global' level.
So that's why there is global_filter.
So you should copy your filter to global_filter.
Regards
Zdenek
^ permalink raw reply [flat|nested] 3+ messages in thread
* Re: [linux-lvm] Again: duplicate PVs - filter rules
2017-01-14 9:26 ` Zdenek Kabelac
@ 2017-01-14 9:50 ` knebb
0 siblings, 0 replies; 3+ messages in thread
From: knebb @ 2017-01-14 9:50 UTC (permalink / raw)
To: linux-lvm
Thanks!
To be honest, I was not aware of global filters. And not aware of using
lvmetad, but it is enabled by default (CentOS7).
So I added the global_filter and now everything is fine:
global_filter = [ "r|/dev/sdb|","r|/dev/sdc|" ]
Greetings
Christian
^ permalink raw reply [flat|nested] 3+ messages in thread
end of thread, other threads:[~2017-01-14 9:52 UTC | newest]
Thread overview: 3+ messages (download: mbox.gz follow: Atom feed
-- links below jump to the message on this page --
2017-01-14 5:41 [linux-lvm] Again: duplicate PVs - filter rules knebb
2017-01-14 9:26 ` Zdenek Kabelac
2017-01-14 9:50 ` knebb
This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox;
as well as URLs for NNTP newsgroup(s).