Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

UX: should not add any invalid cluster property into CIB #861

Closed
zzhou1 opened this issue Aug 20, 2021 · 7 comments
Closed

UX: should not add any invalid cluster property into CIB #861

zzhou1 opened this issue Aug 20, 2021 · 7 comments

Comments

@zzhou1
Copy link
Contributor

zzhou1 commented Aug 20, 2021

tw:~ # crm configure property maintenance=true
WARNING: cib-bootstrap-options: unknown attribute 'maintenance'
tw:~ # crm configure show | grep maintenance
maintenance=true

Instead of a WARNING, it's an ERROR. And, crmsh should not add any invalid cluster property into CIB.
ERROR: cib-bootstrap-options: unknown attribute 'maintenance'

Or, ideally, better to be,
tw:~ # crm configure property maintenance=true
WARNING: cib-bootstrap-options: the best match of unknown attribute 'maintenance' is 'maintenance-mode'
tw:~ # crm configure show | grep maintenance
maintenance-mode=true

@gao-yan
Copy link
Member

gao-yan commented Sep 6, 2021

Be aware some users might have their customized cluster properties for their own use cases. Right, @fmherschel?

@fmherschel
Copy link

@gao-yan that's true! For SAPHanaSR* resource agents we meed to add special properties not already known by the cluster. The RA does the writes and the reads so the cluster core is here only a vehicle.

@liangxin1300
Copy link
Collaborator

BTW, I found this "WARNING" only raised when there is RA added in cluster
When there is no RA added, there is no "WARNING" when you adding any unknown properties
Should this behavior be changed? @zzhou1 @gao-yan

@fmherschel
Copy link

@liangxin1300 Do you mean RA as resource agent?? Or do you mean, if any resource exists the behavior is different?

@liangxin1300
Copy link
Collaborator

@liangxin1300 Do you mean RA as resource agent?? Or do you mean, if any resource exists the behavior is different?

Yes I mean this behavior:

# newly setup cluster without any resource agent configured
crm(live/15sp3-1)configure# property name_test=xin # add unknown property
crm(live/15sp3-1)configure# commit                           # don't complain here
crm(live/15sp3-1)configure# primitive d Dummy         # add resource agent
crm(live/15sp3-1)configure# commit
crm(live/15sp3-1)configure# property age=19             # add unknown property
crm(live/15sp3-1)configure# commit                            # do complain here
WARNING: cib-bootstrap-options: unknown attribute 'name_test'
WARNING: cib-bootstrap-options: unknown attribute 'age'

@gao-yan
Copy link
Member

gao-yan commented Feb 2, 2022

I don't know why it has to behave differently with/without resources :-)

But AFAICS it alright as long as they are just warnings rather than errors, so that crm configure commit should succeed.

@fmherschel
Copy link

@liangxin1300 My point was only about you do not add an resource agent but a resource. The resource agent is a part ot Software handling the resource as a plugin of the cluster. Adding a resource agent would be to add a script in e.g. /usr/lib/ocf/resource.d/heartbeat/MyNewDummy. And such things could also influence the warnings, if you then add a resource using the new RA (here MyNewDummy).

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

No branches or pull requests

4 participants