You are viewing a plain text version of this content. The canonical link for it is here.
Posted to dev@mesos.apache.org by "Benjamin Hindman (JIRA)" <ji...@apache.org> on 2011/08/23 06:09:29 UTC
[jira] [Created] (MESOS-35) Slave webui needs to correctly display
stdout/stderr of executors.
Slave webui needs to correctly display stdout/stderr of executors.
------------------------------------------------------------------
Key: MESOS-35
URL: https://issues.apache.org/jira/browse/MESOS-35
Project: Mesos
Issue Type: Bug
Components: slave, webui
Reporter: Benjamin Hindman
There have been some changes to the work directories for frameworks due to multi-executor support and so the slave webui is no longer properly linking to executors stdout/stderr.
--
This message is automatically generated by JIRA.
For more information on JIRA, see: http://www.atlassian.com/software/jira
[jira] [Commented] (MESOS-35) Slave webui needs to correctly
display stdout/stderr of executors.
Posted by "Matei Zaharia (Commented) (JIRA)" <ji...@apache.org>.
[ https://issues.apache.org/jira/browse/MESOS-35?page=com.atlassian.jira.plugin.system.issuetabpanels:comment-tabpanel&focusedCommentId=13118532#comment-13118532 ]
Matei Zaharia commented on MESOS-35:
------------------------------------
I looked into this, and it seems to be because the executor launcher now tries to place the work directory in <work_dir>/work (where <work_dir> is the config option) rather than directly in <work_dir>. Seems to be a bug introduced in that.
> Slave webui needs to correctly display stdout/stderr of executors.
> ------------------------------------------------------------------
>
> Key: MESOS-35
> URL: https://issues.apache.org/jira/browse/MESOS-35
> Project: Mesos
> Issue Type: Bug
> Components: slave, webui
> Reporter: Benjamin Hindman
>
> There have been some changes to the work directories for frameworks due to multi-executor support and so the slave webui is no longer properly linking to executors stdout/stderr.
--
This message is automatically generated by JIRA.
If you think it was sent incorrectly, please contact your JIRA administrators: https://issues.apache.org/jira/secure/ContactAdministrators!default.jspa
For more information on JIRA, see: http://www.atlassian.com/software/jira
[jira] [Resolved] (MESOS-35) Slave webui needs to correctly display
stdout/stderr of executors.
Posted by "Andy Konwinski (Resolved) (JIRA)" <ji...@apache.org>.
[ https://issues.apache.org/jira/browse/MESOS-35?page=com.atlassian.jira.plugin.system.issuetabpanels:all-tabpanel ]
Andy Konwinski resolved MESOS-35.
---------------------------------
Resolution: Fixed
I've committed v2 of the patch, tests pass on OS X. Thanks to Ben for the in-person code review!
> Slave webui needs to correctly display stdout/stderr of executors.
> ------------------------------------------------------------------
>
> Key: MESOS-35
> URL: https://issues.apache.org/jira/browse/MESOS-35
> Project: Mesos
> Issue Type: Bug
> Components: slave, webui
> Reporter: Benjamin Hindman
> Assignee: Andy Konwinski
> Attachments: MESOS-35-v2.patch, MESOS-35.patch
>
>
> There have been some changes to the work directories for frameworks due to multi-executor support and so the slave webui is no longer properly linking to executors stdout/stderr.
--
This message is automatically generated by JIRA.
If you think it was sent incorrectly, please contact your JIRA administrators: https://issues.apache.org/jira/secure/ContactAdministrators!default.jspa
For more information on JIRA, see: http://www.atlassian.com/software/jira
[jira] [Updated] (MESOS-35) Slave webui needs to correctly display
stdout/stderr of executors.
Posted by "Andy Konwinski (Updated) (JIRA)" <ji...@apache.org>.
[ https://issues.apache.org/jira/browse/MESOS-35?page=com.atlassian.jira.plugin.system.issuetabpanels:all-tabpanel ]
Andy Konwinski updated MESOS-35:
--------------------------------
Attachment: MESOS-35-v2.patch
> Slave webui needs to correctly display stdout/stderr of executors.
> ------------------------------------------------------------------
>
> Key: MESOS-35
> URL: https://issues.apache.org/jira/browse/MESOS-35
> Project: Mesos
> Issue Type: Bug
> Components: slave, webui
> Reporter: Benjamin Hindman
> Assignee: Andy Konwinski
> Attachments: MESOS-35-v2.patch, MESOS-35.patch
>
>
> There have been some changes to the work directories for frameworks due to multi-executor support and so the slave webui is no longer properly linking to executors stdout/stderr.
--
This message is automatically generated by JIRA.
If you think it was sent incorrectly, please contact your JIRA administrators: https://issues.apache.org/jira/secure/ContactAdministrators!default.jspa
For more information on JIRA, see: http://www.atlassian.com/software/jira
[jira] [Commented] (MESOS-35) Slave webui needs to correctly
display stdout/stderr of executors.
Posted by "Matei Zaharia (Commented) (JIRA)" <ji...@apache.org>.
[ https://issues.apache.org/jira/browse/MESOS-35?page=com.atlassian.jira.plugin.system.issuetabpanels:comment-tabpanel&focusedCommentId=13155675#comment-13155675 ]
Matei Zaharia commented on MESOS-35:
------------------------------------
Looks good to me.
> Slave webui needs to correctly display stdout/stderr of executors.
> ------------------------------------------------------------------
>
> Key: MESOS-35
> URL: https://issues.apache.org/jira/browse/MESOS-35
> Project: Mesos
> Issue Type: Bug
> Components: slave, webui
> Reporter: Benjamin Hindman
> Assignee: Andy Konwinski
> Attachments: MESOS-35.patch
>
>
> There have been some changes to the work directories for frameworks due to multi-executor support and so the slave webui is no longer properly linking to executors stdout/stderr.
--
This message is automatically generated by JIRA.
If you think it was sent incorrectly, please contact your JIRA administrators: https://issues.apache.org/jira/secure/ContactAdministrators!default.jspa
For more information on JIRA, see: http://www.atlassian.com/software/jira
[jira] [Assigned] (MESOS-35) Slave webui needs to correctly display
stdout/stderr of executors.
Posted by "Andy Konwinski (Assigned) (JIRA)" <ji...@apache.org>.
[ https://issues.apache.org/jira/browse/MESOS-35?page=com.atlassian.jira.plugin.system.issuetabpanels:all-tabpanel ]
Andy Konwinski reassigned MESOS-35:
-----------------------------------
Assignee: Andy Konwinski
> Slave webui needs to correctly display stdout/stderr of executors.
> ------------------------------------------------------------------
>
> Key: MESOS-35
> URL: https://issues.apache.org/jira/browse/MESOS-35
> Project: Mesos
> Issue Type: Bug
> Components: slave, webui
> Reporter: Benjamin Hindman
> Assignee: Andy Konwinski
> Attachments: MESOS-35.patch
>
>
> There have been some changes to the work directories for frameworks due to multi-executor support and so the slave webui is no longer properly linking to executors stdout/stderr.
--
This message is automatically generated by JIRA.
If you think it was sent incorrectly, please contact your JIRA administrators: https://issues.apache.org/jira/secure/ContactAdministrators!default.jspa
For more information on JIRA, see: http://www.atlassian.com/software/jira
[jira] [Commented] (MESOS-35) Slave webui needs to correctly
display stdout/stderr of executors.
Posted by "Andy Konwinski (Commented) (JIRA)" <ji...@apache.org>.
[ https://issues.apache.org/jira/browse/MESOS-35?page=com.atlassian.jira.plugin.system.issuetabpanels:comment-tabpanel&focusedCommentId=13155628#comment-13155628 ]
Andy Konwinski commented on MESOS-35:
-------------------------------------
I believe this issue no longer manifests (as of SVN r1205259) if you don't specify a value for work_dir when running the mesos slave (i.e. if you let the default values be used for them, which is either mesos_home or ".").
Michael and I use deploylib (deploylib.com), in which we run mesos on EC2 and we set it up to use a config file in which we specify that work_dir = /mnt and this causes the links (in the slave webui) for a framework's executors' stderr and stdout to break. The erro message says that the /mnt/slave/... directory can't be found. When I manually look, the file that is looking for is in /mnt/work/slave/... (notice the extra "/work").
It appears that with these config settings, slave.cpp puts files in a different directory (relative to work_dir from conf) than webui/slave/webui.py looks for them in.
In src/slave/slave.cpp, when we're building up the directory where the executors' stderr and stdout will eventually go, if work_dir is present as a conf value, we should not append "/work" to it, but we currently do. See snippet below, starting at line 1381:
<code>
1381 string workDir = ".";
1382 if (conf.contains("work_dir")) {
1383 workDir = conf.get("work_dir", workDir);
1384 } else if (conf.contains("home")) {
1385 workDir = conf.get("home", workDir);
1386 }
1387
1388 workDir = workDir + "/work";
1389
1390 std::ostringstream out(std::ios_base::app | std::ios_base::out);
1391 out << workDir << "/slaves/" << id
1392 << "/frameworks/" << frameworkId
1393 << "/executors/" << executorId;
</code>
... having that extra "/work" in the path is breaking things, since when work_dir is set, src/slave/webui.cpp doesn't append "/work" to it (see starting at line 80):
<code>
80 webuiPort = conf.get("webui_port", "8081");
81 logDir = conf.get("log_dir", FLAGS_log_dir);
82 if (conf.contains("work_dir")) {
83 workDir = conf.get("work_dir", "");
84 } else if (conf.contains("home")) {
85 workDir = conf.get("home", "") + "/work";
86 } else {
87 workDir = "work";
88 }
</code>
I'll attach a small patch that doesn't append "/work" to workDir in slave.cpp if workDir is set from the "work_dir" conf flag.
> Slave webui needs to correctly display stdout/stderr of executors.
> ------------------------------------------------------------------
>
> Key: MESOS-35
> URL: https://issues.apache.org/jira/browse/MESOS-35
> Project: Mesos
> Issue Type: Bug
> Components: slave, webui
> Reporter: Benjamin Hindman
>
> There have been some changes to the work directories for frameworks due to multi-executor support and so the slave webui is no longer properly linking to executors stdout/stderr.
--
This message is automatically generated by JIRA.
If you think it was sent incorrectly, please contact your JIRA administrators: https://issues.apache.org/jira/secure/ContactAdministrators!default.jspa
For more information on JIRA, see: http://www.atlassian.com/software/jira
[jira] [Commented] (MESOS-35) Slave webui needs to correctly
display stdout/stderr of executors.
Posted by "Andy Konwinski (Commented) (JIRA)" <ji...@apache.org>.
[ https://issues.apache.org/jira/browse/MESOS-35?page=com.atlassian.jira.plugin.system.issuetabpanels:comment-tabpanel&focusedCommentId=13155653#comment-13155653 ]
Andy Konwinski commented on MESOS-35:
-------------------------------------
I've tested this on OSX, and it seems to work.
> Slave webui needs to correctly display stdout/stderr of executors.
> ------------------------------------------------------------------
>
> Key: MESOS-35
> URL: https://issues.apache.org/jira/browse/MESOS-35
> Project: Mesos
> Issue Type: Bug
> Components: slave, webui
> Reporter: Benjamin Hindman
> Assignee: Andy Konwinski
> Attachments: MESOS-35.patch
>
>
> There have been some changes to the work directories for frameworks due to multi-executor support and so the slave webui is no longer properly linking to executors stdout/stderr.
--
This message is automatically generated by JIRA.
If you think it was sent incorrectly, please contact your JIRA administrators: https://issues.apache.org/jira/secure/ContactAdministrators!default.jspa
For more information on JIRA, see: http://www.atlassian.com/software/jira
[jira] [Updated] (MESOS-35) Slave webui needs to correctly display
stdout/stderr of executors.
Posted by "Andy Konwinski (Updated) (JIRA)" <ji...@apache.org>.
[ https://issues.apache.org/jira/browse/MESOS-35?page=com.atlassian.jira.plugin.system.issuetabpanels:all-tabpanel ]
Andy Konwinski updated MESOS-35:
--------------------------------
Attachment: MESOS-35.patch
> Slave webui needs to correctly display stdout/stderr of executors.
> ------------------------------------------------------------------
>
> Key: MESOS-35
> URL: https://issues.apache.org/jira/browse/MESOS-35
> Project: Mesos
> Issue Type: Bug
> Components: slave, webui
> Reporter: Benjamin Hindman
> Attachments: MESOS-35.patch
>
>
> There have been some changes to the work directories for frameworks due to multi-executor support and so the slave webui is no longer properly linking to executors stdout/stderr.
--
This message is automatically generated by JIRA.
If you think it was sent incorrectly, please contact your JIRA administrators: https://issues.apache.org/jira/secure/ContactAdministrators!default.jspa
For more information on JIRA, see: http://www.atlassian.com/software/jira