Bug 1128932 - oo-accept-node quota check fails on xfs
Summary: oo-accept-node quota check fails on xfs
Keywords:
Status: CLOSED CURRENTRELEASE
Alias: None
Product: OpenShift Online
Classification: Red Hat
Component: Containers
Version: 2.x
Hardware: Unspecified
OS: Unspecified
medium
medium
Target Milestone: ---
: 2.x
Assignee: Rajat Chopra
QA Contact: libra bugs
URL:
Whiteboard:
Depends On:
Blocks: 1131016
TreeView+ depends on / blocked
 
Reported: 2014-08-11 21:24 UTC by Troy Dawson
Modified: 2015-05-14 23:37 UTC (History)
4 users (show)

Fixed In Version:
Doc Type: Bug Fix
Doc Text:
Clone Of:
: 1131016 (view as bug list)
Environment:
Last Closed: 2014-10-03 17:53:10 UTC
Target Upstream Version:
Embargoed:


Attachments (Terms of Use)

Description Troy Dawson 2014-08-11 21:24:05 UTC
Description of problem:
If the user home area is on XFS, the check_quotas section will fail on xfs, even if quotas are on and enforcing.

Version-Release number of selected component (if applicable):
openshift-origin-node-util-1.28.1-1.el6oso

How reproducible:
100%

Steps to Reproduce:
1. Create a node that has the gear home filesystem on XFS
2. oo-accept-node -v
3.

Actual results:
...
INFO: checking filesystem quotas
FAIL: quotas are not enabled on /var/lib/openshift (/dev/mapper/EBSStore01-user_home01)
INFO: checking quota db file selinux label
1 ERRORS
...

Expected results:
...
INFO: checking filesystem quotas
INFO: checking quota db file selinux label
...
Additional info:
We have verified that the quota is enabled for the users by trying to fill up their home area.  They are unable to go past their quota.

Looking at the code in oo-accept-node, it is using the command.
  /sbin/quotaon -u -p <home dev>
EXT4:
# /sbin/quotaon -u -p /dev/EBSStore01/user_home01
user quota on /var/lib/openshift (/dev/mapper/EBSStore01-user_home01) is on
XFS:
# /sbin/quotaon -u -p /dev/EBSStore01/user_home01
user quota on /var/lib/openshift (/dev/mapper/EBSStore01-user_home01) is off

Using that command, it certainly looks like the quota is off.  It might be a bug in the quotaon command.
If we use the repquota command, it seems to work better on XFS.

# repquota  -v /dev/EBSStore01/user_home01
...
*** Status for user quotas on device /dev/mapper/EBSStore01-user_home01
Accounting: ON; Enforcement: ON

I don't currently have the correct solution, I'm just bringing the bug forward.

Comment 1 Rajat Chopra 2014-08-18 17:07:20 UTC
Pull request https://github.com/openshift/origin-server/pull/5718

This fixes oo-accept-node. Not clear yet how the other parts of the quota system will work on XFS.

Comment 2 Meng Bo 2014-08-20 02:21:42 UTC
Move the bug back since the PR in comment#1 has been closed.

Comment 3 Rajat Chopra 2014-08-20 02:54:43 UTC
That got closed by mistake. Its in the merge queue now. Sorry about the noise.

Comment 4 Meng Bo 2014-08-20 11:34:53 UTC
Checked on devenv_5096, with xfs type filesystem mounted to node, and add the GEAR_HOME_DIR as the new mount point.

oo-accept-node will check the filesystem and try to use repquota if it is xfs type.

INFO: checking filesystem quotas
repquota: Mountpoint (or device) /xfs not found or has no quota enabled.
repquota: Not all specified mountpoints are using quota.
FAIL: quotas are not enabled on /xfs (/dev/xvdb1)
INFO: checking 0 user accounts

Comment 5 Troy Dawson 2014-10-03 17:53:10 UTC
Closing.  This was fixed at least with release 2.0.50.


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