XFS quotacheck OOM

Bug #1069947 reported by Milan
6
This bug affects 1 person
Affects Status Importance Assigned to Milestone
linux (Ubuntu)
Confirmed
Medium
Unassigned

Bug Description

Hello,

I have a 1.2 TiB XFS file system with 1.1 TiB of data and 14 million inodes used. When I try to enable user and group quota on the file system, XFS quotacheck is run on mount with "-o uquota,gquota". A few seconds after the quotacheck starts, the OOM killer starts killing processes and I get these messages on the serial console:

[ 157.508682] Out of memory: Kill process 680 (upstart-udev-br) score 1 or sacrifice child
[ 157.516799] Killed process 680 (upstart-udev-br) total-vm:17232kB, anon-rss:192kB, file-rss:0kB
[ 157.543556] Out of memory: Kill process 1081 (upstart-socket-) score 1 or sacrifice child
[ 157.551760] Killed process 1081 (upstart-socket-) total-vm:15188kB, anon-rss:184kB, file-rss:0kB
[ 157.578237] Out of memory: Kill process 1284 (rsyslogd) score 1 or sacrifice child
[ 157.585823] Killed process 1284 (rsyslogd) total-vm:253712kB, anon-rss:556kB, file-rss:0kB
[ 157.719863] Out of memory: Kill process 1299 (getty) score 1 or sacrifice child
[ 157.727181] Killed process 1299 (getty) total-vm:12932kB, anon-rss:156kB, file-rss:4kB
...
[ 251.512025] XFS: possible memory allocation deadlock in kmem_zone_alloc (mode:0x2d0)
[ 253.516024] XFS: possible memory allocation deadlock in kmem_zone_alloc (mode:0x2d0)
...

Shortly before the SSH connection to the machine is lost, /proc/slabinfo shows the following line:

slabinfo - version: 2.1
# name <active_objs> <num_objs> <objsize> <objperslab> <pagesperslab> : tunables <limit> <batchcount> <sharedfactor> : slabdata <active_slabs> <num_slabs> <sharedavail>
...
xfs_inode 1981333 1981333 960 17 4 : tunables 0 0 0 : slabdata 116549 116549 0
...

The machine has 2 GiB RAM, of which 1.8 GiB are used by the XFS inode cache, if I read these numbers correctly.

The machine runs the following kernel:

# uname -a
Linux bombax 3.2.0-32-generic #51-Ubuntu SMP Wed Sep 26 21:33:09 UTC 2012 x86_64 x86_64 x86_64 GNU/Linux
#

Patches for this very issue are mentioned here:

http://oss.sgi.com/archives/xfs/2012-06/msg00362.html

(The size of the xfs_inode entry in /proc/slabcache confirms that this is the issue, according to the person mentioning the patches.)

Can you apply these fixes to the Precise kernel?

---
AlsaVersion: Advanced Linux Sound Architecture Driver Version 1.0.24.
AplayDevices: Error: [Errno 2] No such file or directory
ApportVersion: 2.0.1-0ubuntu14
Architecture: amd64
ArecordDevices: Error: [Errno 2] No such file or directory
AudioDevicesInUse: Error: command ['fuser', '-v', '/dev/snd/by-path', '/dev/snd/controlC1', '/dev/snd/hwC1D0', '/dev/snd/pcmC1D3p', '/dev/snd/controlC0', '/dev/snd/hwC0D0', '/dev/snd/pcmC0D0c', '/dev/snd/pcmC0D0p', '/dev/snd/pcmC0D1c', '/dev/snd/pcmC0D1p', '/dev/snd/seq', '/dev/snd/timer'] failed with exit code 1:
CRDA: Error: command ['iw', 'reg', 'get'] failed with exit code 1: nl80211 not found.
Card0.Amixer.info: Error: [Errno 2] No such file or directory
Card0.Amixer.values: Error: [Errno 2] No such file or directory
Card1.Amixer.info: Error: [Errno 2] No such file or directory
Card1.Amixer.values: Error: [Errno 2] No such file or directory
DistroRelease: Ubuntu 12.04
IwConfig: Error: [Errno 2] No such file or directory
Lsusb: Error: [Errno 2] No such file or directory
MachineType: System manufacturer System Product Name
Package: linux 3.2.0.32.35
PackageArchitecture: amd64
ProcEnviron:
 TERM=xterm
 LANG=C.UTF-8
 SHELL=/bin/bash
ProcFB:

ProcKernelCmdLine: BOOT_IMAGE=/boot/vmlinuz-3.2.0-32-generic bootdegraded=true root=/dev/mapper/system1-ubuexp--slash ro nosplash nofb nomodeset consoleblank=0 console=tty0 console=ttyS0,115200n8 debug=unusedvalue
ProcVersionSignature: Ubuntu 3.2.0-32.51-generic 3.2.30
RelatedPackageVersions:
 linux-restricted-modules-3.2.0-32-generic N/A
 linux-backports-modules-3.2.0-32-generic N/A
 linux-firmware 1.79.1
RfKill: Error: [Errno 2] No such file or directory
Tags: precise
Uname: Linux 3.2.0-32-generic x86_64
UpgradeStatus: No upgrade log present (probably fresh install)
UserGroups:

dmi.bios.date: 10/29/2007
dmi.bios.vendor: Phoenix Technologies, LTD
dmi.bios.version: ASUS M2N-SLI DELUXE ACPI BIOS Revision 1302
dmi.board.name: M2N-SLI DELUXE
dmi.board.vendor: ASUSTeK Computer INC.
dmi.board.version: 1.XX
dmi.chassis.asset.tag: 123456789000
dmi.chassis.type: 3
dmi.chassis.vendor: Chassis Manufacture
dmi.chassis.version: Chassis Version
dmi.modalias: dmi:bvnPhoenixTechnologies,LTD:bvrASUSM2N-SLIDELUXEACPIBIOSRevision1302:bd10/29/2007:svnSystemmanufacturer:pnSystemProductName:pvrSystemVersion:rvnASUSTeKComputerINC.:rnM2N-SLIDELUXE:rvr1.XX:cvnChassisManufacture:ct3:cvrChassisVersion:
dmi.product.name: System Product Name
dmi.product.version: System Version
dmi.sys.vendor: System manufacturer

Revision history for this message
Brad Figg (brad-figg) wrote : Missing required logs.

This bug is missing log files that will aid in diagnosing the problem. From a terminal window please run:

apport-collect 1069947

and then change the status of the bug to 'Confirmed'.

If, due to the nature of the issue you have encountered, you are unable to run this command, please add a comment stating that fact and change the bug status to 'Confirmed'.

This change has been made by an automated script, maintained by the Ubuntu Kernel Team.

Changed in linux (Ubuntu):
status: New → Incomplete
tags: added: precise
Changed in linux (Ubuntu):
importance: Undecided → Medium
Revision history for this message
Joseph Salisbury (jsalisbury) wrote :

It was mentioned in http://oss.sgi.com/archives/xfs/2012-06/msg00362.html that the patch will be proposed to linux 3.2 stable. The fix will make it's way into Precise through the usual stable updates, if accepted in upstream stable.

Revision history for this message
Milan (public-mjh) wrote : AcpiTables.txt

apport information

tags: added: apport-collected
description: updated
Revision history for this message
Milan (public-mjh) wrote : AlsaDevices.txt

apport information

Revision history for this message
Milan (public-mjh) wrote : BootDmesg.txt

apport information

Revision history for this message
Milan (public-mjh) wrote : Card0.Codecs.codec.0.txt

apport information

Revision history for this message
Milan (public-mjh) wrote : Card1.Codecs.codec.0.txt

apport information

Revision history for this message
Milan (public-mjh) wrote : CurrentDmesg.txt

apport information

Revision history for this message
Milan (public-mjh) wrote : Dependencies.txt

apport information

Revision history for this message
Milan (public-mjh) wrote : Lspci.txt

apport information

Revision history for this message
Milan (public-mjh) wrote : PciMultimedia.txt

apport information

Revision history for this message
Milan (public-mjh) wrote : ProcCpuinfo.txt

apport information

Revision history for this message
Milan (public-mjh) wrote : ProcInterrupts.txt

apport information

Revision history for this message
Milan (public-mjh) wrote : ProcModules.txt

apport information

Revision history for this message
Milan (public-mjh) wrote : UdevDb.txt

apport information

Revision history for this message
Milan (public-mjh) wrote : UdevLog.txt

apport information

Revision history for this message
Milan (public-mjh) wrote : WifiSyslog.txt

apport information

Changed in linux (Ubuntu):
status: Incomplete → Confirmed
Revision history for this message
Milan (public-mjh) wrote :

May it be possible to add this patch to the Ubuntu kernel anyway? I have two reasons:

1. I cannot turn on XFS quota on a filesystem with many files, as described above.

2. As far as I can remember from the last six months, if I run xfs_check(8) on a filesystem, a quotacheck will be needed afterwards. This means that if I happen to do an xfs_check on a filesystem because I suspect a corrupt filesystem, I cannot use XFS quotas afterwards.

Of course, I unterstand your reasons for waiting for the patch to be accepted in -stable. I tried to find out about the state of the patch, but I couldn't find much:

http://oss.sgi.com/archives/xfs/2012-08/msg00255.html (102 patches are proposed for -stable, the patch mentioned above is among them -- comment: too many patches at once)
http://oss.sgi.com/archives/xfs/2012-09/msg00260.html (here it is mentioned that the patch is included in 3.5)

penalvch (penalvch)
tags: added: bios-outdated-1804 needs-upstream-testing regression-potential
description: updated
To post a comment you must log in.
This report contains Public information  
Everyone can see this information.

Other bug subscribers

Remote bug watches

Bug watches keep track of this bug in other bug trackers.