Bug 1371852

Summary: Dynamic pv and pvc are not automatically created when deploying logging with es-pvc-dynamic=true
Product: OpenShift Container Platform Reporter: Xia Zhao <xiazhao>
Component: LoggingAssignee: Luke Meyer <lmeyer>
Status: CLOSED ERRATA QA Contact: Wei Sun <wsun>
Severity: medium Docs Contact:
Priority: medium    
Version: 3.3.0CC: aos-bugs
Target Milestone: ---   
Target Release: 3.3.1   
Hardware: Unspecified   
OS: Unspecified   
Whiteboard:
Fixed In Version: logging-deployer:3.3.0-11 Doc Type: Bug Fix
Doc Text:
Cause: A deployer script bug caused it to ignore some PVC parameters when supplied via configmap. Consequence: Deployer would not create PVCs even though the user specified es{,-ops}-pvc-size in the deployer configmap, and ES would not come up with storage. Fix: Have the script reference the correct script variables, not env variables set from the deployer template parameters. Result: PVC creation works as expected.
Story Points: ---
Clone Of: Environment:
Last Closed: 2016-10-27 16:13:19 UTC Type: Bug
Regression: --- Mount Type: ---
Documentation: --- CRM:
Verified Versions: Category: ---
oVirt Team: --- RHEL 7.3 requirements from Atomic Host:
Cloudforms Team: --- Target Upstream Version:
Embargoed:

Comment 1 Xia Zhao 2016-08-31 12:58:54 UTC
My test env was unexpectedly shut down at this moment, I will reinstall another env and provide logs/dumps later. Sorry for any inconvenience.

Comment 2 Luke Meyer 2016-08-31 14:42:17 UTC
oc create configmap logging-deployer  --from-literal kibana-hostname=kibana... --from-literal public-master-url=https://...:8443 --from-literal es-cluster-size=1 --from-literal enable-ops-cluster=false --from-literal use-journal=true --from-literal kibana-ops-hostname=kibana-ops... --from-literal es-instance-ram=1G --from-literal es-pvc-dynamic=true

I didn't see in there anywhere you specified what size the PVC should request. Without es_pvc_size=<number> it won't create anything. Docs (https://docs.openshift.org/latest/install_config/aggregate_logging.html#aggregate-logging-specifying-deployer-parameters) could probably be improved on this and the deployer could throw an error if the user specifies es-pvc-dynamic=true without a size as this is almost certainly a mistake.

Comment 3 chunchen 2016-09-01 11:12:07 UTC
I tried with specifying the PVC size, but the issue still is reproduced, like below:

oc create configmap logging-deployer  --from-literal kibana-hostname=kibana.0901-8gr.qe.rhcloud.com --from-literal public-master-url=https://openshift-138.lab.sjc.redhat.com:8443 --from-literal es-cluster-size=1 --from-literal enable-ops-cluster=true --from-literal use-journal=false --from-literal kibana-ops-hostname=kibana-ops.0901-8gr.qe.rhcloud.com --from-literal es-instance-ram=1G --from-literal es-pvc-dynamic=true --from-literal es-pvc-size=10G --from-literal es-ops-pvc-size=10G

Comment 4 Luke Meyer 2016-09-09 20:46:54 UTC
jtconnor helped us out with noticing the reason for this in Origin (https://github.com/openshift/origin-aggregated-logging/issues/224). I'll get the fix from there. In the meantime, the workaround is to specify ES_PVC_SIZE in a template parameter rather than the configmap.

Comment 5 Luke Meyer 2016-09-12 20:54:31 UTC
Fixed with logging-deployer:3.3.0-11

Comment 9 errata-xmlrpc 2016-10-27 16:13:19 UTC
Since the problem described in this bug report should be
resolved in a recent advisory, it has been closed with a
resolution of ERRATA.

For information on the advisory, and where to find the updated
files, follow the link below.

If the solution does not work for you, open a new bug report.

https://access.redhat.com/errata/RHBA-2016:2122