[Linux-ha-dev] Stonith turns node names to lowercase
dejanmm at fastmail.fm
Wed Oct 19 10:02:47 MDT 2011
On Wed, Oct 19, 2011 at 10:49:57AM +0200, Alberic de Pertat wrote:
> > > I am currently in the process of writing a fencing agent for VMware
> > > vCenter. After some tests, I noticed that the stonith command is
> > > turning the nodename to lowercase.
> > But there is already a vcenter stonith plugin (external/vcenter).
> Argh I should have started there.
> > > The problem is that almost every VM in my inventory is uppercase
> > > with some mixed case too. VMware allows you to have two VM with
> > > the same name but different cases. I cannot find a proper way to
> > > deal with this as a case insensitive search through the inventory
> > > could yield more than one result.
> > Interesting. Not sure why would one want to have two VM's names
> > differ only in case.
> I can't really say, but since it is possible, people will do eventually it.
I'd really be very reluctant to support such setups. It can only
cause headache for everybody involved.
> > > Looking through the stonith command source (Mercurial HEAD), I
> > > found the following in stonith.c (l. 456) :
> > >
> > > g_strdown(nodecopy);
> > >
> > > Is there a reason for this ?
> > Not completely sure, but most probably it was there because some
> > devices ignore case and produce only upper (or lower) case names.
> > The case should be ignored when matching node names.
> Well, I went around it by using VMware UUIDs, which are known to be unique and persistent, so the problem is solved for me but may arise again later.
> I'm attaching what I did for reference. If I can find time to do it, I'll try to merge this (UUID support) with the vcenter agent.
> Thanks to all.
> Albéric de Pertat
> 01 40 86 45 81
> Linux-HA-Dev: Linux-HA-Dev at lists.linux-ha.org
> Home Page: http://linux-ha.org/
More information about the Linux-HA-Dev