Bug 1401417 - Enable ansible to deploy logging with the default journald log driver
Summary: Enable ansible to deploy logging with the default journald log driver
Keywords:
Status: CLOSED NOTABUG
Alias: None
Product: OpenShift Container Platform
Classification: Red Hat
Component: Installer
Version: 3.4.0
Hardware: Unspecified
OS: Unspecified
medium
medium
Target Milestone: ---
: ---
Assignee: Scott Dodson
QA Contact: Johnny Liu
URL:
Whiteboard:
Depends On:
Blocks:
TreeView+ depends on / blocked
 
Reported: 2016-12-05 08:02 UTC by Xia Zhao
Modified: 2017-02-21 22:40 UTC (History)
4 users (show)

Fixed In Version:
Doc Type: If docs needed, set a value
Doc Text:
Clone Of:
Environment:
Last Closed: 2017-02-21 22:40:21 UTC
Target Upstream Version:


Attachments (Terms of Use)
ansible task log (22.33 KB, text/plain)
2016-12-05 08:02 UTC, Xia Zhao
no flags Details
deployer log (43.31 KB, text/plain)
2016-12-05 08:03 UTC, Xia Zhao
no flags Details

Description Xia Zhao 2016-12-05 08:02:52 UTC
Created attachment 1228000 [details]
ansible task log

Description of problem:
Currently ansible didn't set value to parameter "use_journal" while deploy logging, and fluentd collects logs from json-file log driver by default:
$ oc logs -f logging-deployer-dlnow
...
+ use_journal=
+ journal_read_from_head=false
+ journal_source=
...

We should enable ansible to deploy logging with the default journald log driver.

Version-Release number of selected component (if applicable):
# openshift version
openshift v3.4.0.32+d349492
kubernetes v1.4.0+776c994
etcd 3.1.0-rc.0

openshift-ansible-3.4.31-1.git.0.4b78e57      


How reproducible:
Always

Steps to Reproduce:
1. Deploy logging with these parameters passing to ansible:
 openshift_hosted_logging_deployer_prefix: ${ops-registry-image-prefix}
 openshift_hosted_logging_deploy: true
 openshift_hosted_logging_storage_kind: dynamic
 openshift_hosted_logging_deployer_version: 3.4.0

2. Check logging pods:
# oc get po
NAME                          READY     STATUS      RESTARTS   AGE
logging-curator-1-l0fzh       1/1       Running     0          4h
logging-deployer-dlnow        0/1       Completed   0          4h
logging-es-1yl4qhyc-1-91pkd   1/1       Running     0          4h
logging-fluentd-5f3s1         1/1       Running     0          4h
logging-fluentd-dhojf         1/1       Running     0          4h
logging-kibana-1-tz7ks        2/2       Running     0          4h

3. Check deployer configmap content
# oc get configmap logging-deployer -o yaml
apiVersion: v1
data:
  es-cluster-size: "1"
  es-ops-cluster-size: "1"
  es-ops-pvc-dynamic: "true"
  es-ops-pvc-prefix: logging-es
  es-ops-pvc-size: 10Gi
  es-pvc-dynamic: "true"
  es-pvc-prefix: logging-es
  es-pvc-size: 10Gi
  kibana-hostname: kibana.{subdomain}
  kibana-ops-hostname: kibana-ops.{subdomain}
  public-master-url: https://{master-domain}:8443
kind: ConfigMap
metadata:
  creationTimestamp: 2016-12-05T02:12:33Z
  name: logging-deployer
  namespace: logging
  resourceVersion: "1221"
  selfLink: /api/v1/namespaces/logging/configmaps/logging-deployer
  uid: 4865c5ef-ba90-11e6-9243-42010af00014

4. Check the fluentd log driver

Actual results:
4. Fluentd collects logs from json-file log driver since "use_journal" was set to empty

Expected results:
4. Ansible should be enabled to deploy logging with the default journald log driver

Additional info:
1. ansible log attached
2. deployer pod log attached

Comment 1 Xia Zhao 2016-12-05 08:03:42 UTC
Created attachment 1228002 [details]
deployer log

Comment 2 Scott Dodson 2016-12-05 14:41:01 UTC
Eric,

When should we set use_journal? Whenever the docker log driver is journald or all the time regardless?

Comment 3 ewolinet 2016-12-05 19:30:07 UTC
When the docker log driver is journald.

Comment 5 Scott Dodson 2017-02-21 22:40:21 UTC
Based on discussion in https://github.com/openshift/openshift-ansible/pull/3432 I am closing this NOTABUG


Note You need to log in before you can comment on or make changes to this bug.