Browse Source

Merge "Link kolla_log volume dir to /var/log/kolla"

tags/8.0.0.0rc1
Zuul 3 months ago
parent
commit
45ee749a6a

+ 7
- 0
ansible/roles/common/tasks/bootstrap.yml View File

@@ -5,3 +5,10 @@
5 5
     action: "create_volume"
6 6
     common_options: "{{ docker_common_options }}"
7 7
     name: "kolla_logs"
8
+
9
+- name: Link kolla_logs volume to /var/log/kolla
10
+  become: true
11
+  file:
12
+    src: /var/lib/docker/volumes/kolla_logs/_data
13
+    path: /var/log/kolla
14
+    state: link

+ 8
- 0
doc/source/user/troubleshooting.rst View File

@@ -95,6 +95,14 @@ provide no information.
95 95
 To learn more about Docker command line operation please refer to `Docker
96 96
 documentation <https://docs.docker.com/reference/>`__.
97 97
 
98
+The log volume "kolla_logs" is linked to ``/var/log/kolla`` on the host.
99
+You can find all kolla logs in there.
100
+
101
+.. code-block:: console
102
+
103
+   readlink -f /var/log/kolla
104
+   /var/lib/docker/volumes/kolla_logs/_data
105
+
98 106
 When ``enable_central_logging`` is enabled, to view the logs in a web browser
99 107
 using Kibana, go to
100 108
 ``http://<kolla_internal_vip_address>:<kibana_server_port>`` or

+ 6
- 0
releasenotes/notes/link_kolla_logs-e57a1e583f2872eb.yaml View File

@@ -0,0 +1,6 @@
1
+---
2
+other:
3
+  - |
4
+    Link kolla_logs docker volume to /var/log/kolla.
5
+    Shorter log path will help to debug from log.
6
+    The volume path is compatible with docker-engine and docker-ce.

+ 3
- 0
tools/cleanup-containers View File

@@ -43,4 +43,7 @@ done
43 43
 echo "Removing volumes..."
44 44
 (docker volume rm ${volumes_to_remove} 2>&1) > /dev/null
45 45
 
46
+echo "Removing link of kolla_log volume..."
47
+(rm -f /var/log/kolla 2>&1) > /dev/null
48
+
46 49
 echo "All cleaned up!"

Loading…
Cancel
Save