Skip to content
GitLab
Explore
Sign in
Primary navigation
Search or go to…
Project
S
Slurm
Manage
Activity
Members
Labels
Plan
Issues
Issue boards
Milestones
Code
Merge requests
Repository
Branches
Commits
Tags
Repository graph
Compare revisions
Snippets
Build
Pipelines
Jobs
Pipeline schedules
Artifacts
Deploy
Releases
Package registry
Model registry
Operate
Environments
Terraform modules
Monitor
Incidents
Service Desk
Analyze
Value stream analytics
Contributor analytics
CI/CD analytics
Repository analytics
Model experiments
Help
Help
Support
GitLab documentation
Compare GitLab plans
Community forum
Contribute to GitLab
Provide feedback
Terms and privacy
Keyboard shortcuts
?
Snippets
Groups
Projects
Show more breadcrumbs
tud-zih-energy
Slurm
Commits
5b02c6cc
Commit
5b02c6cc
authored
22 years ago
by
Moe Jette
Browse files
Options
Downloads
Patches
Plain Diff
Update build and install instructions in README.
Add COMPLETING node and job states.
parent
8c051d24
No related branches found
No related tags found
No related merge requests found
Changes
3
Hide whitespace changes
Inline
Side-by-side
Showing
3 changed files
slurm/slurm.h.in
+4
-3
4 additions, 3 deletions
slurm/slurm.h.in
src/common/slurm_protocol_defs.c
+8
-4
8 additions, 4 deletions
src/common/slurm_protocol_defs.c
src/scancel/opt.c
+10
-2
10 additions, 2 deletions
src/scancel/opt.c
with
22 additions
and
9 deletions
slurm/slurm.h.in
+
4
−
3
View file @
5b02c6cc
...
...
@@ -94,18 +94,19 @@ BEGIN_C_DECLS
#define NO_VAL (0xfffffffe)
#define MAX_TASKS_PER_NODE 64
/* last entry must be JOB_END
* NOTE: keep in sync with job_state_string and job_state_string_compact */
/* last entry must be JOB_END, keep in sync with job_state_string and
* job_state_string_compact, if a job is in the process of de-
* allocating nodes, its final state is ORed with JOB_COMPLETING */
enum job_states {
JOB_PENDING, /* queued waiting for initiation */
JOB_RUNNING, /* allocated resources and executing */
JOB_COMPLETING, /* completing execution */
JOB_COMPLETE, /* completed execution successfully */
JOB_FAILED, /* completed execution unsuccessfully */
JOB_TIMEOUT, /* terminated on reaching time limit */
JOB_NODE_FAIL, /* terminated on node failure */
JOB_END /* last entry in table */
};
#define JOB_COMPLETING (0x8000)
/* Possible task distributions across the nodes */
enum task_dist_states {
...
...
This diff is collapsed.
Click to expand it.
src/common/slurm_protocol_defs.c
+
8
−
4
View file @
5b02c6cc
...
...
@@ -292,14 +292,16 @@ char *job_state_string(enum job_states inx)
static
char
*
job_state_string
[]
=
{
"PENDING"
,
"RUNNING"
,
"COMPLETING"
,
"COMPLETED"
,
"FAILED"
,
"TIMEOUT"
,
"NODE_FAIL"
,
"END"
};
return
job_state_string
[
inx
];
if
(
inx
&
JOB_COMPLETING
)
return
"COMPLETING"
;
else
return
job_state_string
[
inx
];
}
char
*
job_state_string_compact
(
enum
job_states
inx
)
...
...
@@ -307,13 +309,15 @@ char *job_state_string_compact(enum job_states inx)
static
char
*
job_state_string
[]
=
{
"PD"
,
"R"
,
"CG"
,
"CD"
,
"F"
,
"TO"
,
"END"
};
return
job_state_string
[
inx
];
if
(
inx
&
JOB_COMPLETING
)
return
"CG"
;
else
return
job_state_string
[
inx
];
}
char
*
node_state_string
(
enum
node_states
inx
)
...
...
This diff is collapsed.
Click to expand it.
src/scancel/opt.c
+
10
−
2
View file @
5b02c6cc
...
...
@@ -183,11 +183,17 @@ static enum job_states xlate_state_name(const char *state_name)
char
*
state_names
;
for
(
i
=
0
;
i
<
JOB_END
;
i
++
)
{
if
((
strcasecmp
(
state_name
,
job_state_string
(
i
))
==
0
)
||
(
strcasecmp
(
state_name
,
job_state_string_compact
(
i
))
==
0
))
{
if
((
strcasecmp
(
state_name
,
job_state_string
(
i
))
==
0
)
||
(
strcasecmp
(
state_name
,
job_state_string_compact
(
i
))
==
0
)){
return
i
;
}
}
if
((
strcasecmp
(
state_name
,
job_state_string
(
JOB_COMPLETING
))
==
0
)
||
(
strcasecmp
(
state_name
,
job_state_string_compact
(
JOB_COMPLETING
))
==
0
))
{
return
JOB_COMPLETING
;
}
fprintf
(
stderr
,
"Invalid job state specified: %s"
,
state_name
);
state_names
=
xstrdup
(
job_state_string
(
0
));
...
...
@@ -195,6 +201,8 @@ static enum job_states xlate_state_name(const char *state_name)
xstrcat
(
state_names
,
","
);
xstrcat
(
state_names
,
job_state_string
(
i
));
}
xstrcat
(
state_names
,
","
);
xstrcat
(
state_names
,
job_state_string
(
JOB_COMPLETING
));
fprintf
(
stderr
,
"Valid job states include: %s
\n
"
,
state_names
);
xfree
(
state_names
);
exit
(
1
);
...
...
This diff is collapsed.
Click to expand it.
Preview
0%
Loading
Try again
or
attach a new file
.
Cancel
You are about to add
0
people
to the discussion. Proceed with caution.
Finish editing this message first!
Save comment
Cancel
Please
register
or
sign in
to comment