ldirectord ipvsadm не показывают IP реалов и не работу wtih кардиостимулятор и corosync

сначала спасибо за внимание.

У меня есть проблема с ldirectord, который я не могу решить, я комментирую свою ситуацию:

Я имею два узла с производителем темпа и corosync и настраиваю ресурсы сонов:

root@ldap1:/home/mamartin# crm status
Last updated: Tue Jun  3 12:58:30 2014
Last change: Tue Jun  3 12:23:47 2014 via cibadmin on ldap1
Stack: openais
Current DC: ldap2 - partition with quorum
Version: 1.1.7-ee0730e13d124c3d58f00016c3376a1de5323cff
2 Nodes configured, 2 expected votes
7 Resources configured.

Online: [ ldap1 ldap2 ]

 Resource Group: IPV_LVS
     IPV_4    (ocf::heartbeat:IPaddr2):    Started ldap1
     IPV_6    (ocf::heartbeat:IPv6addr):    Started ldap1
     lvs    (ocf::heartbeat:ldirectord):    Started ldap1
 Clone Set: clon_IPV_lo [IPV_lo]
     Started: [ ldap2 ]
     Stopped: [ IPV_lo:1 ]





root@ldap1:/home/mamartin# crm configure show
node ldap2 \
    attributes standby="off"
node ldap1 \
    attributes standby="off"
primitive IPV-lo_4 ocf:heartbeat:IPaddr \
    params ip="192.168.1.10" cidr_netmask="32" nic="lo" \
    op monitor interval="5s"
primitive IPV-lo_6 ocf:heartbeat:IPv6addrLO \
    params ipv6addr="[fc00:1::3]" cidr_netmask="64" \
    op monitor interval="5s"
primitive IPV_4 ocf:heartbeat:IPaddr2 \
    params ip="192.168.1.10" nic="eth0" cidr_netmask="25" lvs_support="true" \
    op monitor interval="5s"
primitive IPV_6 ocf:heartbeat:IPv6addr \
    params ipv6addr="[fc00:1::3]" nic="eth0" cidr_netmask="64" \
    op monitor interval="5s"
primitive lvs ocf:heartbeat:ldirectord \
    params configfile="/etc/ldirectord.cf" \
    op monitor interval="20" timeout="10" \
    meta target-role="Started"
group IPV_LVS IPV_4 IPV_6 lvs
group IPV_lo IPV-lo_6 IPV-lo_4
clone clon_IPV_lo IPV_lo \
    meta interleave="true" target-role="Started"
location cli-prefer-IPV_LVS IPV_LVS \
    rule $id="cli-prefer-rule-IPV_LVS" inf: #uname eq ldap1
colocation LVS_no_IPV_lo -inf: clon_IPV_lo IPV_LVS
property $id="cib-bootstrap-options" \
    dc-version="1.1.7-ee0730e13d124c3d58f00016c3376a1de5323cff" \
    cluster-infrastructure="openais" \
    expected-quorum-votes="2" \
    no-quorum-policy="ignore" \
    stonith-enabled="false" \
    last-lrm-refresh="1401264327"
rsc_defaults $id="rsc-options" \
    resource-stickiness="1000"


Проблема находится в ipvsadm, только показывают один реальный IP, когда я настроил два теперь, покажите ldirector.cf:



root@ldap1:/home/mamartin# ipvsadm
IP Virtual Server version 1.2.1 (size=4096)
Prot LocalAddress:Port Scheduler Flags
  -> RemoteAddress:Port           Forward Weight ActiveConn InActConn
TCP  ldap-maqueta.cica.es:ldap wrr
  -> ldap2.cica.es:ldap            Route   4      0 0
TCP  [[fc00:1::3]]:ldap wrr
  -> [[fc00:1::2]]:ldap Route   4      0 0

root@ldap1:/home/mamartin# cat /etc/ldirectord.cf
checktimeout=10
checkinterval=2
autoreload=yes
logfile="/var/log/ldirectord.log"
quiescent=yes

#ipv4
virtual=192.168.1.10:389
        real=192.168.1.11:389 gate 4
        real=192.168.1.12:389 gate 4
        scheduler=wrr
        protocol=tcp
     checktype=on
#ipv6
virtual6=[[fc00:1::3]]:389
        real6=[[fc00:1::1]]:389 gate 4
        real6=[[fc00:1::2]]:389 gate 4
        scheduler=wrr
        protocol=tcp
        checkport=389
     checktype=on


и в журналах я вижу, что ничто не очищается:



root@ldap1:/home/mamartin# ldirectord -d /etc/ldirectord.cf start
DEBUG2: Running system(/sbin/ipvsadm -a -t 192.168.1.10:389 -r 192.168.1.11:389 -g -w 0)
Running system(/sbin/ipvsadm -a -t 192.168.1.10:389 -r 192.168.1.11:389 -g -w 0)
DEBUG2: Quiescent real server: 192.168.1.11:389 (192.168.1.10:389) (Weight set to 0)
Quiescent real server: 192.168.1.11:389 (192.168.1.10:389) (Weight set to 0)
DEBUG2: Disabled real server=on:tcp:192.168.1.11:389:::4:gate:\/: (virtual=tcp:192.168.1.10:389)
DEBUG2: Running system(/sbin/ipvsadm -a -t 192.168.1.10:389 -r 192.168.1.12:389 -g -w 0)
Running system(/sbin/ipvsadm -a -t 192.168.1.10:389 -r 192.168.1.12:389 -g -w 0)
DEBUG2: Quiescent real server: 192.168.1.12:389 (192.168.1.10:389) (Weight set to 0)
Quiescent real server: 192.168.1.12:389 (192.168.1.10:389) (Weight set to 0)
DEBUG2: Disabled real server=on:tcp:192.168.1.12:389:::4:gate:\/: (virtual=tcp:192.168.1.10:389)
DEBUG2: Checking on: Real servers are added without any checks
DEBUG2: Resetting soft failure count: 192.168.1.12:389 (tcp:192.168.1.10:389)
Resetting soft failure count: 192.168.1.12:389 (tcp:192.168.1.10:389)
DEBUG2: Running system(/sbin/ipvsadm -a -t 192.168.1.10:389 -r 192.168.1.12:389 -g -w 4)
Running system(/sbin/ipvsadm -a -t 192.168.1.10:389 -r 192.168.1.12:389 -g -w 4)
Destination already exists




root@ldap1:/home/mamartin# cat /var/log/ldirectord.log
[Tue Jun  3 09:39:29 2014|ldirectord.cf|19266] Quiescent real server: 192.168.1.11:389 (192.168.1.10:389) (Weight set to 0)
[Tue Jun  3 09:39:29 2014|ldirectord.cf|19266] Quiescent real server: 192.168.1.12:389 (192.168.1.10:389) (Weight set to 0)
[Tue Jun  3 09:39:29 2014|ldirectord.cf|19266] Resetting soft failure count: 192.168.1.12:389 (tcp:192.168.1.10:389)
[Tue Jun  3 09:39:29 2014|ldirectord.cf|19266] system(/sbin/ipvsadm -a -t 192.168.1.10:389 -r 192.168.1.12:389 -g -w 4) failed:
[Tue Jun  3 09:39:29 2014|ldirectord.cf|19266] Added real server: 192.168.1.12:389 (192.168.1.10:389) (Weight set to 4)
[Tue Jun  3 09:39:29 2014|ldirectord.cf|19266] Resetting soft failure count: 192.168.1.11:389 (tcp:192.168.1.10:389)
[Tue Jun  3 09:39:29 2014|ldirectord.cf|19266] Restored real server: 192.168.1.11:389 (192.168.1.10:389) (Weight set to 4)
[Tue Jun  3 09:39:29 2014|ldirectord.cf|19266] Resetting soft failure count: [[fc00:1::2]]:389 (tcp:[[fc00:1::3]]:389)
[Tue Jun  3 09:39:29 2014|ldirectord.cf|19266] system(/sbin/ipvsadm -a -t [[fc00:1::3]]:389 -r [[fc00:1::2]]:389 -g -w 4) failed:
[Tue Jun  3 09:39:29 2014|ldirectord.cf|19266] Added real server: [[fc00:1::2]]:389 ([[fc00:1::3]]:389) (Weight set to 4)
[Tue Jun  3 09:39:29 2014|ldirectord.cf|19266] Resetting soft failure count: [[fc00:1::1]]:389 (tcp:[[fc00:1::3]]:389)
[Tue Jun  3 09:39:29 2014|ldirectord.cf|19266] Restored real server: [[fc00:1::1]]:389 ([[fc00:1::3]]:389) (Weight set to 4)

не знайте, является ли это ошибкой или ошибкой конфигурации, кто-либо может помочь?

С уважением.

1
задан 4 June 2014 в 10:50
1 ответ

Та же проблема после обновления серверов i386 с ядра 2.6.32 и 1.25 ipvadm до ядра 3.2.0 и 1.26 ipvadm, в то время как ipvsadm показывает только один /proc/net/ip_vs показывает все реальные серверы.

На недавно установленном amd64 все работает нормально.

Для решения проблемы я применил патч, размещенный здесь. http://archive.linuxvirtualserver.org/html/lvs-users/2011-08/msg00033.html и обсуждалось здесь https://bugs.debian.org/cgi-bin/bugreport.cgi?bug=685495

1
ответ дан 4 December 2019 в 00:24

Теги

Похожие вопросы