FAQ Search Today's Posts Mark Forums Read
» Video Reviews

» Linux Archive

Linux-archive is a website aiming to archive linux email lists and to make them easily accessible for linux users/developers.


» Sponsor

» Partners

» Sponsor

Go Back   Linux Archive > Redhat > Cluster Development

 
 
LinkBack Thread Tools
 
Old 01-12-2010, 03:00 PM
Christine Caulfield
 
Default fixing cpg names in 3.0.8?

On 12/01/10 16:24, David Teigland wrote:

I just discovered that the cpg group names that fenced, dlm_controld and
gfs_controld use in cluster3 include a nul within the name length. This
can happen because cpg names have both a string part and a length part,
and the length is currently being set to strlen + 1 instead of strlen.
It's harmless since all the code is making the same mistake, but it's an
obvious flaw.

You can easily see this by the trailing x00 from corosync-cpgtool,

fenced:defaultx00

If we fixed the length of the names, it would break internode
compatibility between 3.0.7 and 3.0.8 releases, e.g.

"fenced:defaultx00" and "fenced:default" are two different groups.

AFAIK we're not yet guaranteeing rolling upgrade compatibility from one
3.0 release to the next, so I think I should go ahead and fix this, unless
anyone feels strongly otherwise?



I'm sure we've seen this before. Oh well I'll repeat my opinion anyway.

I don't think it's a flaw and I don't see that it needs to be "fixed".
It's just the way things happen. What benefits accrue from changing it ?


Chrissie
 
Old 01-12-2010, 03:24 PM
David Teigland
 
Default fixing cpg names in 3.0.8?

I just discovered that the cpg group names that fenced, dlm_controld and
gfs_controld use in cluster3 include a nul within the name length. This
can happen because cpg names have both a string part and a length part,
and the length is currently being set to strlen + 1 instead of strlen.
It's harmless since all the code is making the same mistake, but it's an
obvious flaw.

You can easily see this by the trailing x00 from corosync-cpgtool,

fenced:defaultx00

If we fixed the length of the names, it would break internode
compatibility between 3.0.7 and 3.0.8 releases, e.g.

"fenced:defaultx00" and "fenced:default" are two different groups.

AFAIK we're not yet guaranteeing rolling upgrade compatibility from one
3.0 release to the next, so I think I should go ahead and fix this, unless
anyone feels strongly otherwise?

Dave
 
Old 01-12-2010, 03:55 PM
Jan Friesse
 
Default fixing cpg names in 3.0.8?

David,

> How about making corosync-cpgtool default to the -e behavior, and making
> -e = escape unprintable characters in group name ?
>
This can be done quickly, but I don't understand what is that good for
and how does it help. Internally (in cpg exec) names are compared with
full length. This behavior doesn't change from Whitetank. Only thing
what changed was addition of cpgtool, which will notice you on this (in
reality, testcpg, ... will display 0x00 too, but it not visible).

Regards,
Honza
 
Old 01-12-2010, 04:16 PM
David Teigland
 
Default fixing cpg names in 3.0.8?

On Tue, Jan 12, 2010 at 04:00:20PM +0000, Christine Caulfield wrote:
> On 12/01/10 16:24, David Teigland wrote:
> >I just discovered that the cpg group names that fenced, dlm_controld and
> >gfs_controld use in cluster3 include a nul within the name length. This
> >can happen because cpg names have both a string part and a length part,
> >and the length is currently being set to strlen + 1 instead of strlen.
> >It's harmless since all the code is making the same mistake, but it's an
> >obvious flaw.
> >
> >You can easily see this by the trailing x00 from corosync-cpgtool,
> >
> >fenced:defaultx00
> >
> >If we fixed the length of the names, it would break internode
> >compatibility between 3.0.7 and 3.0.8 releases, e.g.
> >
> >"fenced:defaultx00" and "fenced:default" are two different groups.
> >
> >AFAIK we're not yet guaranteeing rolling upgrade compatibility from one
> >3.0 release to the next, so I think I should go ahead and fix this, unless
> >anyone feels strongly otherwise?
>
>
> I'm sure we've seen this before. Oh well I'll repeat my opinion anyway.
>
> I don't think it's a flaw and I don't see that it needs to be "fixed".
> It's just the way things happen. What benefits accrue from changing it ?

Good point, it isn't a flaw per se, we just have inconsistent usages of
that api (ocfs_controld, at least, sets length to strlen). There's
something to be said for consistency, but you've convinced me it's not
worth changing.

How about making corosync-cpgtool default to the -e behavior, and making
-e = escape unprintable characters in group name ?

Dave
 

Thread Tools




All times are GMT. The time now is 03:00 PM.

VBulletin, Copyright ©2000 - 2014, Jelsoft Enterprises Ltd.
Content Relevant URLs by vBSEO ©2007, Crawlability, Inc.
Copyright 2007 - 2008, www.linux-archive.org