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
a0c6528c
Commit
a0c6528c
authored
10 years ago
by
Morris Jette
Browse files
Options
Downloads
Patches
Plain Diff
BGQ runjob env setup fix
This corrects logic added in commit
738913fa
for BGQ systems only
parent
6b6b9a56
No related branches found
No related tags found
No related merge requests found
Changes
1
Hide whitespace changes
Inline
Side-by-side
Showing
1 changed file
src/plugins/launch/runjob/launch_runjob.c
+11
-22
11 additions, 22 deletions
src/plugins/launch/runjob/launch_runjob.c
with
11 additions
and
22 deletions
src/plugins/launch/runjob/launch_runjob.c
+
11
−
22
View file @
a0c6528c
...
@@ -260,6 +260,7 @@ extern int fini(void)
...
@@ -260,6 +260,7 @@ extern int fini(void)
extern
int
launch_p_setup_srun_opt
(
char
**
rest
)
extern
int
launch_p_setup_srun_opt
(
char
**
rest
)
{
{
int
i
;
int
command_pos
=
0
;
int
command_pos
=
0
;
uint32_t
taskid
=
NO_VAL
;
uint32_t
taskid
=
NO_VAL
;
...
@@ -311,28 +312,21 @@ extern int launch_p_setup_srun_opt(char **rest)
...
@@ -311,28 +312,21 @@ extern int launch_p_setup_srun_opt(char **rest)
}
}
if
(
opt
.
export_env
)
{
if
(
opt
.
export_env
)
{
if
(
!
strcasecmp
(
opt
.
export_env
,
"NONE"
))
{
for
(
i
=
0
;
opt
.
export_env
[
i
];
i
++
)
{
/* represents the difference between --env-all
if
(
opt
.
export_env
[
i
]
==
','
)
* and --exp-env */
command_pos
++
;
command_pos
+=
2
;
}
else
{
error
(
"--export= only accepts NONE as "
"an option, ignoring '%s'."
,
opt
.
export_env
);
xfree
(
opt
.
export_env
);
}
}
command_pos
+=
5
;
/* baseline overhead */
}
}
opt
.
argc
+=
command_pos
;
}
}
/* We need to do +2 here just incase multi-prog is needed (we
/* We need to do +2 here just incase multi-prog is needed (we
add an extra argv on so just make space for it).
*
add an extra argv on so just make space for it).
*/
*
/
opt
.
argv
=
(
char
**
)
xmalloc
((
opt
.
argc
+
command_pos
+
2
)
*
opt
.
argv
=
(
char
**
)
xmalloc
((
opt
.
argc
+
2
)
*
sizeof
(
char
*
));
sizeof
(
char
*
));
if
(
!
opt
.
test_only
)
{
if
(
!
opt
.
test_only
)
{
int
i
=
0
;
i
=
0
;
/* First arg has to be something when sending it to the
/* First arg has to be something when sending it to the
runjob api. This can be anything, we put runjob
runjob api. This can be anything, we put runjob
here so --launch-cmd looks nice :), but it doesn't matter.
here so --launch-cmd looks nice :), but it doesn't matter.
...
@@ -432,13 +426,8 @@ extern int launch_p_setup_srun_opt(char **rest)
...
@@ -432,13 +426,8 @@ extern int launch_p_setup_srun_opt(char **rest)
* job, which in this case is exactly what it is. So, very
* job, which in this case is exactly what it is. So, very
* sweet. */
* sweet. */
opt
.
argv
[
i
++
]
=
xstrdup
(
":"
);
opt
.
argv
[
i
++
]
=
xstrdup
(
":"
);
command_pos
=
i
;
/* Sanity check to make sure we set it up correctly. */
opt
.
argc
+=
command_pos
;
if
(
i
!=
command_pos
)
{
fatal
(
"command_pos is set to %d but we are going to "
"put it at %d, please update src/srun/opt.c"
,
command_pos
,
i
);
}
/* Set default job name to the executable name rather than
/* Set default job name to the executable name rather than
* "runjob" */
* "runjob" */
...
...
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