Bug 672517 - condor_q -better prints error if classad expr should return false
Summary: condor_q -better prints error if classad expr should return false
Keywords:
Status: CLOSED ERRATA
Alias: None
Product: Red Hat Enterprise MRG
Classification: Red Hat
Component: condor
Version: beta
Hardware: Unspecified
OS: Unspecified
low
medium
Target Milestone: 2.0
: ---
Assignee: Will Benton
QA Contact: Lubos Trilety
URL:
Whiteboard:
Depends On:
Blocks: 693778
TreeView+ depends on / blocked
 
Reported: 2011-01-25 12:19 UTC by Lubos Trilety
Modified: 2011-06-23 15:42 UTC (History)
3 users (show)

Fixed In Version: condor-7.6.0-0.2
Doc Type: Bug Fix
Doc Text:
C: The job run analysis feature of the 'condor_q' tool could not analyze jobs whose requirements expression included ClassAd function calls that evaluated to false. C: Attempting to analyze such a job would result in an error message indicating that the requirements expression had a "bad form." F: Internal changes to Condor's implementation of the ClassAd language now prevent this error from occurring. R: Users can now analyze jobs with function calls that may return false in their requirements expressions.
Clone Of:
Environment:
Last Closed: 2011-06-23 15:42:14 UTC
Target Upstream Version:
Embargoed:


Attachments (Terms of Use)


Links
System ID Private Priority Status Summary Last Updated
Red Hat Product Errata RHEA-2011:0889 0 normal SHIPPED_LIVE Red Hat Enterprise MRG Grid 2.0 Release 2011-06-23 15:35:53 UTC

Description Lubos Trilety 2011-01-25 12:19:01 UTC
Description of problem:
Command 'condor_q -better' prints following errors if classad expression, which contains stringList*, should return false:
error: bad form
error: problem with ExprToProfile

Examples:
stringListMember("5","1,2,3",",")
stringListSum("1,2,3",",") < 2
stringListSize("NewFeature","e") > 10


Version-Release number of selected component (if applicable):
condor-7.4.5-0.7

How reproducible:
100%

Steps to Reproduce:
1. submit a job with stringListMember("4","1,2,3")
# echo -e "cmd=/bin/sleep\nargs=1d\nRequirements=stringListMember(\"4\",\"1,2,3\")\nqueue" | runuser condor -s /bin/bash -c condor_submit
Submitting job(s).
1 job(s) submitted to cluster 1.

# condor_q -better
-- Submitter: hostname : <IP:43701> : hostname
error: bad form
error: problem with ExprToProfile
---
001.000:  Run analysis summary.  Of 2 machines,
      2 are rejected by your job's requirements
      0 reject your job because of their own requirements
      0 match but are serving users with a better priority in the pool
      0 match but reject the job for unknown reasons
      0 match but will not currently preempt their existing job
      0 match but are currently offline
      0 are available to run your job
	No successful match recorded.
	Last failed match: Tue Jan 25 07:13:54 2011
	Reason for last match failure: no match found

WARNING:  Be advised:
   No resources matched request's constraints

The Requirements expression for your job is:

( stringListMember("4","1,2,3") ) && ( target.Arch == "INTEL" ) &&
( target.OpSys == "LINUX" ) && ( target.Disk >= DiskUsage ) &&
( ( target.Memory * 1024 ) >= ImageSize ) &&
( ( RequestMemory * 1024 ) >= ImageSize ) &&
( TARGET.FileSystemDomain == MY.FileSystemDomain )


Actual results:
'condor_q -better' prints error

Expected results:
no error

Additional info:
Job with stringListMember("2","1,2,3") works correctly, no error in 'condor_q -better' and job is running.

Comment 1 Will Benton 2011-03-23 14:28:40 UTC
This appears to be fixed in 7.6 (specifically, in the 7.5.1 timeframe) as a side effect of the classad compatibility layer; I can't reproduce it with a pre-7.6 build.

Comment 2 Will Benton 2011-04-05 14:37:46 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 job run analysis feature of the 'condor_q' tool could not analyze jobs whose requirements expression included ClassAd function calls that evaluated to false.
C:  Attempting to analyze such a job would result in an error message indicating that the requirements expression had a "bad form."
F:  Internal changes to Condor's implementation of the ClassAd language now prevent this error from occurring.
R:  Users can now analyze jobs with function calls that may return false in their requirements expressions.

Comment 4 Lubos Trilety 2011-05-05 13:22:25 UTC
Tested on:
$CondorVersion: 7.6.1 Apr 27 2011 BuildID: RH-7.6.1-0.4.el5 $
$CondorPlatform: I686-RedHat_5.6 $

$CondorVersion: 7.6.1 Apr 27 2011 BuildID: RH-7.6.1-0.4.el5 $
$CondorPlatform: X86_64-RedHat_5.6 $

$CondorVersion: 7.6.1 Apr 27 2011 BuildID: RH-7.6.1-0.4.el6 $
$CondorPlatform: I686-RedHat_6.0 $

$CondorVersion: 7.6.1 Apr 27 2011 BuildID: RH-7.6.1-0.4.el6 $
$CondorPlatform: X86_64-RedHat_6.0 $

# condor_q -better
-- Submitter: hostname : <IP:37149> : hostname
---
008.000:  Run analysis summary.  Of 1 machines,
      1 are rejected by your job's requirements 
      0 reject your job because of their own requirements 
      0 match but are serving users with a better priority in the pool 
      0 match but reject the job for unknown reasons 
      0 match but will not currently preempt their existing job 
      0 match but are currently offline 
      0 are available to run your job
	No successful match recorded.
	Last failed match: Thu May  5 15:19:43 2011
	Reason for last match failure: no match found

WARNING:  Be advised:
   No resources matched request's constraints

The Requirements expression for your job is:

( stringListMember("4","1,2,3") ) && ( TARGET.Arch == "X86_64" ) &&
( TARGET.OpSys == "LINUX" ) && ( TARGET.Disk >= DiskUsage ) &&
( ( TARGET.Memory * 1024 ) >= ImageSize ) &&
( ( RequestMemory * 1024 ) >= ImageSize ) &&
( TARGET.FileSystemDomain == MY.FileSystemDomain )

Job ClassAd Requirements expression evaluates to false


>>> VERIFIED

Comment 5 errata-xmlrpc 2011-06-23 15:42:14 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/RHEA-2011-0889.html


Note You need to log in before you can comment on or make changes to this bug.