Note: This bug is displayed in read-only format because the product is no longer active in Red Hat Bugzilla.

Bug 1202466

Summary: OPENSHIFT_GEAR_MEMORY_MB is not updated when updating memory limits
Product: OpenShift Container Platform Reporter: Timothy Williams <tiwillia>
Component: ContainersAssignee: Brenton Leanhardt <bleanhar>
Status: CLOSED DUPLICATE QA Contact: libra bugs <libra-bugs>
Severity: medium Docs Contact:
Priority: unspecified    
Version: 2.2.0CC: jhonce, jokerman, libra-onpremise-devel, mmccomas
Target Milestone: ---   
Target Release: ---   
Hardware: x86_64   
OS: Linux   
Whiteboard:
Fixed In Version: Doc Type: Bug Fix
Doc Text:
Story Points: ---
Clone Of: Environment:
Last Closed: 2015-03-16 17:02:52 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:

Description Timothy Williams 2015-03-16 16:56:45 UTC
Description of problem:
When updating memory limits in /etc/openshift/resource_limits.conf, the OPENSHIFT_GEAR_MEMORY_MB environment variable on applications is not updated with the new memory limits.

Version-Release number of selected component (if applicable):
2.2

How reproducible:
Always

Steps to Reproduce:
1. Create a gear and check the value of OPENSHIFT_GEAR_MEMORY_MB
2. Increase the memory limit in /etc/openshift/resource_limits.conf, following the steps at the top of the file to instantiate the changes
3. Check the value of OPENSHIFT_GEAR_MEMORY_MB again
4. Check the actual cgroup memory limit for this application at /cgroup/memory/openshift/GEAR_UUID/memory.limit_in_bytes

Actual results:
OPENSHIFT_GEAR_MEMORY_MB does not change to reflect the new memory limit

Expected results:
OPENSHIFT_GEAR_MEMORY_MB changes to reflect the new memory limit when the memory limit is changed

Additional info:
This can have a major affect on some applications, such as ruby:

https://github.com/openshift/origin-server/blob/master/cartridges/openshift-origin-cartridge-ruby/versions/shared/etc/conf.d/performance.conf.erb#L5

Comment 1 Jhon Honce 2015-03-16 17:02:52 UTC

*** This bug has been marked as a duplicate of bug 1196783 ***