Christine Caulfield | 29 Oct 12:32 2008
Picon

Re: clvmd locking disabled

Stepan Kadlec wrote:
> one more report:
> 
> # vgscan
> File descriptor 3 (/dev/tty) leaked on vgscan invocation. Parent PID
> 3389: bash
> File descriptor 5 (/dev/pts/1) leaked on vgscan invocation. Parent PID
> 3389: bash
> File descriptor 7 (pipe:[9066]) leaked on vgscan invocation. Parent PID
> 3389: bash
>   Unknown locking type requested.
>   Locking type 3 initialisation failed.
> 
> steve
> 
> Stepan Kadlec wrote:
>>     hello,
>>     I can't make the clustered LVM running. it can't start the
>> built-in clustered locking mechanism (using cman).
>>
>>     lvm is compiled with following options:
>>
>> ./configure --with-clvmd=cman  --with-cluster=shared
>> --libdir=/usr/lib64/ --enable-dmeventd --enable-cmdlib

If you've built using with-cluster=shared then the locking type in
lvm.conf should be 2 and not 3, provided you have remembered to install
the shared library that gets built.

I recommend you don't build it shared (the default), and use locking type 3
(Continue reading)

Stepan Kadlec | 31 Oct 13:22 2008

Re: clvmd locking disabled

Christine Caulfield wrote:
> Stepan Kadlec wrote:
>> one more report:
>>
>> # vgscan
>> File descriptor 3 (/dev/tty) leaked on vgscan invocation. Parent PID
>> 3389: bash
>> File descriptor 5 (/dev/pts/1) leaked on vgscan invocation. Parent PID
>> 3389: bash
>> File descriptor 7 (pipe:[9066]) leaked on vgscan invocation. Parent PID
>> 3389: bash
>>   Unknown locking type requested.
>>   Locking type 3 initialisation failed.
>>
>> steve
>>
>> Stepan Kadlec wrote:
>>>     hello,
>>>     I can't make the clustered LVM running. it can't start the
>>> built-in clustered locking mechanism (using cman).
>>>
>>>     lvm is compiled with following options:
>>>
>>> ./configure --with-clvmd=cman  --with-cluster=shared
>>> --libdir=/usr/lib64/ --enable-dmeventd --enable-cmdlib
> 
> 
> If you've built using with-cluster=shared then the locking type in
> lvm.conf should be 2 and not 3, provided you have remembered to install
> the shared library that gets built.
(Continue reading)

Milan Broz | 31 Oct 13:43 2008
Picon

Re: clvmd locking disabled

Stepan Kadlec wrote:
> ok, I have recompiled it with --with-cluster=internal, but still seeing:
> 
> WARNING: Locking disabled. Be careful! This could corrupt your metadata.

Is it during clvmd initialization only?

clvmd tries to initialize locks for possible already activated volumes
(mostly safety/force restart check, clvmd must start before clustered LVs
are activated anyway)

It simply run lvs command (forcing nolocking for this command)
to check which volumes are activated.
The log message is misleading here...

After clvmd initialization, it should work as expected.

Milan

_______________________________________________
linux-lvm mailing list
linux-lvm <at> redhat.com
https://www.redhat.com/mailman/listinfo/linux-lvm
read the LVM HOW-TO at http://tldp.org/HOWTO/LVM-HOWTO/

Stepan Kadlec | 3 Nov 17:56 2008

Re: clvmd locking disabled

Milan Broz wrote:
> Stepan Kadlec wrote:
>> ok, I have recompiled it with --with-cluster=internal, but still seeing:
>>
>> WARNING: Locking disabled. Be careful! This could corrupt your metadata.
> 
> Is it during clvmd initialization only?
> 

yes. where else could it occur?

> clvmd tries to initialize locks for possible already activated volumes
> (mostly safety/force restart check, clvmd must start before clustered LVs
> are activated anyway)
> 
> It simply run lvs command (forcing nolocking for this command)
> to check which volumes are activated.
> The log message is misleading here...
> 

the LVs are imho not activated but CLVMd still complains about disabled 
locking:

xen01:/etc/init.d # lvscan
File descriptor 3 (/dev/tty) leaked on lvscan invocation. Parent PID 
2637: bash
File descriptor 5 (/dev/pts/5) leaked on lvscan invocation. Parent PID 
2637: bash
File descriptor 7 (pipe:[721181]) leaked on lvscan invocation. Parent 
PID 2637: bash
(Continue reading)

Stepan Kadlec | 4 Nov 09:47 2008

Re: clvmd locking disabled


Milan Broz wrote:
> Stepan Kadlec wrote:
>> ok, I have recompiled it with --with-cluster=internal, but still seeing:
>>
>> WARNING: Locking disabled. Be careful! This could corrupt your metadata.
> 
> Is it during clvmd initialization only?
> 
> clvmd tries to initialize locks for possible already activated volumes
> (mostly safety/force restart check, clvmd must start before clustered LVs
> are activated anyway)
> 
> It simply run lvs command (forcing nolocking for this command)
> to check which volumes are activated.
> The log message is misleading here...
> 
> After clvmd initialization, it should work as expected.
> 

I have looked into the sources:

1) the clvmd starts the thread lvm_thread_fn() from clvmd.c
2) it calls the init_lvm() function from lvm-functions.c
3) it calls the get_initial_state() function from lvm-functions.c
4) in get_initial_state is following call:

FILE *lvs = popen
             ("lvm lvs  --config 'log{command_names=0 prefix=\"\"}' 
--nolocking --noheadings -o vg_uuid,lv_uuid,lv_attr,vg_attr",
(Continue reading)

Christine Caulfield | 31 Oct 14:27 2008
Picon

Re: clvmd locking disabled

Stepan Kadlec wrote:
> Christine Caulfield wrote:
>> Stepan Kadlec wrote:
>>> one more report:
>>>
>>> # vgscan
>>> File descriptor 3 (/dev/tty) leaked on vgscan invocation. Parent PID
>>> 3389: bash
>>> File descriptor 5 (/dev/pts/1) leaked on vgscan invocation. Parent PID
>>> 3389: bash
>>> File descriptor 7 (pipe:[9066]) leaked on vgscan invocation. Parent PID
>>> 3389: bash
>>>   Unknown locking type requested.
>>>   Locking type 3 initialisation failed.
>>>
>>> steve
>>>
>>> Stepan Kadlec wrote:
>>>>     hello,
>>>>     I can't make the clustered LVM running. it can't start the
>>>> built-in clustered locking mechanism (using cman).
>>>>
>>>>     lvm is compiled with following options:
>>>>
>>>> ./configure --with-clvmd=cman  --with-cluster=shared
>>>> --libdir=/usr/lib64/ --enable-dmeventd --enable-cmdlib
>>
>>
>> If you've built using with-cluster=shared then the locking type in
>> lvm.conf should be 2 and not 3, provided you have remembered to install
(Continue reading)


Gmane