hadoop-common-commits mailing list archives

Site index · List index
Message view « Date » · « Thread »
Top « Date » · « Thread »
From zhang...@apache.org
Subject [15/50] [abbrv] hadoop git commit: YARN-4255. container-executor does not clean up docker operation command files. Contributed by Sidharta Seethana.
Date Sat, 17 Oct 2015 03:43:16 GMT
YARN-4255. container-executor does not clean up docker operation command files. Contributed
by Sidharta Seethana.


Project: http://git-wip-us.apache.org/repos/asf/hadoop/repo
Commit: http://git-wip-us.apache.org/repos/asf/hadoop/commit/da1ee078
Tree: http://git-wip-us.apache.org/repos/asf/hadoop/tree/da1ee078
Diff: http://git-wip-us.apache.org/repos/asf/hadoop/diff/da1ee078

Branch: refs/heads/HDFS-7966
Commit: da1ee078f9d3c2c25c51d0b392b0925821c42ad3
Parents: fb9c151
Author: Varun Vasudev <vvasudev@apache.org>
Authored: Wed Oct 14 15:25:21 2015 +0530
Committer: Varun Vasudev <vvasudev@apache.org>
Committed: Wed Oct 14 15:25:21 2015 +0530

----------------------------------------------------------------------
 hadoop-yarn-project/CHANGES.txt                                | 3 +++
 .../main/native/container-executor/impl/container-executor.c   | 6 ++++++
 2 files changed, 9 insertions(+)
----------------------------------------------------------------------


http://git-wip-us.apache.org/repos/asf/hadoop/blob/da1ee078/hadoop-yarn-project/CHANGES.txt
----------------------------------------------------------------------
diff --git a/hadoop-yarn-project/CHANGES.txt b/hadoop-yarn-project/CHANGES.txt
index 2aac433..55eac24 100644
--- a/hadoop-yarn-project/CHANGES.txt
+++ b/hadoop-yarn-project/CHANGES.txt
@@ -937,6 +937,9 @@ Release 2.8.0 - UNRELEASED
     YARN-4253. Standardize on using PrivilegedOperationExecutor for all
     invocations of container-executor in LinuxContainerExecutor. (Sidharta Seethana via vvasudev)
 
+    YARN-4255. container-executor does not clean up docker operation command files.
+    (Sidharta Seethana via vvasudev)
+
 Release 2.7.2 - UNRELEASED
 
   INCOMPATIBLE CHANGES

http://git-wip-us.apache.org/repos/asf/hadoop/blob/da1ee078/hadoop-yarn-project/hadoop-yarn/hadoop-yarn-server/hadoop-yarn-server-nodemanager/src/main/native/container-executor/impl/container-executor.c
----------------------------------------------------------------------
diff --git a/hadoop-yarn-project/hadoop-yarn/hadoop-yarn-server/hadoop-yarn-server-nodemanager/src/main/native/container-executor/impl/container-executor.c
b/hadoop-yarn-project/hadoop-yarn/hadoop-yarn-server/hadoop-yarn-server-nodemanager/src/main/native/container-executor/impl/container-executor.c
index f40177e..c696273 100644
--- a/hadoop-yarn-project/hadoop-yarn/hadoop-yarn-server/hadoop-yarn-server-nodemanager/src/main/native/container-executor/impl/container-executor.c
+++ b/hadoop-yarn-project/hadoop-yarn/hadoop-yarn-server/hadoop-yarn-server-nodemanager/src/main/native/container-executor/impl/container-executor.c
@@ -1064,6 +1064,9 @@ int run_docker(const char *command_file) {
   snprintf(docker_command_with_binary, EXECUTOR_PATH_MAX, "%s %s", docker_binary, docker_command);
   char **args = extract_values_delim(docker_command_with_binary, " ");
 
+  //clean up command file before we exec
+  unlink(command_file);
+
   int exit_code = -1;
   if (execvp(docker_binary, args) != 0) {
     fprintf(ERRORFILE, "Couldn't execute the container launch with args %s - %s",
@@ -1360,6 +1363,9 @@ int launch_docker_container_as_user(const char * user, const char *app_id,
   }
 
 cleanup:
+  //clean up docker command file
+  unlink(command_file);
+
   if (exit_code_file != NULL && write_exit_code_file(exit_code_file, exit_code) <
0) {
     fprintf (ERRORFILE,
       "Could not write exit code to file %s.\n", exit_code_file);


Mime
View raw message