Uh oh!
There was an error while loading. Please reload this page.
Improve doc for debug - #846
Conversation
jodh-intel
commented
Dec 6, 2017
Note that, strictly, this is blocked by clearcontainers/proxy#181. |
jodh-intel
commented
Dec 6, 2017
Hi @grahamwhaley, @iphutch - please could you review? |
clearcontainersbot
commented
Dec 6, 2017
kubernetes qa-passed 👍 |
grahamwhaley
left a comment
There was a problem hiding this comment.
Some nitpicks, but nothing that really needs to block this, so I'll also give my
lgtm
| latter is useful as it is independent of the lifecycle of each container. | ||
| To view runtime log output, | ||
| To view runtime log output: |
There was a problem hiding this comment.
silly nit - technically I think that is a colon :, not a semi-colon ; :-)
There was a problem hiding this comment.
Wow, that's embarrassing! Fixing... ;)
| The runtime, the shim (`cc-shim`), and the hypervisor all have separate debug | ||
| options in the [configuration file](#Configuration). | ||
| The runtime, the shim (`cc-shim`), the hypervisor and the proxy all have separate `enable_debug=` debug |
There was a problem hiding this comment.
if we are going to call out cc-shim, do we want to call out cc-proxy as well?
There was a problem hiding this comment.
Yeah, I'll re-order the elements and mention the proxy binary name...
| @@ -94,11 +94,30 @@ $ sudo journalctl -t cc-runtime | |||
| ### Enabling debug for various components | |||
There was a problem hiding this comment.
What do you think to changing this title to:Enabling and viewing debug for other components
to cover the fact we now show enabling and viewing, and we cover the runtime separately in the above section ?
There was a problem hiding this comment.
I take your point but this section also enables debug for the runtime. I'll rework both sections to make this clearer...
a761e8c to
4a55e72Comparejodh-intel
commented
Dec 6, 2017
Hi @grahamwhaley - branch updated. |
clearcontainersbot
commented
Dec 6, 2017
kubernetes qa-passed 👍 |
grahamwhaley
left a comment
There was a problem hiding this comment.
One suggestion - not a blocker.
lgtm
| ```bash | ||
| $ sudo sed -i -e 's/^#\(enable_debug\).*=.*$/\1 = true/g' /usr/share/defaults/clear-containers/configuration.toml | ||
| ``` |
There was a problem hiding this comment.
Looking much better, thanks @jodh-intel
Sorry to be a mild pain, but one more suggestion - do you think we should also link from here to the more detailed/specific debug docs we now have as well?
https://github.com/clearcontainers/runtime/blob/master/docs/debug-agent.md
https://github.com/clearcontainers/runtime/blob/master/docs/debug-kernel.md
There was a problem hiding this comment.
Done. Note that those 2 docs had rotted a bit so I've had to update them. In fact, I'm wondering if we want to merge them (maybe into the README itself) since as you can see, they are now very similar.
clearcontainersbot
commented
Dec 6, 2017
kubernetes qa-passed 👍 |
d51328e to
001ed84Compareclearcontainersbot
commented
Dec 6, 2017
kubernetes qa-passed 👍 |
1 similar comment
clearcontainersbot
commented
Dec 6, 2017
kubernetes qa-passed 👍 |
jodh-intel
commented
Dec 7, 2017
Hi @klynnrif, @rcaballeromx - please could you review? |
jodh-intel
commented
Dec 8, 2017
Hi @klynnrif, @rcaballeromx - could you squeeze in a review for this one today possibly? |
klynnrif
commented
Dec 8, 2017
@jodh-intel@rcaballeromx I should have time to take a look today. |
klynnrif
left a comment
There was a problem hiding this comment.
Completed a scrub for grammar and style guide consistency. Thanks!
| ## Debugging | ||
| ## Logging | ||
| The runtime provides `--log=` and `--log-format=` options. However, it can |
There was a problem hiding this comment.
Suggested rewrite to stay active: However, you can also configure it to log...
| The runtime, the shim (`cc-shim`), and the hypervisor all have separate debug | ||
| options in the [configuration file](#Configuration). | ||
| Note that the proxy log entries also include output from the agent (`cc-agent`) and the |
There was a problem hiding this comment.
I am unsure how notes are dealt with here, but I would typically format any sentence(s) as a note if it begins with "Note that..." For example,
..note::
The proxy log entries also include output from the agent (cc-agent) and the hypervisor, which includes the guest kernel boot-time messages.
| ## Debugging | ||
| The runtime, the shim (`cc-shim`), the proxy (`cc-proxy`) and the hypervisor all have separate `enable_debug=` debug |
There was a problem hiding this comment.
Including the final comma (based on the style guide): The runtime, the shim (cc-shim), the proxy (cc-proxy), and the hypervisor all have searate enable_debug= debug...
| The runtime, the shim (`cc-shim`), the proxy (`cc-proxy`) and the hypervisor all have separate `enable_debug=` debug | ||
| options in the [configuration file](#Configuration). By default, all these | ||
| debug options are disabled. Look at the comments in the installed |
| debug options are disabled. Look at the comments in the installed | ||
| configuration file for further details. | ||
| If you wish to enable debug for all components, assuming a standard configuration file path, run: |
| (standard program when running containers on bare metal). | ||
| The Clear Containers agent relies heavily on [`libcontainer`](https://github.com/opencontainers/runc/tree/master/libcontainer) used by [`runc`](https://github.com/opencontainers/runc/) (standard program when running containers on bare metal). | ||
| To provide a debug log of any agent activity on a guest, the Clear Containers |
There was a problem hiding this comment.
Lines 12-14 suggested rewrite (possible this changes the meaning): To provide a debug log of any agent activity on a guest, the Clear Containers agent sends a log through a QEMU serial console, which is collected by cc-proxy] (https://github.com/clearcontainers/proxy) and shown in the proxy's logs.
| 1. Filter the agent debug logs from the `cc-proxy` logs | ||
| The `cc-proxy` logs show the sources of its collated information. To only see | ||
| the agent debug logs, filter `cc-proxy` logs by the QEMU serial console (the |
There was a problem hiding this comment.
... the agent debug logs, filter cc-proxy logs by the QEMU serial console that sent the agent logs.
| 1. Enable debug in `configuration.toml` | ||
| 1. Enable kernel boot messages | ||
| Set the `enable_debug=` option in the `[proxy.cc]` section to `true` (assumes a standard configuration file path): |
There was a problem hiding this comment.
Set the enable_debut= option in the [proxy.cc] section to true, which assumes a standard configuration file path:
| 1. Enable proxy debug | ||
| Set the `enable_debug=` option in the `[proxy.cc]` section to `true` (assumes a standard configuration file path): |
There was a problem hiding this comment.
Set the enable_debug= option in the [proxy.cc] section to true, which assumes a standard configuration file path:
| The Clear Containers Agent relies heavily on libcontainer used by runc | ||
| (standard program when running containers on bare metal). | ||
| The Clear Containers agent relies heavily on [`libcontainer`](https://github.com/opencontainers/runc/tree/master/libcontainer) used by [`runc`](https://github.com/opencontainers/runc/) (standard program when running containers on bare metal). |
There was a problem hiding this comment.
... used by [runc] (https://github.com/opencontainers/runc/), which is the standard program when running containers on bare metal.
jodh-intel
commented
Dec 11, 2017
Hi @klynnrif - thanks for reviewing. Branch updated. (Note that as some of your suggested changes weren't strictly part of the changes I'd made on this PR, I've created a new commit specifically to address all the review changes). |
jodh-intel
commented
Dec 12, 2017
Hi @klynnrif, @rcaballeromx - could one of you take a look at this please? I'd really like to get this landed this week if possible. |
klynnrif
commented
Dec 12, 2017
@jodh-intel@rcaballeromx I can take a look at this today. Thanks! |
klynnrif
left a comment
There was a problem hiding this comment.
A couple minor changes suggested. Thanks!
| Note: | ||
| The proxy log entries also include output from the agent (`cc-agent`) and the | ||
| hypervisor (which includes the guest kernel boot-time messages). |
There was a problem hiding this comment.
... hypervisor, which includes the guest kernel boot-time messages.
| The runtime, the shim (`cc-shim`), the proxy (`cc-proxy`), | ||
| and the hypervisor all have separate `enable_debug=` debug | ||
| options in the [configuration file](#Configuration). By default, all these |
There was a problem hiding this comment.
Lines 116-117 suggested rewrite: All of these debug options are disables by default.
clearcontainersbot
commented
Dec 14, 2017
kubernetes qa-passed 👍 |
All commands should be introduced with a sentence that ends with a colon. Signed-off-by: James O. D. Hunt <james.o.hunt@intel.com>
Renamed "Debugging" section to "Logging" and explained how to view log output for all system components. Also created a top-level "Debugging" section which explains how to enable full debug. Fixesclearcontainers#845. Signed-off-by: James O. D. Hunt <james.o.hunt@intel.com>
The agent and kernel debug documents had deviated from reality. Signed-off-by: James O. D. Hunt <james.o.hunt@intel.com>
Apply further changes to the debug and logging documents based on review feedback. Signed-off-by: James O. D. Hunt <james.o.hunt@intel.com>
bdcb1fe to
56aa874Comparejodh-intel
commented
Dec 14, 2017
Hi @klynnrif - thanks for re-reviewing. Branch updated. |
clearcontainersbot
commented
Dec 14, 2017
kubernetes qa-passed 👍 |
jodh-intel
commented
Dec 15, 2017
Hi @klynnrif - could you re-review this today if possible? |
klynnrif
commented
Dec 15, 2017
@jodh-intel Yes, I can. Thanks! |
jodh-intel
commented
Dec 18, 2017
Hi @klynnrif - please can you check this today? We have sufficient approvals (thanks Rodrigo) but I want to give you one last chance to review (as we still have the red cross against your name). If I haven't heard anything by COB today, I'll assume you are happy for me to force-merge this. |
jodh-intel
commented
Dec 19, 2017
We have sufficient approvals, so merging as we really need this to land... |
…oints network: Marshal BridgedMacvlanEndpoint and MacvtapEndpoint
No description provided.