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

Bug 1086691

Summary: Accessing a Gear by ssh shows "Your application is out of disk space" when "quota" command is missing
Product: OpenShift Container Platform Reporter: Miguel Perez Colino <miguel>
Component: ContainersAssignee: Brenton Leanhardt <bleanhar>
Status: CLOSED ERRATA QA Contact: libra bugs <libra-bugs>
Severity: unspecified Docs Contact:
Priority: high    
Version: 2.0.0CC: gpei, libra-onpremise-devel, misalunk
Target Milestone: ---   
Target Release: ---   
Hardware: Unspecified   
OS: Unspecified   
Whiteboard:
Fixed In Version: Doc Type: Bug Fix
Doc Text:
Story Points: ---
Clone Of: Environment:
Last Closed: 2014-05-15 14:40:58 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:
Attachments:
Description Flags
Proposed fix none

Description Miguel Perez Colino 2014-04-11 10:20:49 UTC
Description of problem:
Accessing a Gear by ssh shows:
Your application is out of disk space; please run "rhc app-tidy disktest"
.. when the quota command is missing

Version-Release number of selected component (if applicable):
OSE 2.0
rubygem-openshift-origin-node-1.17.5.11-1.el6op.noarch

How reproducible:
Make /usr/bin/quota unavailable in a node. Access via ssh a gear in that node


Steps to Reproduce:
1. Make /usr/bin/quota unavailable in a node. 
2. Access via ssh a gear in that node

Actual results:
Your application is out of disk space; please run "rhc app-tidy ttt"

Expected results:
Command "quota" not found for app ttt, please check the node hosting this app

Additional info:
It can be fixed by modifying the "if" statement in line 86 of /usr/bin/rhcsh

  # If quota command not found, notify it
  if which quota  > /dev/null  2>&1
    then
    # Quota returns nonzero if you are over limit
    quota >/dev/null 2>&1
    if [ $? -ne 0 ]
    then
      echo "Your application is out of disk space; please run \"rhc app-tidy $OPENSHIFT_APP_NAME\"" 1>&2
    fi
  else
      echo "Command \"quota\" not found for app $OPENSHIFT_APP_NAME, please check the node hosting this app"
  fi

Comment 1 Miguel Perez Colino 2014-04-11 10:21:45 UTC
Created attachment 885358 [details]
Proposed fix

Comment 4 Brenton Leanhardt 2014-04-14 13:07:13 UTC
Upstream pull request: https://github.com/openshift/origin-server/pull/5234

This will mostl likely make it in to the OSE 2.1 build today.

Comment 5 openshift-github-bot 2014-04-14 14:27:46 UTC
Commit pushed to master at https://github.com/openshift/origin-server

https://github.com/openshift/origin-server/commit/22cac6eac6f2bd6196ee27e33702c9579716f01d
Bug 1086691 - Accessing a Gear by ssh shows "Your application is out of disk space" when "quota" command is missing

Comment 7 Gaoyun Pei 2014-04-16 02:58:10 UTC
Verify this bug with rubygem-openshift-origin-node-1.23.3-1.git.80.2aa8d87.el6op.noarch

Create an app on node1, then remove the quota command.
[root@node1 ~]# quota
-bash: quota: command not found

[root@broker conf.d]# rhc ssh app1
...
Command "quota" not found for app app1, please check the node hosting this app
[app1-eee.ose21-manual.com.cn 534df11bfdae85037a0000a8]\>