Configure Policy - FairShare and Other Parameters

Accelerator has a time-windowing multi-level FairShare mechanism. This allocates CPU cycles to the fsgroups at each level according to the assigned weights of each group until the leaf nodes of the FairShare tree are reached. Each node of the FairShare tree may have a separate time window. The word 'fsgroup' is used as an abbreviation here.

To configure FairShare, use the vovfsgroup command.
Access to FairShare groups is controlled by ACLs (Access Control Lists), which means you can configure them so only designated users can submit jobs in an fsgroup.

Locate Server Configuration Directory to Find policy.tcl

The test queue was start in vncdexin in directory ~/ncadmin. So the server configuration directory for this Accelerator queue is ~/ncadmin/vncdexin.swd. By default, the server configuration directory is $VOVDIR/../../vnc/vnc.swd.

If you forget, you can find it out by this command:
% nc cmd vovserverdir
/home/dexin/ncadmin

In this case, you will find policy.tcl file at /home/dexin/ncadmin/vncdexin.swd/policy.tcl.

You will find other configuration files in the same directory, for example, taskers.tcl, resources.tcl.

Configure policy.tcl for FairShare

In the following example, two groups, production and regression, are configured.

Execute the following:
# in policy.tcl
% vovfsgroup create /production -weight 400 -window 8h
% vovfsgroup create /regression -weight 100 -window 8h
Two groups are defined: /production and /regression. When there are jobs from both the production group and regression group, the target share ratio of CPUs will be 400:100.

Save the New Configuration

Changes made by the vovfsgroup command are only in the vovserver's memory until the next save, and may be lost if the vovserver is restarted before then.

Save the configuration to a file so it can be reloaded.
% nc cmd vovfsgroup genconfig myfsconfig.tcl

Test the New Fairshare Configuration

  1. You use -g option in command nc run to submit a job from a particular group.
    % nc run -g regression -f listOfJobs
    % nc run -g production -f listOfJobs
  2. Use the Monitors GUI or browser page to monitor the dynamic changes of FairShare.
    • Use the monitors: use command nc monitor to bring up the monitors and click on the FairShare tab.
    • Use the browser: use command nc cmd vovbrowser to find the Accelerator URL, then find the FairShare page at URL /cgi/fairshare.cgi.

Server Configuration Parameters

Certain parameters of the Accelerator vovserver are also configurable by means of entries in the policy.tcl file. The Server Configuration page describes these in detail.)

Here are some examples:
# This is part of the policy.tcl file. 
set config(maxQueueLength)            8000
set config(httpSecure)                1
set config(saveToDiskPeriod)          2h; 
set config(autoLogout)                1h;    # Logout from browser interface

# Used by Accelerator for autoforget. 
set config(autoForgetValid)           1h 
set config(autoForgetFailed)          2d 
set config(autoForgetOthers)          2d
set config(autoRescheduleThreshold)   2s