Skip to content

Instantly share code, notes, and snippets.

@mdunsmuir
Created July 17, 2015 23:46
Show Gist options
  • Star 0 You must be signed in to star a gist
  • Fork 0 You must be signed in to fork a gist
  • Save mdunsmuir/22b809c642ff6794b709 to your computer and use it in GitHub Desktop.
Save mdunsmuir/22b809c642ff6794b709 to your computer and use it in GitHub Desktop.
# Generated by ffi_gen. Please do not change this file by hand.
require 'ffi'
module Slurm
extend FFI::Library
ffi_lib "slurm"
def self.attach_function(name, *_)
begin; super; rescue FFI::NotFoundError => e
(class << self; self; end).class_eval { define_method(name) { |*_| raise e } }
end
end
def params(protos)
protos
end
SYSTEM_DIMENSIONS = 1
HIGHEST_DIMENSIONS = 5
HAVE_SYS_SOCKET_H = 1
DEFAULT_WAIT_ALL_NODES = 0
PR_IU64 = "llu"
SLURM_VERSION_NUMBER = 0x0e0b07
def slurm_version_num(a, b, c)
((a<<16)+(b<<8)+c)
end
INFINITE = 0xffffffff
NO_VAL = 0xfffffffe
MAX_TASKS_PER_NODE = 128
SLURM_BATCH_SCRIPT = 0xfffffffe
SLURM_ID_HASH_NUM = 10000000000
JOB_STATE_BASE = 0x00ff
JOB_STATE_FLAGS = 0xff00
JOB_COMPLETING = 0x8000
JOB_CONFIGURING = 0x4000
JOB_RESIZING = 0x2000
JOB_SPECIAL_EXIT = 0x1000
JOB_REQUEUE_HOLD = 0x0800
JOB_REQUEUE = 0x0400
READY_JOB_FATAL = -2
READY_JOB_ERROR = -1
READY_NODE_STATE = 0x01
READY_JOB_STATE = 0x02
MAIL_JOB_BEGIN = 0x0001
MAIL_JOB_END = 0x0002
MAIL_JOB_FAIL = 0x0004
MAIL_JOB_REQUEUE = 0x0008
MAIL_JOB_TIME100 = 0x0010
MAIL_JOB_TIME90 = 0x0020
MAIL_JOB_TIME80 = 0x0040
MAIL_JOB_TIME50 = 0x0080
NICE_OFFSET = 10000
PARTITION_SUBMIT = 0x01
PARTITION_SCHED = 0x02
def partition_down(PARTITION_SUBMIT)
end
def partition_drain(PARTITION_SCHED)
end
PARTITION_INACTIVE = 0x00
ACCT_GATHER_PROFILE_NOT_SET = 0x00000000
ACCT_GATHER_PROFILE_NONE = 0x00000001
ACCT_GATHER_PROFILE_ENERGY = 0x00000002
ACCT_GATHER_PROFILE_TASK = 0x00000004
ACCT_GATHER_PROFILE_LUSTRE = 0x00000008
ACCT_GATHER_PROFILE_NETWORK = 0x00000010
ACCT_GATHER_PROFILE_ALL = 0xffffffff
OPEN_MODE_APPEND = 1
OPEN_MODE_TRUNCATE = 2
CPU_FREQ_RANGE_FLAG = 0x80000000
CPU_FREQ_LOW = 0x80000001
CPU_FREQ_MEDIUM = 0x80000002
CPU_FREQ_HIGH = 0x80000003
CPU_FREQ_HIGHM1 = 0x80000004
CPU_FREQ_PERFORMANCE = 0x80000005
CPU_FREQ_POWERSAVE = 0x80000006
CPU_FREQ_USERSPACE = 0x80000007
CPU_FREQ_ONDEMAND = 0x80000008
CPU_FREQ_CONSERVATIVE = 0x80000009
NODE_STATE_BASE = 0x000f
NODE_STATE_FLAGS = 0xfff0
NODE_STATE_NET = 0x0010
NODE_STATE_RES = 0x0020
NODE_STATE_UNDRAIN = 0x0040
NODE_STATE_CLOUD = 0x0080
NODE_RESUME = 0x0100
NODE_STATE_DRAIN = 0x0200
NODE_STATE_COMPLETING = 0x0400
NODE_STATE_NO_RESPOND = 0x0800
NODE_STATE_POWER_SAVE = 0x1000
NODE_STATE_FAIL = 0x2000
NODE_STATE_POWER_UP = 0x4000
NODE_STATE_MAINT = 0x8000
SLURM_SSL_SIGNATURE_LENGTH = 128
SHOW_ALL = 0x0001
SHOW_DETAIL = 0x0002
SHOW_DETAIL2 = 0x0004
SHOW_MIXED = 0x0008
CR_CPU = 0x0001
CR_SOCKET = 0x0002
CR_CORE = 0x0004
CR_BOARD = 0x0008
CR_MEMORY = 0x0010
CR_OTHER_CONS_RES = 0x0020
CR_NHC_STEP_NO = 0x0040
CR_NHC_NO = 0x0080
CR_ONE_TASK_PER_CORE = 0x0100
CR_PACK_NODES = 0x0200
CR_CORE_DEFAULT_DIST_BLOCK = 0x1000
CR_ALLOCATE_FULL_SOCKET = 0x2000
CR_LLN = 0x4000
MEM_PER_CPU = 0x80000000
SHARED_FORCE = 0x8000
PRIVATE_DATA_JOBS = 0x0001
PRIVATE_DATA_NODES = 0x0002
PRIVATE_DATA_PARTITIONS = 0x0004
PRIVATE_DATA_USAGE = 0x0008
PRIVATE_DATA_USERS = 0x0010
PRIVATE_DATA_ACCOUNTS = 0x0020
PRIVATE_DATA_RESERVATIONS = 0x0040
PRIVATE_CLOUD_NODES = 0x0080
PRIORITY_RESET_NONE = 0x0000
PRIORITY_RESET_NOW = 0x0001
PRIORITY_RESET_DAILY = 0x0002
PRIORITY_RESET_WEEKLY = 0x0003
PRIORITY_RESET_MONTHLY = 0x0004
PRIORITY_RESET_QUARTERLY = 0x0005
PRIORITY_RESET_YEARLY = 0x0006
PROP_PRIO_OFF = 0x0000
PROP_PRIO_ON = 0x0001
PROP_PRIO_NICER = 0x0002
PRIORITY_FLAGS_ACCRUE_ALWAYS = 0x0001
PRIORITY_FLAGS_TICKET_BASED = 0x0002
PRIORITY_FLAGS_SIZE_RELATIVE = 0x0004
PRIORITY_FLAGS_DEPTH_OBLIVIOUS = 0x0008
PRIORITY_FLAGS_CALCULATE_RUNNING = 0x0010
PRIORITY_FLAGS_FAIR_TREE = 0x0020
ALLOC_SID_ADMIN_HOLD = 0x00000001
ALLOC_SID_USER_HOLD = 0x00000002
PART_FLAG_DEFAULT = 0x0001
PART_FLAG_HIDDEN = 0x0002
PART_FLAG_NO_ROOT = 0x0004
PART_FLAG_ROOT_ONLY = 0x0008
PART_FLAG_REQ_RESV = 0x0010
PART_FLAG_LLN = 0x0020
PART_FLAG_DEFAULT_CLR = 0x0100
PART_FLAG_HIDDEN_CLR = 0x0200
PART_FLAG_NO_ROOT_CLR = 0x0400
PART_FLAG_ROOT_ONLY_CLR = 0x0800
PART_FLAG_REQ_RESV_CLR = 0x1000
PART_FLAG_LLN_CLR = 0x2000
RESERVE_FLAG_MAINT = 0x00000001
RESERVE_FLAG_NO_MAINT = 0x00000002
RESERVE_FLAG_DAILY = 0x00000004
RESERVE_FLAG_NO_DAILY = 0x00000008
RESERVE_FLAG_WEEKLY = 0x00000010
RESERVE_FLAG_NO_WEEKLY = 0x00000020
RESERVE_FLAG_IGN_JOBS = 0x00000040
RESERVE_FLAG_NO_IGN_JOB = 0x00000080
RESERVE_FLAG_LIC_ONLY = 0x00000100
RESERVE_FLAG_NO_LIC_ONLY = 0x00000200
RESERVE_FLAG_STATIC = 0x00000400
RESERVE_FLAG_NO_STATIC = 0x00000800
RESERVE_FLAG_PART_NODES = 0x00001000
RESERVE_FLAG_NO_PART_NODES = 0x00002000
RESERVE_FLAG_OVERLAP = 0x00004000
RESERVE_FLAG_SPEC_NODES = 0x00008000
RESERVE_FLAG_FIRST_CORES = 0x00010000
RESERVE_FLAG_TIME_FLOAT = 0x00020000
DEBUG_FLAG_SELECT_TYPE = 0x0000000000000001
DEBUG_FLAG_STEPS = 0x0000000000000002
DEBUG_FLAG_TRIGGERS = 0x0000000000000004
DEBUG_FLAG_CPU_BIND = 0x0000000000000008
DEBUG_FLAG_WIKI = 0x0000000000000010
DEBUG_FLAG_NO_CONF_HASH = 0x0000000000000020
DEBUG_FLAG_GRES = 0x0000000000000040
DEBUG_FLAG_BG_PICK = 0x0000000000000080
DEBUG_FLAG_BG_WIRES = 0x0000000000000100
DEBUG_FLAG_BG_ALGO = 0x0000000000000200
DEBUG_FLAG_BG_ALGO_DEEP = 0x0000000000000400
DEBUG_FLAG_PRIO = 0x0000000000000800
DEBUG_FLAG_BACKFILL = 0x0000000000001000
DEBUG_FLAG_GANG = 0x0000000000002000
DEBUG_FLAG_RESERVATION = 0x0000000000004000
DEBUG_FLAG_FRONT_END = 0x0000000000008000
DEBUG_FLAG_NO_REALTIME = 0x0000000000010000
DEBUG_FLAG_SWITCH = 0x0000000000020000
DEBUG_FLAG_ENERGY = 0x0000000000040000
DEBUG_FLAG_EXT_SENSORS = 0x0000000000080000
DEBUG_FLAG_LICENSE = 0x0000000000100000
DEBUG_FLAG_PROFILE = 0x0000000000200000
DEBUG_FLAG_INFINIBAND = 0x0000000000400000
DEBUG_FLAG_FILESYSTEM = 0x0000000000800000
DEBUG_FLAG_JOB_CONT = 0x0000000001000000
DEBUG_FLAG_TASK = 0x0000000002000000
DEBUG_FLAG_PROTOCOL = 0x0000000004000000
DEBUG_FLAG_BACKFILL_MAP = 0x0000000008000000
DEBUG_FLAG_TRACE_JOBS = 0x0000000010000000
DEBUG_FLAG_ROUTE = 0x0000000020000000
DEBUG_FLAG_DB_ASSOC = 0x0000000040000000
DEBUG_FLAG_DB_EVENT = 0x0000000080000000
DEBUG_FLAG_DB_JOB = 0x0000000100000000
DEBUG_FLAG_DB_QOS = 0x0000000200000000
DEBUG_FLAG_DB_QUERY = 0x0000000400000000
DEBUG_FLAG_DB_RESV = 0x0000000800000000
DEBUG_FLAG_DB_RES = 0x0000001000000000
DEBUG_FLAG_DB_STEP = 0x0000002000000000
DEBUG_FLAG_DB_USAGE = 0x0000004000000000
DEBUG_FLAG_DB_WCKEY = 0x0000008000000000
GROUP_FORCE = 0x8000
GROUP_CACHE = 0x4000
GROUP_TIME_MASK = 0x0fff
PREEMPT_MODE_OFF = 0x0000
PREEMPT_MODE_SUSPEND = 0x0001
PREEMPT_MODE_REQUEUE = 0x0002
PREEMPT_MODE_CHECKPOINT = 0x0004
PREEMPT_MODE_CANCEL = 0x0008
PREEMPT_MODE_GANG = 0x8000
RECONFIG_KEEP_PART_INFO = 0x0001
RECONFIG_KEEP_PART_STAT = 0x0002
HEALTH_CHECK_NODE_IDLE = 0x0001
HEALTH_CHECK_NODE_ALLOC = 0x0002
HEALTH_CHECK_NODE_MIXED = 0x0004
HEALTH_CHECK_CYCLE = 0x8000
HEALTH_CHECK_NODE_ANY = 0x000f
PROLOG_FLAG_ALLOC = 0x0001
PROLOG_FLAG_NOHOLD = 0x0002
LOG_FMT_ISO8601_MS = 0
LOG_FMT_ISO8601 = 1
LOG_FMT_RFC5424_MS = 2
LOG_FMT_RFC5424 = 3
LOG_FMT_CLOCK = 4
LOG_FMT_SHORT = 5
LOG_FMT_THREAD_ID = 6
STAT_COMMAND_RESET = 0x0000
STAT_COMMAND_GET = 0x0001
TRIGGER_FLAG_PERM = 0x0001
TRIGGER_RES_TYPE_JOB = 0x0001
TRIGGER_RES_TYPE_NODE = 0x0002
TRIGGER_RES_TYPE_SLURMCTLD = 0x0003
TRIGGER_RES_TYPE_SLURMDBD = 0x0004
TRIGGER_RES_TYPE_DATABASE = 0x0005
TRIGGER_RES_TYPE_FRONT_END = 0x0006
TRIGGER_TYPE_UP = 0x00000001
TRIGGER_TYPE_DOWN = 0x00000002
TRIGGER_TYPE_FAIL = 0x00000004
TRIGGER_TYPE_TIME = 0x00000008
TRIGGER_TYPE_FINI = 0x00000010
TRIGGER_TYPE_RECONFIG = 0x00000020
TRIGGER_TYPE_BLOCK_ERR = 0x00000040
TRIGGER_TYPE_IDLE = 0x00000080
TRIGGER_TYPE_DRAINED = 0x00000100
TRIGGER_TYPE_PRI_CTLD_FAIL = 0x00000200
TRIGGER_TYPE_PRI_CTLD_RES_OP = 0x00000400
TRIGGER_TYPE_PRI_CTLD_RES_CTRL = 0x00000800
TRIGGER_TYPE_PRI_CTLD_ACCT_FULL = 0x00001000
TRIGGER_TYPE_BU_CTLD_FAIL = 0x00002000
TRIGGER_TYPE_BU_CTLD_RES_OP = 0x00004000
TRIGGER_TYPE_BU_CTLD_AS_CTRL = 0x00008000
TRIGGER_TYPE_PRI_DBD_FAIL = 0x00010000
TRIGGER_TYPE_PRI_DBD_RES_OP = 0x00020000
TRIGGER_TYPE_PRI_DB_FAIL = 0x00040000
TRIGGER_TYPE_PRI_DB_RES_OP = 0x00080000
KILL_JOB_BATCH = 0x0001
KILL_JOB_ARRAY = 0x0002
KILL_STEPS_ONLY = 0x0004
# Just incase we don't have a c99 compatible system. This should be
# defined in inttypes.h.
class SlurmJobCredential < FFI::Struct
layout :dummy, :char
end
# Define switch_jobinfo_t below to avoid including extraneous slurm headers
class SwitchJobinfo < FFI::Struct
layout :dummy, :char
end
# Opaque data for select plugins
class JobResources < FFI::Struct
layout :dummy, :char
end
# Opaque data for select plugins
class SelectJobinfo < FFI::Struct
layout :dummy, :char
end
# for BlueGene
class SelectNodeinfo < FFI::Struct
layout :dummy, :char
end
# Define jobacctinfo_t below to avoid including extraneous slurm headers
class Jobacctinfo < FFI::Struct
layout :dummy, :char
end
# Define allocation_msg_thread_t below to avoid including extraneous
# slurm headers
class AllocationMsgThread < FFI::Struct
layout :dummy, :char
end
# (Not documented)
class SbcastCred < FFI::Struct
layout :dummy, :char
end
# last entry must be JOB_END, keep in sync with job_state_string and
# job_state_string_compact. values may be ORed with JOB_STATE_FLAGS
# below.
#
# <em>This entry is only for documentation and no real method. The FFI::Enum can be accessed via #enum_type(:job_states).</em>
#
# === Options:
# :pending ::
#
# :running ::
# queued waiting for initiation
# :suspended ::
# allocated resources and executing
# :complete ::
# allocated resources, execution suspended
# :cancelled ::
# completed execution successfully
# :failed ::
# cancelled by user
# :timeout ::
# completed execution unsuccessfully
# :node_fail ::
# terminated on reaching time limit
# :preempted ::
# terminated on node failure
# :boot_fail ::
# terminated due to preemption
# :end_ ::
# terminated due to node boot failure
#
# @method _enum_job_states_
# @return [Symbol]
# @scope class
enum :job_states, [
:pending, 0,
:running, 1,
:suspended, 2,
:complete, 3,
:cancelled, 4,
:failed, 5,
:timeout, 6,
:node_fail, 7,
:preempted, 8,
:boot_fail, 9,
:end_, 10
]
# Reason for job to be pending rather than executing or reason for job
# failure. If multiple reasons exists, only one is given for the sake of
# system efficiency
#
# <em>This entry is only for documentation and no real method. The FFI::Enum can be accessed via #enum_type(:job_state_reason).</em>
#
# === Options:
# :wait_no_reason ::
# Reasons for job to be pending
# :wait_priority ::
# not set or job not pending
# :wait_dependency ::
# higher priority jobs exist
# :wait_resources ::
# dependent job has not completed
# :wait_part_node_limit ::
# required resources not available
# :wait_part_time_limit ::
# request exceeds partition node limit
# :wait_part_down ::
# request exceeds partition time limit
# :wait_part_inactive ::
# requested partition is down
# :wait_held ::
# requested partition is inactive
# :wait_time ::
# job is held by administrator
# :wait_licenses ::
# job waiting for specific begin time
# :wait_assoc_job_limit ::
# job is waiting for licenses
# :wait_assoc_resource_limit ::
# user/bank job limit reached
# :wait_assoc_time_limit ::
# user/bank resource limit reached
# :wait_reservation ::
# user/bank time limit reached
# :wait_node_not_avail ::
# reservation not available
# :wait_held_user ::
# required node is DOWN or DRAINED
# :wait_front_end ::
# job is held by user
# :fail_down_partition ::
# Front end nodes are DOWN
# :fail_down_node ::
# partition for job is DOWN
# :fail_bad_constraints ::
# some node in the allocation failed
# :fail_system ::
# constraints can not be satisfied
# :fail_launch ::
# slurm system failure
# :fail_exit_code ::
# unable to launch job
# :fail_timeout ::
# exit code was non-zero
# :fail_inactive_limit ::
# reached end of time limit
# :fail_account ::
# reached slurm InactiveLimit
# :fail_qos ::
# invalid account
# :wait_qos_thres ::
# invalid QOS
# :wait_qos_job_limit ::
# required QOS threshold has been breached
# :wait_qos_resource_limit ::
# QOS job limit reached
# :wait_qos_time_limit ::
# QOS resource limit reached
# :wait_block_max_err ::
# QOS time limit reached
# :wait_block_d_action ::
# BLUEGENE Block has too many cnodes
# in error state to allow more jobs.
# :wait_cleaning ::
# BLUEGENE Block is being freed,
# can't allow more jobs.
# :wait_prolog ::
# If a job is requeued and it is
# still cleaning up from the last run.
# :wait_qos ::
# Prolog is running
# :wait_account ::
# QOS not allowed
# :wait_dep_invalid ::
# Account not allowed
# :wait_qos_grp_cpu ::
# Dependency condition invalid or never
# satisfied
# :wait_qos_grp_cpu_min ::
# QOS GrpCpus exceeded
# :wait_qos_grp_cpu_run_min ::
# QOS GrpCPUMins exceeded
# :wait_qos_grp_job ::
# QOS GrpCPURunMins exceeded
# :wait_qos_grp_memory ::
# QOS GrpJobs exceeded
# :wait_qos_grp_nodes ::
# QOS GrpMemory exceeded
# :wait_qos_grp_sub_job ::
# QOS GrpNodes exceeded
# :wait_qos_grp_wall ::
# QOS GrpSubmitJobs exceeded
# :wait_qos_max_cpus_per_job ::
# QOS GrpWall exceeded
# :wait_qos_max_cpu_mins_per_job ::
# QOS MaxCpusPerJob exceeded
# :wait_qos_max_node_per_job ::
# QOS MaxCpusMinsPerJob exceeded
# :wait_qos_max_wall_per_job ::
# QOS MaxNodesPerJob exceeded
# :wait_qos_max_cpu_per_user ::
# QOS MaxWallDurationPerJob exceeded
# :wait_qos_max_job_per_user ::
# QOS MaxCpusPerUser exceeded
# :wait_qos_max_node_per_user ::
# QOS MaxJobsPerUser exceeded
# :wait_qos_max_sub_job ::
# QOS MaxNodesPerUser exceeded
# :wait_qos_min_cpus ::
# QOS MaxSubmitJobsPerUser exceeded
# :wait_assoc_grp_cpu ::
# QOS MinCPUsPerJob not reached
# :wait_assoc_grp_cpu_min ::
# ASSOC GrpCpus exceeded
# :wait_assoc_grp_cpu_run_min ::
# ASSOC GrpCPUMins exceeded
# :wait_assoc_grp_job ::
# ASSOC GrpCPURunMins exceeded
# :wait_assoc_grp_memory ::
# ASSOC GrpJobs exceeded
# :wait_assoc_grp_nodes ::
# ASSOC GrpMemory exceeded
# :wait_assoc_grp_sub_job ::
# ASSOC GrpNodes exceeded
# :wait_assoc_grp_wall ::
# ASSOC GrpSubmitJobs exceeded
# :wait_assoc_max_jobs ::
# ASSOC GrpWall exceeded
# :wait_assoc_max_cpus_per_job ::
# ASSOC MaxJobs exceeded
# :wait_assoc_max_cpu_mins_per_job ::
# ASSOC MaxCpusPerJob exceeded
# :wait_assoc_max_node_per_job ::
# ASSOC MaxCpusMinsPerJob exceeded
# :wait_assoc_max_wall_per_job ::
# ASSOC MaxNodesPerJob exceeded
# :wait_assoc_max_sub_job ::
# ASSOC MaxWallDurationPerJob
# exceeded
# :wait_max_requeue ::
# ASSOC MaxSubmitJobsPerUser exceeded
# :wait_array_task_limit ::
# MAX_BATCH_REQUEUE reached
#
# @method _enum_job_state_reason_
# @return [Symbol]
# @scope class
enum :job_state_reason, [
:wait_no_reason, 0,
:wait_priority, 1,
:wait_dependency, 2,
:wait_resources, 3,
:wait_part_node_limit, 4,
:wait_part_time_limit, 5,
:wait_part_down, 6,
:wait_part_inactive, 7,
:wait_held, 8,
:wait_time, 9,
:wait_licenses, 10,
:wait_assoc_job_limit, 11,
:wait_assoc_resource_limit, 12,
:wait_assoc_time_limit, 13,
:wait_reservation, 14,
:wait_node_not_avail, 15,
:wait_held_user, 16,
:wait_front_end, 17,
:fail_down_partition, 18,
:fail_down_node, 19,
:fail_bad_constraints, 20,
:fail_system, 21,
:fail_launch, 22,
:fail_exit_code, 23,
:fail_timeout, 24,
:fail_inactive_limit, 25,
:fail_account, 26,
:fail_qos, 27,
:wait_qos_thres, 28,
:wait_qos_job_limit, 29,
:wait_qos_resource_limit, 30,
:wait_qos_time_limit, 31,
:wait_block_max_err, 32,
:wait_block_d_action, 33,
:wait_cleaning, 34,
:wait_prolog, 35,
:wait_qos, 36,
:wait_account, 37,
:wait_dep_invalid, 38,
:wait_qos_grp_cpu, 39,
:wait_qos_grp_cpu_min, 40,
:wait_qos_grp_cpu_run_min, 41,
:wait_qos_grp_job, 42,
:wait_qos_grp_memory, 43,
:wait_qos_grp_nodes, 44,
:wait_qos_grp_sub_job, 45,
:wait_qos_grp_wall, 46,
:wait_qos_max_cpus_per_job, 47,
:wait_qos_max_cpu_mins_per_job, 48,
:wait_qos_max_node_per_job, 49,
:wait_qos_max_wall_per_job, 50,
:wait_qos_max_cpu_per_user, 51,
:wait_qos_max_job_per_user, 52,
:wait_qos_max_node_per_user, 53,
:wait_qos_max_sub_job, 54,
:wait_qos_min_cpus, 55,
:wait_assoc_grp_cpu, 56,
:wait_assoc_grp_cpu_min, 57,
:wait_assoc_grp_cpu_run_min, 58,
:wait_assoc_grp_job, 59,
:wait_assoc_grp_memory, 60,
:wait_assoc_grp_nodes, 61,
:wait_assoc_grp_sub_job, 62,
:wait_assoc_grp_wall, 63,
:wait_assoc_max_jobs, 64,
:wait_assoc_max_cpus_per_job, 65,
:wait_assoc_max_cpu_mins_per_job, 66,
:wait_assoc_max_node_per_job, 67,
:wait_assoc_max_wall_per_job, 68,
:wait_assoc_max_sub_job, 69,
:wait_max_requeue, 70,
:wait_array_task_limit, 71
]
# (Not documented)
#
# <em>This entry is only for documentation and no real method. The FFI::Enum can be accessed via #enum_type(:job_acct_types).</em>
#
# === Options:
# :start ::
#
# :step ::
#
# :suspend ::
#
# :terminated ::
#
#
# @method _enum_job_acct_types_
# @return [Symbol]
# @scope class
enum :job_acct_types, [
:start, 0,
:step, 1,
:suspend, 2,
:terminated, 3
]
# Actual partition states based upon state flags
#
# <em>This entry is only for documentation and no real method. The FFI::Enum can be accessed via #enum_type(:connection_type).</em>
#
# === Options:
# :select_mesh ::
#
# :select_torus ::
# nodes wired in mesh
# :select_nav ::
# nodes wired in torus
# :select_small ::
# nodes wired in torus else mesh
# :select_htc_s ::
# nodes in a small partition
# :select_htc_d ::
# nodes in a htc running SMP mode
# :select_htc_v ::
# nodes in a htc running Dual mode
# :select_htc_l ::
# nodes in a htc running VN mode
#
# @method _enum_connection_type_
# @return [Symbol]
# @scope class
enum :connection_type, [
:select_mesh, 0,
:select_torus, 1,
:select_nav, 2,
:select_small, 3,
:select_htc_s, 4,
:select_htc_d, 5,
:select_htc_v, 6,
:select_htc_l, 7
]
# (Not documented)
#
# <em>This entry is only for documentation and no real method. The FFI::Enum can be accessed via #enum_type(:node_use_type).</em>
#
# === Options:
# :select_coprocessor_mode ::
#
# :select_virtual_node_mode ::
# use extra processor for communications
# :select_nav_mode ::
# application uses both processors
#
# @method _enum_node_use_type_
# @return [Symbol]
# @scope class
enum :node_use_type, [
:select_coprocessor_mode, 0,
:select_virtual_node_mode, 1,
:select_nav_mode, 2
]
# (Not documented)
#
# <em>This entry is only for documentation and no real method. The FFI::Enum can be accessed via #enum_type(:select_jobdata_type).</em>
#
# === Options:
# :geometry ::
#
# :rotate ::
# data-> uint16_t geometry(SYSTEM_DIMENSIONS)
# :conn_type ::
# data-> uint16_t rotate
# :block_id ::
# data-> uint16_t connection_type
# :nodes ::
# data-> char *bg_block_id
# :ionodes ::
# data-> char *nodes
# :node_cnt ::
# data-> char *ionodes
# :altered ::
# data-> uint32_t cnode_cnt
# :blrts_image ::
# data-> uint16_t altered
# :linux_image ::
# data-> char *blrtsimage
# :mloader_image ::
# data-> char *linuximage
# :ramdisk_image ::
# data-> char *mloaderimage
# :reboot ::
# data-> char *ramdiskimage
# :resv_id ::
# data-> uint16_t reboot
# :pagg_id ::
# data-> uint32_t reservation_id
# :ptr ::
# data-> uint64_t job container ID
# :block_ptr ::
# data-> select_jobinfo_t *jobinfo
# :dim_cnt ::
# data-> bg_record_t *bg_record
# :block_node_cnt ::
# data-> uint16_t dim_cnt
# :start_loc ::
# data-> uint32_t block_cnode_cnt
# :user_name ::
# data-> uint16_t
# start_loc(SYSTEM_DIMENSIONS)
# :confirmed ::
# data-> char * user_name
# :cleaning ::
# data-> uint8_t ALPS reservation confirmed
# :network ::
# data-> uint16_t if the job is in
# cleaning state or not.
#
# @method _enum_select_jobdata_type_
# @return [Symbol]
# @scope class
enum :select_jobdata_type, [
:geometry, 0,
:rotate, 1,
:conn_type, 2,
:block_id, 3,
:nodes, 4,
:ionodes, 5,
:node_cnt, 6,
:altered, 7,
:blrts_image, 8,
:linux_image, 9,
:mloader_image, 10,
:ramdisk_image, 11,
:reboot, 12,
:resv_id, 13,
:pagg_id, 14,
:ptr, 15,
:block_ptr, 16,
:dim_cnt, 17,
:block_node_cnt, 18,
:start_loc, 19,
:user_name, 20,
:confirmed, 21,
:cleaning, 22,
:network, 23
]
# (Not documented)
#
# <em>This entry is only for documentation and no real method. The FFI::Enum can be accessed via #enum_type(:select_nodedata_type).</em>
#
# === Options:
# :bitmap_size ::
#
# :subgrp_size ::
# data-> uint16_t
# :subcnt ::
# data-> uint16_t
# :bitmap ::
# data-> uint16_t
# :str ::
# data-> bitstr_t * needs to be
# freed with FREE_NULL_BITMAP
# :ptr ::
# data-> char * needs to be
# freed with xfree
# :extra_info ::
# data-> select_nodeinfo_t *nodeinfo
# :rack_mp ::
# data-> char * needs to be
# freed with xfree
# :mem_alloc ::
# data-> char * needs to be
# freed with xfree
#
# @method _enum_select_nodedata_type_
# @return [Symbol]
# @scope class
enum :select_nodedata_type, [
:bitmap_size, 0,
:subgrp_size, 1,
:subcnt, 2,
:bitmap, 3,
:str, 4,
:ptr, 5,
:extra_info, 6,
:rack_mp, 7,
:mem_alloc, 8
]
# (Not documented)
#
# <em>This entry is only for documentation and no real method. The FFI::Enum can be accessed via #enum_type(:select_print_mode).</em>
#
# === Options:
# :head ::
#
# :data ::
# Print just the header
# :mixed ::
# Print just the data
# :mixed_short ::
# Print "field=value"
# :bg_id ::
# Print less "field=value"
# :nodes ::
# Print just the BG_ID
# :connection ::
# Print the nodelist
# :rotate ::
# Print just the CONNECTION type
# :geometry ::
# Print just the ROTATE
# :start ::
# Print just the GEO
# :blrts_image ::
# Print just the START location
# :linux_image ::
# Print just the BLRTS IMAGE
# :mloader_image ::
# Print just the LINUX IMAGE
# :ramdisk_image ::
# Print just the MLOADER IMAGE
# :reboot ::
# Print just the RAMDISK IMAGE
# :resv_id ::
# Print just the REBOOT
# :start_loc ::
# Print just Cray/BASIL reservation ID
#
# @method _enum_select_print_mode_
# @return [Symbol]
# @scope class
enum :select_print_mode, [
:head, 0,
:data, 1,
:mixed, 2,
:mixed_short, 3,
:bg_id, 4,
:nodes, 5,
:connection, 6,
:rotate, 7,
:geometry, 8,
:start, 9,
:blrts_image, 10,
:linux_image, 11,
:mloader_image, 12,
:ramdisk_image, 13,
:reboot, 14,
:resv_id, 15,
:start_loc, 16
]
# (Not documented)
#
# <em>This entry is only for documentation and no real method. The FFI::Enum can be accessed via #enum_type(:select_node_cnt).</em>
#
# === Options:
# :get_node_scaling ::
#
# :get_node_cpu_cnt ::
# Give scaling factor for node count
# :get_mp_cpu_cnt ::
# Give how many cpus are on a node
# :apply_node_min_offset ::
# Give how many cpus are on a
# base partition
# :apply_node_max_offset ::
# Apply min offset to variable
# :set_node_cnt ::
# Apply max offset to variable
# :set_mp_cnt ::
# Set altered node cnt
#
# @method _enum_select_node_cnt_
# @return [Symbol]
# @scope class
enum :select_node_cnt, [
:get_node_scaling, 0,
:get_node_cpu_cnt, 1,
:get_mp_cpu_cnt, 2,
:apply_node_min_offset, 3,
:apply_node_max_offset, 4,
:set_node_cnt, 5,
:set_mp_cnt, 6
]
# (Not documented)
#
# <em>This entry is only for documentation and no real method. The FFI::Enum can be accessed via #enum_type(:acct_gather_profile_info).</em>
#
# === Options:
# :dir ::
#
# :default ::
# Give directory profiling is stored
# :running ::
# What is being collected for
# profiling by default
#
# @method _enum_acct_gather_profile_info_
# @return [Symbol]
# @scope class
enum :acct_gather_profile_info, [
:dir, 0,
:default, 1,
:running, 2
]
# jobacct data types
#
# <em>This entry is only for documentation and no real method. The FFI::Enum can be accessed via #enum_type(:jobacct_data_type).</em>
#
# === Options:
# :total ::
#
# :pipe ::
# data-> jobacctinfo_t *
# :rusage ::
# data-> file descriptor
# :max_vsize ::
# data-> rusage set user_cpu_sec,
# user_cpu_usec, sys_cpu_sec, sys_cpu_usec
# :max_vsize_id ::
# data-> uint64_t vsize
# :tot_vsize ::
# data-> jobacct_id_t vsize
# :max_rss ::
# data-> uint64_t vsize
# :max_rss_id ::
# data-> uint64_t psize
# :tot_rss ::
# data-> jobacct_id_t psize
# :max_pages ::
# data-> uint64_t psize
# :max_pages_id ::
# data-> uint64_t psize
# :tot_pages ::
# data-> jobacct_id_t psize
# :min_cpu ::
# data-> uint64_t psize
# :min_cpu_id ::
# data-> uint32_t psize
# :tot_cpu ::
# data-> jobacct_id_t psize
# :act_cpufreq ::
# data-> uint32_t psize
# :consumed_energy ::
# data-> uint32_t psize hb
# :max_disk_read ::
# data-> uint32_t psize hb
# :max_disk_read_id ::
# data->double psize
# :tot_disk_read ::
# data->jobacct_id_t psize
# :max_disk_write ::
# data->double psize
# :max_disk_write_id ::
# data->double psize
# :tot_disk_write ::
# data->jobacct_id_t psize
#
# @method _enum_jobacct_data_type_
# @return [Symbol]
# @scope class
enum :jobacct_data_type, [
:total, 0,
:pipe, 1,
:rusage, 2,
:max_vsize, 3,
:max_vsize_id, 4,
:tot_vsize, 5,
:max_rss, 6,
:max_rss_id, 7,
:tot_rss, 8,
:max_pages, 9,
:max_pages_id, 10,
:tot_pages, 11,
:min_cpu, 12,
:min_cpu_id, 13,
:tot_cpu, 14,
:act_cpufreq, 15,
:consumed_energy, 16,
:max_disk_read, 17,
:max_disk_read_id, 18,
:tot_disk_read, 19,
:max_disk_write, 20,
:max_disk_write_id, 21,
:tot_disk_write, 22
]
# (Not documented)
#
# <em>This entry is only for documentation and no real method. The FFI::Enum can be accessed via #enum_type(:acct_energy_type).</em>
#
# === Options:
# :data_joules_task ::
#
# :data_struct ::
#
# :data_reconfig ::
#
# :data_profile ::
#
# :data_last_poll ::
#
#
# @method _enum_acct_energy_type_
# @return [Symbol]
# @scope class
enum :acct_energy_type, [
:data_joules_task, 0,
:data_struct, 1,
:data_reconfig, 2,
:data_profile, 3,
:data_last_poll, 4
]
# Possible task distributions across the nodes
#
# <em>This entry is only for documentation and no real method. The FFI::Enum can be accessed via #enum_type(:task_dist_states).</em>
#
# === Options:
# :slurm_dist_cyclic ::
# NOTE: start SLURM_DIST_CYCLIC at 1 for HP MPI
# :slurm_dist_block ::
# distribute tasks 1 per node, round robin
# :slurm_dist_arbitrary ::
# distribute tasks filling node by node
# :slurm_dist_plane ::
# arbitrary task distribution
# :slurm_dist_cyclic_cyclic ::
# distribute tasks by filling up
# planes of lllp first and then by
# going across the nodes See
# documentation for more
# information
# :slurm_dist_cyclic_block ::
# distribute tasks 1 per node,
# round robin, same for lowest
# level of logical processor (lllp)
# :slurm_dist_block_cyclic ::
# cyclic for node and block for lllp
# :slurm_dist_block_block ::
# block for node and cyclic for lllp
# :slurm_no_lllp_dist ::
# block for node and block for lllp
# :slurm_dist_unknown ::
# No distribution specified for lllp
# :slurm_dist_cyclic_cfull ::
# unknown dist
# :slurm_dist_block_cfull ::
# Same as cyclic:cyclic except for
# multi-cpu tasks cyclically
# bind cpus
#
# @method _enum_task_dist_states_
# @return [Symbol]
# @scope class
enum :task_dist_states, [
:slurm_dist_cyclic, 1,
:slurm_dist_block, 2,
:slurm_dist_arbitrary, 3,
:slurm_dist_plane, 4,
:slurm_dist_cyclic_cyclic, 5,
:slurm_dist_cyclic_block, 6,
:slurm_dist_block_cyclic, 7,
:slurm_dist_block_block, 8,
:slurm_no_lllp_dist, 9,
:slurm_dist_unknown, 10,
:slurm_dist_cyclic_cfull, 11,
:slurm_dist_block_cfull, 12
]
# Open stdout/err file mode, 0 for system default (JobFileAppend)
#
# <em>This entry is only for documentation and no real method. The FFI::Enum can be accessed via #enum_type(:cpu_bind_type).</em>
#
# === Options:
# :bind_verbose ::
# verbose can be set with any other flag
# :bind_to_threads ::
# the following auto-binding flags are mutually exclusive
# :bind_to_cores ::
# =threads
# :bind_to_sockets ::
# =cores
# :bind_to_ldoms ::
# =sockets
# :bind_to_boards ::
# locality domains
# :bind_none ::
# CPU_BIND_NONE needs to be the lowest value among manual bindings
# :bind_rank ::
# =no
# :bind_map ::
# =rank
# :bind_mask ::
# =map_cpu:<list of CPU IDs>
# :bind_ldrank ::
# =mask_cpu:<list of CPU masks>
# :bind_ldmap ::
# =locality domain rank
# :bind_ldmask ::
# =map_ldom:<list of locality domains>
# :bind_one_thread_per_core ::
# the following is used primarily for the
# --hint=nomultithread when -mblock:block is requested.
# :bind_cpusets ::
# the following is used only as a flag for expressing
# the contents of TaskPluginParams
# :auto_bind_to_threads ::
# default binding if auto binding doesn't match.
#
# @method _enum_cpu_bind_type_
# @return [Symbol]
# @scope class
enum :cpu_bind_type, [
:bind_verbose, 1,
:bind_to_threads, 2,
:bind_to_cores, 4,
:bind_to_sockets, 8,
:bind_to_ldoms, 16,
:bind_to_boards, 4096,
:bind_none, 32,
:bind_rank, 64,
:bind_map, 128,
:bind_mask, 256,
:bind_ldrank, 512,
:bind_ldmap, 1024,
:bind_ldmask, 2048,
:bind_one_thread_per_core, 8192,
:bind_cpusets, 32768,
:auto_bind_to_threads, 16384
]
# Flag to indicate that cpu_freq is a range: low,medium,high,high-1
# instead of an integer value in kilohertz
#
# <em>This entry is only for documentation and no real method. The FFI::Enum can be accessed via #enum_type(:mem_bind_type).</em>
#
# === Options:
# :verbose ::
# verbose can be set with any other flag
# :none ::
# MEM_BIND_NONE needs to be the first in this sub-list
# :rank ::
# =no
# :map ::
# =rank
# :mask ::
# =map_mem:<list of CPU IDs>
# :local ::
# =mask_mem:<list of CPU masks>
#
# @method _enum_mem_bind_type_
# @return [Symbol]
# @scope class
enum :mem_bind_type, [
:verbose, 1,
:none, 2,
:rank, 4,
:map, 8,
:mask, 16,
:local, 32
]
# The last entry in node_states must be STATE_END, keep in sync with
# node_state_string. values may be ORed with NODE_STATE_FLAGS below.
# Node states typically alternate between NODE_STATE_IDLE and
# NODE_STATE_ALLOCATED. The NODE_STATE_COMPLETING flag will be set
# when jobs are in the process of terminating.
#
# <em>This entry is only for documentation and no real method. The FFI::Enum can be accessed via #enum_type(:node_states).</em>
#
# === Options:
# :state_unknown ::
#
# :state_down ::
# node's initial state, unknown
# :state_idle ::
# node in non-usable state
# :state_allocated ::
# node idle and available for use
# :state_error ::
# node has been allocated to a job
# :state_mixed ::
# node is in an error state
# :state_future ::
# node has a mixed state
# :state_end ::
# node slot reserved for future use
#
# @method _enum_node_states_
# @return [Symbol]
# @scope class
enum :node_states, [
:state_unknown, 0,
:state_down, 1,
:state_idle, 2,
:state_allocated, 3,
:state_error, 4,
:state_mixed, 5,
:state_future, 6,
:state_end, 7
]
# Define keys for ctx_key argument of slurm_step_ctx_get()
#
# <em>This entry is only for documentation and no real method. The FFI::Enum can be accessed via #enum_type(:ctx_keys).</em>
#
# === Options:
# :slurm_step_ctx_stepid ::
#
# :slurm_step_ctx_tasks ::
# get the created job step id
# :slurm_step_ctx_tid ::
# get array of task count on each node
# :slurm_step_ctx_resp ::
# get array of task IDs for specified node
# :slurm_step_ctx_cred ::
# get job step create response message
# :slurm_step_ctx_switch_job ::
#
# :slurm_step_ctx_num_hosts ::
#
# :slurm_step_ctx_host ::
#
# :slurm_step_ctx_jobid ::
#
# :slurm_step_ctx_user_managed_sockets ::
#
#
# @method _enum_ctx_keys_
# @return [Symbol]
# @scope class
enum :ctx_keys, [
:slurm_step_ctx_stepid, 0,
:slurm_step_ctx_tasks, 1,
:slurm_step_ctx_tid, 2,
:slurm_step_ctx_resp, 3,
:slurm_step_ctx_cred, 4,
:slurm_step_ctx_switch_job, 5,
:slurm_step_ctx_num_hosts, 6,
:slurm_step_ctx_host, 7,
:slurm_step_ctx_jobid, 8,
:slurm_step_ctx_user_managed_sockets, 9
]
# The hostlist opaque data type
#
# A hostlist is a list of hostnames optimized for a prefixXXXX style
# naming convention, where XXXX is a decimal, numeric suffix.
class Hostlist < FFI::Struct
layout :dummy, :char
end
# slurm_hostlist_create():
#
# Create a new hostlist from a string representation.
#
# The string representation (str) may contain one or more hostnames or
# bracketed hostlists separated by either `,' or whitespace. A bracketed
# hostlist is denoted by a common prefix followed by a list of numeric
# ranges contained within brackets: e.g. "tux(0-5,12,20-25)"
#
# To support systems with 3-D topography, a rectangular prism may
# be described using two three digit numbers separated by "x": e.g.
# "bgl(123x456)". This selects all nodes between 1 and 4 inclusive
# in the first dimension, between 2 and 5 in the second, and between
# 3 and 6 in the third dimension for a total of 4*4*4=64 nodes
#
# Note: if this module is compiled with WANT_RECKLESS_HOSTRANGE_EXPANSION
# defined, a much more loose interpretation of host ranges is used.
# Reckless hostrange expansion allows all of the following (in addition to
# bracketed hostlists):
#
# o tux0-5,tux12,tux20-25
# o tux0-tux5,tux12,tux20-tux25
# o tux0-5,12,20-25
#
# If str is NULL, and empty hostlist is created and returned.
#
# If the create fails, hostlist_create() returns NULL.
#
# The returned hostlist must be freed with hostlist_destroy()
#
# @method slurm_hostlist_create(hostlist)
# @param [String] hostlist
# @return [Hostlist]
# @scope class
attach_function :slurm_hostlist_create, :slurm_hostlist_create, [:string], Hostlist
# slurm_hostlist_count():
#
# Return the number of hosts in hostlist hl.
#
# @method slurm_hostlist_count(hl)
# @param [Hostlist] hl
# @return [Integer]
# @scope class
attach_function :slurm_hostlist_count, :slurm_hostlist_count, [Hostlist], :int
# slurm_hostlist_destroy():
#
# Destroy a hostlist object. Frees all memory allocated to the hostlist.
#
# @method slurm_hostlist_destroy(hl)
# @param [Hostlist] hl
# @return [nil]
# @scope class
attach_function :slurm_hostlist_destroy, :slurm_hostlist_destroy, [Hostlist], :void
# slurm_hostlist_find():
#
# Searches hostlist hl for the first host matching hostname
# and returns position in list if found.
#
# Returns -1 if host is not found.
#
# @method slurm_hostlist_find(hl, hostname)
# @param [Hostlist] hl
# @param [String] hostname
# @return [Integer]
# @scope class
attach_function :slurm_hostlist_find, :slurm_hostlist_find, [Hostlist, :string], :int
# slurm_hostlist_push():
#
# push a string representation of hostnames onto a hostlist.
#
# The hosts argument may take the same form as in slurm_hostlist_create()
#
# Returns the number of hostnames inserted into the list,
# or 0 on failure.
#
# @method slurm_hostlist_push(hl, hosts)
# @param [Hostlist] hl
# @param [String] hosts
# @return [Integer]
# @scope class
attach_function :slurm_hostlist_push, :slurm_hostlist_push, [Hostlist, :string], :int
# slurm_hostlist_push_host():
#
# Push a single host onto the hostlist hl.
# This function is more efficient than slurm_hostlist_push() for a single
# hostname, since the argument does not need to be checked for ranges.
#
# return value is 1 for success, 0 for failure.
#
# @method slurm_hostlist_push_host(hl, host)
# @param [Hostlist] hl
# @param [String] host
# @return [Integer]
# @scope class
attach_function :slurm_hostlist_push_host, :slurm_hostlist_push_host, [Hostlist, :string], :int
# slurm_hostlist_ranged_string():
#
# Write the string representation of the hostlist hl into buf,
# writing at most n chars. Returns the number of bytes written,
# or -1 if truncation occurred.
#
# The result will be NULL terminated.
#
# slurm_hostlist_ranged_string() will write a bracketed hostlist representation
# where possible.
#
# @method slurm_hostlist_ranged_string(hl, n, buf)
# @param [Hostlist] hl
# @param [Integer] n
# @param [String] buf
# @return [Integer]
# @scope class
attach_function :slurm_hostlist_ranged_string, :slurm_hostlist_ranged_string, [Hostlist, :int, :string], :long
# slurm_hostlist_ranged_string_malloc():
#
# Return the string representation of the hostlist hl.
#
# The result must be released using free();
#
# @method slurm_hostlist_ranged_string_malloc(hl)
# @param [Hostlist] hl
# @return [String]
# @scope class
attach_function :slurm_hostlist_ranged_string_malloc, :slurm_hostlist_ranged_string_malloc, [Hostlist], :string
# hostlist_ranged_string_xmalloc():
#
# Wrapper of hostlist_ranged_string(), with result buffer dynamically
# allocated using xmalloc().
# The result will be NULL on failure (out of memory).
#
# Caller should free the result string using xfree().
#
# @method slurm_hostlist_ranged_string_xmalloc(hl)
# @param [Hostlist] hl
# @return [String]
# @scope class
attach_function :slurm_hostlist_ranged_string_xmalloc, :slurm_hostlist_ranged_string_xmalloc, [Hostlist], :string
# slurm_hostlist_shift():
#
# Returns the string representation of the first host in the hostlist
# or NULL if the hostlist is empty or there was an error allocating memory.
# The host is removed from the hostlist.
#
# Note: Caller is responsible for freeing the returned memory.
#
# @method slurm_hostlist_shift(hl)
# @param [Hostlist] hl
# @return [String]
# @scope class
attach_function :slurm_hostlist_shift, :slurm_hostlist_shift, [Hostlist], :string
# slurm_hostlist_uniq():
#
# Sort the hostlist hl and remove duplicate entries.
#
# @method slurm_hostlist_uniq(hl)
# @param [Hostlist] hl
# @return [nil]
# @scope class
attach_function :slurm_hostlist_uniq, :slurm_hostlist_uniq, [Hostlist], :void
# \
# SLURM LIST FUNCTIONS
# \
class List < FFI::Struct
layout :dummy, :char
end
# List opaque data type.
class ListIterator < FFI::Struct
layout :dummy, :char
end
# Function prototype to deallocate data stored in a list.
# This function is responsible for freeing all memory associated
# with an item, including all subordinate items (if applicable).
#
# <em>This entry is only for documentation and no real method.</em>
#
# @method _callback_list_cmp_f_(x, y)
# @param [FFI::Pointer(*Void)] x
# @param [FFI::Pointer(*Void)] y
# @return [FFI::Pointer(*Void)]
# @scope class
callback :list_cmp_f, [:pointer, :pointer], :pointer
# Function prototype for comparing two items in a list.
# Returns less-than-zero if (x<y), zero if (x==y), and
# greather-than-zero if (x>y).
#
# <em>This entry is only for documentation and no real method.</em>
#
# @method _callback_list_find_f_(x, key)
# @param [FFI::Pointer(*Void)] x
# @param [FFI::Pointer(*Void)] key
# @return [FFI::Pointer(*Void)]
# @scope class
callback :list_find_f, [:pointer, :pointer], :pointer
# Function prototype for matching items in a list.
# Returns non-zero if (x==key); o/w returns zero.
#
# <em>This entry is only for documentation and no real method.</em>
#
# @method _callback_list_for_f_(x, arg)
# @param [FFI::Pointer(*Void)] x
# @param [FFI::Pointer(*Void)] arg
# @return [FFI::Pointer(*Void)]
# @scope class
callback :list_for_f, [:pointer, :pointer], :pointer
# slurm_list_append():
#
# Inserts data (x) at the end of list (l).
# Returns the data's ptr, or lsd_nomem_error() if insertion failed.
#
# @method slurm_list_append(l, x)
# @param [List] l
# @param [FFI::Pointer(*Void)] x
# @return [FFI::Pointer(*Void)]
# @scope class
attach_function :slurm_list_append, :slurm_list_append, [List, :pointer], :pointer
# slurm_list_count():
#
# Returns the number of items in list (l).
#
# @method slurm_list_count(l)
# @param [List] l
# @return [Integer]
# @scope class
attach_function :slurm_list_count, :slurm_list_count, [List], :int
# slurm_list_create():
#
# Creates and returns a new empty list, or lsd_nomem_error() on failure.
# The deletion function (f) is used to deallocate memory used by items
# in the list; if this is NULL, memory associated with these items
# will not be freed when the list is destroyed.
# Note: Abandoning a list without calling slurm_list_destroy() will result
# in a memory leak.
#
# @method slurm_list_create(f)
# @param [FFI::Pointer(ListDelF)] f
# @return [List]
# @scope class
attach_function :slurm_list_create, :slurm_list_create, [:pointer], List
# slurm_list_destroy():
#
# Destroys list (l), freeing memory used for list iterators and the
# list itself; if a deletion function was specified when the list
# was created, it will be called for each item in the list.
#
# @method slurm_list_destroy(l)
# @param [List] l
# @return [nil]
# @scope class
attach_function :slurm_list_destroy, :slurm_list_destroy, [List], :void
# slurm_list_find():
#
# Traverses the list from the point of the list iterator (i)
# using (f) to match each item with (key).
# Returns a ptr to the next item for which the function (f)
# returns non-zero, or NULL once the end of the list is reached.
# Example: i=slurm_list_iterator_reset(i);
# while ((x=slurm_list_find(i,f,k))) {...}
#
# @method slurm_list_find(i, f, key)
# @param [ListIterator] i
# @param [Proc(_callback_list_find_f_)] f
# @param [FFI::Pointer(*Void)] key
# @return [FFI::Pointer(*Void)]
# @scope class
attach_function :slurm_list_find, :slurm_list_find, [ListIterator, :list_find_f, :pointer], :pointer
# slurm_list_is_empty():
#
# Returns non-zero if list (l) is empty; o/w returns zero.
#
# @method slurm_list_is_empty(l)
# @param [List] l
# @return [Integer]
# @scope class
attach_function :slurm_list_is_empty, :slurm_list_is_empty, [List], :int
# Creates and returns a list iterator for non-destructively traversing
# list (l), or lsd_nomem_error() on failure.
#
# @method slurm_list_iterator_create(l)
# @param [List] l
# @return [ListIterator]
# @scope class
attach_function :slurm_list_iterator_create, :slurm_list_iterator_create, [List], ListIterator
# slurm_list_iterator_reset():
#
# Resets the list iterator (i) to start traversal at the beginning
# of the list.
#
# @method slurm_list_iterator_reset(i)
# @param [ListIterator] i
# @return [nil]
# @scope class
attach_function :slurm_list_iterator_reset, :slurm_list_iterator_reset, [ListIterator], :void
# Destroys the list iterator (i); list iterators not explicitly destroyed
# in this manner will be destroyed when the list is deallocated via
# list_destroy().
#
# @method slurm_list_iterator_destroy(i)
# @param [ListIterator] i
# @return [nil]
# @scope class
attach_function :slurm_list_iterator_destroy, :slurm_list_iterator_destroy, [ListIterator], :void
# slurm_list_next():
#
# Returns a ptr to the next item's data,
# or NULL once the end of the list is reached.
# Example: i=slurm_list_iterator_create(i);
# while ((x=slurm_list_next(i))) {...}
#
# @method slurm_list_next(i)
# @param [ListIterator] i
# @return [FFI::Pointer(*Void)]
# @scope class
attach_function :slurm_list_next, :slurm_list_next, [ListIterator], :pointer
# slurm_list_sort():
#
# Sorts list (l) into ascending order according to the function (f).
# Note: Sorting a list resets all iterators associated with the list.
# Note: The sort algorithm is stable.
#
# @method slurm_list_sort(l, f)
# @param [List] l
# @param [Proc(_callback_list_cmp_f_)] f
# @return [nil]
# @scope class
attach_function :slurm_list_sort, :slurm_list_sort, [List, :list_cmp_f], :void
# slurm_list_pop():
#
# Pops the data item at the top of the stack (l).
# Returns the data's ptr, or NULL if the stack is empty.
#
# @method slurm_list_pop(l)
# @param [List] l
# @return [FFI::Pointer(*Void)]
# @scope class
attach_function :slurm_list_pop, :slurm_list_pop, [List], :pointer
# \
# PROTOCOL DATA STRUCTURE DEFINITIONS
# \
#
# = Fields:
# :data ::
# (FFI::Pointer(*Void))
# :plugin_id ::
# (Integer)
class DynamicPluginData < FFI::Struct
layout :data, :pointer,
:plugin_id, :uint
end
# (Not documented)
#
# = Fields:
# :base_consumed_energy ::
# (Integer)
# :base_watts ::
# (Integer) lowest power consump of node, in watts
# :consumed_energy ::
# (Integer) total energy consumed by node, in joules
# :current_watts ::
# (Integer) current power consump of node, in watts
# :previous_consumed_energy ::
# (Integer)
# :poll_time ::
# (Integer) When information was last retrieved
class AcctGatherEnergy < FFI::Struct
layout :base_consumed_energy, :uint,
:base_watts, :uint,
:consumed_energy, :uint,
:current_watts, :uint,
:previous_consumed_energy, :uint,
:poll_time, :long
end
# (Not documented)
#
# = Fields:
# :consumed_energy ::
# (Integer) total energy consumed, in joules
# :temperature ::
# (Integer) temperature, in celsius
# :energy_update_time ::
# (Integer) last update time for consumed_energy
# :current_watts ::
# (Integer) current power consumption, in watts
class ExtSensorsData < FFI::Struct
layout :consumed_energy, :uint,
:temperature, :uint,
:energy_update_time, :long,
:current_watts, :uint
end
# (Not documented)
#
# = Fields:
# :account ::
# (String) charge to specified account
# :acctg_freq ::
# (String) accounting polling intervals (seconds)
# :alloc_node ::
# (String) node making resource allocation request
# NOTE: Normally set by slurm_submit* or
# slurm_allocate* function
# :alloc_resp_port ::
# (Integer) port to send allocation confirmation to
# :alloc_sid ::
# (Integer) local sid making resource allocation request
# NOTE: Normally set by slurm_submit* or
# slurm_allocate* function
# NOTE: Also used for update flags, see
# ALLOC_SID_* flags
# :argc ::
# (Integer) number of arguments to the script
# :argv ::
# (FFI::Pointer(**CharS)) arguments to the script
# :array_inx ::
# (String) job array index values
# :array_bitmap ::
# (FFI::Pointer(*Void)) NOTE: Set by slurmctld
# :begin_time ::
# (Integer) delay initiation until this time
# :ckpt_interval ::
# (Integer) periodically checkpoint this job
# :ckpt_dir ::
# (String) directory to store checkpoint images
# :comment ::
# (String) arbitrary comment (used by Moab scheduler)
# :contiguous ::
# (Integer) 1 if job requires contiguous nodes,
# 0 otherwise,default=0
# :core_spec ::
# (Integer) specialized core count
# :cpu_bind ::
# (String) binding map for map/mask_cpu - This
# currently does not matter to the
# job allocation, setting this does
# not do anything for steps.
# :cpu_bind_type ::
# (Integer) see cpu_bind_type_t - This
# currently does not matter to the
# job allocation, setting this does
# not do anything for steps.
# :dependency ::
# (String) synchronize job execution with other jobs
# :end_time ::
# (Integer) time by which job must complete, used for
# job update only now, possible deadline
# scheduling in the future
# :environment ::
# (FFI::Pointer(**CharS)) environment variables to set for job,
# name=value pairs, one per line
# :env_size ::
# (Integer) element count in environment
# :exc_nodes ::
# (String) comma separated list of nodes excluded
# from job's allocation, default NONE
# :features ::
# (String) comma separated list of required features,
# default NONE
# :gres ::
# (String) comma separated list of required generic
# resources, default NONE
# :group_id ::
# (Integer) group to assume, if run as root.
# :immediate ::
# (Integer) 1 if allocate to run or fail immediately,
# 0 if to be queued awaiting resources
# :job_id ::
# (Integer) job ID, default set by SLURM
# :job_id_str ::
# (String) string representation of the jobid
# :kill_on_node_fail ::
# (Integer) 1 if node failure to kill job,
# 0 otherwise,default=1
# :licenses ::
# (String) licenses required by the job
# :mail_type ::
# (Integer) see MAIL_JOB_ definitions above
# :mail_user ::
# (String) user to receive notification
# :mem_bind ::
# (String) binding map for map/mask_cpu
# :mem_bind_type ::
# (Integer) see mem_bind_type_t
# :name ::
# (String) name of the job, default ""
# :network ::
# (String) network use spec
# :nice ::
# (Integer) requested priority change,
# NICE_OFFSET == no change
# :num_tasks ::
# (Integer) number of tasks to be started,
# for batch only
# :open_mode ::
# (Integer) out/err open mode truncate or append,
# see OPEN_MODE_*
# :other_port ::
# (Integer) port to send various notification msg to
# :overcommit ::
# (Integer) over subscribe resources, for batch only
# :partition ::
# (String) name of requested partition,
# default in SLURM config
# :plane_size ::
# (Integer) plane size when task_dist =
# SLURM_DIST_PLANE
# :priority ::
# (Integer) relative priority of the job,
# explicitly set only for user root,
# 0 == held (don't initiate)
# :profile ::
# (Integer) Level of acct_gather_profile {all | none}
# :qos ::
# (String) Quality of Service
# :reboot ::
# (Integer) force node reboot before startup
# :resp_host ::
# (String) NOTE: Set by slurmctld
# :req_nodes ::
# (String) comma separated list of required nodes
# default NONE
# :requeue ::
# (Integer) enable or disable job requeue option
# :reservation ::
# (String) name of reservation to use
# :script ::
# (String) the actual job script, default NONE
# :shared ::
# (Integer) 1 if job can share nodes with other jobs,
# 0 if job needs exclusive access to the node,
# or NO_VAL to accept the system default.
# SHARED_FORCE to eliminate user control.
# :spank_job_env ::
# (FFI::Pointer(**CharS)) environment variables for job prolog/epilog
# scripts as set by SPANK plugins
# :spank_job_env_size ::
# (Integer) element count in spank_env
# :task_dist ::
# (Integer) see enum task_dist_state
# :time_limit ::
# (Integer) maximum run time in minutes, default is
# partition limit
# :time_min ::
# (Integer) minimum run time in minutes, default is
# time_limit
# :user_id ::
# (Integer) set only if different from current UID,
# can only be explicitly set by user root
# :wait_all_nodes ::
# (Integer) 0 to start job immediately after allocation
# 1 to start job after all nodes booted
# or NO_VAL to use system default
# :warn_flags ::
# (Integer) flags related to job signals
# (eg. KILL_JOB_BATCH)
# :warn_signal ::
# (Integer) signal to send when approaching end time
# :warn_time ::
# (Integer) time before end to send signal (seconds)
# :work_dir ::
# (String) pathname of working directory
# :cpus_per_task ::
# (Integer) number of processors required for
# each task
# :min_cpus ::
# (Integer) minimum number of processors required,
# default=0
# :max_cpus ::
# (Integer) maximum number of processors required,
# default=0
# :min_nodes ::
# (Integer) minimum number of nodes required by job,
# default=0
# :max_nodes ::
# (Integer) maximum number of nodes usable by job,
# default=0
# :boards_per_node ::
# (Integer) boards per node required by job
# :sockets_per_board ::
# (Integer) sockets per board required by job
# :sockets_per_node ::
# (Integer) sockets per node required by job
# :cores_per_socket ::
# (Integer) cores per socket required by job
# :threads_per_core ::
# (Integer) threads per core required by job
# :ntasks_per_node ::
# (Integer) number of tasks to invoke on each node
# :ntasks_per_socket ::
# (Integer) number of tasks to invoke on
# each socket
# :ntasks_per_core ::
# (Integer) number of tasks to invoke on each core
# :ntasks_per_board ::
# (Integer) number of tasks to invoke on each board
# :pn_min_cpus ::
# (Integer) minimum # CPUs per node, default=0
# :pn_min_memory ::
# (Integer) minimum real memory per node OR
# real memory per CPU | MEM_PER_CPU,
# default=0 (no limit)
# :pn_min_tmp_disk ::
# (Integer) minimum tmp disk per node,
# default=0
# :geometry ::
# (Array<Integer>) node count in various
# dimensions, e.g. X, Y, and Z
# :conn_type ::
# (Array<Integer>) see enum connection_type
# :rotate ::
# (Integer) permit geometry rotation if set
# :blrtsimage ::
# (String) BlrtsImage for block
# :linuximage ::
# (String) LinuxImage for block
# :mloaderimage ::
# (String) MloaderImage for block
# :ramdiskimage ::
# (String) RamDiskImage for block
# :req_switch ::
# (Integer) Minimum number of switches
# :select_jobinfo ::
# (DynamicPluginData) opaque data type,
# SLURM internal use only
# :std_err ::
# (String) pathname of stderr
# :std_in ::
# (String) pathname of stdin
# :std_out ::
# (String) pathname of stdout
# :wait4switch ::
# (Integer) Maximum time to wait for minimum switches
# :wckey ::
# (String) wckey for job
class JobDescriptor < FFI::Struct
layout :account, :string,
:acctg_freq, :string,
:alloc_node, :string,
:alloc_resp_port, :ushort,
:alloc_sid, :uint,
:argc, :uint,
:argv, :pointer,
:array_inx, :string,
:array_bitmap, :pointer,
:begin_time, :long,
:ckpt_interval, :ushort,
:ckpt_dir, :string,
:comment, :string,
:contiguous, :ushort,
:core_spec, :ushort,
:cpu_bind, :string,
:cpu_bind_type, :ushort,
:dependency, :string,
:end_time, :long,
:environment, :pointer,
:env_size, :uint,
:exc_nodes, :string,
:features, :string,
:gres, :string,
:group_id, :uint,
:immediate, :ushort,
:job_id, :uint,
:job_id_str, :string,
:kill_on_node_fail, :ushort,
:licenses, :string,
:mail_type, :ushort,
:mail_user, :string,
:mem_bind, :string,
:mem_bind_type, :ushort,
:name, :string,
:network, :string,
:nice, :ushort,
:num_tasks, :uint,
:open_mode, :uchar,
:other_port, :ushort,
:overcommit, :uchar,
:partition, :string,
:plane_size, :ushort,
:priority, :uint,
:profile, :uint,
:qos, :string,
:reboot, :ushort,
:resp_host, :string,
:req_nodes, :string,
:requeue, :ushort,
:reservation, :string,
:script, :string,
:shared, :ushort,
:spank_job_env, :pointer,
:spank_job_env_size, :uint,
:task_dist, :ushort,
:time_limit, :uint,
:time_min, :uint,
:user_id, :uint,
:wait_all_nodes, :ushort,
:warn_flags, :ushort,
:warn_signal, :ushort,
:warn_time, :ushort,
:work_dir, :string,
:cpus_per_task, :ushort,
:min_cpus, :uint,
:max_cpus, :uint,
:min_nodes, :uint,
:max_nodes, :uint,
:boards_per_node, :ushort,
:sockets_per_board, :ushort,
:sockets_per_node, :ushort,
:cores_per_socket, :ushort,
:threads_per_core, :ushort,
:ntasks_per_node, :ushort,
:ntasks_per_socket, :ushort,
:ntasks_per_core, :ushort,
:ntasks_per_board, :ushort,
:pn_min_cpus, :ushort,
:pn_min_memory, :uint,
:pn_min_tmp_disk, :uint,
:geometry, [:ushort, 5],
:conn_type, [:ushort, 5],
:rotate, :ushort,
:blrtsimage, :string,
:linuximage, :string,
:mloaderimage, :string,
:ramdiskimage, :string,
:req_switch, :uint,
:select_jobinfo, DynamicPluginData,
:std_err, :string,
:std_in, :string,
:std_out, :string,
:wait4switch, :uint,
:wckey, :string
end
# (Not documented)
#
# = Fields:
# :account ::
# (String) charge to specified account
# :alloc_node ::
# (String) local node making resource alloc
# :alloc_sid ::
# (Integer) local sid making resource alloc
# :array_bitmap ::
# (FFI::Pointer(*Void)) NOTE: set on unpack
# :array_job_id ::
# (Integer) job_id of a job array or 0 if N/A
# :array_task_id ::
# (Integer) task_id of a job array
# :array_max_tasks ::
# (Integer) Maximum number of running tasks
# :array_task_str ::
# (String) string expression of task IDs in this record
# :assoc_id ::
# (Integer) association id for job
# :batch_flag ::
# (Integer) 1 if batch: queued job with script
# :batch_host ::
# (String) name of host running batch script
# :batch_script ::
# (String) contents of batch script
# :boards_per_node ::
# (Integer) boards per node required by job
# :command ::
# (String) command to be executed, built from submitted
# job's argv and NULL for salloc command
# :comment ::
# (String) arbitrary comment (used by Moab scheduler)
# :contiguous ::
# (Integer) 1 if job requires contiguous nodes
# :core_spec ::
# (Integer) specialized core count
# :cores_per_socket ::
# (Integer) cores per socket required by job
# :cpus_per_task ::
# (Integer) number of processors required for
# each task
# :dependency ::
# (String) synchronize job execution with other jobs
# :derived_ec ::
# (Integer) highest exit code of all job steps
# :eligible_time ::
# (Integer) time job is eligible for running
# :end_time ::
# (Integer) time of termination, actual or expected
# :exc_nodes ::
# (String) comma separated list of excluded nodes
# :exc_node_inx ::
# (FFI::Pointer(*Int32T)) excluded list index pairs into node_table:
# start_range_1, end_range_1,
# start_range_2, .., -1
# :exit_code ::
# (Integer) exit code for job (status from wait call)
# :features ::
# (String) comma separated list of required features
# :gres ::
# (String) comma separated list of generic resources
# :group_id ::
# (Integer) group job submitted as
# :job_id ::
# (Integer) job ID
# :job_resrcs ::
# (JobResources) opaque data type, job resources
# :job_state ::
# (Integer) state of the job, see enum job_states
# :licenses ::
# (String) licenses required by the job
# :max_cpus ::
# (Integer) maximum number of cpus usable by job
# :max_nodes ::
# (Integer) maximum number of nodes usable by job
# :name ::
# (String) name of the job
# :network ::
# (String) network specification
# :nodes ::
# (String) list of nodes allocated to job
# :nice ::
# (Integer) requested priority change
# :node_inx ::
# (FFI::Pointer(*Int32T)) list index pairs into node_table for *nodes:
# start_range_1, end_range_1,
# start_range_2, .., -1
# :ntasks_per_core ::
# (Integer) number of tasks to invoke on each core
# :ntasks_per_node ::
# (Integer) number of tasks to invoke on each node
# :ntasks_per_socket ::
# (Integer) number of tasks to invoke on each socket
# :ntasks_per_board ::
# (Integer) number of tasks to invoke on each board
# :num_nodes ::
# (Integer) minimum number of nodes required by job
# :num_cpus ::
# (Integer) minimum number of cpus required by job
# :partition ::
# (String) name of assigned partition
# :pn_min_memory ::
# (Integer) minimum real memory per node, default=0
# :pn_min_cpus ::
# (Integer) minimum # CPUs per node, default=0
# :pn_min_tmp_disk ::
# (Integer) minimum tmp disk per node, default=0
# :preempt_time ::
# (Integer) preemption signal time
# :pre_sus_time ::
# (Integer) time job ran prior to last suspend
# :priority ::
# (Integer) relative priority of the job,
# 0=held, 1=required nodes DOWN/DRAINED
# :profile ::
# (Integer) Level of acct_gather_profile {all | none}
# :qos ::
# (String) Quality of Service
# :reboot ::
# (Integer) node reboot requested before start
# :req_nodes ::
# (String) comma separated list of required nodes
# :req_node_inx ::
# (FFI::Pointer(*Int32T)) required list index pairs into node_table:
# start_range_1, end_range_1,
# start_range_2, .., -1
# :req_switch ::
# (Integer) Minimum number of switches
# :requeue ::
# (Integer) enable or disable job requeue option
# :resize_time ::
# (Integer) time of latest size change
# :restart_cnt ::
# (Integer) count of job restarts
# :resv_name ::
# (String) reservation name
# :sched_nodes ::
# (String) list of nodes scheduled to be used for job
# :select_jobinfo ::
# (DynamicPluginData) opaque data type,
# process using
# slurm_get_select_jobinfo()
# :shared ::
# (Integer) 1 if job can share nodes with other jobs
# :show_flags ::
# (Integer) conveys level of details requested
# :sockets_per_board ::
# (Integer) sockets per board required by job
# :sockets_per_node ::
# (Integer) sockets per node required by job
# :start_time ::
# (Integer) time execution begins, actual or expected
# :state_desc ::
# (String) optional details for state_reason
# :state_reason ::
# (Integer) reason job still pending or failed, see
# slurm.h:enum job_state_reason
# :std_err ::
# (String) pathname of job's stderr file
# :std_in ::
# (String) pathname of job's stdin file
# :std_out ::
# (String) pathname of job's stdout file
# :submit_time ::
# (Integer) time of job submission
# :suspend_time ::
# (Integer) time job last suspended or resumed
# :time_limit ::
# (Integer) maximum run time in minutes or INFINITE
# :time_min ::
# (Integer) minimum run time in minutes or INFINITE
# :threads_per_core ::
# (Integer) threads per core required by job
# :user_id ::
# (Integer) user the job runs as
# :wait4switch ::
# (Integer) Maximum time to wait for minimum switches
# :wckey ::
# (String) wckey for job
# :work_dir ::
# (String) pathname of working directory
class JobInfo < FFI::Struct
layout :account, :string,
:alloc_node, :string,
:alloc_sid, :uint,
:array_bitmap, :pointer,
:array_job_id, :uint,
:array_task_id, :uint,
:array_max_tasks, :uint,
:array_task_str, :string,
:assoc_id, :uint,
:batch_flag, :ushort,
:batch_host, :string,
:batch_script, :string,
:boards_per_node, :ushort,
:command, :string,
:comment, :string,
:contiguous, :ushort,
:core_spec, :ushort,
:cores_per_socket, :ushort,
:cpus_per_task, :ushort,
:dependency, :string,
:derived_ec, :uint,
:eligible_time, :long,
:end_time, :long,
:exc_nodes, :string,
:exc_node_inx, :pointer,
:exit_code, :uint,
:features, :string,
:gres, :string,
:group_id, :uint,
:job_id, :uint,
:job_resrcs, JobResources,
:job_state, :ushort,
:licenses, :string,
:max_cpus, :uint,
:max_nodes, :uint,
:name, :string,
:network, :string,
:nodes, :string,
:nice, :ushort,
:node_inx, :pointer,
:ntasks_per_core, :ushort,
:ntasks_per_node, :ushort,
:ntasks_per_socket, :ushort,
:ntasks_per_board, :ushort,
:num_nodes, :uint,
:num_cpus, :uint,
:partition, :string,
:pn_min_memory, :uint,
:pn_min_cpus, :ushort,
:pn_min_tmp_disk, :uint,
:preempt_time, :long,
:pre_sus_time, :long,
:priority, :uint,
:profile, :uint,
:qos, :string,
:reboot, :uchar,
:req_nodes, :string,
:req_node_inx, :pointer,
:req_switch, :uint,
:requeue, :ushort,
:resize_time, :long,
:restart_cnt, :ushort,
:resv_name, :string,
:sched_nodes, :string,
:select_jobinfo, DynamicPluginData,
:shared, :ushort,
:show_flags, :ushort,
:sockets_per_board, :ushort,
:sockets_per_node, :ushort,
:start_time, :long,
:state_desc, :string,
:state_reason, :ushort,
:std_err, :string,
:std_in, :string,
:std_out, :string,
:submit_time, :long,
:suspend_time, :long,
:time_limit, :uint,
:time_min, :uint,
:threads_per_core, :ushort,
:user_id, :uint,
:wait4switch, :uint,
:wckey, :string,
:work_dir, :string
end
# (Not documented)
#
# = Fields:
# :last_update ::
# (Integer) time of latest info
# :record_count ::
# (Integer) number of records
# :job_array ::
# (JobInfo) the job records
class JobInfoMsg < FFI::Struct
layout :last_update, :long,
:record_count, :uint,
:job_array, JobInfo
end
# (Not documented)
#
# = Fields:
# :end_time ::
# (Integer) step end time
# :exit_code ::
# (Integer) exit code for job (status from wait call)
# :job_id ::
# (Integer)
# :jobacct ::
# (Jobacctinfo)
# :name ::
# (String) step name
# :start_time ::
# (Integer) step start time
# :step_id ::
# (Integer)
# :time_limit ::
# (Integer) In minutes
class StepUpdateRequestMsg < FFI::Struct
layout :end_time, :long,
:exit_code, :uint,
:job_id, :uint,
:jobacct, Jobacctinfo,
:name, :string,
:start_time, :long,
:step_id, :uint,
:time_limit, :uint
end
# (Not documented)
#
# = Fields:
# :front_end ::
# (String) If a front-end architecture, the name of
# of the node running all tasks,
# NULL otherwise
# :node_cnt ::
# (Integer) node count
# :node_list ::
# (String) list of nodes in step
# :plane_size ::
# (Integer) plane size when task_dist =
# SLURM_DIST_PLANE
# :tasks ::
# (FFI::Pointer(*Uint16T)) Array of length "node_cnt". Each element of the array
# is the number of tasks assigned to the corresponding node
# :task_cnt ::
# (Integer) total number of tasks in the step
# :task_dist ::
# (Integer) see enum task_dist_state
# :tids ::
# (FFI::Pointer(**Uint32T)) host id => task id mapping
class SlurmStepLayout < FFI::Struct
layout :front_end, :string,
:node_cnt, :uint,
:node_list, :string,
:plane_size, :ushort,
:tasks, :pointer,
:task_cnt, :uint,
:task_dist, :ushort,
:tids, :pointer
end
# (Not documented)
#
# = Fields:
# :fd ::
# (Integer)
# :taskid ::
# (Integer)
# :nodeid ::
# (Integer)
class SlurmStepIoFdsIn < FFI::Struct
layout :fd, :int,
:taskid, :uint,
:nodeid, :uint
end
# (Not documented)
#
# = Fields:
# :in_ ::
# (SlurmStepIoFdsIn)
# :out ::
# (SlurmStepIoFdsIn)
# :err ::
# (SlurmStepIoFdsIn)
class SlurmStepIoFds < FFI::Struct
layout :in_, SlurmStepIoFdsIn.by_value,
:out, SlurmStepIoFdsIn.by_value,
:err, SlurmStepIoFdsIn.by_value
end
# (Not documented)
#
# = Fields:
# :return_code ::
# (Integer)
# :node_name ::
# (String)
# :srun_node_id ::
# (Integer)
# :count_of_pids ::
# (Integer)
# :local_pids ::
# (FFI::Pointer(*Uint32T))
# :task_ids ::
# (FFI::Pointer(*Uint32T)) array of length count_of_pids
class LaunchTasksResponseMsg < FFI::Struct
layout :return_code, :uint,
:node_name, :string,
:srun_node_id, :uint,
:count_of_pids, :uint,
:local_pids, :pointer,
:task_ids, :pointer
end
# (Not documented)
#
# = Fields:
# :num_tasks ::
# (Integer)
# :task_id_list ::
# (FFI::Pointer(*Uint32T))
# :return_code ::
# (Integer)
# :job_id ::
# (Integer)
# :step_id ::
# (Integer)
class TaskExtMsg < FFI::Struct
layout :num_tasks, :uint,
:task_id_list, :pointer,
:return_code, :uint,
:job_id, :uint,
:step_id, :uint
end
# (Not documented)
#
# = Fields:
# :job_id ::
# (Integer) slurm job_id
# :step_id ::
# (Integer) step_id or NO_VAL
class SrunPingMsg < FFI::Struct
layout :job_id, :uint,
:step_id, :uint
end
# (Not documented)
#
# = Fields:
# :job_id ::
# (Integer) slurm job_id
# :step_id ::
# (Integer) step_id or NO_VAL
class SrunJobCompleteMsg < FFI::Struct
layout :job_id, :uint,
:step_id, :uint
end
# (Not documented)
#
# = Fields:
# :job_id ::
# (Integer) slurm job_id
# :step_id ::
# (Integer) step_id or NO_VAL
# :timeout ::
# (Integer) when job scheduled to be killed
class SrunTimeoutMsg < FFI::Struct
layout :job_id, :uint,
:step_id, :uint,
:timeout, :long
end
# (Not documented)
#
# = Fields:
# :job_id ::
# (Integer) slurm job_id
# :msg ::
# (String) message to user's srun
class SrunUserMsg < FFI::Struct
layout :job_id, :uint,
:msg, :string
end
# (Not documented)
#
# = Fields:
# :job_id ::
# (Integer) slurm job_id
# :nodelist ::
# (String) name of failed node(s)
# :step_id ::
# (Integer) step_id or NO_VAL
class SrunNodeFailMsg < FFI::Struct
layout :job_id, :uint,
:nodelist, :string,
:step_id, :uint
end
# (Not documented)
#
# = Fields:
# :job_id ::
# (Integer) slurm job_id
# :nodelist ::
# (String) name of node(s) lacking this step
# :step_id ::
# (Integer) step_id or NO_VAL
class SrunStepMissingMsg < FFI::Struct
layout :job_id, :uint,
:nodelist, :string,
:step_id, :uint
end
# (Not documented)
#
# <em>This entry is only for documentation and no real method. The FFI::Enum can be accessed via #enum_type(:suspend_opts).</em>
#
# === Options:
# :suspend_job ::
#
# :resume_job ::
# Suspend a job now
#
# @method _enum_suspend_opts_
# @return [Symbol]
# @scope class
enum :suspend_opts, [
:suspend_job, 0,
:resume_job, 1
]
# NOTE: Set either job_id_str (NULL by default) or job_id
#
# = Fields:
# :op ::
# (Integer) suspend operation, see enum suspend_opts
# :job_id ::
# (Integer) slurm job ID (number)
# :job_id_str ::
# (String) slurm job ID (string)
class SuspendMsg < FFI::Struct
layout :op, :ushort,
:job_id, :uint,
:job_id_str, :string
end
# (Not documented)
#
# = Fields:
# :ckpt_interval ::
# (Integer) checkpoint interval in minutes
# :cpu_count ::
# (Integer) number of required processors
# :cpu_freq ::
# (Integer) requested cpu frequency
# :exclusive ::
# (Integer) 1 if CPUs not shared with other steps
# :features ::
# (String) required node features, default NONE
# :immediate ::
# (Integer) 1 if allocate to run or fail immediately,
# 0 if to be queued awaiting resources
# :job_id ::
# (Integer) job ID
# :pn_min_memory ::
# (Integer) minimum real memory per node OR
# real memory per CPU | MEM_PER_CPU,
# default=0 (use job limit)
# :ckpt_dir ::
# (String) directory to store checkpoint image files
# :gres ::
# (String) generic resources needed
# :name ::
# (String) name of the job step
# :network ::
# (String) network use spec
# :profile ::
# (Integer) Level of acct_gather_profile {all | none}
# :no_kill ::
# (Integer) 1 if no kill on node failure
# :min_nodes ::
# (Integer) minimum number of nodes required by job,
# default=0
# :max_nodes ::
# (Integer) maximum number of nodes usable by job,
# default=0
# :node_list ::
# (String) list of required nodes
# :overcommit ::
# (Integer) "true" to allow the allocation of more tasks
# to a node than available processors,
# "false" to accept at most one task per
# processor. "false" by default.
# :plane_size ::
# (Integer) plane size when task_dist =
# SLURM_DIST_PLANE
# :relative ::
# (Integer) first node to use of job's allocation
# :resv_port_cnt ::
# (Integer) reserve ports if set
# :task_count ::
# (Integer) number of tasks required
# :task_dist ::
# (Integer) see enum task_dist_state, default
# is SLURM_DIST_CYCLIC
# :time_limit ::
# (Integer) step time limit
# :uid ::
# (Integer) user ID
# :verbose_level ::
# (Integer) for extra logging decisions in step
# launch api
module SlurmStepCtxParamsTWrappers
# @return [nil]
def init()
Slurm.slurm_step_ctx_params_t_init(self)
end
end
class SlurmStepCtxParamsT < FFI::Struct
include SlurmStepCtxParamsTWrappers
layout :ckpt_interval, :ushort,
:cpu_count, :uint,
:cpu_freq, :uint,
:exclusive, :ushort,
:features, :string,
:immediate, :ushort,
:job_id, :uint,
:pn_min_memory, :uint,
:ckpt_dir, :string,
:gres, :string,
:name, :string,
:network, :string,
:profile, :uint,
:no_kill, :uchar,
:min_nodes, :uint,
:max_nodes, :uint,
:node_list, :string,
:overcommit, :int,
:plane_size, :ushort,
:relative, :ushort,
:resv_port_cnt, :ushort,
:task_count, :uint,
:task_dist, :ushort,
:time_limit, :uint,
:uid, :uint,
:verbose_level, :ushort
end
# (Not documented)
#
# = Fields:
# :alias_list ::
# (String) node name/address/hostnamne aliases
# :argc ::
# (Integer)
# :argv ::
# (FFI::Pointer(**CharS))
# :envc ::
# (Integer)
# :env ::
# (FFI::Pointer(**CharS))
# :cwd ::
# (String)
# :user_managed_io ::
# (Integer)
# :msg_timeout ::
# (Integer) timeout set for sending message
# :buffered_stdio ::
# (Integer) START - only used if user_managed_io is false
# :labelio ::
# (Integer)
# :remote_output_filename ::
# (String)
# :remote_error_filename ::
# (String)
# :remote_input_filename ::
# (String)
# :local_fds ::
# (SlurmStepIoFds)
# :gid ::
# (Integer) END - only used if user_managed_io is false
# :multi_prog ::
# (Integer)
# :slurmd_debug ::
# (Integer) remote slurmd debug level
# :parallel_debug ::
# (Integer)
# :profile ::
# (Integer) Level of acct_gather_profile {all | none}
# :task_prolog ::
# (String)
# :task_epilog ::
# (String)
# :cpu_bind_type ::
# (Integer) use cpu_bind_type_t
# :cpu_bind ::
# (String)
# :cpu_freq ::
# (Integer) requested cpu frequency
# :mem_bind_type ::
# (Integer) use mem_bind_type_t
# :mem_bind ::
# (String)
# :max_sockets ::
# (Integer)
# :max_cores ::
# (Integer)
# :max_threads ::
# (Integer)
# :cpus_per_task ::
# (Integer)
# :task_dist ::
# (Integer)
# :partition ::
# (String)
# :preserve_env ::
# (Integer)
# :mpi_plugin_name ::
# (String)
# :open_mode ::
# (Integer)
# :acctg_freq ::
# (String)
# :pty ::
# (Integer)
# :ckpt_dir ::
# (String)
# :restart_dir ::
# (String)
# :spank_job_env ::
# (FFI::Pointer(**CharS)) environment variables for job prolog/epilog
# scripts as set by SPANK plugins
# :spank_job_env_size ::
# (Integer) element count in spank_env
module SlurmStepLaunchParamsTWrappers
# @return [nil]
def init()
Slurm.slurm_step_launch_params_t_init(self)
end
end
class SlurmStepLaunchParamsT < FFI::Struct
include SlurmStepLaunchParamsTWrappers
layout :alias_list, :string,
:argc, :uint,
:argv, :pointer,
:envc, :uint,
:env, :pointer,
:cwd, :string,
:user_managed_io, :int,
:msg_timeout, :uint,
:buffered_stdio, :int,
:labelio, :int,
:remote_output_filename, :string,
:remote_error_filename, :string,
:remote_input_filename, :string,
:local_fds, SlurmStepIoFds.by_value,
:gid, :uint,
:multi_prog, :int,
:slurmd_debug, :uint,
:parallel_debug, :int,
:profile, :uint,
:task_prolog, :string,
:task_epilog, :string,
:cpu_bind_type, :ushort,
:cpu_bind, :string,
:cpu_freq, :uint,
:mem_bind_type, :ushort,
:mem_bind, :string,
:max_sockets, :ushort,
:max_cores, :ushort,
:max_threads, :ushort,
:cpus_per_task, :ushort,
:task_dist, :ushort,
:partition, :string,
:preserve_env, :int,
:mpi_plugin_name, :string,
:open_mode, :uchar,
:acctg_freq, :string,
:pty, :int,
:ckpt_dir, :string,
:restart_dir, :string,
:spank_job_env, :pointer,
:spank_job_env_size, :uint
end
# (Not documented)
#
# = Fields:
# :step_complete ::
# (FFI::Pointer(*))
# :step_signal ::
# (FFI::Pointer(*))
# :step_timeout ::
# (FFI::Pointer(*))
# :task_start ::
# (FFI::Pointer(*))
# :task_finish ::
# (FFI::Pointer(*))
class SlurmStepLaunchCallbacksT < FFI::Struct
layout :step_complete, :pointer,
:step_signal, :pointer,
:step_timeout, :pointer,
:task_start, :pointer,
:task_finish, :pointer
end
# (Not documented)
#
# = Fields:
# :ping ::
# (FFI::Pointer(*))
# :job_complete ::
# (FFI::Pointer(*))
# :timeout ::
# (FFI::Pointer(*))
# :user_msg ::
# (FFI::Pointer(*))
# :node_fail ::
# (FFI::Pointer(*))
# :job_suspend ::
# (FFI::Pointer(*))
class SlurmAllocationCallbacksT < FFI::Struct
layout :ping, :pointer,
:job_complete, :pointer,
:timeout, :pointer,
:user_msg, :pointer,
:node_fail, :pointer,
:job_suspend, :pointer
end
# (Not documented)
#
# = Fields:
# :acct_full ::
# (FFI::Pointer(*))
# :dbd_fail ::
# (FFI::Pointer(*))
# :dbd_resumed ::
# (FFI::Pointer(*))
# :db_fail ::
# (FFI::Pointer(*))
# :db_resumed ::
# (FFI::Pointer(*))
class SlurmTriggerCallbacksT < FFI::Struct
layout :acct_full, :pointer,
:dbd_fail, :pointer,
:dbd_resumed, :pointer,
:db_fail, :pointer,
:db_resumed, :pointer
end
# (Not documented)
#
# = Fields:
# :array_job_id ::
# (Integer) job_id of a job array or 0 if N/A
# :array_task_id ::
# (Integer) task_id of a job array
# :ckpt_dir ::
# (String) path to store checkpoint image files
# :ckpt_interval ::
# (Integer) checkpoint interval in minutes
# :gres ::
# (String) generic resources required
# :job_id ::
# (Integer) job ID
# :name ::
# (String) name of job step
# :network ::
# (String) network specs for job step
# :nodes ::
# (String) list of nodes allocated to job_step
# :node_inx ::
# (FFI::Pointer(*Int32T)) list index pairs into node_table for *nodes:
# start_range_1, end_range_1,
# start_range_2, .., -1
# :num_cpus ::
# (Integer) how many cpus are being used by step
# :cpu_freq ::
# (Integer) requested cpu frequency
# :num_tasks ::
# (Integer) number of tasks
# :partition ::
# (String) name of assigned partition
# :resv_ports ::
# (String) ports allocated for MPI
# :run_time ::
# (Integer) net run time (factor out time suspended)
# :select_jobinfo ::
# (DynamicPluginData) opaque data type,
# process using
# slurm_get_select_jobinfo()
# :start_time ::
# (Integer) step start time
# :state ::
# (Integer) state of the step, see enum job_states
# :step_id ::
# (Integer) step ID
# :time_limit ::
# (Integer) step time limit
# :user_id ::
# (Integer) user the job runs as
class JobStepInfoT < FFI::Struct
layout :array_job_id, :uint,
:array_task_id, :uint,
:ckpt_dir, :string,
:ckpt_interval, :ushort,
:gres, :string,
:job_id, :uint,
:name, :string,
:network, :string,
:nodes, :string,
:node_inx, :pointer,
:num_cpus, :uint,
:cpu_freq, :uint,
:num_tasks, :uint,
:partition, :string,
:resv_ports, :string,
:run_time, :long,
:select_jobinfo, DynamicPluginData,
:start_time, :long,
:state, :ushort,
:step_id, :uint,
:time_limit, :uint,
:user_id, :uint
end
# (Not documented)
#
# = Fields:
# :last_update ::
# (Integer) time of latest info
# :job_step_count ::
# (Integer) number of records
# :job_steps ::
# (JobStepInfoT) the job step records
class JobStepInfoResponseMsg < FFI::Struct
layout :last_update, :long,
:job_step_count, :uint,
:job_steps, JobStepInfoT
end
# (Not documented)
#
# = Fields:
# :node_name ::
# (String)
# :pid ::
# (FFI::Pointer(*Uint32T))
# :pid_cnt ::
# (Integer)
class JobStepPidsT < FFI::Struct
layout :node_name, :string,
:pid, :pointer,
:pid_cnt, :uint
end
# (Not documented)
#
# = Fields:
# :job_id ::
# (Integer)
# :pid_list ::
# (List) List of job_step_pids_t *'s
# :step_id ::
# (Integer)
class JobStepPidsResponseMsgT < FFI::Struct
layout :job_id, :uint,
:pid_list, List,
:step_id, :uint
end
# (Not documented)
#
# = Fields:
# :jobacct ::
# (Jobacctinfo)
# :num_tasks ::
# (Integer)
# :return_code ::
# (Integer)
# :step_pids ::
# (JobStepPidsT)
class JobStepStatT < FFI::Struct
layout :jobacct, Jobacctinfo,
:num_tasks, :uint,
:return_code, :uint,
:step_pids, JobStepPidsT
end
# (Not documented)
#
# = Fields:
# :job_id ::
# (Integer) job ID
# :stats_list ::
# (List) List of job_step_stat_t *'s
# :step_id ::
# (Integer)
class JobStepStatResponseMsgT < FFI::Struct
layout :job_id, :uint,
:stats_list, List,
:step_id, :uint
end
# (Not documented)
#
# = Fields:
# :arch ::
# (String) computer architecture
# :boards ::
# (Integer) total number of boards per node
# :boot_time ::
# (Integer) time of node boot
# :cores ::
# (Integer) number of cores per socket
# :core_spec_cnt ::
# (Integer) number of specialized cores on node
# :cpu_load ::
# (Integer) CPU load * 100
# :cpus ::
# (Integer) configured count of cpus running on
# the node
# :cpu_spec_list ::
# (String) node's specialized cpus
# :energy ::
# (AcctGatherEnergy) energy data
# :ext_sensors ::
# (ExtSensorsData) external sensor data
# :features ::
# (String) list of a node's features
# :gres ::
# (String) list of a node's generic resources
# :gres_drain ::
# (String) list of drained GRES
# :gres_used ::
# (String) list of GRES in current use
# :mem_spec_limit ::
# (Integer) MB memory limit for specialization
# :name ::
# (String) node name to slurm
# :node_addr ::
# (String) communication name (optional)
# :node_hostname ::
# (String) node's hostname (optional)
# :node_state ::
# (Integer) see enum node_states
# :os ::
# (String) operating system currently running
# :real_memory ::
# (Integer) configured MB of real memory on the node
# :reason ::
# (String) reason for node being DOWN or DRAINING
# :reason_time ::
# (Integer) Time stamp when reason was set, ignore if
# no reason is set.
# :reason_uid ::
# (Integer) User that set the reason, ignore if
# no reason is set.
# :select_nodeinfo ::
# (DynamicPluginData) opaque data structure,
# use
# slurm_get_select_nodeinfo()
# to access contents
# :slurmd_start_time ::
# (Integer) time of slurmd startup
# :sockets ::
# (Integer) total number of sockets per node
# :threads ::
# (Integer) number of threads per core
# :tmp_disk ::
# (Integer) configured MB of total disk in TMP_FS
# :weight ::
# (Integer) arbitrary priority of node for scheduling
# :version ::
# (String) Slurm version number
class NodeInfo < FFI::Struct
layout :arch, :string,
:boards, :ushort,
:boot_time, :long,
:cores, :ushort,
:core_spec_cnt, :ushort,
:cpu_load, :uint,
:cpus, :ushort,
:cpu_spec_list, :string,
:energy, AcctGatherEnergy,
:ext_sensors, ExtSensorsData,
:features, :string,
:gres, :string,
:gres_drain, :string,
:gres_used, :string,
:mem_spec_limit, :uint,
:name, :string,
:node_addr, :string,
:node_hostname, :string,
:node_state, :uint,
:os, :string,
:real_memory, :uint,
:reason, :string,
:reason_time, :long,
:reason_uid, :uint,
:select_nodeinfo, DynamicPluginData,
:slurmd_start_time, :long,
:sockets, :ushort,
:threads, :ushort,
:tmp_disk, :uint,
:weight, :uint,
:version, :string
end
# (Not documented)
#
# = Fields:
# :last_update ::
# (Integer) time of latest info
# :node_scaling ::
# (Integer) the amount of nodes per
# each record used for
# systems like bluegene
# where SLURM handles a
# bluegene midplane as a
# single SLURM node.
# :record_count ::
# (Integer) number of records
# :node_array ::
# (NodeInfo) the node records
class NodeInfoMsg < FFI::Struct
layout :last_update, :long,
:node_scaling, :uint,
:record_count, :uint,
:node_array, NodeInfo
end
# (Not documented)
#
# = Fields:
# :allow_groups ::
# (String) allowed group string
# :allow_users ::
# (String) allowed user string
# :boot_time ::
# (Integer) Time of node boot,
# computed from up_time
# :deny_groups ::
# (String) denied group string
# :deny_users ::
# (String) denied user string
# :name ::
# (String) node name
# :node_state ::
# (Integer) see enum node_states
# :reason ::
# (String) reason for node being DOWN or
# DRAINING
# :reason_time ::
# (Integer) Time stamp when reason was set,
# ignore if no reason is set.
# :reason_uid ::
# (Integer) User that set the reason,
# ignore if no reason is set.
# :slurmd_start_time ::
# (Integer) Time of slurmd startup
# :version ::
# (String) Slurm version number
class FrontEndInfo < FFI::Struct
layout :allow_groups, :string,
:allow_users, :string,
:boot_time, :long,
:deny_groups, :string,
:deny_users, :string,
:name, :string,
:node_state, :uint,
:reason, :string,
:reason_time, :long,
:reason_uid, :uint,
:slurmd_start_time, :long,
:version, :string
end
# (Not documented)
#
# = Fields:
# :last_update ::
# (Integer) time of latest info
# :record_count ::
# (Integer) number of records
# :front_end_array ::
# (FrontEndInfo) the front_end records
class FrontEndInfoMsg < FFI::Struct
layout :last_update, :long,
:record_count, :uint,
:front_end_array, FrontEndInfo
end
# (Not documented)
#
# = Fields:
# :level ::
# (Integer) level in hierarchy, leaf=0
# :link_speed ::
# (Integer) link speed, arbitrary units
# :name ::
# (String) switch name
# :nodes ::
# (String) name if direct descendent nodes
# :switches ::
# (String) name if direct descendent switches
class TopoInfo < FFI::Struct
layout :level, :ushort,
:link_speed, :uint,
:name, :string,
:nodes, :string,
:switches, :string
end
# (Not documented)
#
# = Fields:
# :record_count ::
# (Integer) number of records
# :topo_array ::
# (TopoInfo) the switch topology records
class TopoInfoResponseMsg < FFI::Struct
layout :record_count, :uint,
:topo_array, TopoInfo
end
# (Not documented)
#
# = Fields:
# :job_id ::
# (Integer) job ID
class JobAllocInfoMsg < FFI::Struct
layout :job_id, :uint
end
# (Not documented)
#
# = Fields:
# :node_name ::
# (String) node name
# :energy ::
# (AcctGatherEnergy)
class AcctGatherNodeRespMsg < FFI::Struct
layout :node_name, :string,
:energy, AcctGatherEnergy
end
# (Not documented)
#
# = Fields:
# :delta ::
# (Integer)
class AcctGatherEnergyReqMsg < FFI::Struct
layout :delta, :ushort
end
# Clear LLN partition flag
#
# = Fields:
# :allow_alloc_nodes ::
# (String) list names of allowed allocating
# nodes
# :allow_accounts ::
# (String) comma delimited list of accounts,
# null indicates all
# :allow_groups ::
# (String) comma delimited list of groups,
# null indicates all
# :allow_qos ::
# (String) comma delimited list of qos,
# null indicates all
# :alternate ::
# (String) name of alternate partition
# :cr_type ::
# (Integer) see CR_* values
# :def_mem_per_cpu ::
# (Integer) default MB memory per allocated CPU
# :default_time ::
# (Integer) minutes, NO_VAL or INFINITE
# :deny_accounts ::
# (String) comma delimited list of denied accounts
# :deny_qos ::
# (String) comma delimited list of denied qos
# :flags ::
# (Integer) see PART_FLAG_* above
# :grace_time ::
# (Integer) preemption grace time in seconds
# :max_cpus_per_node ::
# (Integer) maximum allocated CPUs per node
# :max_mem_per_cpu ::
# (Integer) maximum MB memory per allocated CPU
# :max_nodes ::
# (Integer) per job or INFINITE
# :max_share ::
# (Integer) number of jobs to gang schedule
# :max_time ::
# (Integer) minutes or INFINITE
# :min_nodes ::
# (Integer) per job
# :name ::
# (String) name of the partition
# :node_inx ::
# (FFI::Pointer(*Int32T)) list index pairs into node_table:
# start_range_1, end_range_1,
# start_range_2, .., -1
# :nodes ::
# (String) list names of nodes in partition
# :preempt_mode ::
# (Integer) See PREEMPT_MODE_* in slurm/slurm.h
# :priority ::
# (Integer) scheduling priority for jobs
# :state_up ::
# (Integer) see PARTITION_ states above
# :total_cpus ::
# (Integer) total number of cpus in the partition
# :total_nodes ::
# (Integer) total number of nodes in the partition
class PartitionInfo < FFI::Struct
layout :allow_alloc_nodes, :string,
:allow_accounts, :string,
:allow_groups, :string,
:allow_qos, :string,
:alternate, :string,
:cr_type, :ushort,
:def_mem_per_cpu, :uint,
:default_time, :uint,
:deny_accounts, :string,
:deny_qos, :string,
:flags, :ushort,
:grace_time, :uint,
:max_cpus_per_node, :uint,
:max_mem_per_cpu, :uint,
:max_nodes, :uint,
:max_share, :ushort,
:max_time, :uint,
:min_nodes, :uint,
:name, :string,
:node_inx, :pointer,
:nodes, :string,
:preempt_mode, :ushort,
:priority, :ushort,
:state_up, :ushort,
:total_cpus, :uint,
:total_nodes, :uint
end
# (Not documented)
#
# = Fields:
# :name ::
# (String) name of partition to be delete
class DeletePartitionMsg < FFI::Struct
layout :name, :string
end
# (Not documented)
#
# = Fields:
# :job_id ::
# (Integer) assigned job id
# :alias_list ::
# (String) node name/address/hostnamne aliases
# :cpus_per_node ::
# (FFI::Pointer(*Uint16T)) cpus per node
# :cpu_count_reps ::
# (FFI::Pointer(*Uint32T)) how many nodes have same cpu count
# :error_code ::
# (Integer) error code for warning message
# :node_cnt ::
# (Integer) count of nodes
# :node_list ::
# (String) assigned list of nodes
# :num_cpu_groups ::
# (Integer) elements in below cpu arrays
# :partition ::
# (String) name of partition used to run job
# :pn_min_memory ::
# (Integer) minimum real memory per node OR
# real memory per CPU | MEM_PER_CPU,
# default=0 (no limit)
# :select_jobinfo ::
# (DynamicPluginData) opaque data structure,
# use
# slurm_get_select_jobinfo()
# to access contents
class ResourceAllocationResponseMsg < FFI::Struct
layout :job_id, :uint,
:alias_list, :string,
:cpus_per_node, :pointer,
:cpu_count_reps, :pointer,
:error_code, :uint,
:node_cnt, :uint,
:node_list, :string,
:num_cpu_groups, :uint,
:partition, :string,
:pn_min_memory, :uint,
:select_jobinfo, DynamicPluginData
end
# (Not documented)
#
# = Fields:
# :job_id ::
# (Integer) assigned job id
# :node_list ::
# (String) assigned list of nodes
# :num_cpu_groups ::
# (Integer) elements in below cpu arrays
# :cpus_per_node ::
# (FFI::Pointer(*Uint16T)) cpus per node
# :cpu_count_reps ::
# (FFI::Pointer(*Uint32T)) how many nodes have same cpu count
# :node_cnt ::
# (Integer) count of nodes
# :node_addr ::
# (FFI::Pointer(*SlurmAddrT)) network addresses
# :error_code ::
# (Integer) error code for warning message
# :select_jobinfo ::
# (DynamicPluginData) opaque data structure,
# use
# slurm_get_select_jobinfo()
# to access contents
class JobAllocInfoResponseMsg < FFI::Struct
layout :job_id, :uint,
:node_list, :string,
:num_cpu_groups, :uint,
:cpus_per_node, :pointer,
:cpu_count_reps, :pointer,
:node_cnt, :uint,
:node_addr, :pointer,
:error_code, :uint,
:select_jobinfo, DynamicPluginData
end
# (Not documented)
#
# = Fields:
# :last_update ::
# (Integer) time of latest info
# :record_count ::
# (Integer) number of records
# :partition_array ::
# (PartitionInfo) the partition records
class PartitionInfoMsg < FFI::Struct
layout :last_update, :long,
:record_count, :uint,
:partition_array, PartitionInfo
end
# BLUEGENE specific information
#
# = Fields:
# :cnodes ::
# (String) used for sub-block jobs
# :cnode_inx ::
# (FFI::Pointer(*Int32T)) list index pairs for cnodes in the
# node listed for *cnodes:
# start_range_1, end_range_1,
# start_range_2, .., -1 used for
# sub-block jobs
# :job_id ::
# (Integer) job id
# :job_ptr ::
# (FFI::Pointer(*Void)) internal use only, not packed.
# :user_id ::
# (Integer) user running the job's ID
# :user_name ::
# (String) user running the job's name
class BlockJobInfoT < FFI::Struct
layout :cnodes, :string,
:cnode_inx, :pointer,
:job_id, :uint,
:job_ptr, :pointer,
:user_id, :uint,
:user_name, :string
end
# (Not documented)
#
# = Fields:
# :bg_block_id ::
# (String)
# :blrtsimage ::
# (String) BlrtsImage for this block
# :conn_type ::
# (Array<Integer>)
# :cnode_cnt ::
# (Integer)
# :cnode_err_cnt ::
# (Integer)
# :ionode_inx ::
# (FFI::Pointer(*Int32T)) list index pairs for ionodes in the
# node listed for *ionode_str:
# start_range_1, end_range_1,
# start_range_2, .., -1
# :ionode_str ::
# (String)
# :job_list ::
# (List) List of running jobs on each block
# :linuximage ::
# (String) LinuxImage for this block
# :mloaderimage ::
# (String) mloaderImage for this block
# :mp_inx ::
# (FFI::Pointer(*Int32T)) list index pairs into node_table for *mp_str:
# start_range_1, end_range_1,
# start_range_2, .., -1
# :mp_str ::
# (String)
# :node_use ::
# (Integer)
# :ramdiskimage ::
# (String) RamDiskImage for this block
# :reason ::
# (String)
# :state ::
# (Integer)
class BlockInfoT < FFI::Struct
layout :bg_block_id, :string,
:blrtsimage, :string,
:conn_type, [:ushort, 5],
:cnode_cnt, :uint,
:cnode_err_cnt, :uint,
:ionode_inx, :pointer,
:ionode_str, :string,
:job_list, List,
:linuximage, :string,
:mloaderimage, :string,
:mp_inx, :pointer,
:mp_str, :string,
:node_use, :ushort,
:ramdiskimage, :string,
:reason, :string,
:state, :ushort
end
# (Not documented)
#
# = Fields:
# :block_array ::
# (BlockInfoT)
# :last_update ::
# (Integer)
# :record_count ::
# (Integer)
class BlockInfoMsgT < FFI::Struct
layout :block_array, BlockInfoT,
:last_update, :long,
:record_count, :uint
end
# slurm_print_block_info_msg - output information about all Bluegene
# blocks based upon message as loaded using slurm_load_block
# IN out - file to write to
# IN info_ptr - block information message pointer
# IN one_liner - print as a single line if true
#
# @method slurm_print_block_info_msg(out, info_ptr, one_liner)
# @param [FFI::Pointer(*FILE)] out
# @param [BlockInfoMsgT] info_ptr
# @param [Integer] one_liner
# @return [nil]
# @scope class
attach_function :slurm_print_block_info_msg, :slurm_print_block_info_msg, [:pointer, BlockInfoMsgT, :int], :void
# slurm_print_block_info - output information about a specific Bluegene
# block based upon message as loaded using slurm_load_block
# IN out - file to write to
# IN bg_info_ptr - an individual block information record pointer
# IN one_liner - print as a single line if true
#
# @method slurm_print_block_info(out, bg_info_ptr, one_liner)
# @param [FFI::Pointer(*FILE)] out
# @param [BlockInfoT] bg_info_ptr
# @param [Integer] one_liner
# @return [nil]
# @scope class
attach_function :slurm_print_block_info, :slurm_print_block_info, [:pointer, BlockInfoT, :int], :void
# slurm_sprint_block_info - output information about a specific Bluegene
# block based upon message as loaded using slurm_load_block
# IN bg_info_ptr - an individual partition information record pointer
# IN one_liner - print as a single line if true
# RET out - char * containing formatted output (must be freed after call)
# NULL is returned on failure.
#
# @method slurm_sprint_block_info(bg_info_ptr, one_liner)
# @param [BlockInfoT] bg_info_ptr
# @param [Integer] one_liner
# @return [String]
# @scope class
attach_function :slurm_sprint_block_info, :slurm_sprint_block_info, [BlockInfoT, :int], :string
# slurm_load_block_info - issue RPC to get slurm all node select plugin
# information if changed since update_time
# IN update_time - time of current configuration data
# IN block_info_msg_pptr - place to store a node select configuration
# pointer
# IN show_flags - controls output form or filtering, see SHOW_* in slurm.h
# RET 0 or a slurm error code
# NOTE: free the response using slurm_free_block_info_msg
#
# @method slurm_load_block_info(update_time, block_info_msg_pptr, show_flags)
# @param [Integer] update_time
# @param [FFI::Pointer(**BlockInfoMsgT)] block_info_msg_pptr
# @param [Integer] show_flags
# @return [Integer]
# @scope class
attach_function :slurm_load_block_info, :slurm_load_block_info, [:long, :pointer, :ushort], :int
# slurm_free_block_info_msg - free buffer returned by
# slurm_load_block
# IN block_info_msg_ptr - pointer to block_info_msg_t
# RET 0 or a slurm error code
#
# @method slurm_free_block_info_msg(block_info_msg)
# @param [BlockInfoMsgT] block_info_msg
# @return [nil]
# @scope class
attach_function :slurm_free_block_info_msg, :slurm_free_block_info_msg, [BlockInfoMsgT], :void
# update state or remove block
#
# @method slurm_update_block(block_msg)
# @param [BlockInfoT] block_msg
# @return [Integer]
# @scope class
attach_function :slurm_update_block, :slurm_update_block, [BlockInfoT], :int
# (Not documented)
#
# @method slurm_init_update_block_msg(update_block_msg)
# @param [BlockInfoT] update_block_msg
# @return [nil]
# @scope class
attach_function :slurm_init_update_block_msg, :slurm_init_update_block_msg, [BlockInfoT], :void
# Time offset is
# relative
#
# = Fields:
# :accounts ::
# (String) names of accounts permitted to use
# :end_time ::
# (Integer) end time of reservation
# :features ::
# (String) required node features
# :flags ::
# (Integer) see RESERVE_FLAG_* above
# :licenses ::
# (String) names of licenses to be reserved
# :name ::
# (String) name of reservation
# :node_cnt ::
# (Integer) count of nodes required
# :core_cnt ::
# (Integer) count of cores required
# :node_inx ::
# (FFI::Pointer(*Int32T)) list index pairs into node_table for *nodes:
# start_range_1, end_range_1,
# start_range_2, .., -1
# :node_list ::
# (String) list of reserved nodes or ALL
# :partition ::
# (String) name of partition to be used
# :start_time ::
# (Integer) start time of reservation
# :users ::
# (String) names of users permitted to use
class ReserveInfo < FFI::Struct
layout :accounts, :string,
:end_time, :long,
:features, :string,
:flags, :uint,
:licenses, :string,
:name, :string,
:node_cnt, :uint,
:core_cnt, :uint,
:node_inx, :pointer,
:node_list, :string,
:partition, :string,
:start_time, :long,
:users, :string
end
# (Not documented)
#
# = Fields:
# :last_update ::
# (Integer) time of latest info
# :record_count ::
# (Integer) number of records
# :reservation_array ::
# (ReserveInfo) the reservation records
class ReserveInfoMsg < FFI::Struct
layout :last_update, :long,
:record_count, :uint,
:reservation_array, ReserveInfo
end
# (Not documented)
#
# = Fields:
# :accounts ::
# (String) names of accounts permitted to use
# :duration ::
# (Integer) duration of reservation in seconds
# :end_time ::
# (Integer) end time of reservation
# :features ::
# (String) required node features
# :flags ::
# (Integer) see RESERVE_FLAG_* above
# :licenses ::
# (String) names of licenses to be reserved
# :name ::
# (String) name of reservation (optional on create)
# :core_cnt ::
# (FFI::Pointer(*Uint32T)) Count of cores required
# :node_cnt ::
# (FFI::Pointer(*Uint32T)) Count of nodes required. Specify set of job
# sizes with trailing zero to optimize layout
# for those jobs just specify their total size
# to ignore optimized topology. For example,
# {512,512,1024,0} OR {2048,0}.
# :node_list ::
# (String) list of reserved nodes or ALL
# :partition ::
# (String) name of partition to be used
# :start_time ::
# (Integer) start time of reservation
# :users ::
# (String) names of users permitted to use
class ResvDescMsg < FFI::Struct
layout :accounts, :string,
:duration, :uint,
:end_time, :long,
:features, :string,
:flags, :uint,
:licenses, :string,
:name, :string,
:core_cnt, :pointer,
:node_cnt, :pointer,
:node_list, :string,
:partition, :string,
:start_time, :long,
:users, :string
end
# (Not documented)
#
# = Fields:
# :name ::
# (String) name of reservation
class ReserveResponseMsg < FFI::Struct
layout :name, :string
end
# (Not documented)
#
# = Fields:
# :name ::
# (String) name of reservation just created or
# to be delete
class ReservationNameMsg < FFI::Struct
layout :name, :string
end
# don't block salloc/srun until
# slurmctld knows the prolog has
# run on each node in the allocation
#
# = Fields:
# :last_update ::
# (Integer) last update time of the build parameters
# :accounting_storage_enforce ::
# (Integer) job requires valid association:
# user/account/partition/cluster
# :accounting_storage_backup_host ::
# (String) accounting storage
# backup host
# :accounting_storage_host ::
# (String) accounting storage host
# :accounting_storage_loc ::
# (String) accounting storage (db table)
# location
# :accounting_storage_pass ::
# (String) accounting storage
# password
# :accounting_storage_port ::
# (Integer) node accountinging storage port
# :accounting_storage_type ::
# (String) accounting storage type
# :accounting_storage_user ::
# (String) accounting storage user
# :acctng_store_job_comment ::
# (Integer) send job comment to accounting
# :acct_gather_conf ::
# (FFI::Pointer(*Void)) account gather config
# :acct_gather_energy_type ::
# (String) energy accounting type
# :acct_gather_profile_type ::
# (String) profile accounting type
# :acct_gather_infiniband_type ::
# (String) infiniband accounting type
# :acct_gather_filesystem_type ::
# (String) filesystem accounting type
# :acct_gather_node_freq ::
# (Integer) secs between node acct request
# :authinfo ::
# (String) authentication info
# :authtype ::
# (String) authentication type
# :backup_addr ::
# (String) comm path of slurmctld secondary server
# :backup_controller ::
# (String) name of slurmctld secondary server
# :batch_start_timeout ::
# (Integer) max secs for batch job to start
# :boot_time ::
# (Integer) time slurmctld last booted
# :checkpoint_type ::
# (String) checkpoint plugin type
# :chos_loc ::
# (String) Chroot OS path
# :core_spec_plugin ::
# (String) core specialization plugin name
# :cluster_name ::
# (String) general name of the entire cluster
# :complete_wait ::
# (Integer) seconds to wait for job completion before
# scheduling another job
# :control_addr ::
# (String) comm path of slurmctld primary server
# :control_machine ::
# (String) name of slurmctld primary server
# :cpu_freq_def ::
# (Integer) default cpu frequency / governor
# :crypto_type ::
# (String) cryptographic signature plugin
# :debug_flags ::
# (Integer) see DEBUG_FLAG_* above for values
# :def_mem_per_cpu ::
# (Integer) default MB memory per allocated CPU
# :disable_root_jobs ::
# (Integer) if set then user root can't run jobs
# :dynalloc_port ::
# (Integer) port for dynamic allocation connection
# :enforce_part_limits ::
# (Integer) if set, reject job exceeding
# partition size and/or time limits
# :epilog ::
# (String) pathname of job epilog
# :epilog_msg_time ::
# (Integer) usecs for slurmctld to process an
# epilog complete message
# :epilog_slurmctld ::
# (String) pathname of job epilog run by slurmctld
# :ext_sensors_type ::
# (String) external sensors plugin type
# :ext_sensors_freq ::
# (Integer) secs between ext sensors sampling
# :ext_sensors_conf ::
# (FFI::Pointer(*Void)) external sensors config file
# :fast_schedule ::
# (Integer) 1 to *not* check configurations by node
# (only check configuration file, faster)
# :first_job_id ::
# (Integer) first slurm generated job_id to assign
# :fs_dampening_factor ::
# (Integer) dampening for Fairshare factor
# :get_env_timeout ::
# (Integer) timeout for srun --get-user-env option
# :gres_plugins ::
# (String) list of generic resource plugins
# :group_info ::
# (Integer) see GROUP_* fields above
# :hash_val ::
# (Integer) Hash value of the slurm.conf file
# :health_check_interval ::
# (Integer) secs between health checks
# :health_check_node_state ::
# (Integer) Node states on which to execute
# health check program, see
# HEALTH_CHECK_NODE_* above
# :health_check_program ::
# (String) pathname of health check program
# :inactive_limit ::
# (Integer) seconds of inactivity before a
# inactive resource allocation is released
# :job_acct_gather_freq ::
# (String) poll frequency for job accounting
# gather plugins
# :job_acct_gather_type ::
# (String) job accounting gather type
# :job_acct_gather_params ::
# (String) job accounting gather parameters
# :job_ckpt_dir ::
# (String) directory saving job record checkpoint
# :job_comp_host ::
# (String) job completion logging host
# :job_comp_loc ::
# (String) job completion logging location
# :job_comp_pass ::
# (String) job completion storage password
# :job_comp_port ::
# (Integer) job completion storage port
# :job_comp_type ::
# (String) job completion storage type
# :job_comp_user ::
# (String) job completion storage user
# :job_container_plugin ::
# (String) job container plugin type
# :job_credential_private_key ::
# (String) path to private key
# :job_credential_public_certificate ::
# (String) path to public certificate
# :job_file_append ::
# (Integer) if set, append to stdout/err file
# :job_requeue ::
# (Integer) If set, jobs get requeued on node failre
# :job_submit_plugins ::
# (String) List of job_submit plugins to use
# :keep_alive_time ::
# (Integer) Keep alive time for srun I/O sockets
# :kill_on_bad_exit ::
# (Integer) If set, the job will be
# terminated immediately when one of
# the processes is aborted or crashed
# :kill_wait ::
# (Integer) seconds between SIGXCPU to SIGKILL
# on job termination
# :launch_type ::
# (String) type of step launcher to use
# :layouts ::
# (String) comma separted list of layouts plugins
# :licenses ::
# (String) licenses available on this cluster
# :licenses_used ::
# (String) licenses used on this cluster
# :log_fmt ::
# (Integer) Log file timestamp format
# :mail_prog ::
# (String) pathname of mail program
# :max_array_sz ::
# (Integer) Maximum job array size
# :max_job_cnt ::
# (Integer) maximum number of active jobs
# :max_job_id ::
# (Integer) maximum job id before using first_job_id
# :max_mem_per_cpu ::
# (Integer) maximum MB memory per allocated CPU
# :max_step_cnt ::
# (Integer) maximum number of steps per job
# :max_tasks_per_node ::
# (Integer) maximum tasks per node
# :mem_limit_enforce ::
# (Integer) Enforce mem limit at runtime y|n
# :min_job_age ::
# (Integer) COMPLETED jobs over this age (secs)
# purged from in memory records
# :mpi_default ::
# (String) Default version of MPI in use
# :mpi_params ::
# (String) MPI parameters
# :msg_timeout ::
# (Integer) message timeout
# :next_job_id ::
# (Integer) next slurm generated job_id to assign
# :node_prefix ::
# (String) prefix of nodes in partition, only set in
# bluegene clusters NULL otherwise
# :over_time_limit ::
# (Integer) job's time limit can be exceeded by this
# number of minutes before cancellation
# :plugindir ::
# (String) pathname to plugins
# :plugstack ::
# (String) pathname to plugin stack config file
# :preempt_mode ::
# (Integer) See PREEMPT_MODE_* in slurm/slurm.h
# :preempt_type ::
# (String) job preemption selection plugin
# :priority_decay_hl ::
# (Integer) priority decay half life in
# seconds
# :priority_calc_period ::
# (Integer) seconds between priority decay
# calculation
# :priority_favor_small ::
# (Integer) favor small jobs over large
# :priority_flags ::
# (Integer) set some flags for priority configuration,
# see PRIORITY_FLAGS_* above
# :priority_max_age ::
# (Integer) time when not to add any more
# priority to a job if reached
# :priority_params ::
# (String) priority plugin parameters
# :priority_reset_period ::
# (Integer) when to clear usage,
# see PRIORITY_RESET_*
# :priority_type ::
# (String) priority type plugin
# :priority_weight_age ::
# (Integer) weight for age factor
# :priority_weight_fs ::
# (Integer) weight for Fairshare factor
# :priority_weight_js ::
# (Integer) weight for Job Size factor
# :priority_weight_part ::
# (Integer) weight for Partition factor
# :priority_weight_qos ::
# (Integer) weight for QOS factor
# :private_data ::
# (Integer) block viewing of information,
# see PRIVATE_DATA_*
# :proctrack_type ::
# (String) process tracking plugin type
# :prolog ::
# (String) pathname of job prolog run by slurmd
# :prolog_slurmctld ::
# (String) pathname of job prolog run by slurmctld
# :propagate_prio_process ::
# (Integer) process priority propagation,
# see PROP_PRIO_*
# :prolog_flags ::
# (Integer) set some flags for prolog configuration
# see PROLOG_FLAG_*
# :propagate_rlimits ::
# (String) Propagate (all/specific) resource limits
# :propagate_rlimits_except ::
# (String) Propagate all rlimits except these
# :reboot_program ::
# (String) program to reboot the node
# :reconfig_flags ::
# (Integer) see RECONFIG_*
# :requeue_exit ::
# (String) requeue exit values
# :requeue_exit_hold ::
# (String) requeue exit hold values
# :resume_program ::
# (String) program to make nodes full power
# :resume_rate ::
# (Integer) nodes to make full power, per minute
# :resume_timeout ::
# (Integer) time required in order to perform a node
# resume operation
# :resv_epilog ::
# (String) path of reservation epilog run by slurmctld
# :resv_over_run ::
# (Integer) how long a running job can exceed
# reservation time
# :resv_prolog ::
# (String) path of reservation prolog run by slurmctld
# :ret2service ::
# (Integer) 1 return DOWN node to service at
# registration
# :route_plugin ::
# (String) route plugin
# :salloc_default_command ::
# (String) default salloc command
# :sched_logfile ::
# (String) where slurm Scheduler log gets written
# :sched_log_level ::
# (Integer) configured level of slurm Scheduler log
# :sched_params ::
# (String) SchedulerParameters OR
# contents of scheduler plugin config file
# :sched_time_slice ::
# (Integer) gang scheduler slice time, secs
# :schedtype ::
# (String) type of scheduler to use
# :schedport ::
# (Integer) port for scheduler connection
# :schedrootfltr ::
# (Integer) 1 if rootOnly partitions should be
# filtered from scheduling (if needed)
# :select_type ::
# (String) type of node selector to use
# :select_conf_key_pairs ::
# (FFI::Pointer(*Void)) key-pair list which can be
# listed with slurm_print_key_pairs()
# :select_type_param ::
# (Integer) Parameters
# describing the select_type plugin
# :slurm_conf ::
# (String) pathname of slurm config file
# :slurm_user_id ::
# (Integer) uid of slurm_user_name
# :slurm_user_name ::
# (String) user that slurmctld runs as
# :slurmd_user_id ::
# (Integer) uid of slurmd_user_name
# :slurmd_user_name ::
# (String) user that slurmd runs as
# :slurmctld_debug ::
# (Integer) slurmctld logging level
# :slurmctld_logfile ::
# (String) where slurmctld error log gets written
# :slurmctld_pidfile ::
# (String) where to put slurmctld pidfile
# :slurmctld_plugstack ::
# (String) generic slurmctld plugins
# :slurmctld_port ::
# (Integer) default communications port to slurmctld
# :slurmctld_port_count ::
# (Integer) number of slurmctld comm ports
# :slurmctld_timeout ::
# (Integer) seconds that backup controller waits
# on non-responding primarly controller
# :slurmd_debug ::
# (Integer) slurmd logging level
# :slurmd_logfile ::
# (String) where slurmd error log gets written
# :slurmd_pidfile ::
# (String) where to put slurmd pidfile
# :slurmd_plugstack ::
# (String) generic slurmd plugins
# :slurmd_port ::
# (Integer) default communications port to slurmd
# :slurmd_spooldir ::
# (String) where slurmd put temporary state info
# :slurmd_timeout ::
# (Integer) how long slurmctld waits for slurmd before
# considering node DOWN
# :srun_epilog ::
# (String) srun epilog program
# :srun_port_range ::
# (FFI::Pointer(*Uint16T)) port range for srun
# :srun_prolog ::
# (String) srun prolog program
# :state_save_location ::
# (String) pathname of slurmctld state save
# directory
# :suspend_exc_nodes ::
# (String) nodes to not make power saving
# :suspend_exc_parts ::
# (String) partitions to not make power saving
# :suspend_program ::
# (String) program to make nodes power saving
# :suspend_rate ::
# (Integer) nodes to make power saving, per minute
# :suspend_time ::
# (Integer) node idle for this long before power save mode
# :suspend_timeout ::
# (Integer) time required in order to perform a node
# suspend operation
# :switch_type ::
# (String) switch or interconnect type
# :task_epilog ::
# (String) pathname of task launch epilog
# :task_plugin ::
# (String) task launch plugin
# :task_plugin_param ::
# (Integer) see CPU_BIND_*
# :task_prolog ::
# (String) pathname of task launch prolog
# :tmp_fs ::
# (String) pathname of temporary file system
# :topology_plugin ::
# (String) network topology plugin
# :track_wckey ::
# (Integer) see if we are using wckey or not
# :tree_width ::
# (Integer) number of threads per node to span
# :unkillable_program ::
# (String) program run by the slurmstepd when
# processes in a job step are unkillable
# :unkillable_timeout ::
# (Integer) time in seconds, after processes in a
# job step have been signalled, before
# they are considered "unkillable".
# :use_pam ::
# (Integer) enable/disable PAM support
# :use_spec_resources ::
# (Integer) enable/disable job control over
# specialized resources
# :version ::
# (String) version of slurmctld
# :vsize_factor ::
# (Integer) virtual memory limit size factor
# :wait_time ::
# (Integer) default job --wait time
# :z_16 ::
# (Integer) reserved for future use
# :z_32 ::
# (Integer) reserved for future use
# :z_char ::
# (String) reserved for future use
module SlurmCtlConfWrappers
# @return [FFI::Pointer(*Void)]
def _2_key_pairs()
Slurm.slurm_ctl_conf_2_key_pairs(self)
end
end
class SlurmCtlConf < FFI::Struct
include SlurmCtlConfWrappers
layout :last_update, :long,
:accounting_storage_enforce, :ushort,
:accounting_storage_backup_host, :string,
:accounting_storage_host, :string,
:accounting_storage_loc, :string,
:accounting_storage_pass, :string,
:accounting_storage_port, :uint,
:accounting_storage_type, :string,
:accounting_storage_user, :string,
:acctng_store_job_comment, :ushort,
:acct_gather_conf, :pointer,
:acct_gather_energy_type, :string,
:acct_gather_profile_type, :string,
:acct_gather_infiniband_type, :string,
:acct_gather_filesystem_type, :string,
:acct_gather_node_freq, :ushort,
:authinfo, :string,
:authtype, :string,
:backup_addr, :string,
:backup_controller, :string,
:batch_start_timeout, :ushort,
:boot_time, :long,
:checkpoint_type, :string,
:chos_loc, :string,
:core_spec_plugin, :string,
:cluster_name, :string,
:complete_wait, :ushort,
:control_addr, :string,
:control_machine, :string,
:cpu_freq_def, :uint,
:crypto_type, :string,
:debug_flags, :ulong,
:def_mem_per_cpu, :uint,
:disable_root_jobs, :ushort,
:dynalloc_port, :ushort,
:enforce_part_limits, :ushort,
:epilog, :string,
:epilog_msg_time, :uint,
:epilog_slurmctld, :string,
:ext_sensors_type, :string,
:ext_sensors_freq, :ushort,
:ext_sensors_conf, :pointer,
:fast_schedule, :ushort,
:first_job_id, :uint,
:fs_dampening_factor, :ushort,
:get_env_timeout, :ushort,
:gres_plugins, :string,
:group_info, :ushort,
:hash_val, :uint,
:health_check_interval, :ushort,
:health_check_node_state, :ushort,
:health_check_program, :string,
:inactive_limit, :ushort,
:job_acct_gather_freq, :string,
:job_acct_gather_type, :string,
:job_acct_gather_params, :string,
:job_ckpt_dir, :string,
:job_comp_host, :string,
:job_comp_loc, :string,
:job_comp_pass, :string,
:job_comp_port, :uint,
:job_comp_type, :string,
:job_comp_user, :string,
:job_container_plugin, :string,
:job_credential_private_key, :string,
:job_credential_public_certificate, :string,
:job_file_append, :ushort,
:job_requeue, :ushort,
:job_submit_plugins, :string,
:keep_alive_time, :ushort,
:kill_on_bad_exit, :ushort,
:kill_wait, :ushort,
:launch_type, :string,
:layouts, :string,
:licenses, :string,
:licenses_used, :string,
:log_fmt, :ushort,
:mail_prog, :string,
:max_array_sz, :uint,
:max_job_cnt, :uint,
:max_job_id, :uint,
:max_mem_per_cpu, :uint,
:max_step_cnt, :uint,
:max_tasks_per_node, :ushort,
:mem_limit_enforce, :ushort,
:min_job_age, :ushort,
:mpi_default, :string,
:mpi_params, :string,
:msg_timeout, :ushort,
:next_job_id, :uint,
:node_prefix, :string,
:over_time_limit, :ushort,
:plugindir, :string,
:plugstack, :string,
:preempt_mode, :ushort,
:preempt_type, :string,
:priority_decay_hl, :uint,
:priority_calc_period, :uint,
:priority_favor_small, :ushort,
:priority_flags, :ushort,
:priority_max_age, :uint,
:priority_params, :string,
:priority_reset_period, :ushort,
:priority_type, :string,
:priority_weight_age, :uint,
:priority_weight_fs, :uint,
:priority_weight_js, :uint,
:priority_weight_part, :uint,
:priority_weight_qos, :uint,
:private_data, :ushort,
:proctrack_type, :string,
:prolog, :string,
:prolog_slurmctld, :string,
:propagate_prio_process, :ushort,
:prolog_flags, :ushort,
:propagate_rlimits, :string,
:propagate_rlimits_except, :string,
:reboot_program, :string,
:reconfig_flags, :ushort,
:requeue_exit, :string,
:requeue_exit_hold, :string,
:resume_program, :string,
:resume_rate, :ushort,
:resume_timeout, :ushort,
:resv_epilog, :string,
:resv_over_run, :ushort,
:resv_prolog, :string,
:ret2service, :ushort,
:route_plugin, :string,
:salloc_default_command, :string,
:sched_logfile, :string,
:sched_log_level, :ushort,
:sched_params, :string,
:sched_time_slice, :ushort,
:schedtype, :string,
:schedport, :ushort,
:schedrootfltr, :ushort,
:select_type, :string,
:select_conf_key_pairs, :pointer,
:select_type_param, :ushort,
:slurm_conf, :string,
:slurm_user_id, :uint,
:slurm_user_name, :string,
:slurmd_user_id, :uint,
:slurmd_user_name, :string,
:slurmctld_debug, :ushort,
:slurmctld_logfile, :string,
:slurmctld_pidfile, :string,
:slurmctld_plugstack, :string,
:slurmctld_port, :uint,
:slurmctld_port_count, :ushort,
:slurmctld_timeout, :ushort,
:slurmd_debug, :ushort,
:slurmd_logfile, :string,
:slurmd_pidfile, :string,
:slurmd_plugstack, :string,
:slurmd_port, :uint,
:slurmd_spooldir, :string,
:slurmd_timeout, :ushort,
:srun_epilog, :string,
:srun_port_range, :pointer,
:srun_prolog, :string,
:state_save_location, :string,
:suspend_exc_nodes, :string,
:suspend_exc_parts, :string,
:suspend_program, :string,
:suspend_rate, :ushort,
:suspend_time, :uint,
:suspend_timeout, :ushort,
:switch_type, :string,
:task_epilog, :string,
:task_plugin, :string,
:task_plugin_param, :ushort,
:task_prolog, :string,
:tmp_fs, :string,
:topology_plugin, :string,
:track_wckey, :ushort,
:tree_width, :ushort,
:unkillable_program, :string,
:unkillable_timeout, :ushort,
:use_pam, :ushort,
:use_spec_resources, :ushort,
:version, :string,
:vsize_factor, :ushort,
:wait_time, :ushort,
:z_16, :ushort,
:z_32, :uint,
:z_char, :string
end
# (Not documented)
#
# = Fields:
# :booted ::
# (Integer) when daemon was started
# :last_slurmctld_msg ::
# (Integer) time of last slurmctld message
# :slurmd_debug ::
# (Integer) logging level
# :actual_cpus ::
# (Integer) actual logical processor count
# :actual_boards ::
# (Integer) actual total boards count
# :actual_sockets ::
# (Integer) actual total sockets count
# :actual_cores ::
# (Integer) actual core per socket count
# :actual_threads ::
# (Integer) actual thread per core count
# :actual_real_mem ::
# (Integer) actual real memory in MB
# :actual_tmp_disk ::
# (Integer) actual temp disk space in MB
# :pid ::
# (Integer) process ID
# :hostname ::
# (String) local hostname
# :slurmd_logfile ::
# (String) slurmd log file location
# :step_list ::
# (String) list of active job steps
# :version ::
# (String) version running
class SlurmdStatusMsg < FFI::Struct
layout :booted, :long,
:last_slurmctld_msg, :long,
:slurmd_debug, :ushort,
:actual_cpus, :ushort,
:actual_boards, :ushort,
:actual_sockets, :ushort,
:actual_cores, :ushort,
:actual_threads, :ushort,
:actual_real_mem, :uint,
:actual_tmp_disk, :uint,
:pid, :uint,
:hostname, :string,
:slurmd_logfile, :string,
:step_list, :string,
:version, :string
end
# (Not documented)
#
# = Fields:
# :job_id ::
# (Integer) job ID
# :step_id ::
# (Integer) step ID
# :error_code ::
# (Integer) error code for warning message
class SubmitResponseMsg < FFI::Struct
layout :job_id, :uint,
:step_id, :uint,
:error_code, :uint
end
# NOTE: If setting node_addr and/or node_hostname then comma separate names
# and include an equal number of node_names
#
# = Fields:
# :features ::
# (String) new feature for node
# :gres ::
# (String) new generic resources for node
# :node_addr ::
# (String) communication name (optional)
# :node_hostname ::
# (String) node's hostname (optional)
# :node_names ::
# (String) nodelist expression
# :node_state ::
# (Integer) see enum node_states
# :reason ::
# (String) reason for node being DOWN or DRAINING
# :reason_uid ::
# (Integer) user ID of sending (needed if user
# root is sending message)
# :weight ::
# (Integer) new weight for node
class SlurmUpdateNodeMsg < FFI::Struct
layout :features, :string,
:gres, :string,
:node_addr, :string,
:node_hostname, :string,
:node_names, :string,
:node_state, :uint,
:reason, :string,
:reason_uid, :uint,
:weight, :uint
end
# (Not documented)
#
# = Fields:
# :name ::
# (String) comma separated list of front end nodes
# :node_state ::
# (Integer) see enum node_states
# :reason ::
# (String) reason for node being DOWN or DRAINING
# :reason_uid ::
# (Integer) user ID of sending (needed if user
# root is sending message)
class SlurmUpdateFrontEndMsg < FFI::Struct
layout :name, :string,
:node_state, :uint,
:reason, :string,
:reason_uid, :uint
end
# (Not documented)
#
# = Fields:
# :job_id ::
# (Integer) assigned job id
# :node_addr ::
# (FFI::Pointer(*SlurmAddrT)) network addresses
# :node_cnt ::
# (Integer) count of nodes
# :node_list ::
# (String) assigned list of nodes
# :sbcast_cred ::
# (SbcastCred) opaque data structure
class JobSbcastCredMsg < FFI::Struct
layout :job_id, :uint,
:node_addr, :pointer,
:node_cnt, :uint,
:node_list, :string,
:sbcast_cred, SbcastCred
end
# Opaque data type for slurm_step_ctx_* functions
class SlurmStepCtxStruct < FFI::Struct
layout :dummy, :char
end
# (Not documented)
#
# = Fields:
# :command_id ::
# (Integer)
class StatsInfoRequestMsg < FFI::Struct
layout :command_id, :ushort
end
# (Not documented)
#
# = Fields:
# :parts_packed ::
# (Integer)
# :req_time ::
# (Integer)
# :req_time_start ::
# (Integer)
# :server_thread_count ::
# (Integer)
# :agent_queue_size ::
# (Integer)
# :schedule_cycle_max ::
# (Integer)
# :schedule_cycle_last ::
# (Integer)
# :schedule_cycle_sum ::
# (Integer)
# :schedule_cycle_counter ::
# (Integer)
# :schedule_cycle_depth ::
# (Integer)
# :schedule_queue_len ::
# (Integer)
# :jobs_submitted ::
# (Integer)
# :jobs_started ::
# (Integer)
# :jobs_completed ::
# (Integer)
# :jobs_canceled ::
# (Integer)
# :jobs_failed ::
# (Integer)
# :bf_backfilled_jobs ::
# (Integer)
# :bf_last_backfilled_jobs ::
# (Integer)
# :bf_cycle_counter ::
# (Integer)
# :bf_cycle_sum ::
# (Integer)
# :bf_cycle_last ::
# (Integer)
# :bf_cycle_max ::
# (Integer)
# :bf_last_depth ::
# (Integer)
# :bf_last_depth_try ::
# (Integer)
# :bf_depth_sum ::
# (Integer)
# :bf_depth_try_sum ::
# (Integer)
# :bf_queue_len ::
# (Integer)
# :bf_queue_len_sum ::
# (Integer)
# :bf_when_last_cycle ::
# (Integer)
# :bf_active ::
# (Integer)
# :rpc_type_size ::
# (Integer)
# :rpc_type_id ::
# (FFI::Pointer(*Uint16T))
# :rpc_type_cnt ::
# (FFI::Pointer(*Uint32T))
# :rpc_type_time ::
# (FFI::Pointer(*Uint64T))
# :rpc_user_size ::
# (Integer)
# :rpc_user_id ::
# (FFI::Pointer(*Uint32T))
# :rpc_user_cnt ::
# (FFI::Pointer(*Uint32T))
# :rpc_user_time ::
# (FFI::Pointer(*Uint64T))
class StatsInfoResponseMsg < FFI::Struct
layout :parts_packed, :uint,
:req_time, :long,
:req_time_start, :long,
:server_thread_count, :uint,
:agent_queue_size, :uint,
:schedule_cycle_max, :uint,
:schedule_cycle_last, :uint,
:schedule_cycle_sum, :uint,
:schedule_cycle_counter, :uint,
:schedule_cycle_depth, :uint,
:schedule_queue_len, :uint,
:jobs_submitted, :uint,
:jobs_started, :uint,
:jobs_completed, :uint,
:jobs_canceled, :uint,
:jobs_failed, :uint,
:bf_backfilled_jobs, :uint,
:bf_last_backfilled_jobs, :uint,
:bf_cycle_counter, :uint,
:bf_cycle_sum, :uint,
:bf_cycle_last, :uint,
:bf_cycle_max, :uint,
:bf_last_depth, :uint,
:bf_last_depth_try, :uint,
:bf_depth_sum, :uint,
:bf_depth_try_sum, :uint,
:bf_queue_len, :uint,
:bf_queue_len_sum, :uint,
:bf_when_last_cycle, :long,
:bf_active, :uint,
:rpc_type_size, :uint,
:rpc_type_id, :pointer,
:rpc_type_cnt, :pointer,
:rpc_type_time, :pointer,
:rpc_user_size, :uint,
:rpc_user_id, :pointer,
:rpc_user_cnt, :pointer,
:rpc_user_time, :pointer
end
# (Not documented)
#
# = Fields:
# :flags ::
# (Integer) TRIGGER_FLAG_*
# :trig_id ::
# (Integer) trigger ID
# :res_type ::
# (Integer) TRIGGER_RES_TYPE_*
# :res_id ::
# (String) resource ID
# :trig_type ::
# (Integer) TRIGGER_TYPE_*
# :offset ::
# (Integer) seconds from trigger, 0x8000 origin
# :user_id ::
# (Integer) user requesting trigger
# :program ::
# (String) program to execute
class TriggerInfo < FFI::Struct
layout :flags, :ushort,
:trig_id, :uint,
:res_type, :ushort,
:res_id, :string,
:trig_type, :uint,
:offset, :ushort,
:user_id, :uint,
:program, :string
end
# (Not documented)
#
# = Fields:
# :record_count ::
# (Integer) number of records
# :trigger_array ::
# (TriggerInfo) the trigger records
class TriggerInfoMsg < FFI::Struct
layout :record_count, :uint,
:trigger_array, TriggerInfo
end
# Individual license information
#
# = Fields:
# :name ::
# (String) license name
# :total ::
# (Integer) total number of available licenses
# :in_use ::
# (Integer) number of license in use
# :available ::
# (Integer) number of available license
# :remote ::
# (Integer) non-zero if remote license (not
# defined in slurm.conf)
class SlurmLicenseInfo < FFI::Struct
layout :name, :string,
:total, :uint,
:in_use, :uint,
:available, :uint,
:remote, :uchar
end
# License information array as returned by the controller.
#
# = Fields:
# :last_update ::
# (Integer)
# :num_lic ::
# (Integer)
# :lic_array ::
# (SlurmLicenseInfo)
class LicenseInfoMsg < FFI::Struct
layout :last_update, :long,
:num_lic, :uint,
:lic_array, SlurmLicenseInfo
end
# (Not documented)
#
# = Fields:
# :job_array_count ::
# (Integer)
# :job_array_id ::
# (FFI::Pointer(**CharS)) Note: The string may be truncated
# :error_code ::
# (FFI::Pointer(*Uint32T))
class JobArrayRespMsgT < FFI::Struct
layout :job_array_count, :uint,
:job_array_id, :pointer,
:error_code, :pointer
end
# slurm_init_job_desc_msg - initialize job descriptor with
# default values
# OUT job_desc_msg - user defined job descriptor
#
# @method slurm_init_job_desc_msg(job_desc_msg)
# @param [JobDescriptor] job_desc_msg
# @return [nil]
# @scope class
attach_function :slurm_init_job_desc_msg, :slurm_init_job_desc_msg, [JobDescriptor], :void
# slurm_allocate_resources - allocate resources for a job request
# If the requested resources are not immediately available, the slurmctld
# will send the job_alloc_resp_msg to the sepecified node and port.
# IN job_desc_msg - description of resource allocation request
# OUT job_alloc_resp_msg - response to request. This only represents
# a job allocation if resources are immediately. Otherwise it just contains
# the job id of the enqueued job request.
# RET 0 on success, otherwise return -1 and set errno to indicate the error
# NOTE: free the response using slurm_free_resource_allocation_response_msg()
#
# @method slurm_allocate_resources(job_desc_msg, job_alloc_resp_msg)
# @param [JobDescriptor] job_desc_msg
# @param [FFI::Pointer(**ResourceAllocationResponseMsgT)] job_alloc_resp_msg
# @return [Integer]
# @scope class
attach_function :slurm_allocate_resources, :slurm_allocate_resources, [JobDescriptor, :pointer], :int
# slurm_allocate_resources_blocking
# allocate resources for a job request. This call will block until
# the allocation is granted, or the specified timeout limit is reached.
# IN req - description of resource allocation request
# IN timeout - amount of time, in seconds, to wait for a response before
# giving up.
# A timeout of zero will wait indefinitely.
# IN pending_callback - If the allocation cannot be granted immediately,
# the controller will put the job in the PENDING state. If
# pending callback is not NULL, it will be called with the job_id
# of the pending job as the sole parameter.
#
# RET allocation structure on success, NULL on error set errno to
# indicate the error (errno will be ETIMEDOUT if the timeout is reached
# with no allocation granted)
# NOTE: free the response using slurm_free_resource_allocation_response_msg()
#
# @method slurm_allocate_resources_blocking(user_req, timeout, pending_callback)
# @param [JobDescriptor] user_req
# @param [Integer] timeout
# @param [FFI::Pointer(*)] pending_callback
# @return [ResourceAllocationResponseMsg]
# @scope class
attach_function :slurm_allocate_resources_blocking, :slurm_allocate_resources_blocking, [JobDescriptor, :long, :pointer], ResourceAllocationResponseMsg
# slurm_free_resource_allocation_response_msg - free slurm resource
# allocation response message
# IN msg - pointer to allocation response message
# NOTE: buffer is loaded by slurm_allocate_resources
#
# @method slurm_free_resource_allocation_response_msg(msg)
# @param [ResourceAllocationResponseMsg] msg
# @return [nil]
# @scope class
attach_function :slurm_free_resource_allocation_response_msg, :slurm_free_resource_allocation_response_msg, [ResourceAllocationResponseMsg], :void
# slurm_free_job_alloc_info_response_msg - free slurm resource
# allocation lookup message
# IN msg - pointer to job allocation info response message
# NOTE: buffer is loaded by slurm_allocation_lookup
#
# @method slurm_free_job_alloc_info_response_msg(msg)
# @param [JobAllocInfoResponseMsg] msg
# @return [nil]
# @scope class
attach_function :slurm_free_job_alloc_info_response_msg, :slurm_free_job_alloc_info_response_msg, [JobAllocInfoResponseMsg], :void
# slurm_allocation_lookup - retrieve info for an existing resource allocation
# IN job_id - job allocation identifier
# OUT resp - job allocation information
# RET 0 on success, otherwise return -1 and set errno to indicate the error
# NOTE: free "info" using slurm_free_job_alloc_info_response_msg
#
# @method slurm_allocation_lookup(job_id, info)
# @param [Integer] job_id
# @param [FFI::Pointer(**JobAllocInfoResponseMsgT)] info
# @return [Integer]
# @scope class
attach_function :slurm_allocation_lookup, :slurm_allocation_lookup, [:uint, :pointer], :int
# slurm_allocation_lookup_lite - retrieve minor info for an existing
# resource allocation
# IN job_id - job allocation identifier
# OUT resp - job allocation information
# RET 0 on success, otherwise return -1 and set errno to indicate the error
# NOTE: free the response using slurm_free_resource_allocation_response_msg()
#
# @method slurm_allocation_lookup_lite(job_id, info)
# @param [Integer] job_id
# @param [FFI::Pointer(**ResourceAllocationResponseMsgT)] info
# @return [Integer]
# @scope class
attach_function :slurm_allocation_lookup_lite, :slurm_allocation_lookup_lite, [:uint, :pointer], :int
# slurm_read_hostfile - Read a SLURM hostfile specified by "filename".
# "filename" must contain a list of SLURM NodeNames, one per line.
# Reads up to "n" number of hostnames from the file. Returns a
# string representing a hostlist ranged string of the contents of
# the file. This is a helper function, it does not contact any
# SLURM daemons.
#
# IN filename - name of SLURM Hostlist file to be read.
# IN n - number of NodeNames required
# RET - a string representing the hostlist. Returns NULL if there are
# fewer than "n" hostnames in the file, or if an error occurs.
#
# NOTE: Returned string must be freed with free().
#
# @method slurm_read_hostfile(filename, n)
# @param [String] filename
# @param [Integer] n
# @return [String]
# @scope class
attach_function :slurm_read_hostfile, :slurm_read_hostfile, [:string, :int], :string
# slurm_allocation_msg_thr_create - startup a message handler talking
# with the controller dealing with messages from the controller during an
# allocation.
# IN port - port we are listening for messages on from the controller
# IN callbacks - callbacks for different types of messages
# RET allocation_msg_thread_t * or NULL on failure
#
# @method slurm_allocation_msg_thr_create(port, callbacks)
# @param [FFI::Pointer(*Uint16T)] port
# @param [SlurmAllocationCallbacksT] callbacks
# @return [AllocationMsgThread]
# @scope class
attach_function :slurm_allocation_msg_thr_create, :slurm_allocation_msg_thr_create, [:pointer, SlurmAllocationCallbacksT], AllocationMsgThread
# slurm_allocation_msg_thr_destroy - shutdown the message handler talking
# with the controller dealing with messages from the controller during an
# allocation.
# IN msg_thr - allocation_msg_thread_t pointer allocated with
# slurm_allocation_msg_thr_create
#
# @method slurm_allocation_msg_thr_destroy(msg_thr)
# @param [AllocationMsgThread] msg_thr
# @return [nil]
# @scope class
attach_function :slurm_allocation_msg_thr_destroy, :slurm_allocation_msg_thr_destroy, [AllocationMsgThread], :void
# slurm_submit_batch_job - issue RPC to submit a job for later execution
# NOTE: free the response using slurm_free_submit_response_response_msg
# IN job_desc_msg - description of batch job request
# OUT slurm_alloc_msg - response to request
# RET 0 on success, otherwise return -1 and set errno to indicate the error
#
# @method slurm_submit_batch_job(job_desc_msg, slurm_alloc_msg)
# @param [JobDescriptor] job_desc_msg
# @param [FFI::Pointer(**SubmitResponseMsgT)] slurm_alloc_msg
# @return [Integer]
# @scope class
attach_function :slurm_submit_batch_job, :slurm_submit_batch_job, [JobDescriptor, :pointer], :int
# slurm_free_submit_response_response_msg - free slurm
# job submit response message
# IN msg - pointer to job submit response message
# NOTE: buffer is loaded by slurm_submit_batch_job
#
# @method slurm_free_submit_response_response_msg(msg)
# @param [SubmitResponseMsg] msg
# @return [nil]
# @scope class
attach_function :slurm_free_submit_response_response_msg, :slurm_free_submit_response_response_msg, [SubmitResponseMsg], :void
# slurm_job_will_run - determine if a job would execute immediately if
# submitted now
# IN job_desc_msg - description of resource allocation request
# RET 0 on success, otherwise return -1 and set errno to indicate the error
#
# @method slurm_job_will_run(job_desc_msg)
# @param [JobDescriptor] job_desc_msg
# @return [Integer]
# @scope class
attach_function :slurm_job_will_run, :slurm_job_will_run, [JobDescriptor], :int
# slurm_sbcast_lookup - retrieve info for an existing resource allocation
# including a credential needed for sbcast
# IN jobid - job allocation identifier
# OUT info - job allocation information including a credential for sbcast
# RET 0 on success, otherwise return -1 and set errno to indicate the error
# NOTE: free the "resp" using slurm_free_sbcast_cred_msg
#
# @method slurm_sbcast_lookup(jobid, info)
# @param [Integer] jobid
# @param [FFI::Pointer(**JobSbcastCredMsgT)] info
# @return [Integer]
# @scope class
attach_function :slurm_sbcast_lookup, :slurm_sbcast_lookup, [:uint, :pointer], :int
# (Not documented)
#
# @method slurm_free_sbcast_cred_msg(msg)
# @param [JobSbcastCredMsg] msg
# @return [nil]
# @scope class
attach_function :slurm_free_sbcast_cred_msg, :slurm_free_sbcast_cred_msg, [JobSbcastCredMsg], :void
# slurm_load_licenses()
#
# Retrieve license information from the controller.
# IN feature - feature name or NULL
# OUT
#
# @method slurm_load_licenses(long, license_info_msg_t, u_short)
# @param [Integer] long
# @param [FFI::Pointer(**LicenseInfoMsgT)] license_info_msg_t
# @param [Integer] u_short
# @return [Integer]
# @scope class
attach_function :slurm_load_licenses, :slurm_load_licenses, [:long, :pointer, :ushort], :int
# (Not documented)
#
# @method slurm_free_license_info_msg(license_info_msg)
# @param [LicenseInfoMsg] license_info_msg
# @return [nil]
# @scope class
attach_function :slurm_free_license_info_msg, :slurm_free_license_info_msg, [LicenseInfoMsg], :void
# slurm_kill_job - send the specified signal to all steps of an existing job
# IN job_id - the job's id
# IN signal - signal number
# IN flags - see KILL_JOB_* flags above
# RET 0 on success, otherwise return -1 and set errno to indicate the error
#
# @method slurm_kill_job(job_id, signal, flags)
# @param [Integer] job_id
# @param [Integer] signal
# @param [Integer] flags
# @return [Integer]
# @scope class
attach_function :slurm_kill_job, :slurm_kill_job, [:uint, :ushort, :ushort], :int
# slurm_kill_job_step - send the specified signal to an existing job step
# IN job_id - the job's id
# IN step_id - the job step's id
# IN signal - signal number
# RET 0 on success, otherwise return -1 and set errno to indicate the error
#
# @method slurm_kill_job_step(job_id, step_id, signal)
# @param [Integer] job_id
# @param [Integer] step_id
# @param [Integer] signal
# @return [Integer]
# @scope class
attach_function :slurm_kill_job_step, :slurm_kill_job_step, [:uint, :uint, :ushort], :int
# slurm_kill_job2()
#
# @method slurm_kill_job2(string, u_short, u_short)
# @param [String] string
# @param [Integer] u_short
# @param [Integer] u_short
# @return [Integer]
# @scope class
attach_function :slurm_kill_job2, :slurm_kill_job2, [:string, :ushort, :ushort], :int
# slurm_kill_job_step2()
#
# @method slurm_kill_job_step2(string, u_short, u_short)
# @param [String] string
# @param [Integer] u_short
# @param [Integer] u_short
# @return [Integer]
# @scope class
attach_function :slurm_kill_job_step2, :slurm_kill_job_step2, [:string, :ushort, :ushort], :int
# slurm_signal_job - send the specified signal to all steps of an existing job
# IN job_id - the job's id
# IN signal - signal number
# RET 0 on success, otherwise return -1 and set errno to indicate the error
#
# @method slurm_signal_job(job_id, signal)
# @param [Integer] job_id
# @param [Integer] signal
# @return [Integer]
# @scope class
attach_function :slurm_signal_job, :slurm_signal_job, [:uint, :ushort], :int
# slurm_signal_job_step - send the specified signal to an existing job step
# IN job_id - the job's id
# IN step_id - the job step's id - use SLURM_BATCH_SCRIPT as the step_id
# to send a signal to a job's batch script
# IN signal - signal number
# RET 0 on success, otherwise return -1 and set errno to indicate the error
#
# @method slurm_signal_job_step(job_id, step_id, signal)
# @param [Integer] job_id
# @param [Integer] step_id
# @param [Integer] signal
# @return [Integer]
# @scope class
attach_function :slurm_signal_job_step, :slurm_signal_job_step, [:uint, :uint, :uint], :int
# slurm_complete_job - note the completion of a job and all of its steps
# IN job_id - the job's id
# IN job_return_code - the highest exit code of any task of the job
# RET 0 on success, otherwise return -1 and set errno to indicate the error
#
# @method slurm_complete_job(job_id, job_return_code)
# @param [Integer] job_id
# @param [Integer] job_return_code
# @return [Integer]
# @scope class
attach_function :slurm_complete_job, :slurm_complete_job, [:uint, :uint], :int
# slurm_terminate_job_step - terminates a job step by sending a
# REQUEST_TERMINATE_TASKS rpc to all slurmd of a job step, and then
# calls slurm_complete_job_step() after verifying that all
# nodes in the job step no longer have running tasks from the job
# step. (May take over 35 seconds to return.)
# IN job_id - the job's id
# IN step_id - the job step's id - use SLURM_BATCH_SCRIPT as the step_id
# to terminate a job's batch script
# RET 0 on success, otherwise return -1 and set errno to indicate the error
#
# @method slurm_terminate_job_step(job_id, step_id)
# @param [Integer] job_id
# @param [Integer] step_id
# @return [Integer]
# @scope class
attach_function :slurm_terminate_job_step, :slurm_terminate_job_step, [:uint, :uint], :int
# slurm_step_ctx_params_t_init - This initializes parameters
# in the structure that you will pass to slurm_step_ctx_create().
# This function will NOT allocate any new memory.
# IN ptr - pointer to a structure allocated by the user. The structure will
# be initialized.
#
# @method slurm_step_ctx_params_t_init(ptr)
# @param [SlurmStepCtxParamsT] ptr
# @return [nil]
# @scope class
attach_function :slurm_step_ctx_params_t_init, :slurm_step_ctx_params_t_init, [SlurmStepCtxParamsT], :void
# slurm_step_ctx_create - Create a job step and its context.
# IN step_params - job step parameters
# RET the step context or NULL on failure with slurm errno set
# NOTE: Free allocated memory using slurm_step_ctx_destroy.
#
# @method slurm_step_ctx_create(step_params)
# @param [SlurmStepCtxParamsT] step_params
# @return [SlurmStepCtxStruct]
# @scope class
attach_function :slurm_step_ctx_create, :slurm_step_ctx_create, [SlurmStepCtxParamsT], SlurmStepCtxStruct
# slurm_step_ctx_create_timeout - Create a job step and its context.
# IN step_params - job step parameters
# IN timeout - in milliseconds
# RET the step context or NULL on failure with slurm errno set
# NOTE: Free allocated memory using slurm_step_ctx_destroy.
#
# @method slurm_step_ctx_create_timeout(step_params, timeout)
# @param [SlurmStepCtxParamsT] step_params
# @param [Integer] timeout
# @return [SlurmStepCtxStruct]
# @scope class
attach_function :slurm_step_ctx_create_timeout, :slurm_step_ctx_create_timeout, [SlurmStepCtxParamsT, :int], SlurmStepCtxStruct
# slurm_step_ctx_create_no_alloc - Create a job step and its context without
# getting an allocation.
# IN step_params - job step parameters
# IN step_id - since we are faking it give me the id to use
# RET the step context or NULL on failure with slurm errno set
# NOTE: Free allocated memory using slurm_step_ctx_destroy.
#
# @method slurm_step_ctx_create_no_alloc(step_params, step_id)
# @param [SlurmStepCtxParamsT] step_params
# @param [Integer] step_id
# @return [SlurmStepCtxStruct]
# @scope class
attach_function :slurm_step_ctx_create_no_alloc, :slurm_step_ctx_create_no_alloc, [SlurmStepCtxParamsT, :uint], SlurmStepCtxStruct
# slurm_step_ctx_get - get parameters from a job step context.
# IN ctx - job step context generated by slurm_step_ctx_create
# RET SLURM_SUCCESS or SLURM_ERROR (with slurm_errno set)
#
# @method slurm_step_ctx_get(ctx, ctx_key)
# @param [SlurmStepCtxStruct] ctx
# @param [Integer] ctx_key
# @return [Integer]
# @scope class
attach_function :slurm_step_ctx_get, :slurm_step_ctx_get, [SlurmStepCtxStruct, :int], :int
# slurm_jobinfo_ctx_get - get parameters from jobinfo context.
# IN jobinfo - job information from context, returned by slurm_step_ctx_get()
# IN data_type - type of data required, specific to the switch type
# OUT data - the requested data type
# RET SLURM_SUCCESS or SLURM_ERROR (with slurm_errno set)
#
# @method slurm_jobinfo_ctx_get(jobinfo, data_type, data)
# @param [SwitchJobinfo] jobinfo
# @param [Integer] data_type
# @param [FFI::Pointer(*Void)] data
# @return [Integer]
# @scope class
attach_function :slurm_jobinfo_ctx_get, :slurm_jobinfo_ctx_get, [SwitchJobinfo, :int, :pointer], :int
# slurm_step_ctx_daemon_per_node_hack - Hack the step context
# to run a single process per node, regardless of the settings
# selected at slurm_step_ctx_create time.
#
# This is primarily used when launching 1 task per node as done
# with IBM's PE where we want to launch a single pmd daemon
# on each node regardless of the number of tasks running on each
# node.
# IN ctx - job step context generated by slurm_step_ctx_create
# IN node_list - node list of nodes to run on
# IN node_cnt - number of nodes to run on
# IN/OUT curr_task_num - task_id of newest task, initialze to zero
# RET SLURM_SUCCESS or SLURM_ERROR (with slurm_errno set)
#
# @method slurm_step_ctx_daemon_per_node_hack(ctx, node_list, node_cnt, curr_task_num)
# @param [SlurmStepCtxStruct] ctx
# @param [String] node_list
# @param [Integer] node_cnt
# @param [FFI::Pointer(*Uint32T)] curr_task_num
# @return [Integer]
# @scope class
attach_function :slurm_step_ctx_daemon_per_node_hack, :slurm_step_ctx_daemon_per_node_hack, [SlurmStepCtxStruct, :string, :uint, :pointer], :int
# slurm_step_ctx_destroy - free allocated memory for a job step context.
# IN ctx - job step context generated by slurm_step_ctx_create
# RET SLURM_SUCCESS or SLURM_ERROR (with slurm_errno set)
#
# @method slurm_step_ctx_destroy(ctx)
# @param [SlurmStepCtxStruct] ctx
# @return [Integer]
# @scope class
attach_function :slurm_step_ctx_destroy, :slurm_step_ctx_destroy, [SlurmStepCtxStruct], :int
# slurm_step_launch_params_t_init - initialize a user-allocated
# slurm_step_launch_params_t structure with default values.
# default values. This function will NOT allocate any new memory.
# IN ptr - pointer to a structure allocated by the use. The structure will
# be initialized.
#
# @method slurm_step_launch_params_t_init(ptr)
# @param [SlurmStepLaunchParamsT] ptr
# @return [nil]
# @scope class
attach_function :slurm_step_launch_params_t_init, :slurm_step_launch_params_t_init, [SlurmStepLaunchParamsT], :void
# slurm_step_launch - launch a parallel job step
# IN ctx - job step context generated by slurm_step_ctx_create
# IN params - job step parameters
# IN callbacks - Identify functions to be called when various events occur
# RET SLURM_SUCCESS or SLURM_ERROR (with errno set)
#
# @method slurm_step_launch(ctx, params, callbacks)
# @param [SlurmStepCtxStruct] ctx
# @param [SlurmStepLaunchParamsT] params
# @param [SlurmStepLaunchCallbacksT] callbacks
# @return [Integer]
# @scope class
attach_function :slurm_step_launch, :slurm_step_launch, [SlurmStepCtxStruct, SlurmStepLaunchParamsT, SlurmStepLaunchCallbacksT], :int
# slurm_step_launch_add - Add tasks to a step that was already started
# IN ctx - job step context generated by slurm_step_ctx_create
# IN params - job step parameters
# IN node_list - list of extra nodes to add
# IN start_nodeid - in the global scheme which node id is the first
# node in node_list.
# RET SLURM_SUCCESS or SLURM_ERROR (with errno set)
#
# @method slurm_step_launch_add(ctx, params, node_list, start_nodeid)
# @param [SlurmStepCtxStruct] ctx
# @param [SlurmStepLaunchParamsT] params
# @param [String] node_list
# @param [Integer] start_nodeid
# @return [Integer]
# @scope class
attach_function :slurm_step_launch_add, :slurm_step_launch_add, [SlurmStepCtxStruct, SlurmStepLaunchParamsT, :string, :int], :int
# Block until all tasks have started.
#
# @method slurm_step_launch_wait_start(ctx)
# @param [SlurmStepCtxStruct] ctx
# @return [Integer]
# @scope class
attach_function :slurm_step_launch_wait_start, :slurm_step_launch_wait_start, [SlurmStepCtxStruct], :int
# Block until all tasks have finished (or failed to start altogether).
#
# @method slurm_step_launch_wait_finish(ctx)
# @param [SlurmStepCtxStruct] ctx
# @return [nil]
# @scope class
attach_function :slurm_step_launch_wait_finish, :slurm_step_launch_wait_finish, [SlurmStepCtxStruct], :void
# Abort an in-progress launch, or terminate the fully launched job step.
#
# Can be called from a signal handler.
#
# @method slurm_step_launch_abort(ctx)
# @param [SlurmStepCtxStruct] ctx
# @return [nil]
# @scope class
attach_function :slurm_step_launch_abort, :slurm_step_launch_abort, [SlurmStepCtxStruct], :void
# Forward a signal to all those nodes with running tasks
#
# @method slurm_step_launch_fwd_signal(ctx, signo)
# @param [SlurmStepCtxStruct] ctx
# @param [Integer] signo
# @return [nil]
# @scope class
attach_function :slurm_step_launch_fwd_signal, :slurm_step_launch_fwd_signal, [SlurmStepCtxStruct, :int], :void
# Wake tasks stopped for debugging on nodes with running tasks
#
# @method slurm_step_launch_fwd_wake(ctx)
# @param [SlurmStepCtxStruct] ctx
# @return [nil]
# @scope class
attach_function :slurm_step_launch_fwd_wake, :slurm_step_launch_fwd_wake, [SlurmStepCtxStruct], :void
# Specify the plugin name to be used. This may be needed to specify the
# non-default MPI plugin when using SLURM API to launch tasks.
# IN plugin name - "none", "pmi2", etc.
# RET SLURM_SUCCESS or SLURM_ERROR (with errno set)
#
# @method slurm_mpi_plugin_init(plugin_name)
# @param [String] plugin_name
# @return [Integer]
# @scope class
attach_function :slurm_mpi_plugin_init, :slurm_mpi_plugin_init, [:string], :int
# slurm_api_version - Return a single number reflecting the SLURM API's
# version number. Use the macros SLURM_VERSION_NUM, SLURM_VERSION_MAJOR,
# SLURM_VERSION_MINOR, and SLURM_VERSION_MICRO to work with this value
# RET API's version number
#
# @method slurm_api_version()
# @return [Integer]
# @scope class
attach_function :slurm_api_version, :slurm_api_version, [], :long
# slurm_load_ctl_conf - issue RPC to get slurm control configuration
# information if changed since update_time
# IN update_time - time of current configuration data
# IN slurm_ctl_conf_ptr - place to store slurm control configuration
# pointer
# RET 0 on success, otherwise return -1 and set errno to indicate the error
# NOTE: free the response using slurm_free_ctl_conf
#
# @method slurm_load_ctl_conf(update_time, slurm_ctl_conf_ptr)
# @param [Integer] update_time
# @param [FFI::Pointer(**SlurmCtlConfT)] slurm_ctl_conf_ptr
# @return [Integer]
# @scope class
attach_function :slurm_load_ctl_conf, :slurm_load_ctl_conf, [:long, :pointer], :int
# slurm_free_ctl_conf - free slurm control information response message
# IN msg - pointer to slurm control information response message
# NOTE: buffer is loaded by slurm_load_ctl_conf
#
# @method slurm_free_ctl_conf(slurm_ctl_conf_ptr)
# @param [SlurmCtlConf] slurm_ctl_conf_ptr
# @return [nil]
# @scope class
attach_function :slurm_free_ctl_conf, :slurm_free_ctl_conf, [SlurmCtlConf], :void
# slurm_print_ctl_conf - output the contents of slurm control configuration
# message as loaded using slurm_load_ctl_conf
# IN out - file to write to
# IN slurm_ctl_conf_ptr - slurm control configuration pointer
#
# @method slurm_print_ctl_conf(out, slurm_ctl_conf_ptr)
# @param [FFI::Pointer(*FILE)] out
# @param [SlurmCtlConf] slurm_ctl_conf_ptr
# @return [nil]
# @scope class
attach_function :slurm_print_ctl_conf, :slurm_print_ctl_conf, [:pointer, SlurmCtlConf], :void
# slurm_write_ctl_conf - write the contents of slurm control configuration
# message as loaded using slurm_load_ctl_conf to a file
# IN out - file to write to
# IN slurm_ctl_conf_ptr - slurm control configuration pointer
# IN node_info_ptr - pointer to node table of information
# IN part_info_ptr - pointer to partition information
#
# @method slurm_write_ctl_conf(slurm_ctl_conf_ptr, node_info_ptr, part_info_ptr)
# @param [SlurmCtlConf] slurm_ctl_conf_ptr
# @param [NodeInfoMsg] node_info_ptr
# @param [PartitionInfoMsg] part_info_ptr
# @return [nil]
# @scope class
attach_function :slurm_write_ctl_conf, :slurm_write_ctl_conf, [SlurmCtlConf, NodeInfoMsg, PartitionInfoMsg], :void
# slurm_ctl_conf_2_key_pairs - put the slurm_ctl_conf_t variables into
# a List of opaque data type config_key_pair_t
# IN slurm_ctl_conf_ptr - slurm control configuration pointer
# RET List of opaque data type config_key_pair_t
#
# @method slurm_ctl_conf_2_key_pairs(slurm_ctl_conf_ptr)
# @param [SlurmCtlConf] slurm_ctl_conf_ptr
# @return [FFI::Pointer(*Void)]
# @scope class
attach_function :slurm_ctl_conf_2_key_pairs, :slurm_ctl_conf_2_key_pairs, [SlurmCtlConf], :pointer
# slurm_print_key_pairs - output the contents of key_pairs
# which is a list of opaque data type config_key_pair_t
# IN out - file to write to
# IN key_pairs - List containing key pairs to be printed
# IN title - title of key pair list
#
# @method slurm_print_key_pairs(out, key_pairs, title)
# @param [FFI::Pointer(*FILE)] out
# @param [FFI::Pointer(*Void)] key_pairs
# @param [String] title
# @return [nil]
# @scope class
attach_function :slurm_print_key_pairs, :slurm_print_key_pairs, [:pointer, :pointer, :string], :void
# slurm_load_slurmd_status - issue RPC to get the status of slurmd
# daemon on this machine
# IN slurmd_status_ptr - place to store slurmd status information
# RET 0 or -1 on error
# NOTE: free the response using slurm_free_slurmd_status()
#
# @method slurm_load_slurmd_status(slurmd_status_ptr)
# @param [FFI::Pointer(**SlurmdStatusT)] slurmd_status_ptr
# @return [Integer]
# @scope class
attach_function :slurm_load_slurmd_status, :slurm_load_slurmd_status, [:pointer], :int
# slurm_free_slurmd_status - free slurmd state information
# IN msg - pointer to slurmd state information
# NOTE: buffer is loaded by slurm_load_slurmd_status
#
# @method slurm_free_slurmd_status(slurmd_status_ptr)
# @param [SlurmdStatusMsg] slurmd_status_ptr
# @return [nil]
# @scope class
attach_function :slurm_free_slurmd_status, :slurm_free_slurmd_status, [SlurmdStatusMsg], :void
# slurm_print_slurmd_status - output the contents of slurmd status
# message as loaded using slurm_load_slurmd_status
# IN out - file to write to
# IN slurmd_status_ptr - slurmd status pointer
#
# @method slurm_print_slurmd_status(out, slurmd_status_ptr)
# @param [FFI::Pointer(*FILE)] out
# @param [SlurmdStatusMsg] slurmd_status_ptr
# @return [nil]
# @scope class
attach_function :slurm_print_slurmd_status, :slurm_print_slurmd_status, [:pointer, SlurmdStatusMsg], :void
# slurm_init_update_step_msg - initialize step update message with default
# values before calling slurm_update_step()
# OUT step_msg - step update messasge descriptor
#
# @method slurm_init_update_step_msg(step_msg)
# @param [StepUpdateRequestMsg] step_msg
# @return [nil]
# @scope class
attach_function :slurm_init_update_step_msg, :slurm_init_update_step_msg, [StepUpdateRequestMsg], :void
# Get scheduling statistics
#
# @method slurm_get_statistics(buf, req)
# @param [FFI::Pointer(**StatsInfoResponseMsgT)] buf
# @param [StatsInfoRequestMsg] req
# @return [Integer]
# @scope class
attach_function :slurm_get_statistics, :slurm_get_statistics, [:pointer, StatsInfoRequestMsg], :int
# Reset scheduling statistics
#
# @method slurm_reset_statistics(req)
# @param [StatsInfoRequestMsg] req
# @return [Integer]
# @scope class
attach_function :slurm_reset_statistics, :slurm_reset_statistics, [StatsInfoRequestMsg], :int
# slurm_job_cpus_allocated_on_node_id -
# get the number of cpus allocated to a job
# on a node by node id
# IN job_resrcs_ptr - pointer to job_resources structure
# IN node_id - zero-origin node id in allocation
# RET number of CPUs allocated to job on this node or -1 on error
#
# @method slurm_job_cpus_allocated_on_node_id(job_resrcs_ptr, node_id)
# @param [JobResources] job_resrcs_ptr
# @param [Integer] node_id
# @return [Integer]
# @scope class
attach_function :slurm_job_cpus_allocated_on_node_id, :slurm_job_cpus_allocated_on_node_id, [JobResources, :int], :int
# slurm_job_cpus_allocated_on_node -
# get the number of cpus allocated to a job
# on a node by node name
# IN job_resrcs_ptr - pointer to job_resources structure
# IN node_name - name of node
# RET number of CPUs allocated to job on this node or -1 on error
#
# @method slurm_job_cpus_allocated_on_node(job_resrcs_ptr, node_name)
# @param [JobResources] job_resrcs_ptr
# @param [String] node_name
# @return [Integer]
# @scope class
attach_function :slurm_job_cpus_allocated_on_node, :slurm_job_cpus_allocated_on_node, [JobResources, :string], :int
# slurm_free_job_info_msg - free the job information response message
# IN msg - pointer to job information response message
# NOTE: buffer is loaded by slurm_load_jobs.
#
# @method slurm_free_job_info_msg(job_buffer_ptr)
# @param [JobInfoMsg] job_buffer_ptr
# @return [nil]
# @scope class
attach_function :slurm_free_job_info_msg, :slurm_free_job_info_msg, [JobInfoMsg], :void
# slurm_get_end_time - get the expected end time for a given slurm job
# IN jobid - slurm job id
# end_time_ptr - location in which to store scheduled end time for job
# RET 0 or -1 on error
#
# @method slurm_get_end_time(jobid, end_time_ptr)
# @param [Integer] jobid
# @param [FFI::Pointer(*TimeT)] end_time_ptr
# @return [Integer]
# @scope class
attach_function :slurm_get_end_time, :slurm_get_end_time, [:uint, :pointer], :int
# Given a job record pointer, return its stderr path
#
# @method slurm_get_job_stderr(buf, buf_size, job_ptr)
# @param [String] buf
# @param [Integer] buf_size
# @param [JobInfo] job_ptr
# @return [nil]
# @scope class
attach_function :slurm_get_job_stderr, :slurm_get_job_stderr, [:string, :int, JobInfo], :void
# Given a job record pointer, return its stdin path
#
# @method slurm_get_job_stdin(buf, buf_size, job_ptr)
# @param [String] buf
# @param [Integer] buf_size
# @param [JobInfo] job_ptr
# @return [nil]
# @scope class
attach_function :slurm_get_job_stdin, :slurm_get_job_stdin, [:string, :int, JobInfo], :void
# Given a job record pointer, return its stdout path
#
# @method slurm_get_job_stdout(buf, buf_size, job_ptr)
# @param [String] buf
# @param [Integer] buf_size
# @param [JobInfo] job_ptr
# @return [nil]
# @scope class
attach_function :slurm_get_job_stdout, :slurm_get_job_stdout, [:string, :int, JobInfo], :void
# slurm_get_rem_time - get the expected time remaining for a given job
# IN jobid - slurm job id
# RET remaining time in seconds or -1 on error
#
# @method slurm_get_rem_time(jobid)
# @param [Integer] jobid
# @return [Integer]
# @scope class
attach_function :slurm_get_rem_time, :slurm_get_rem_time, [:uint], :long
# slurm_job_node_ready - report if nodes are ready for job to execute now
# IN job_id - slurm job id
# RET: READY_* values defined above
#
# @method slurm_job_node_ready(job_id)
# @param [Integer] job_id
# @return [Integer]
# @scope class
attach_function :slurm_job_node_ready, :slurm_job_node_ready, [:uint], :int
# slurm_load_job - issue RPC to get job information for one job ID
# IN job_info_msg_pptr - place to store a job configuration pointer
# IN job_id - ID of job we want information about
# IN show_flags - job filtering options
# RET 0 or -1 on error
# NOTE: free the response using slurm_free_job_info_msg
#
# @method slurm_load_job(resp, job_id, show_flags)
# @param [FFI::Pointer(**JobInfoMsgT)] resp
# @param [Integer] job_id
# @param [Integer] show_flags
# @return [Integer]
# @scope class
attach_function :slurm_load_job, :slurm_load_job, [:pointer, :uint, :ushort], :int
# slurm_load_job_user - issue RPC to get slurm information about all jobs
# to be run as the specified user
# IN/OUT job_info_msg_pptr - place to store a job configuration pointer
# IN user_id - ID of user we want information for
# IN show_flags - job filtering options
# RET 0 or -1 on error
# NOTE: free the response using slurm_free_job_info_msg
#
# @method slurm_load_job_user(job_info_msg_pptr, user_id, show_flags)
# @param [FFI::Pointer(**JobInfoMsgT)] job_info_msg_pptr
# @param [Integer] user_id
# @param [Integer] show_flags
# @return [Integer]
# @scope class
attach_function :slurm_load_job_user, :slurm_load_job_user, [:pointer, :uint, :ushort], :int
# slurm_load_jobs - issue RPC to get slurm all job configuration
# information if changed since update_time
# IN update_time - time of current configuration data
# IN/OUT job_info_msg_pptr - place to store a job configuration pointer
# IN show_flags - job filtering options
# RET 0 or -1 on error
# NOTE: free the response using slurm_free_job_info_msg
#
# @method slurm_load_jobs(update_time, job_info_msg_pptr, show_flags)
# @param [Integer] update_time
# @param [FFI::Pointer(**JobInfoMsgT)] job_info_msg_pptr
# @param [Integer] show_flags
# @return [Integer]
# @scope class
attach_function :slurm_load_jobs, :slurm_load_jobs, [:long, :pointer, :ushort], :int
# slurm_notify_job - send message to the job's stdout,
# usable only by user root
# IN job_id - slurm job_id or 0 for all jobs
# IN message - arbitrary message
# RET 0 or -1 on error
#
# @method slurm_notify_job(job_id, message)
# @param [Integer] job_id
# @param [String] message
# @return [Integer]
# @scope class
attach_function :slurm_notify_job, :slurm_notify_job, [:uint, :string], :int
# slurm_pid2jobid - issue RPC to get the slurm job_id given a process_id
# on this machine
# IN job_pid - process_id of interest on this machine
# OUT job_id_ptr - place to store a slurm job_id
# RET 0 or -1 on error
#
# @method slurm_pid2jobid(job_pid, job_id_ptr)
# @param [Integer] job_pid
# @param [FFI::Pointer(*Uint32T)] job_id_ptr
# @return [Integer]
# @scope class
attach_function :slurm_pid2jobid, :slurm_pid2jobid, [:int, :pointer], :int
# slurm_print_job_info - output information about a specific Slurm
# job based upon message as loaded using slurm_load_jobs
# IN out - file to write to
# IN job_ptr - an individual job information record pointer
# IN one_liner - print as a single line if true
#
# @method slurm_print_job_info(file, job_ptr, one_liner)
# @param [FFI::Pointer(*FILE)] file
# @param [JobInfo] job_ptr
# @param [Integer] one_liner
# @return [nil]
# @scope class
attach_function :slurm_print_job_info, :slurm_print_job_info, [:pointer, JobInfo, :int], :void
# slurm_print_job_info_msg - output information about all Slurm
# jobs based upon message as loaded using slurm_load_jobs
# IN out - file to write to
# IN job_info_msg_ptr - job information message pointer
# IN one_liner - print as a single line if true
#
# @method slurm_print_job_info_msg(out, job_info_msg_ptr, one_liner)
# @param [FFI::Pointer(*FILE)] out
# @param [JobInfoMsg] job_info_msg_ptr
# @param [Integer] one_liner
# @return [nil]
# @scope class
attach_function :slurm_print_job_info_msg, :slurm_print_job_info_msg, [:pointer, JobInfoMsg, :int], :void
# slurm_sprint_job_info - output information about a specific Slurm
# job based upon message as loaded using slurm_load_jobs
# IN job_ptr - an individual job information record pointer
# IN one_liner - print as a single line if true
# RET out - char * containing formatted output (must be freed after call)
# NULL is returned on failure.
#
# @method slurm_sprint_job_info(job_ptr, one_liner)
# @param [JobInfo] job_ptr
# @param [Integer] one_liner
# @return [String]
# @scope class
attach_function :slurm_sprint_job_info, :slurm_sprint_job_info, [JobInfo, :int], :string
# slurm_update_job - issue RPC to a job's configuration per request,
# only usable by user root or (for some parameters) the job's owner
# IN job_msg - description of job updates
# RET 0 on success, otherwise return -1 and set errno to indicate the error
#
# @method slurm_update_job(job_msg)
# @param [JobDescriptor] job_msg
# @return [Integer]
# @scope class
attach_function :slurm_update_job, :slurm_update_job, [JobDescriptor], :int
# slurm_update_job2 - issue RPC to a job's configuration per request,
# only usable by user root or (for some parameters) the job's owner
# IN job_msg - description of job updates
# OUT resp - per task response to the request,
# free using slurm_free_job_array_resp()
# RET 0 on success, otherwise return -1 and set errno to indicate the error
#
# @method slurm_update_job2(job_msg, resp)
# @param [JobDescriptor] job_msg
# @param [FFI::Pointer(**JobArrayRespMsgT)] resp
# @return [Integer]
# @scope class
attach_function :slurm_update_job2, :slurm_update_job2, [JobDescriptor, :pointer], :int
# slurm_xlate_job_id - Translate a Slurm job ID string into a slurm job ID
# number. If this job ID contains an array index, map this to the
# equivalent Slurm job ID number (e.g. "123_2" to 124)
#
# IN job_id_str - String containing a single job ID number
# RET - equivalent job ID number or 0 on error
#
# @method slurm_xlate_job_id(job_id_str)
# @param [String] job_id_str
# @return [Integer]
# @scope class
attach_function :slurm_xlate_job_id, :slurm_xlate_job_id, [:string], :uint
# slurm_get_job_steps - issue RPC to get specific slurm job step
# configuration information if changed since update_time.
# a job_id value of NO_VAL implies all jobs, a step_id value of
# NO_VAL implies all steps
# IN update_time - time of current configuration data
# IN job_id - get information for specific job id, NO_VAL for all jobs
# IN step_id - get information for specific job step id, NO_VAL for all
# job steps
# IN step_response_pptr - place to store a step response pointer
# IN show_flags - job step filtering options
# RET 0 on success, otherwise return -1 and set errno to indicate the error
# NOTE: free the response using slurm_free_job_step_info_response_msg
#
# @method slurm_get_job_steps(update_time, job_id, step_id, step_response_pptr, show_flags)
# @param [Integer] update_time
# @param [Integer] job_id
# @param [Integer] step_id
# @param [FFI::Pointer(**JobStepInfoResponseMsgT)] step_response_pptr
# @param [Integer] show_flags
# @return [Integer]
# @scope class
attach_function :slurm_get_job_steps, :slurm_get_job_steps, [:long, :uint, :uint, :pointer, :ushort], :int
# slurm_free_job_step_info_response_msg - free the job step
# information response message
# IN msg - pointer to job step information response message
# NOTE: buffer is loaded by slurm_get_job_steps.
#
# @method slurm_free_job_step_info_response_msg(msg)
# @param [JobStepInfoResponseMsg] msg
# @return [nil]
# @scope class
attach_function :slurm_free_job_step_info_response_msg, :slurm_free_job_step_info_response_msg, [JobStepInfoResponseMsg], :void
# slurm_print_job_step_info_msg - output information about all Slurm
# job steps based upon message as loaded using slurm_get_job_steps
# IN out - file to write to
# IN job_step_info_msg_ptr - job step information message pointer
# IN one_liner - print as a single line if true
#
# @method slurm_print_job_step_info_msg(out, job_step_info_msg_ptr, one_liner)
# @param [FFI::Pointer(*FILE)] out
# @param [JobStepInfoResponseMsg] job_step_info_msg_ptr
# @param [Integer] one_liner
# @return [nil]
# @scope class
attach_function :slurm_print_job_step_info_msg, :slurm_print_job_step_info_msg, [:pointer, JobStepInfoResponseMsg, :int], :void
# slurm_print_job_step_info - output information about a specific Slurm
# job step based upon message as loaded using slurm_get_job_steps
# IN out - file to write to
# IN job_ptr - an individual job step information record pointer
# IN one_liner - print as a single line if true
#
# @method slurm_print_job_step_info(out, step_ptr, one_liner)
# @param [FFI::Pointer(*FILE)] out
# @param [JobStepInfoT] step_ptr
# @param [Integer] one_liner
# @return [nil]
# @scope class
attach_function :slurm_print_job_step_info, :slurm_print_job_step_info, [:pointer, JobStepInfoT, :int], :void
# slurm_job_step_layout_get - get the slurm_step_layout_t structure for
# a particular job step
#
# IN job_id
# IN step_id
# RET pointer to a slurm_step_layout_t (free with
# slurm_free_step_layout) on success, and NULL on error.
#
# @method slurm_job_step_layout_get(job_id, step_id)
# @param [Integer] job_id
# @param [Integer] step_id
# @return [SlurmStepLayout]
# @scope class
attach_function :slurm_job_step_layout_get, :slurm_job_step_layout_get, [:uint, :uint], SlurmStepLayout
# slurm_sprint_job_step_info - output information about a specific Slurm
# job step based upon message as loaded using slurm_get_job_steps
# IN job_ptr - an individual job step information record pointer
# IN one_liner - print as a single line if true
# RET out - char * containing formatted output (must be freed after call)
# NULL is returned on failure.
#
# @method slurm_sprint_job_step_info(step_ptr, one_liner)
# @param [JobStepInfoT] step_ptr
# @param [Integer] one_liner
# @return [String]
# @scope class
attach_function :slurm_sprint_job_step_info, :slurm_sprint_job_step_info, [JobStepInfoT, :int], :string
# slurm_job_step_stat - status a current step
#
# IN job_id
# IN step_id
# IN node_list, optional, if NULL then all nodes in step are returned.
# OUT resp
# RET SLURM_SUCCESS on success SLURM_ERROR else
#
# @method slurm_job_step_stat(job_id, step_id, node_list, resp)
# @param [Integer] job_id
# @param [Integer] step_id
# @param [String] node_list
# @param [FFI::Pointer(**JobStepStatResponseMsgT)] resp
# @return [Integer]
# @scope class
attach_function :slurm_job_step_stat, :slurm_job_step_stat, [:uint, :uint, :string, :pointer], :int
# slurm_job_step_get_pids - get the complete list of pids for a given
# job step
#
# IN job_id
# IN step_id
# OUT resp
# RET SLURM_SUCCESS on success SLURM_ERROR else
#
# @method slurm_job_step_get_pids(job_id, step_id, node_list, resp)
# @param [Integer] job_id
# @param [Integer] step_id
# @param [String] node_list
# @param [FFI::Pointer(**JobStepPidsResponseMsgT)] resp
# @return [Integer]
# @scope class
attach_function :slurm_job_step_get_pids, :slurm_job_step_get_pids, [:uint, :uint, :string, :pointer], :int
# (Not documented)
#
# @method slurm_job_step_layout_free(layout)
# @param [SlurmStepLayout] layout
# @return [nil]
# @scope class
attach_function :slurm_job_step_layout_free, :slurm_job_step_layout_free, [SlurmStepLayout], :void
# (Not documented)
#
# @method slurm_job_step_pids_free(object)
# @param [JobStepPidsT] object
# @return [nil]
# @scope class
attach_function :slurm_job_step_pids_free, :slurm_job_step_pids_free, [JobStepPidsT], :void
# (Not documented)
#
# @method slurm_job_step_pids_response_msg_free(object)
# @param [FFI::Pointer(*Void)] object
# @return [nil]
# @scope class
attach_function :slurm_job_step_pids_response_msg_free, :slurm_job_step_pids_response_msg_free, [:pointer], :void
# (Not documented)
#
# @method slurm_job_step_stat_free(object)
# @param [JobStepStatT] object
# @return [nil]
# @scope class
attach_function :slurm_job_step_stat_free, :slurm_job_step_stat_free, [JobStepStatT], :void
# (Not documented)
#
# @method slurm_job_step_stat_response_msg_free(object)
# @param [FFI::Pointer(*Void)] object
# @return [nil]
# @scope class
attach_function :slurm_job_step_stat_response_msg_free, :slurm_job_step_stat_response_msg_free, [:pointer], :void
# Update the time limit of a job step,
# IN step_msg - step update messasge descriptor
# RET 0 or -1 on error
#
# @method slurm_update_step(step_msg)
# @param [StepUpdateRequestMsg] step_msg
# @return [Integer]
# @scope class
attach_function :slurm_update_step, :slurm_update_step, [StepUpdateRequestMsg], :int
# slurm_load_node - issue RPC to get slurm all node configuration information
# if changed since update_time
# IN update_time - time of current configuration data
# OUT resp - place to store a node configuration pointer
# IN show_flags - node filtering options
# RET 0 or a slurm error code
# NOTE: free the response using slurm_free_node_info_msg
#
# @method slurm_load_node(update_time, resp, show_flags)
# @param [Integer] update_time
# @param [FFI::Pointer(**NodeInfoMsgT)] resp
# @param [Integer] show_flags
# @return [Integer]
# @scope class
attach_function :slurm_load_node, :slurm_load_node, [:long, :pointer, :ushort], :int
# slurm_load_node_single - issue RPC to get slurm configuration information
# for a specific node
# OUT resp - place to store a node configuration pointer
# IN node_name - name of the node for which information is requested
# IN show_flags - node filtering options
# RET 0 or a slurm error code
# NOTE: free the response using slurm_free_node_info_msg
#
# @method slurm_load_node_single(resp, node_name, show_flags)
# @param [FFI::Pointer(**NodeInfoMsgT)] resp
# @param [String] node_name
# @param [Integer] show_flags
# @return [Integer]
# @scope class
attach_function :slurm_load_node_single, :slurm_load_node_single, [:pointer, :string, :ushort], :int
# slurm_node_energy - issue RPC to get the energy data on this machine
# IN host - name of node to query, NULL if localhost
# IN delta - Use cache if data is newer than this in seconds
# OUT acct_gather_energy_t structure on success or NULL other wise
# RET 0 or a slurm error code
# NOTE: free the response using slurm_acct_gather_energy_destroy
#
# @method slurm_get_node_energy(host, delta, acct_gather_energy)
# @param [String] host
# @param [Integer] delta
# @param [FFI::Pointer(**AcctGatherEnergyT)] acct_gather_energy
# @return [Integer]
# @scope class
attach_function :slurm_get_node_energy, :slurm_get_node_energy, [:string, :ushort, :pointer], :int
# slurm_free_node_info_msg - free the node information response message
# IN msg - pointer to node information response message
# NOTE: buffer is loaded by slurm_load_node.
#
# @method slurm_free_node_info_msg(node_buffer_ptr)
# @param [NodeInfoMsg] node_buffer_ptr
# @return [nil]
# @scope class
attach_function :slurm_free_node_info_msg, :slurm_free_node_info_msg, [NodeInfoMsg], :void
# slurm_print_node_info_msg - output information about all Slurm nodes
# based upon message as loaded using slurm_load_node
# IN out - file to write to
# IN node_info_msg_ptr - node information message pointer
# IN one_liner - print as a single line if true
#
# @method slurm_print_node_info_msg(out, node_info_msg_ptr, one_liner)
# @param [FFI::Pointer(*FILE)] out
# @param [NodeInfoMsg] node_info_msg_ptr
# @param [Integer] one_liner
# @return [nil]
# @scope class
attach_function :slurm_print_node_info_msg, :slurm_print_node_info_msg, [:pointer, NodeInfoMsg, :int], :void
# slurm_print_node_table - output information about a specific Slurm nodes
# based upon message as loaded using slurm_load_node
# IN out - file to write to
# IN node_ptr - an individual node information record pointer
# IN node_scaling - number of nodes each node represents
# IN one_liner - print as a single line if true
#
# @method slurm_print_node_table(out, node_ptr, node_scaling, one_liner)
# @param [FFI::Pointer(*FILE)] out
# @param [NodeInfo] node_ptr
# @param [Integer] node_scaling
# @param [Integer] one_liner
# @return [nil]
# @scope class
attach_function :slurm_print_node_table, :slurm_print_node_table, [:pointer, NodeInfo, :int, :int], :void
# slurm_sprint_node_table - output information about a specific Slurm nodes
# based upon message as loaded using slurm_load_node
# IN node_ptr - an individual node information record pointer
# IN one_liner - print as a single line if true
# IN node_scaling - number of nodes each node represents
# RET out - char * containing formatted output (must be freed after call)
# NULL is returned on failure.
#
# @method slurm_sprint_node_table(node_ptr, node_scaling, one_liner)
# @param [NodeInfo] node_ptr
# @param [Integer] node_scaling
# @param [Integer] one_liner
# @return [String]
# @scope class
attach_function :slurm_sprint_node_table, :slurm_sprint_node_table, [NodeInfo, :int, :int], :string
# slurm_init_update_node_msg - initialize node update message
# OUT update_node_msg - user defined node descriptor
#
# @method slurm_init_update_node_msg(update_node_msg)
# @param [SlurmUpdateNodeMsg] update_node_msg
# @return [nil]
# @scope class
attach_function :slurm_init_update_node_msg, :slurm_init_update_node_msg, [SlurmUpdateNodeMsg], :void
# slurm_update_node - issue RPC to a node's configuration per request,
# only usable by user root
# IN node_msg - description of node updates
# RET 0 on success, otherwise return -1 and set errno to indicate the error
#
# @method slurm_update_node(node_msg)
# @param [SlurmUpdateNodeMsg] node_msg
# @return [Integer]
# @scope class
attach_function :slurm_update_node, :slurm_update_node, [SlurmUpdateNodeMsg], :int
# slurm_load_front_end - issue RPC to get slurm all front_end configuration
# information if changed since update_time
# IN update_time - time of current configuration data
# IN front_end_info_msg_pptr - place to store a front_end configuration pointer
# RET 0 or a slurm error code
# NOTE: free the response using slurm_free_front_end_info_msg
#
# @method slurm_load_front_end(update_time, resp)
# @param [Integer] update_time
# @param [FFI::Pointer(**FrontEndInfoMsgT)] resp
# @return [Integer]
# @scope class
attach_function :slurm_load_front_end, :slurm_load_front_end, [:long, :pointer], :int
# slurm_free_front_end_info_msg - free the front_end information response
# message
# IN msg - pointer to front_end information response message
# NOTE: buffer is loaded by slurm_load_front_end.
#
# @method slurm_free_front_end_info_msg(front_end_buffer_ptr)
# @param [FrontEndInfoMsg] front_end_buffer_ptr
# @return [nil]
# @scope class
attach_function :slurm_free_front_end_info_msg, :slurm_free_front_end_info_msg, [FrontEndInfoMsg], :void
# slurm_print_front_end_info_msg - output information about all Slurm
# front_ends based upon message as loaded using slurm_load_front_end
# IN out - file to write to
# IN front_end_info_msg_ptr - front_end information message pointer
# IN one_liner - print as a single line if true
#
# @method slurm_print_front_end_info_msg(out, front_end_info_msg_ptr, one_liner)
# @param [FFI::Pointer(*FILE)] out
# @param [FrontEndInfoMsg] front_end_info_msg_ptr
# @param [Integer] one_liner
# @return [nil]
# @scope class
attach_function :slurm_print_front_end_info_msg, :slurm_print_front_end_info_msg, [:pointer, FrontEndInfoMsg, :int], :void
# slurm_print_front_end_table - output information about a specific Slurm
# front_ends based upon message as loaded using slurm_load_front_end
# IN out - file to write to
# IN front_end_ptr - an individual front_end information record pointer
# IN one_liner - print as a single line if true
#
# @method slurm_print_front_end_table(out, front_end_ptr, one_liner)
# @param [FFI::Pointer(*FILE)] out
# @param [FrontEndInfo] front_end_ptr
# @param [Integer] one_liner
# @return [nil]
# @scope class
attach_function :slurm_print_front_end_table, :slurm_print_front_end_table, [:pointer, FrontEndInfo, :int], :void
# slurm_sprint_front_end_table - output information about a specific Slurm
# front_end based upon message as loaded using slurm_load_front_end
# IN front_end_ptr - an individual front_end information record pointer
# IN one_liner - print as a single line if true
# RET out - char * containing formatted output (must be freed after call)
# NULL is returned on failure.
#
# @method slurm_sprint_front_end_table(front_end_ptr, one_liner)
# @param [FrontEndInfo] front_end_ptr
# @param [Integer] one_liner
# @return [String]
# @scope class
attach_function :slurm_sprint_front_end_table, :slurm_sprint_front_end_table, [FrontEndInfo, :int], :string
# slurm_init_update_front_end_msg - initialize front_end node update message
# OUT update_front_end_msg - user defined node descriptor
#
# @method slurm_init_update_front_end_msg(update_front_end_msg)
# @param [SlurmUpdateFrontEndMsg] update_front_end_msg
# @return [nil]
# @scope class
attach_function :slurm_init_update_front_end_msg, :slurm_init_update_front_end_msg, [SlurmUpdateFrontEndMsg], :void
# slurm_update_front_end - issue RPC to a front_end node's configuration per
# request, only usable by user root
# IN front_end_msg - description of front_end node updates
# RET 0 on success, otherwise return -1 and set errno to indicate the error
#
# @method slurm_update_front_end(front_end_msg)
# @param [SlurmUpdateFrontEndMsg] front_end_msg
# @return [Integer]
# @scope class
attach_function :slurm_update_front_end, :slurm_update_front_end, [SlurmUpdateFrontEndMsg], :int
# slurm_load_topo - issue RPC to get slurm all switch topology configuration
# information
# IN node_info_msg_pptr - place to store a node configuration pointer
# RET 0 or a slurm error code
# NOTE: free the response using slurm_free_topo_info_msg
#
# @method slurm_load_topo(topo_info_msg_pptr)
# @param [FFI::Pointer(**TopoInfoResponseMsgT)] topo_info_msg_pptr
# @return [Integer]
# @scope class
attach_function :slurm_load_topo, :slurm_load_topo, [:pointer], :int
# slurm_free_topo_info_msg - free the switch topology configuration
# information response message
# IN msg - pointer to switch topology configuration response message
# NOTE: buffer is loaded by slurm_load_topo.
#
# @method slurm_free_topo_info_msg(msg)
# @param [TopoInfoResponseMsg] msg
# @return [nil]
# @scope class
attach_function :slurm_free_topo_info_msg, :slurm_free_topo_info_msg, [TopoInfoResponseMsg], :void
# slurm_print_topo_info_msg - output information about all switch topology
# configuration information based upon message as loaded using
# slurm_load_topo
# IN out - file to write to
# IN topo_info_msg_ptr - switch topology information message pointer
# IN one_liner - print as a single line if not zero
#
# @method slurm_print_topo_info_msg(out, topo_info_msg_ptr, one_liner)
# @param [FFI::Pointer(*FILE)] out
# @param [TopoInfoResponseMsg] topo_info_msg_ptr
# @param [Integer] one_liner
# @return [nil]
# @scope class
attach_function :slurm_print_topo_info_msg, :slurm_print_topo_info_msg, [:pointer, TopoInfoResponseMsg, :int], :void
# slurm_print_topo_record - output information about a specific Slurm topology
# record based upon message as loaded using slurm_load_topo
# IN out - file to write to
# IN topo_ptr - an individual switch information record pointer
# IN one_liner - print as a single line if not zero
# RET out - char * containing formatted output (must be freed after call)
# NULL is returned on failure.
#
# @method slurm_print_topo_record(out, topo_ptr, one_liner)
# @param [FFI::Pointer(*FILE)] out
# @param [TopoInfo] topo_ptr
# @param [Integer] one_liner
# @return [nil]
# @scope class
attach_function :slurm_print_topo_record, :slurm_print_topo_record, [:pointer, TopoInfo, :int], :void
# slurm_get_select_jobinfo - get data from a select job credential
# IN jobinfo - updated select job credential
# IN data_type - type of data to enter into job credential
# IN/OUT data - the data to enter into job credential
# RET 0 or -1 on error
#
# @method slurm_get_select_jobinfo(jobinfo, data_type, data)
# @param [DynamicPluginData] jobinfo
# @param [Symbol from _enum_select_jobdata_type_] data_type
# @param [FFI::Pointer(*Void)] data
# @return [Integer]
# @scope class
attach_function :slurm_get_select_jobinfo, :slurm_get_select_jobinfo, [DynamicPluginData, :select_jobdata_type, :pointer], :int
# slurm_get_select_nodeinfo - get data from a select node credential
# IN nodeinfo - updated select node credential
# IN data_type - type of data to enter into node credential
# IN state - state of node query
# IN/OUT data - the data to enter into node credential
# RET 0 or -1 on error
#
# @method slurm_get_select_nodeinfo(nodeinfo, data_type, state, data)
# @param [DynamicPluginData] nodeinfo
# @param [Symbol from _enum_select_nodedata_type_] data_type
# @param [Symbol from _enum_node_states_] state
# @param [FFI::Pointer(*Void)] data
# @return [Integer]
# @scope class
attach_function :slurm_get_select_nodeinfo, :slurm_get_select_nodeinfo, [DynamicPluginData, :select_nodedata_type, :node_states, :pointer], :int
# slurm_init_part_desc_msg - initialize partition descriptor with
# default values
# IN/OUT update_part_msg - user defined partition descriptor
#
# @method slurm_init_part_desc_msg(update_part_msg)
# @param [PartitionInfo] update_part_msg
# @return [nil]
# @scope class
attach_function :slurm_init_part_desc_msg, :slurm_init_part_desc_msg, [PartitionInfo], :void
# slurm_load_partitions - issue RPC to get slurm all partition configuration
# information if changed since update_time
# IN update_time - time of current configuration data
# IN partition_info_msg_pptr - place to store a partition configuration
# pointer
# IN show_flags - partitions filtering options
# RET 0 or a slurm error code
# NOTE: free the response using slurm_free_partition_info_msg
#
# @method slurm_load_partitions(update_time, part_buffer_ptr, show_flags)
# @param [Integer] update_time
# @param [FFI::Pointer(**PartitionInfoMsgT)] part_buffer_ptr
# @param [Integer] show_flags
# @return [Integer]
# @scope class
attach_function :slurm_load_partitions, :slurm_load_partitions, [:long, :pointer, :ushort], :int
# slurm_free_partition_info_msg - free the partition information
# response message
# IN msg - pointer to partition information response message
# NOTE: buffer is loaded by slurm_load_partitions
#
# @method slurm_free_partition_info_msg(part_info_ptr)
# @param [PartitionInfoMsg] part_info_ptr
# @return [nil]
# @scope class
attach_function :slurm_free_partition_info_msg, :slurm_free_partition_info_msg, [PartitionInfoMsg], :void
# slurm_print_partition_info_msg - output information about all Slurm
# partitions based upon message as loaded using slurm_load_partitions
# IN out - file to write to
# IN part_info_ptr - partitions information message pointer
# IN one_liner - print as a single line if true
#
# @method slurm_print_partition_info_msg(out, part_info_ptr, one_liner)
# @param [FFI::Pointer(*FILE)] out
# @param [PartitionInfoMsg] part_info_ptr
# @param [Integer] one_liner
# @return [nil]
# @scope class
attach_function :slurm_print_partition_info_msg, :slurm_print_partition_info_msg, [:pointer, PartitionInfoMsg, :int], :void
# slurm_print_partition_info - output information about a specific Slurm
# partition based upon message as loaded using slurm_load_partitions
# IN out - file to write to
# IN part_ptr - an individual partition information record pointer
# IN one_liner - print as a single line if true
#
# @method slurm_print_partition_info(out, part_ptr, one_liner)
# @param [FFI::Pointer(*FILE)] out
# @param [PartitionInfo] part_ptr
# @param [Integer] one_liner
# @return [nil]
# @scope class
attach_function :slurm_print_partition_info, :slurm_print_partition_info, [:pointer, PartitionInfo, :int], :void
# slurm_sprint_partition_info - output information about a specific Slurm
# partition based upon message as loaded using slurm_load_partitions
# IN part_ptr - an individual partition information record pointer
# IN one_liner - print as a single line if true
# RET out - char * with formatted output (must be freed after call)
# NULL is returned on failure.
#
# @method slurm_sprint_partition_info(part_ptr, one_liner)
# @param [PartitionInfo] part_ptr
# @param [Integer] one_liner
# @return [String]
# @scope class
attach_function :slurm_sprint_partition_info, :slurm_sprint_partition_info, [PartitionInfo, :int], :string
# slurm_create_partition - create a new partition, only usable by user root
# IN part_msg - description of partition configuration
# RET 0 on success, otherwise return -1 and set errno to indicate the error
#
# @method slurm_create_partition(part_msg)
# @param [PartitionInfo] part_msg
# @return [Integer]
# @scope class
attach_function :slurm_create_partition, :slurm_create_partition, [PartitionInfo], :int
# slurm_update_partition - issue RPC to update a partition's configuration
# per request, only usable by user root
# IN part_msg - description of partition updates
# RET 0 on success, otherwise return -1 and set errno to indicate the error
#
# @method slurm_update_partition(part_msg)
# @param [PartitionInfo] part_msg
# @return [Integer]
# @scope class
attach_function :slurm_update_partition, :slurm_update_partition, [PartitionInfo], :int
# slurm_delete_partition - issue RPC to delete a partition, only usable
# by user root
# IN part_msg - description of partition to delete
# RET 0 on success, otherwise return -1 and set errno to indicate the error
#
# @method slurm_delete_partition(part_msg)
# @param [DeletePartitionMsg] part_msg
# @return [Integer]
# @scope class
attach_function :slurm_delete_partition, :slurm_delete_partition, [DeletePartitionMsg], :int
# slurm_init_resv_desc_msg - initialize reservation descriptor with
# default values
# OUT job_desc_msg - user defined partition descriptor
#
# @method slurm_init_resv_desc_msg(update_resv_msg)
# @param [ResvDescMsg] update_resv_msg
# @return [nil]
# @scope class
attach_function :slurm_init_resv_desc_msg, :slurm_init_resv_desc_msg, [ResvDescMsg], :void
# slurm_create_reservation - create a new reservation, only usable by user root
# IN resv_msg - description of reservation
# RET name of reservation on success (caller must free the memory),
# otherwise return NULL and set errno to indicate the error
#
# @method slurm_create_reservation(resv_msg)
# @param [ResvDescMsg] resv_msg
# @return [String]
# @scope class
attach_function :slurm_create_reservation, :slurm_create_reservation, [ResvDescMsg], :string
# slurm_update_reservation - modify an existing reservation, only usable by
# user root
# IN resv_msg - description of reservation
# RET 0 on success, otherwise return -1 and set errno to indicate the error
#
# @method slurm_update_reservation(resv_msg)
# @param [ResvDescMsg] resv_msg
# @return [Integer]
# @scope class
attach_function :slurm_update_reservation, :slurm_update_reservation, [ResvDescMsg], :int
# slurm_delete_reservation - issue RPC to delete a reservation, only usable
# by user root
# IN resv_msg - description of reservation to delete
# RET 0 on success, otherwise return -1 and set errno to indicate the error
#
# @method slurm_delete_reservation(resv_msg)
# @param [ReservationNameMsg] resv_msg
# @return [Integer]
# @scope class
attach_function :slurm_delete_reservation, :slurm_delete_reservation, [ReservationNameMsg], :int
# slurm_load_reservations - issue RPC to get all slurm reservation
# configuration information if changed since update_time
# IN update_time - time of current configuration data
# IN reserve_info_msg_pptr - place to store a reservation configuration
# pointer
# RET 0 or a slurm error code
# NOTE: free the response using slurm_free_reservation_info_msg
#
# @method slurm_load_reservations(update_time, resp)
# @param [Integer] update_time
# @param [FFI::Pointer(**ReserveInfoMsgT)] resp
# @return [Integer]
# @scope class
attach_function :slurm_load_reservations, :slurm_load_reservations, [:long, :pointer], :int
# slurm_print_reservation_info_msg - output information about all Slurm
# reservations based upon message as loaded using slurm_load_reservation
# IN out - file to write to
# IN resv_info_ptr - reservation information message pointer
# IN one_liner - print as a single line if true
#
# @method slurm_print_reservation_info_msg(out, resv_info_ptr, one_liner)
# @param [FFI::Pointer(*FILE)] out
# @param [ReserveInfoMsg] resv_info_ptr
# @param [Integer] one_liner
# @return [nil]
# @scope class
attach_function :slurm_print_reservation_info_msg, :slurm_print_reservation_info_msg, [:pointer, ReserveInfoMsg, :int], :void
# slurm_print_reservation_info - output information about a specific Slurm
# reservation based upon message as loaded using slurm_load_reservation
# IN out - file to write to
# IN resv_ptr - an individual reservation information record pointer
# IN one_liner - print as a single line if true
#
# @method slurm_print_reservation_info(out, resv_ptr, one_liner)
# @param [FFI::Pointer(*FILE)] out
# @param [ReserveInfo] resv_ptr
# @param [Integer] one_liner
# @return [nil]
# @scope class
attach_function :slurm_print_reservation_info, :slurm_print_reservation_info, [:pointer, ReserveInfo, :int], :void
# slurm_sprint_reservation_info - output information about a specific Slurm
# reservation based upon message as loaded using slurm_load_reservations
# IN resv_ptr - an individual reservation information record pointer
# IN one_liner - print as a single line if true
# RET out - char * containing formatted output (must be freed after call)
# NULL is returned on failure.
#
# @method slurm_sprint_reservation_info(resv_ptr, one_liner)
# @param [ReserveInfo] resv_ptr
# @param [Integer] one_liner
# @return [String]
# @scope class
attach_function :slurm_sprint_reservation_info, :slurm_sprint_reservation_info, [ReserveInfo, :int], :string
# slurm_free_reservation_info_msg - free the reservation information
# response message
# IN msg - pointer to reservation information response message
# NOTE: buffer is loaded by slurm_load_reservation
#
# @method slurm_free_reservation_info_msg(resv_info_ptr)
# @param [ReserveInfoMsg] resv_info_ptr
# @return [nil]
# @scope class
attach_function :slurm_free_reservation_info_msg, :slurm_free_reservation_info_msg, [ReserveInfoMsg], :void
# slurm_ping - issue RPC to have Slurm controller (slurmctld)
# IN controller - 1==primary controller, 2==secondary controller
# RET 0 or a slurm error code
#
# @method slurm_ping(primary)
# @param [Integer] primary
# @return [Integer]
# @scope class
attach_function :slurm_ping, :slurm_ping, [:int], :int
# slurm_reconfigure - issue RPC to have Slurm controller (slurmctld)
# reload its configuration file
# RET 0 or a slurm error code
#
# @method slurm_reconfigure()
# @return [Integer]
# @scope class
attach_function :slurm_reconfigure, :slurm_reconfigure, [], :int
# slurm_shutdown - issue RPC to have Slurm controller (slurmctld)
# cease operations, both the primary and backup controller
# are shutdown.
# IN options - 0: all slurm daemons are shutdown
# 1: slurmctld generates a core file
# 2: only the slurmctld is shutdown (no core file)
# RET 0 or a slurm error code
#
# @method slurm_shutdown(options)
# @param [Integer] options
# @return [Integer]
# @scope class
attach_function :slurm_shutdown, :slurm_shutdown, [:ushort], :int
# slurm_takeover - issue RPC to have Slurm backup controller (slurmctld)
# take over the primary controller.
#
# RET 0 or a slurm error code
#
# @method slurm_takeover()
# @return [Integer]
# @scope class
attach_function :slurm_takeover, :slurm_takeover, [], :int
# slurm_set_debugflags - issue RPC to set slurm controller debug flags
# IN debug_flags_plus - debug flags to be added
# IN debug_flags_minus - debug flags to be removed
# RET 0 on success, otherwise return -1 and set errno to indicate the error
#
# @method slurm_set_debugflags(debug_flags_plus, debug_flags_minus)
# @param [Integer] debug_flags_plus
# @param [Integer] debug_flags_minus
# @return [Integer]
# @scope class
attach_function :slurm_set_debugflags, :slurm_set_debugflags, [:ulong, :ulong], :int
# slurm_set_debug_level - issue RPC to set slurm controller debug level
# IN debug_level - requested debug level
# RET 0 on success, otherwise return -1 and set errno to indicate the error
#
# @method slurm_set_debug_level(debug_level)
# @param [Integer] debug_level
# @return [Integer]
# @scope class
attach_function :slurm_set_debug_level, :slurm_set_debug_level, [:uint], :int
# slurm_set_schedlog_level - issue RPC to set slurm scheduler log level
# IN schedlog_level - requested scheduler log level
# RET 0 on success, otherwise return -1 and set errno to indicate the error
#
# @method slurm_set_schedlog_level(schedlog_level)
# @param [Integer] schedlog_level
# @return [Integer]
# @scope class
attach_function :slurm_set_schedlog_level, :slurm_set_schedlog_level, [:uint], :int
# slurm_suspend - suspend execution of a job.
# IN job_id - job on which to perform operation
# RET 0 or a slurm error code
#
# @method slurm_suspend(job_id)
# @param [Integer] job_id
# @return [Integer]
# @scope class
attach_function :slurm_suspend, :slurm_suspend, [:uint], :int
# slurm_suspend2 - suspend execution of a job.
# IN job_id in string form - job on which to perform operation, may be job
# array specification (e.g. "123_1-20,44");
# OUT resp - per task response to the request,
# free using slurm_free_job_array_resp()
# RET 0 or a slurm error code
#
# @method slurm_suspend2(job_id, resp)
# @param [String] job_id
# @param [FFI::Pointer(**JobArrayRespMsgT)] resp
# @return [Integer]
# @scope class
attach_function :slurm_suspend2, :slurm_suspend2, [:string, :pointer], :int
# slurm_resume - resume execution of a previously suspended job.
# IN job_id - job on which to perform operation
# RET 0 or a slurm error code
#
# @method slurm_resume(job_id)
# @param [Integer] job_id
# @return [Integer]
# @scope class
attach_function :slurm_resume, :slurm_resume, [:uint], :int
# slurm_resume2 - resume execution of a previously suspended job.
# IN job_id in string form - job on which to perform operation, may be job
# array specification (e.g. "123_1-20,44");
# OUT resp - per task response to the request,
# free using slurm_free_job_array_resp()
# RET 0 or a slurm error code
#
# @method slurm_resume2(job_id, resp)
# @param [String] job_id
# @param [FFI::Pointer(**JobArrayRespMsgT)] resp
# @return [Integer]
# @scope class
attach_function :slurm_resume2, :slurm_resume2, [:string, :pointer], :int
# Free job array oriented response with individual return codes by task ID
#
# @method slurm_free_job_array_resp(resp)
# @param [JobArrayRespMsgT] resp
# @return [nil]
# @scope class
attach_function :slurm_free_job_array_resp, :slurm_free_job_array_resp, [JobArrayRespMsgT], :void
# slurm_requeue - re-queue a batch job, if already running
# then terminate it first
# IN job_id - job on which to perform operation
# IN state - the state in which the job should be requeued
# valid values are:
# 0 - if the job has to be requeued in JOB_PENDING state
# JOB_SPECIAL_EXIT - if the job has to be requeued in
# the special exit state and be held.
# JOB_REQUEUE_HOLD - if the job has to be requeued in
# JOB_PENDING and held state.
# RET 0 or a slurm error code
#
# @method slurm_requeue(job_id, state)
# @param [Integer] job_id
# @param [Integer] state
# @return [Integer]
# @scope class
attach_function :slurm_requeue, :slurm_requeue, [:uint, :uint], :int
# slurm_requeue2 - re-queue a batch job, if already running
# then terminate it first
# IN job_id in string form - job on which to perform operation, may be job
# array specification (e.g. "123_1-20,44");
# IN state - the state in which the job should be requeued
# valid values are:
# 0 - if the job has to be requeued in JOB_PENDING state
# JOB_SPECIAL_EXIT - if the job has to be requeued in
# the special exit state and be held.
# JOB_REQUEUE_HOLD - if the job has to be requeued in
# JOB_PENDING and held state.
# OUT resp - per task response to the request,
# free using slurm_free_job_array_resp()
# RET 0 or a slurm error code
#
# @method slurm_requeue2(job_id, state, resp)
# @param [String] job_id
# @param [Integer] state
# @param [FFI::Pointer(**JobArrayRespMsgT)] resp
# @return [Integer]
# @scope class
attach_function :slurm_requeue2, :slurm_requeue2, [:string, :uint, :pointer], :int
# slurm_checkpoint_able - determine if the specified job step can presently
# be checkpointed
# IN job_id - job on which to perform operation
# IN step_id - job step on which to perform operation
# OUT start_time - time at which checkpoint request was issued
# RET 0 (can be checkpoined) or a slurm error code
#
# @method slurm_checkpoint_able(job_id, step_id, start_time)
# @param [Integer] job_id
# @param [Integer] step_id
# @param [FFI::Pointer(*TimeT)] start_time
# @return [Integer]
# @scope class
attach_function :slurm_checkpoint_able, :slurm_checkpoint_able, [:uint, :uint, :pointer], :int
# slurm_checkpoint_disable - disable checkpoint requests for some job step
# IN job_id - job on which to perform operation
# IN step_id - job step on which to perform operation
# RET 0 or a slurm error code
#
# @method slurm_checkpoint_disable(job_id, step_id)
# @param [Integer] job_id
# @param [Integer] step_id
# @return [Integer]
# @scope class
attach_function :slurm_checkpoint_disable, :slurm_checkpoint_disable, [:uint, :uint], :int
# slurm_checkpoint_enable - enable checkpoint requests for some job step
# IN job_id - job on which to perform operation
# IN step_id - job step on which to perform operation
# RET 0 or a slurm error code
#
# @method slurm_checkpoint_enable(job_id, step_id)
# @param [Integer] job_id
# @param [Integer] step_id
# @return [Integer]
# @scope class
attach_function :slurm_checkpoint_enable, :slurm_checkpoint_enable, [:uint, :uint], :int
# slurm_checkpoint_create - initiate a checkpoint requests for some job step.
# the job will continue execution after the checkpoint operation completes
# IN job_id - job on which to perform operation
# IN step_id - job step on which to perform operation
# IN max_wait - maximum wait for operation to complete, in seconds
# IN image_dir - directory to store image files
# RET 0 or a slurm error code
#
# @method slurm_checkpoint_create(job_id, step_id, max_wait, image_dir)
# @param [Integer] job_id
# @param [Integer] step_id
# @param [Integer] max_wait
# @param [String] image_dir
# @return [Integer]
# @scope class
attach_function :slurm_checkpoint_create, :slurm_checkpoint_create, [:uint, :uint, :ushort, :string], :int
# slurm_checkpoint_requeue - initiate a checkpoint requests for some job.
# the job will be requeued after the checkpoint operation completes
# IN job_id - job on which to perform operation
# IN max_wait - maximum wait for operation to complete, in seconds
# IN image_dir - directory used to get/put checkpoint images
# RET 0 or a slurm error code
#
# @method slurm_checkpoint_requeue(job_id, max_wait, image_dir)
# @param [Integer] job_id
# @param [Integer] max_wait
# @param [String] image_dir
# @return [Integer]
# @scope class
attach_function :slurm_checkpoint_requeue, :slurm_checkpoint_requeue, [:uint, :ushort, :string], :int
# slurm_checkpoint_vacate - initiate a checkpoint requests for some job step.
# the job will terminate after the checkpoint operation completes
# IN job_id - job on which to perform operation
# IN step_id - job step on which to perform operation
# IN max_wait - maximum wait for operation to complete, in seconds
# IN image_dir - directory to store image files
# RET 0 or a slurm error code
#
# @method slurm_checkpoint_vacate(job_id, step_id, max_wait, image_dir)
# @param [Integer] job_id
# @param [Integer] step_id
# @param [Integer] max_wait
# @param [String] image_dir
# @return [Integer]
# @scope class
attach_function :slurm_checkpoint_vacate, :slurm_checkpoint_vacate, [:uint, :uint, :ushort, :string], :int
# slurm_checkpoint_restart - restart execution of a checkpointed job step.
# IN job_id - job on which to perform operation
# IN step_id - job step on which to perform operation
# IN stick - stick to nodes previously running on
# IN image_dir - directory to find checkpoint image files
# RET 0 or a slurm error code
#
# @method slurm_checkpoint_restart(job_id, step_id, stick, image_dir)
# @param [Integer] job_id
# @param [Integer] step_id
# @param [Integer] stick
# @param [String] image_dir
# @return [Integer]
# @scope class
attach_function :slurm_checkpoint_restart, :slurm_checkpoint_restart, [:uint, :uint, :ushort, :string], :int
# slurm_checkpoint_complete - note the completion of a job step's checkpoint
# operation.
# IN job_id - job on which to perform operation
# IN step_id - job step on which to perform operation
# IN begin_time - time at which checkpoint began
# IN error_code - error code, highest value for all complete calls is preserved
# IN error_msg - error message, preserved for highest error_code
# RET 0 or a slurm error code
#
# @method slurm_checkpoint_complete(job_id, step_id, begin_time, error_code, error_msg)
# @param [Integer] job_id
# @param [Integer] step_id
# @param [Integer] begin_time
# @param [Integer] error_code
# @param [String] error_msg
# @return [Integer]
# @scope class
attach_function :slurm_checkpoint_complete, :slurm_checkpoint_complete, [:uint, :uint, :long, :uint, :string], :int
# slurm_checkpoint_task_complete - note the completion of a task's checkpoint
# operation.
# IN job_id - job on which to perform operation
# IN step_id - job step on which to perform operation
# IN task_id - task which completed the operation
# IN begin_time - time at which checkpoint began
# IN error_code - error code, highest value for all complete calls is preserved
# IN error_msg - error message, preserved for highest error_code
# RET 0 or a slurm error code
#
# @method slurm_checkpoint_task_complete(job_id, step_id, task_id, begin_time, error_code, error_msg)
# @param [Integer] job_id
# @param [Integer] step_id
# @param [Integer] task_id
# @param [Integer] begin_time
# @param [Integer] error_code
# @param [String] error_msg
# @return [Integer]
# @scope class
attach_function :slurm_checkpoint_task_complete, :slurm_checkpoint_task_complete, [:uint, :uint, :uint, :long, :uint, :string], :int
# slurm_checkpoint_error - gather error information for the last checkpoint
# operation for some job step
# IN job_id - job on which to perform operation
# IN step_id - job step on which to perform operation
# OUT error_code - error number associated with the last checkpoint operation,
# this value is dependent upon the checkpoint plugin used and may be
# completely unrelated to slurm error codes, the highest value for all
# complete calls is preserved
# OUT error_msg - error message, preserved for highest error_code, value
# must be freed by the caller to prevent memory leak
# RET 0 or a slurm error code
#
# @method slurm_checkpoint_error(job_id, step_id, error_code, error_msg)
# @param [Integer] job_id
# @param [Integer] step_id
# @param [FFI::Pointer(*Uint32T)] error_code
# @param [FFI::Pointer(**CharS)] error_msg
# @return [Integer]
# @scope class
attach_function :slurm_checkpoint_error, :slurm_checkpoint_error, [:uint, :uint, :pointer, :pointer], :int
# slurm_checkpoint_tasks - send checkpoint request to tasks of
# specified step
# IN job_id: job ID of step
# IN step_id: step ID of step
# IN image_dir: location to store ckpt images. parameter to plugin.
# IN max_wait: seconds to wait for the operation to complete
# IN nodelist: nodes to send the request
# RET: 0 on success, non-zero on failure with errno set
#
# @method slurm_checkpoint_tasks(job_id, step_id, begin_time, image_dir, max_wait, nodelist)
# @param [Integer] job_id
# @param [Integer] step_id
# @param [Integer] begin_time
# @param [String] image_dir
# @param [Integer] max_wait
# @param [String] nodelist
# @return [Integer]
# @scope class
attach_function :slurm_checkpoint_tasks, :slurm_checkpoint_tasks, [:uint, :ushort, :long, :string, :ushort, :string], :int
# slurm_set_trigger - Set an event trigger
# RET 0 or a slurm error code
#
# @method slurm_set_trigger(trigger_set)
# @param [TriggerInfo] trigger_set
# @return [Integer]
# @scope class
attach_function :slurm_set_trigger, :slurm_set_trigger, [TriggerInfo], :int
# slurm_clear_trigger - Clear (remove) an existing event trigger
# RET 0 or a slurm error code
#
# @method slurm_clear_trigger(trigger_clear)
# @param [TriggerInfo] trigger_clear
# @return [Integer]
# @scope class
attach_function :slurm_clear_trigger, :slurm_clear_trigger, [TriggerInfo], :int
# slurm_get_triggers - Get all event trigger information
# Use slurm_free_trigger_msg() to free the memory allocated by this function
# RET 0 or a slurm error code
#
# @method slurm_get_triggers(trigger_get)
# @param [FFI::Pointer(**TriggerInfoMsgT)] trigger_get
# @return [Integer]
# @scope class
attach_function :slurm_get_triggers, :slurm_get_triggers, [:pointer], :int
# slurm_pull_trigger - Pull an event trigger
# RET 0 or a slurm error code
#
# @method slurm_pull_trigger(trigger_pull)
# @param [TriggerInfo] trigger_pull
# @return [Integer]
# @scope class
attach_function :slurm_pull_trigger, :slurm_pull_trigger, [TriggerInfo], :int
# slurm_free_trigger_msg - Free data structure returned by
# slurm_get_triggers()
#
# @method slurm_free_trigger_msg(trigger_free)
# @param [TriggerInfoMsg] trigger_free
# @return [nil]
# @scope class
attach_function :slurm_free_trigger_msg, :slurm_free_trigger_msg, [TriggerInfoMsg], :void
# slurm_init_trigger_msg - initialize trigger clear/update message
# OUT trigger_info_msg - user defined trigger descriptor
#
# @method slurm_init_trigger_msg(trigger_info_msg)
# @param [TriggerInfo] trigger_info_msg
# @return [nil]
# @scope class
attach_function :slurm_init_trigger_msg, :slurm_init_trigger_msg, [TriggerInfo], :void
end
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment