<?xml version="1.0" encoding="UTF-8" ?>

<bugzilla version="5.2"
          urlbase="https://bugzilla.altlinux.org/"
          
          maintainer="jenya@basealt.ru"
>

    <bug>
          <bug_id>40643</bug_id>
          
          <creation_ts>2021-08-03 15:49:49 +0300</creation_ts>
          <short_desc>не стартую кластерные ресурсы типа (class=ocf provider=heartbeat type=pgsql) в кластере, собранном в Altlinux 9</short_desc>
          <delta_ts>2022-01-24 15:10:42 +0300</delta_ts>
          <reporter_accessible>1</reporter_accessible>
          <cclist_accessible>1</cclist_accessible>
          <classification_id>3</classification_id>
          <classification>Distributions</classification>
          <product>Branch p9</product>
          <component>pacemaker-cli</component>
          <version>не указана</version>
          <rep_platform>x86</rep_platform>
          <op_sys>Linux</op_sys>
          <bug_status>CLOSED</bug_status>
          <resolution>FIXED</resolution>
          
          
          <bug_file_loc></bug_file_loc>
          <status_whiteboard></status_whiteboard>
          <keywords></keywords>
          <priority>P5</priority>
          <bug_severity>critical</bug_severity>
          <target_milestone>---</target_milestone>
          
          
          <everconfirmed>1</everconfirmed>
          <reporter name="Vadim Ponomarev">vponomarev</reporter>
          <assigned_to name="pav@altlinux.org">pav</assigned_to>
          <cc>cas</cc>
    
    <cc>vponomarev</cc>
          
          <qa_contact name="qa-p9@altlinux.org">qa-p9</qa_contact>

      

      

      

          <comment_sort_order>oldest_to_newest</comment_sort_order>  
          <long_desc isprivate="0" >
    <commentid>201186</commentid>
    <comment_count>0</comment_count>
    <who name="Vadim Ponomarev">vponomarev</who>
    <bug_when>2021-08-03 15:49:49 +0300</bug_when>
    <thetext>Проблема: не стартую кластерные ресурсы типа (class=ocf provider=heartbeat type=pgsql) в кластере, собранном в Altlinux 9.

Причина: команда /usr/sbin/crm_attribute некорретно отрабатывает значения параметра -v, начинающиеся с символа -
[root@test99c21735-node01 ~]# export OCF_RESOURCE_INSTANCE=&quot;test99c21735-clone&quot;
[root@test99c21735-node01 ~]# crm_mon -Afr1 | grep master-test99c21735-clone
    * master-test99c21735-clone         : INFINITY
[root@test99c21735-node01 ~]# /usr/sbin/crm_master -l reboot -v INFINITY
[root@test99c21735-node01 ~]# crm_mon -Afr1 | grep master-test99c21735-clone
    * master-test99c21735-clone         : INFINITY
[root@test99c21735-node01 ~]# /usr/sbin/crm_master -l reboot -v -INFINITY
Could not map name=FINITY to a UUID
[root@test99c21735-node01 ~]# /usr/sbin/crm_attribute -n master-$OCF_RESOURCE_INSTANCE -l reboot -v -INFINITY
Could not map name=FINITY to a UUID

Дополнительная информация:
[root@test99c21735-node01 ~]# cat /etc/os-release
NAME=&quot;ALT Server&quot;
VERSION=&quot;9.1&quot;
ID=altlinux
VERSION_ID=9.1
PRETTY_NAME=&quot;ALT Server 9.1 (FalcoRusticolus)&quot;
ANSI_COLOR=&quot;1;33&quot;
CPE_NAME=&quot;cpe:/o:alt:server:9.1&quot;
HOME_URL=&quot;https://basealt.ru/&quot;
BUG_REPORT_URL=&quot;https://bugs.altlinux.org/&quot;
[root@test99c21735-node01 ~]# rpm -q --whatprovides /usr/sbin/crm_master
pacemaker-cli-2.1.0-alt1.x86_64
[root@test99c21735-node01 ~]# rpm -q --whatprovides /usr/sbin/crm_attribute
pacemaker-cli-2.1.0-alt1.x86_64

В версии pacemaker-cli-2.0.3-alt1.x86_64 проблема не проявлялась.</thetext>
  </long_desc><long_desc isprivate="0" >
    <commentid>201187</commentid>
    <comment_count>1</comment_count>
    <who name="Andrey Cherepanov">cas</who>
    <bug_when>2021-08-03 16:07:07 +0300</bug_when>
    <thetext>(Ответ для Vadim Ponomarev на комментарий #0)
&gt; Проблема: не стартую кластерные ресурсы типа (class=ocf provider=heartbeat
&gt; type=pgsql) в кластере, собранном в Altlinux 9.
&gt; 
&gt; Причина: команда /usr/sbin/crm_attribute некорретно отрабатывает значения
&gt; параметра -v, начинающиеся с символа -
&gt; [root@test99c21735-node01 ~]# export
&gt; OCF_RESOURCE_INSTANCE=&quot;test99c21735-clone&quot;
&gt; [root@test99c21735-node01 ~]# crm_mon -Afr1 | grep master-test99c21735-clone
&gt;     * master-test99c21735-clone         : INFINITY
&gt; [root@test99c21735-node01 ~]# /usr/sbin/crm_master -l reboot -v INFINITY
&gt; [root@test99c21735-node01 ~]# crm_mon -Afr1 | grep master-test99c21735-clone
&gt;     * master-test99c21735-clone         : INFINITY
&gt; [root@test99c21735-node01 ~]# /usr/sbin/crm_master -l reboot -v -INFINITY
&gt; Could not map name=FINITY to a UUID
&gt; [root@test99c21735-node01 ~]# /usr/sbin/crm_attribute -n
&gt; master-$OCF_RESOURCE_INSTANCE -l reboot -v -INFINITY
&gt; Could not map name=FINITY to a UUID
&gt; 
&gt; Дополнительная информация:
&gt; [root@test99c21735-node01 ~]# cat /etc/os-release
&gt; NAME=&quot;ALT Server&quot;
&gt; VERSION=&quot;9.1&quot;
&gt; ID=altlinux
&gt; VERSION_ID=9.1
&gt; PRETTY_NAME=&quot;ALT Server 9.1 (FalcoRusticolus)&quot;
&gt; ANSI_COLOR=&quot;1;33&quot;
&gt; CPE_NAME=&quot;cpe:/o:alt:server:9.1&quot;
&gt; HOME_URL=&quot;https://basealt.ru/&quot;
&gt; BUG_REPORT_URL=&quot;https://bugs.altlinux.org/&quot;
&gt; [root@test99c21735-node01 ~]# rpm -q --whatprovides /usr/sbin/crm_master
&gt; pacemaker-cli-2.1.0-alt1.x86_64
&gt; [root@test99c21735-node01 ~]# rpm -q --whatprovides /usr/sbin/crm_attribute
&gt; pacemaker-cli-2.1.0-alt1.x86_64
&gt; 
&gt; В версии pacemaker-cli-2.0.3-alt1.x86_64 проблема не проявлялась.

Попробуйте:
/usr/sbin/crm_master -l reboot -v &apos;\-INFINITY&apos;</thetext>
  </long_desc><long_desc isprivate="0" >
    <commentid>201188</commentid>
    <comment_count>2</comment_count>
    <who name="Vadim Ponomarev">vponomarev</who>
    <bug_when>2021-08-03 16:49:40 +0300</bug_when>
    <thetext>(Ответ для Andrey Cherepanov на комментарий #1)
&gt; (Ответ для Vadim Ponomarev на комментарий #0)
&gt; &gt; Проблема: не стартую кластерные ресурсы типа (class=ocf provider=heartbeat
&gt; &gt; type=pgsql) в кластере, собранном в Altlinux 9.
&gt; &gt; 
&gt; &gt; Причина: команда /usr/sbin/crm_attribute некорретно отрабатывает значения
&gt; &gt; параметра -v, начинающиеся с символа -
&gt; &gt; [root@test99c21735-node01 ~]# export
&gt; &gt; OCF_RESOURCE_INSTANCE=&quot;test99c21735-clone&quot;
&gt; &gt; [root@test99c21735-node01 ~]# crm_mon -Afr1 | grep master-test99c21735-clone
&gt; &gt;     * master-test99c21735-clone         : INFINITY
&gt; &gt; [root@test99c21735-node01 ~]# /usr/sbin/crm_master -l reboot -v INFINITY
&gt; &gt; [root@test99c21735-node01 ~]# crm_mon -Afr1 | grep master-test99c21735-clone
&gt; &gt;     * master-test99c21735-clone         : INFINITY
&gt; &gt; [root@test99c21735-node01 ~]# /usr/sbin/crm_master -l reboot -v -INFINITY
&gt; &gt; Could not map name=FINITY to a UUID
&gt; &gt; [root@test99c21735-node01 ~]# /usr/sbin/crm_attribute -n
&gt; &gt; master-$OCF_RESOURCE_INSTANCE -l reboot -v -INFINITY
&gt; &gt; Could not map name=FINITY to a UUID
&gt; &gt; 
&gt; &gt; Дополнительная информация:
&gt; &gt; [root@test99c21735-node01 ~]# cat /etc/os-release
&gt; &gt; NAME=&quot;ALT Server&quot;
&gt; &gt; VERSION=&quot;9.1&quot;
&gt; &gt; ID=altlinux
&gt; &gt; VERSION_ID=9.1
&gt; &gt; PRETTY_NAME=&quot;ALT Server 9.1 (FalcoRusticolus)&quot;
&gt; &gt; ANSI_COLOR=&quot;1;33&quot;
&gt; &gt; CPE_NAME=&quot;cpe:/o:alt:server:9.1&quot;
&gt; &gt; HOME_URL=&quot;https://basealt.ru/&quot;
&gt; &gt; BUG_REPORT_URL=&quot;https://bugs.altlinux.org/&quot;
&gt; &gt; [root@test99c21735-node01 ~]# rpm -q --whatprovides /usr/sbin/crm_master
&gt; &gt; pacemaker-cli-2.1.0-alt1.x86_64
&gt; &gt; [root@test99c21735-node01 ~]# rpm -q --whatprovides /usr/sbin/crm_attribute
&gt; &gt; pacemaker-cli-2.1.0-alt1.x86_64
&gt; &gt; 
&gt; &gt; В версии pacemaker-cli-2.0.3-alt1.x86_64 проблема не проявлялась.
&gt; 
&gt; Попробуйте:
&gt; /usr/sbin/crm_master -l reboot -v &apos;\-INFINITY&apos;


[root@test99c21735-node01 ~]# /usr/sbin/crm_master -l reboot -v &apos;\-INFINITY&apos;
[root@test99c21735-node01 ~]# crm_mon -Afr1 | grep master-test99c21735-clone
    * master-test99c21735-clone         : \-INFINITY

Не работает (должно быть     * master-test99c21735-clone         : -INFINITY)
И даже если бы сработало, то это даже не workaround, поскольку кластерный агент pgsql содержит вызов crm_master без экранирующих символов, а править его - плохой путь.</thetext>
  </long_desc><long_desc isprivate="0" >
    <commentid>201189</commentid>
    <comment_count>3</comment_count>
    <who name="Vadim Ponomarev">vponomarev</who>
    <bug_when>2021-08-03 17:01:12 +0300</bug_when>
    <thetext>править надо  crm_attribute, кластерный агент корректный (ну за исключением того что юзает depricated-утилиту crm_master), его трогать не стоит
на самом деле сделать &quot;затычку&quot; в crm_master легко, ибо работает

[root@test99c21735-node01 ~]# /usr/sbin/crm_attribute -n master-$OCF_RESOURCE_INSTANCE -l reboot --update=-INFINITY
[root@test99c21735-node01 ~]# crm_mon -Afr1 | grep master-test99c21735-clone
    * master-test99c21735-clone         : -INFINITY

Но это плохой путь. Сломан crm_attribute - его нужно починить.</thetext>
  </long_desc><long_desc isprivate="0" >
    <commentid>203578</commentid>
    <comment_count>4</comment_count>
    <who name="Vadim Ponomarev">vponomarev</who>
    <bug_when>2021-10-08 11:05:13 +0300</bug_when>
    <thetext>Ошибка исправлена в pacemaker релиз 2.1.1:
Fixes since Pacemaker-2.1.0
 - tools: crm_attribute supports node attribute values starting with a &apos;-&apos; again (regression introduced in 2.1.0)

см. https://github.com/ClusterLabs/pacemaker/releases/tag/Pacemaker-2.1.1

Просьба собрать и заменить версию пакетов группы pacemaker c 2.1.0 на 2.1.1</thetext>
  </long_desc><long_desc isprivate="0" >
    <commentid>203579</commentid>
    <comment_count>5</comment_count>
    <who name="Andrey Cherepanov">cas</who>
    <bug_when>2021-10-08 11:27:09 +0300</bug_when>
    <thetext>(Ответ для Vadim Ponomarev на комментарий #4)
&gt; Ошибка исправлена в pacemaker релиз 2.1.1:
&gt; Fixes since Pacemaker-2.1.0
&gt;  - tools: crm_attribute supports node attribute values starting with a &apos;-&apos;
&gt; again (regression introduced in 2.1.0)
&gt; 
&gt; см. https://github.com/ClusterLabs/pacemaker/releases/tag/Pacemaker-2.1.1
&gt; 
&gt; Просьба собрать и заменить версию пакетов группы pacemaker c 2.1.0 на 2.1.1

Спасибо. 286631 BUILDING #1 [locked] p9 pacemaker.git=2.1.1-alt1</thetext>
  </long_desc><long_desc isprivate="0" >
    <commentid>204593</commentid>
    <comment_count>6</comment_count>
    <who name="Vadim Ponomarev">vponomarev</who>
    <bug_when>2021-11-09 09:49:49 +0300</bug_when>
    <thetext>В ветках p9 и p10 появилось. Спасибо. 
Подскажите, а когда появится в ветке c9f1?</thetext>
  </long_desc><long_desc isprivate="0" >
    <commentid>204598</commentid>
    <comment_count>7</comment_count>
    <who name="Andrey Cherepanov">cas</who>
    <bug_when>2021-11-09 10:19:01 +0300</bug_when>
    <thetext>(Ответ для Vadim Ponomarev на комментарий #6)
&gt; В ветках p9 и p10 появилось. Спасибо. 
&gt; Подскажите, а когда появится в ветке c9f1?

Только после закрытия найденной CVE.</thetext>
  </long_desc><long_desc isprivate="0" >
    <commentid>207058</commentid>
    <comment_count>8</comment_count>
    <who name="Andrey Cherepanov">cas</who>
    <bug_when>2022-01-24 15:10:42 +0300</bug_when>
    <thetext>Исправлено.</thetext>
  </long_desc>
      
      

    </bug>

</bugzilla>