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
cb48cc47
Commit
cb48cc47
authored
8 years ago
by
Morris Jette
Browse files
Options
Downloads
Plain Diff
Merge branch 'slurm-15.08' into slurm-16.05
parents
a1b0a459
fa073e12
No related branches found
Branches containing commit
No related tags found
No related merge requests found
Changes
3
Hide whitespace changes
Inline
Side-by-side
Showing
3 changed files
NEWS
+1
-0
1 addition, 0 deletions
NEWS
src/plugins/proctrack/linuxproc/kill_tree.c
+6
-2
6 additions, 2 deletions
src/plugins/proctrack/linuxproc/kill_tree.c
src/plugins/proctrack/pgid/proctrack_pgid.c
+6
-2
6 additions, 2 deletions
src/plugins/proctrack/pgid/proctrack_pgid.c
with
13 additions
and
4 deletions
NEWS
+
1
−
0
View file @
cb48cc47
...
...
@@ -262,6 +262,7 @@ documents those changes that are of interest to users and administrators.
-- Print correct return code on failure to update node features through sview.
-- Documentation - cleanup typos.
-- Add logic so that slurmstepd can be launched under valgrind.
-- Increase buffer size to read /proc/*/stat files.
* Changes in Slurm 15.08.12
===========================
...
...
This diff is collapsed.
Click to expand it.
src/plugins/proctrack/linuxproc/kill_tree.c
+
6
−
2
View file @
cb48cc47
...
...
@@ -149,7 +149,8 @@ static xppid_t **_build_hashtbl(void)
{
DIR
*
dir
;
struct
dirent
*
de
;
char
path
[
PATH_MAX
],
*
endptr
,
*
num
,
rbuf
[
1024
];
char
path
[
PATH_MAX
],
*
endptr
,
*
num
,
*
rbuf
;
ssize_t
buf_used
;
char
myname
[
1024
],
cmd
[
1024
];
char
state
;
int
fd
;
...
...
@@ -167,6 +168,7 @@ static xppid_t **_build_hashtbl(void)
hashtbl
=
(
xppid_t
**
)
xmalloc
(
HASH_LEN
*
sizeof
(
xppid_t
*
));
slurm_seterrno
(
0
);
rbuf
=
xmalloc
(
4096
);
while
((
de
=
readdir
(
dir
))
!=
NULL
)
{
num
=
de
->
d_name
;
if
((
num
[
0
]
<
'0'
)
||
(
num
[
0
]
>
'9'
))
...
...
@@ -183,7 +185,8 @@ static xppid_t **_build_hashtbl(void)
if
((
fd
=
open
(
path
,
O_RDONLY
))
<
0
)
{
continue
;
}
if
(
read
(
fd
,
rbuf
,
1024
)
<=
0
)
{
buf_used
=
read
(
fd
,
rbuf
,
4096
);
if
((
buf_used
<=
0
)
||
(
buf_used
>=
4096
))
{
close
(
fd
);
continue
;
}
...
...
@@ -202,6 +205,7 @@ static xppid_t **_build_hashtbl(void)
_push_to_hashtbl
((
pid_t
)
ppid
,
(
pid_t
)
pid
,
xstrcmp
(
myname
,
cmd
),
cmd
,
hashtbl
);
}
xfree
(
rbuf
);
closedir
(
dir
);
return
hashtbl
;
}
...
...
This diff is collapsed.
Click to expand it.
src/plugins/proctrack/pgid/proctrack_pgid.c
+
6
−
2
View file @
cb48cc47
...
...
@@ -196,7 +196,8 @@ proctrack_p_get_pids(uint64_t cont_id, pid_t **pids, int *npids)
{
DIR
*
dir
;
struct
dirent
*
de
;
char
path
[
PATH_MAX
],
*
endptr
,
*
num
,
rbuf
[
1024
];
char
path
[
PATH_MAX
],
*
endptr
,
*
num
,
*
rbuf
;
ssize_t
buf_used
;
char
cmd
[
1024
];
char
state
;
int
fd
,
rc
=
SLURM_SUCCESS
;
...
...
@@ -209,6 +210,7 @@ proctrack_p_get_pids(uint64_t cont_id, pid_t **pids, int *npids)
rc
=
SLURM_ERROR
;
goto
fini
;
}
rbuf
=
xmalloc
(
4096
);
while
((
de
=
readdir
(
dir
))
!=
NULL
)
{
num
=
de
->
d_name
;
if
((
num
[
0
]
<
'0'
)
||
(
num
[
0
]
>
'9'
))
...
...
@@ -223,7 +225,8 @@ proctrack_p_get_pids(uint64_t cont_id, pid_t **pids, int *npids)
if
((
fd
=
open
(
path
,
O_RDONLY
))
<
0
)
{
continue
;
}
if
(
read
(
fd
,
rbuf
,
1024
)
<=
0
)
{
buf_used
=
read
(
fd
,
rbuf
,
4096
);
if
((
buf_used
<=
0
)
||
(
buf_used
>=
4096
))
{
close
(
fd
);
continue
;
}
...
...
@@ -243,6 +246,7 @@ proctrack_p_get_pids(uint64_t cont_id, pid_t **pids, int *npids)
xrealloc
(
pid_array
,
sizeof
(
pid_t
)
*
(
pid_count
+
1
));
pid_array
[
pid_count
++
]
=
pid
;
}
xfree
(
rbuf
);
closedir
(
dir
);
fini:
*
pids
=
pid_array
;
...
...
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