Architecture

The Scheduler Entry-Point

The OpenSVC daemon runs the node scheduler every minute, which in turn runs each service schedulers in separate threads.

Each task of the node scheduler can be executed directly through the om node command, and each task of the service scheduler can be executed directly through the svcmgr command.

Most tasks produce data sent to the collector for site-level aggregation.

Node Scheduler Tasks

The node scheduler tasks schedules are defined in <OSVCETC>/node.conf. Each task has its own section supporting the schedule parameter. The section name is visible in om node print schedule output in the config parameter column.

$ om node print schedule
Action                  Last Run             Config Parameter           Schedule Definition                               
|- auto_reboot          2017-09-30 16:59:19  reboot.schedule            16:00-17:00@1 sat:last,tue-mon:last * %2+1,feb-apr
|- auto_rotate_root_pw  -                    rotate_root_pw.schedule    -
|- checks               2017-10-01 17:43:29  checks.schedule            ["16:00-21:00@30 *:last", "! * wed", "*@1"]
|- collect_stats        2017-10-01 17:42:29  stats_collection.schedule  @10
|- compliance_auto      2017-10-01 00:01:22  compliance.schedule        00:00-01:00@61
|- dequeue_actions      2017-01-30 10:02:01  dequeue_actions.schedule   -
|- pushasset            2017-10-01 00:06:22  asset.schedule             00:00-06:00@361 mon-sun
|- pushbrocade          -                    brocade.schedule           -
|- pushcentera          -                    centera.schedule           -
|- pushdcs              -                    dcs.schedule               -
|- pushdisks            2017-10-01 00:03:22  disks.schedule             00:00-06:00@361 mon-sun
|- pushemcvnx           -                    emcvnx.schedule            -
|- pusheva              -                    eva.schedule               -
|- pushfreenas          -                    freenas.schedule           -
|- pushgcedisks         -                    gcedisks.schedule          -
|- pushhds              -                    hds.schedule               -
|- pushhp3par           -                    hp3par.schedule            -
|- pushibmds            -                    ibmds.schedule             -
|- pushibmsvc           -                    ibmsvc.schedule            -
|- pushnecism           -                    necism.schedule            -
|- pushnetapp           -                    netapp.schedule            -
|- pushnsr              -                    nsr.schedule               -
|- pushpatch            2017-10-01 00:16:01  patches.schedule           00:00-06:00@361 mon-sun
|- pushpkg              2017-10-01 00:12:01  packages.schedule          00:00-06:00@361 mon-sun
|- pushstats            2017-10-01 17:41:29  stats.schedule             ["00:00-23:59@10"]
|- pushsym              -                    sym.schedule               -
|- pushvioserver        -                    vioserver.schedule         -
|- pushxtremio          -                    xtremio.schedule           -
`- sysreport            2017-10-01 00:25:02  sysreport.schedule         00:00-06:00@361 mon-sun

Service Scheduler Tasks

A service scheduler tasks schedules are defined in <OSVCETC>/<svcname>.conf. The section and parameter names are visible in om <svcname> print schedule output in the config parameter column.

$ om testmd print schedule
Action                  Last Run             Config Parameter          Schedule Definition
|- compliance_auto      2017-10-01 00:09:01  DEFAULT.comp_schedule     00:00-06:00@361
|- push_config          2017-10-01 00:01:02  DEFAULT.push_schedule     00:00-06:00@361
|- push_resinfo         2017-10-01 16:42:29  DEFAULT.resinfo_schedule  @60
|- push_service_status  2017-10-01 17:39:30  DEFAULT.status_schedule   @8
|- resource_monitor     2017-10-01 17:38:02  DEFAULT.monitor_schedule  @2
|- sync_all             2017-10-01 04:00:04  sync#1.schedule           04:00-06:00@121
`- sync_all             2017-10-01 04:00:04  sync#i0.schedule          04:00-06:00@121

Here, the push_appinfo and syncall tasks are mapped over respectivelly app and sync resources. Hence their number vary depending on the service configuration.

The Listener Entry-Point

The listener port is defined in <OSVCETC>/node.conf through the node.listener parameter. When the daemon listener receives an empty packet, it executes the om node dequeue actions command in a new thread. This command fetches from the collector the list of actions to execute, executes them, and send results to the collector. This behaviour is referred as the pull mode.

Alternaltively, the node can be configured to allow direct actions from the collector through ssh and sudo. This is the push mode.