Note: This bug is displayed in read-only format because the product is no longer active in Red Hat Bugzilla.

Bug 628741

Summary: condor_configure_pool only allows adding features at lowest priority
Product: Red Hat Enterprise MRG Reporter: Erik Erlandson <eerlands>
Component: condor-wallaby-toolsAssignee: Robert Rati <rrati>
Status: CLOSED ERRATA QA Contact: Martin Kudlej <mkudlej>
Severity: high Docs Contact:
Priority: medium    
Version: 1.3CC: ltoscano, matt, mkudlej, rrati
Target Milestone: 1.3.2Keywords: FutureFeature
Target Release: ---   
Hardware: All   
OS: All   
Whiteboard:
Fixed In Version: condor-wallaby-tools-3.7-1 Doc Type: Enhancement
Doc Text:
Prior to this update, the 'condor_configure_pool' tool only allowed adding features at the lowest priority. Any duplicate parameters in features applied to a node always received the value for the parameter defined in the feature which was first applied with the parameter to the node or group. It was not possible to add a feature at a higher priority, and therefore control a parameter's value, without removing features and re-adding them in the desired order. This update adds two new commands to the 'condor_configure_pool' tool to allow to manage feature priorities. The first command ('insert') works just as the 'add' command does only it inserts the feature at the highest priority. The second command ('edit') takes no parameter or feature options and invokes an editor with the node represented in the YAML format. Features and parameters can now be added, removed, or edited. Once the changes are saved and the editor exited, the changes will be applied to the node or the group in the store.
Story Points: ---
Clone Of: Environment:
Last Closed: 2011-02-15 12:14:48 UTC Type: ---
Regression: --- Mount Type: ---
Documentation: --- CRM:
Verified Versions: Category: ---
oVirt Team: --- RHEL 7.3 requirements from Atomic Host:
Cloudforms Team: --- Target Upstream Version:
Embargoed:
Attachments:
Description Flags
dump of the config store on mrg31, should repro the behavior I'm seeing none

Description Erik Erlandson 2010-08-30 21:52:26 UTC
Created attachment 442044 [details]
dump of the config store on mrg31, should repro the behavior I'm seeing

Description of problem:

I created a feature called 'DisablePreemption' which sets PREEMT = FALSE, however when I deploy it, the PREEMPT default value seems to override it:

% condor_config_val -v PREEMPT
PREEMPT: ( ((Activity == "Suspended") && ((CurrentTime - EnteredCurrentActivity) > 10 * 60)) || (SUSPEND && (WANT_SUSPEND == False)) )
  Defined in '/var/lib/condor/wallaby_node.config', line 493.

Comment 1 Will Benton 2010-09-11 05:23:41 UTC
After looking at the dump, I suspected that this might be a problem with sqlite's type translators (or with QMF's type translators).  However, this appears to not be the case.  As far as I can tell, this is an integration issue with the configd or with Condor; I can't reproduce it in the store alone.  (See spec/bz628741_spec.rb in the wallaby source repo.)

Comment 2 Robert Rati 2010-09-13 21:27:54 UTC
The issue is with feature priorities.  The condor_configure_pool tool only allows appending features to a group/node, so the DisablePreemption feature had a lower priority than the VMUniverse feature (which included ExecuteNode, which in turn had a value for PREEMPT).  The result was the value of PREEMPT set by the DisablePreemption feature was overriden by the value provided for that parameter in the ExecuteNode feature.

This is the intended behavior of the system, but does expose an issue specific to user friendliness.  The above situation could currently be handled a few ways in the current setup:

1) The user explicitly sets parameter values on Groups/Nodes instead of in a different feature.  This will ensure they can not be overriden.

2) The user removes all features from the group/node, and then re-adds them in the order they want.

Neither is particularly user friendly.  There are a few proposed changes to handle this situation:

1) Create an insert option on condor_configure_pool.  This would act the same as the add function (which ideally would change to append), only the features were be inserted as the highest priority on the group/node.

2) Provide an ability to edit the priority of the features on a node/group.

1 is pretty simple and low-risk and is desirable for 1.3, but does create a new set of test scenarios.  2 I think is too risky to add at this stage of the release, but should be targeted for the next release.

Comment 3 Robert Rati 2010-10-22 20:12:27 UTC
The condor_configure_pool tool has 2 new commands:
- insert (-i|--insert)
- edit (-e|--edit)

The insert command will insert features at the highest priority

The edit command which will dump the group/node data into a file in YAML format and open an editor similar to how the store tool works.

The help also has add changed to append to better clarify what is happening.

Fixed in:
condor-wallaby-tools-3.7-1

Comment 4 Robert Rati 2010-11-29 19:32:05 UTC
    Technical note added. If any revisions are required, please edit the "Technical Notes" field
    accordingly. All revisions will be proofread by the Engineering Content Services team.
    
    New Contents:
C: The condor_configure_pool command will only allow adding features at lowest priority.
C: Any duplicate parameters in features applied to a node will always receive the value for the parameter defined in the feature first applied with the parameter to the node or group.  It is not possible to add a feature at a higher priority, and therefore control a parameters value, without removing features and re-adding in a the order desired.
F: 2 new commands were added to condor_configure_pool to allow to manage feature priorities.  The first command, insert, works just as the add command does only it inserts the feature at the highest priority.  The send command, edit, takes no parameter or feature options and invokes an editor with the node represented in YAML format.  Features and parameters can be added, removed, or edited.  Once the changes are saved and the editor exited, the changes will be applied to the node or group in the store.
R: It is now possible to insert a feature as the highest priority, or edit and completely re-arrange the feature priorities, for nodes and groups.

Comment 7 Martin Kudlej 2011-01-19 13:47:43 UTC
Tested on RHEL 5.6 x i386/x86_64 with:
condor-wallaby-base-db-1.4-5.el5
wallaby-utils-0.9.18-2.el5
condor-wallaby-tools-3.6-6.el5
ruby-wallaby-0.9.18-2.el5
python-wallabyclient-3.6-6.el5
condor-wallaby-client-3.6-6.el5
wallaby-0.9.18-2.el5

and it doesn't work.

Comment 8 Martin Kudlej 2011-01-19 16:00:14 UTC
Tested on RHEL 5.6 x i386/x86_64 with:
python-wallabyclient-3.8-8.el5
wallaby-utils-0.10.0-2.el5
ruby-wallaby-0.10.0-2.el5
condor-wallaby-client-3.8-8.el5
condor-wallaby-base-db-1.5-2.el5
condor-wallaby-tools-3.8-8.el5
wallaby-0.10.0-2.el5

and "edit" and "insert" work as it is expected. --> VERIFIED

Comment 9 Martin Prpič 2011-02-09 13:11:23 UTC
    Technical note updated. If any revisions are required, please edit the "Technical Notes" field
    accordingly. All revisions will be proofread by the Engineering Content Services team.
    
    Diffed Contents:
@@ -1,4 +1 @@
-C: The condor_configure_pool command will only allow adding features at lowest priority.
+Prior to this update, the 'condor_configure_pool' tool only allowed adding features at the lowest priority. Any duplicate parameters in features applied to a node always received the value for the parameter defined in the feature which was first applied with the parameter to the node or group. It was not possible to add a feature at a higher priority, and therefore control a parameter's value, without removing features and re-adding them in the desired order. This update adds two new commands to the 'condor_configure_pool' tool to allow to manage feature priorities. The first command ('insert') works just as the 'add' command does only it inserts the feature at the highest priority. The second command ('edit') takes no parameter or feature options and invokes an editor with the node represented in the YAML format. Features and parameters can now be added, removed, or edited. Once the changes are saved and the editor exited, the changes will be applied to the node or the group in the store.-C: Any duplicate parameters in features applied to a node will always receive the value for the parameter defined in the feature first applied with the parameter to the node or group.  It is not possible to add a feature at a higher priority, and therefore control a parameters value, without removing features and re-adding in a the order desired.
-F: 2 new commands were added to condor_configure_pool to allow to manage feature priorities.  The first command, insert, works just as the add command does only it inserts the feature at the highest priority.  The send command, edit, takes no parameter or feature options and invokes an editor with the node represented in YAML format.  Features and parameters can be added, removed, or edited.  Once the changes are saved and the editor exited, the changes will be applied to the node or group in the store.
-R: It is now possible to insert a feature as the highest priority, or edit and completely re-arrange the feature priorities, for nodes and groups.

Comment 10 errata-xmlrpc 2011-02-15 12:14:48 UTC
An advisory has been issued which should help the problem
described in this bug report. This report is therefore being
closed with a resolution of ERRATA. For more information
on therefore solution and/or where to find the updated files,
please follow the link below. You may reopen this bug report
if the solution does not work for you.

http://rhn.redhat.com/errata/RHBA-2011-0217.html