collect-logs: add README for log files
This change will create a README file with a simple job debug guide and links to the frequently used but somewhat hidden files within the collected logs. Change-Id: I818067952017c88e855bfeee76fa438638cdd942
This commit is contained in:
parent
4208173975
commit
b7d02e35c2
|
@ -48,6 +48,8 @@ artcl_tar_gz: false
|
|||
|
||||
## publishing related vars
|
||||
artcl_publish: false
|
||||
artcl_env: default
|
||||
artcl_readme_file: "{{ artcl_collect_dir }}/README-logs.html"
|
||||
artcl_txt_rename: false
|
||||
# give up log upload after 30 minutes
|
||||
artcl_publish_timeout: 1800
|
||||
|
|
|
@ -13,6 +13,11 @@
|
|||
curl -k {{ lookup('env', 'BUILD_URL') }}/consoleText | gzip > {{ artcl_collect_dir }}/console.txt.gz
|
||||
when: lookup('env', 'BUILD_URL') != ""
|
||||
|
||||
- name: Generate the README for the logs
|
||||
template:
|
||||
src: README-logs.html.j2
|
||||
dest: "{{ artcl_readme_file }}"
|
||||
|
||||
- name: Retrieve the ARA static playbook report
|
||||
command: cp -a {{ local_working_dir }}/ara {{ artcl_collect_dir }}/ara
|
||||
ignore_errors: "yes"
|
||||
|
@ -80,3 +85,4 @@
|
|||
template:
|
||||
src: full_logs.html.j2
|
||||
dest: "{{ artcl_collect_dir }}/full_logs.html"
|
||||
when: artcl_env != 'tripleo-ci'
|
||||
|
|
|
@ -0,0 +1,53 @@
|
|||
<!DOCTYPE HTML>
|
||||
<html lang="en-US">
|
||||
<head>
|
||||
<title>README for Quickstart Logs</title>
|
||||
</head>
|
||||
<body>
|
||||
<h1>How to figure out what went wrong?</h1>
|
||||
<p>Check the console log and search for <b>PLAY RECAP</b>. There are sometimes
|
||||
multiple ansible runs in a job, usually the last one is the relevant.
|
||||
If no <b>PLAY RECAP</b> text is found that usually means an infra failure
|
||||
before Quickstart could even start. Try rechecking or asking on <i>#tripleo</i>
|
||||
if there's an ongoing infra issue.</p>
|
||||
|
||||
<p>Look for a line above the <b>PLAY RECAP</b> that starts with
|
||||
"<b>fatal:</b>". If no such line is found, try searching for other PLAY RECAP
|
||||
lines or other error outputs.</p>
|
||||
|
||||
<p>If this "fatal" line contains the execution of a shell script and redirects
|
||||
to a log, check which machine that task ran on. Look under that node's
|
||||
directory in the logs to find the file.</p>
|
||||
|
||||
<p>Example output:<br/>
|
||||
<br/><code>
|
||||
fatal: [<b>undercloud</b>]: FAILED! => {"changed": true, "cmd": "set -o pipefail &&
|
||||
/home/{{ undercloud_user }}/<b>overcloud-prep-images.sh</b> 2>&1 | awk '{ print
|
||||
strftime(\"%Y-%m-%d %H:%M:%S |\"), $0; fflush(); }' >
|
||||
/home/stack/<b>overcloud_prep_images.log</b>", "failed": true, "rc": 1}<br/>
|
||||
<br/>
|
||||
PLAY RECAP *********************************************************************<br/>
|
||||
</code></p>
|
||||
|
||||
<p>In this case the <code>overcloud-prep-images.sh</code> script failed, which
|
||||
is redirected to <code>/home/{{ undercloud_user }}/overcloud_prep_images.log
|
||||
</code> on the undercloud.</p>
|
||||
|
||||
<p>If this is a different Ansible error, that could mean either an infra
|
||||
problem (often has <b>UNREACHABLE</b> in the line) or a bug in Quickstart. Ask
|
||||
on <i>#tripleo</i> to get help or open a bug on
|
||||
<a href='https://bugs.launchpad.net/tripleo/+filebug'>Launchpad</a>. Add the
|
||||
"ci" tag if it's a CI issue and "quickstart" if you suspect that the bug is in
|
||||
Quickstart itself.</p>
|
||||
|
||||
<h1>Links to common log files</h1>
|
||||
<ul>
|
||||
<li><a href='undercloud/home/{{ undercloud_user }}/'>undercloud/home/{{ undercloud_user }}/</a>
|
||||
- the source and log output of all templated shell scripts</li>
|
||||
<li><a href='undercloud/var/log/extra/'>undercloud/var/log/extra/</a> -
|
||||
extra system details like package list, and cpu info gathered from the
|
||||
undercloud</li>
|
||||
<li><a href='docs/build/'>docs/build/</a> - autogenerated documentation</li>
|
||||
</ul>
|
||||
</body>
|
||||
</html>
|
Loading…
Reference in New Issue