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

Fixes for Nagios tests #11

Merged
merged 1 commit into from Mar 24, 2014
Merged
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Jump to
Jump to file
Failed to load files.
Diff view
Diff view
17 changes: 17 additions & 0 deletions manifests/config.pp
Expand Up @@ -35,6 +35,17 @@
# and if true
# group_<group_name>.<subgroup>.<user name>
#
# [*high_priority_groups*]
# A hash of groups with high priority. It is used for the group sorting
# expression for condor. Groups with lower value are considered first.
# example:
# $high_priority_groups = {
# 'cms.admin' => -30,
# 'ops' => -20,
# 'dteam' => -10,
# }
# This will consider the group cms.admin first, followed by ops and dteam.
#
# [*is_ce*]
# If machine is a computing element or a scheduler (condor term)
#
Expand Down Expand Up @@ -85,6 +96,12 @@
$computing_elements = [],
$condor_admin_email = 'root@mysite.org',
$custom_attribute = 'NORDUGRID_QUEUE',
$high_priority_groups = {
'cms.admin' => -30,
'ops' => -20,
'dteam' => -10,
}
,
$include_username_in_accounting = false,
$is_ce = false,
$is_manager = false,
Expand Down
31 changes: 25 additions & 6 deletions manifests/init.pp
Expand Up @@ -29,6 +29,17 @@
# when creating queues with ARC CEs
# Default: NORDUGRID_QUEUE
#
# [*high_priority_groups*]
# A hash of groups with high priority. It is used for the group sorting
# expression for condor. Groups with lower value are considered first.
# example:
# $high_priority_groups = {
# 'cms.admin' => -30,
# 'ops' => -20,
# 'dteam' => -10,
# }
# This will consider the group cms.admin first, followed by ops and dteam.
#
# [*include_username_in_accounting*]
# Bool. If false the accounting groups used are of the form
# group_<group_name>.<subgroup>
Expand Down Expand Up @@ -94,6 +105,12 @@
$condor_admin_email = 'root@mysite.org',
$condor_priority = '99',
$custom_attribute = 'NORDUGRID_QUEUE',
$high_priority_groups = {
'cms.admin' => -30,
'ops' => -20,
'dteam' => -10,
}
,
$include_username_in_accounting = false,
$install_repositories = true,
$is_ce = false,
Expand All @@ -115,12 +132,14 @@
}

class { 'htcondor::config':
accounting_groups => $accounting_groups,
cluster_has_multiple_domains => $cluster_has_multiple_domains,
accounting_groups => $accounting_groups,
cluster_has_multiple_domains => $cluster_has_multiple_domains,
collector_name => $collector_name,
computing_elements => $computing_elements,
condor_admin_email => $condor_admin_email,
custom_attribute => $custom_attribute,
computing_elements => $computing_elements,
condor_admin_email => $condor_admin_email,
custom_attribute => $custom_attribute,
high_priority_groups => $high_priority_groups,
include_username_in_accounting => $include_username_in_accounting,
is_ce => $is_ce,
is_manager => $is_manager,
is_worker => $is_worker,
Expand All @@ -129,7 +148,7 @@
number_of_cpus => $number_of_cpus,
pool_password => $pool_password,
uid_domain => $uid_domain,
use_accounting_groups => $use_accounting_groups,
use_accounting_groups => $use_accounting_groups,
worker_nodes => $worker_nodes,
}

Expand Down
15 changes: 9 additions & 6 deletions templates/11_fairshares.config.erb
@@ -1,9 +1,3 @@
## Restrictions on max number of running jobs per user. By default
## there are no limits.

CMSSGM_LIMIT = 10
ATLASSGM_LIMIT = 10

## Half-life of user priorities
PRIORITY_HALFLIFE = 43200

Expand All @@ -23,6 +17,15 @@ GROUP_NAMES = \
<% end -%>
<% end -%>

<% if @high_priority_groups -%>
# consider high_priority groups first
GROUP_SORT_EXPR = ifThenElse(AccountingGroup=?="<none>", 3.4e+38, \
<% @high_priority_groups.keys.sort.each do |key| -%>
ifThenElse(AccountingGroup=?="group_<%= key -%>", <%= @high_priority_groups[key] -%>, \
<% end -%>
ifThenElse(GroupQuota > 0, GroupResourcesInUse/GroupQuota, 3.3e+38)))))
<% end -%>

# Default priorities
DEFAULT_PRIO_FACTOR = 100000.00
<% @accounting_groups.keys.sort.each do |key| -%>
Expand Down
9 changes: 6 additions & 3 deletions templates/condor_config.local.erb
Expand Up @@ -17,12 +17,15 @@ x509UserProxyVOName)))
# This one is not useful for grid sites but is useful if you want to
# implement user based quotas:
# group_<name>.<subgroup>.<user name>
AcctGroup = strcat("group_",x509UserProxyVOName,".",AcctSubGroup,".",Owner)
AcctGroup = strcat("group_", x509UserProxyVOName, ".",AcctSubGroup, ".", Owner)
<% else -%>
AcctGroup = strcat("group_",x509UserProxyVOName,".",AcctSubGroup)
AcctGroup = strcat("group_", x509UserProxyVOName, ".", AcctSubGroup)
<% end -%>
# condor uses AcctGroup, but some monitoring scripts use AccountingGroup
# let's have both.
AccountingGroup = $(AcctGroup)
SUBMIT_EXPRS = $(SUBMIT_EXPRS) AcctGroup AcctSubGroup AccountingGroup
ConcurrencyLimits = strcat(AcctGroup, ",", AcctSubGroup, ",", Owner)
SUBMIT_EXPRS = $(SUBMIT_EXPRS) AcctGroup, AcctSubGroup, AccountingGroup, ConcurrencyLimits
<% else -%>

<% end -%>