Discussion:
[Linux-ha-dev] [Problem] external/vcenter fails in stonith of the guest of the similar name.
r***@ybb.ne.jp
2012-10-22 00:20:53 UTC
Permalink
Hi All,

external/vcenter fails in stonith of the guest of the similar name.

For example, as for the practice of stonith of sr2, stonith does backup-sr2 when two guests of sr2,backup-sr2 exist.

The problem is a thing by the next search.

$vm = Vim::find_entity_view(view_type => "VirtualMachine", filter => { name => qr/\Q$host_to_vm{$targetHost}\E/i });


It seems to be caused by the fact that the correction that Mr. Lars pointed out before leaks out.

* http://lists.community.tummy.com/pipermail/linux-ha-dev/2011-April/018397.html

(snip)
Unless this filter thing has a special mode where it internally does a
"$x eq $y" for scalars and "$x =~ $y" for explicitly designated qr//
Regexp objects, I'd suggest to here also do
filter => { name => qr/^\Q$realTarget\E$/i }
(snip)

Please revise it to add a character of ^ to a search.

Best Regards,
Hideo Yamauchi.
Dejan Muhamedagic
2012-10-22 15:37:22 UTC
Permalink
Hi Hideo-san,
Post by r***@ybb.ne.jp
Hi All,
external/vcenter fails in stonith of the guest of the similar name.
For example, as for the practice of stonith of sr2, stonith does backup-sr2 when two guests of sr2,backup-sr2 exist.
The problem is a thing by the next search.
$vm = Vim::find_entity_view(view_type => "VirtualMachine", filter => { name => qr/\Q$host_to_vm{$targetHost}\E/i });
It seems to be caused by the fact that the correction that Mr. Lars pointed out before leaks out.
* http://lists.community.tummy.com/pipermail/linux-ha-dev/2011-April/018397.html
(snip)
Unless this filter thing has a special mode where it internally does a
"$x eq $y" for scalars and "$x =~ $y" for explicitly designated qr//
Regexp objects, I'd suggest to here also do
filter => { name => qr/^\Q$realTarget\E$/i }
(snip)
Please revise it to add a character of ^ to a search.
Applied. Thanks!

Dejan
Post by r***@ybb.ne.jp
Best Regards,
Hideo Yamauchi.
_______________________________________________________
http://lists.linux-ha.org/mailman/listinfo/linux-ha-dev
Home Page: http://linux-ha.org/
r***@ybb.ne.jp
2012-10-22 16:02:35 UTC
Permalink
Hi Dejan,
Post by Dejan Muhamedagic
Post by r***@ybb.ne.jp
Please revise it to add a character of ^ to a search.
Applied. Thanks!
I confirmed it.
(http://hg.linux-ha.org/glue/rev/0809ed6abeb7)

Many Thanks,
Hideo Yamauchi.
Post by Dejan Muhamedagic
Hi Hideo-san,
Post by r***@ybb.ne.jp
Hi All,
external/vcenter fails in stonith of the guest of the similar name.
For example, as for the practice of stonith of sr2, stonith does backup-sr2 when two guests of sr2,backup-sr2 exist.
The problem is a thing by the next search.
  $vm = Vim::find_entity_view(view_type => "VirtualMachine", filter => { name => qr/\Q$host_to_vm{$targetHost}\E/i });
It seems to be caused by the fact that the correction that Mr. Lars pointed out before leaks out.
  * http://lists.community.tummy.com/pipermail/linux-ha-dev/2011-April/018397.html
(snip)
Unless this filter thing has a special mode where it internally does a
"$x eq $y" for scalars and "$x =~ $y" for explicitly designated qr//
Regexp objects, I'd suggest to here also do
    filter => { name => qr/^\Q$realTarget\E$/i }
(snip)
Please revise it to add a character of ^ to a search.
Applied. Thanks!
Dejan
Post by r***@ybb.ne.jp
Best Regards,
Hideo Yamauchi.
_______________________________________________________
http://lists.linux-ha.org/mailman/listinfo/linux-ha-dev
Home Page: http://linux-ha.org/
_______________________________________________________
http://lists.linux-ha.org/mailman/listinfo/linux-ha-dev
Home Page: http://linux-ha.org/
Loading...