Hide Forgot
Description of problem: There should be a check to ensure that the vm.overcommit_memory variable is set to 0 on Red Hat Satellite 6.X We have two scripts to add this check into: One is : https://access.redhat.com/solutions/1474003 The other is the pre-upgrade check preformed by the foreman-installer itself: # foreman-rake katello:upgrade_check Version-Release number of selected component (if applicable): How reproducible: Very Steps to Reproduce: 1. Set teh vm.overcommit to 2 and the upgrade will fail every time. 2. 3. Actual results: Currently there is no check for this. Expected results: For either the healthcheck script or the preupgrade script to flag this as needing to be fixed. Additional info: This BZ is related to https://access.redhat.com/solutions/2548501
add'l info: If you run a java app without Xmx set, it will ask for 1/4 of physical memory. If vm.overcommit_memory is set to 0 (default) or 1, this is fine. The OS will give the process 1/4 of memory, but will not guarantee that the full space is available. However, if vm.overcommit_memory is set to 2, it enforces that all memory allocated to processes is backed by physical memory. To try this out, you can start a VM, use >75% of memory, then run "java -version". If overcommit is set to 2, it will fail. This is not unreasonable behavior, since Java has no idea how much mem it will need without Xmx guidance, and typically it's fine to ask for more than what it actually uses. Some users set vm.overcommit_memory to 2 in order to avoid OOM conditions. However, any process that asks for more memory than it needs may not be able to execute. There are two ways to "fix" this for Satellite: * verify that overcommit is not set to 2 during pre-upgrade check * ensure that all java processes have Xmx set to something reasonable, to avoid the "25% of physical mem" default. Both of these would be good to do, but the first option is most needed. Users should not run overcommit_memory=2 on a Satellite, since it is not a tested scenario.
Created redmine issue http://projects.theforeman.org/issues/16300 from this bug
Verified. Tested in Satellite 6.3 - Snap 13 Some output from the CLI of what I did to verify: --- [root@tyan-gt24-13 ~]# sysctl -n vm.overcommit_memory 2 [root@tyan-gt24-13 ~]# satellite-installer This system has the vm.overcommit.memory flag enabled in sysctl. Please set this to 0 and then run the installer again.
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/RHSA-2018:0336