[LU-9977] client ran out of memory when diffing two 2GB files Created: 12/Sep/17 Updated: 07/Dec/17 Resolved: 07/Dec/17 |
|
| Status: | Resolved |
| Project: | Lustre |
| Component/s: | None |
| Affects Version/s: | Lustre 2.11.0, Lustre 2.10.2 |
| Fix Version/s: | None |
| Type: | Bug | Priority: | Critical |
| Reporter: | James Casper | Assignee: | Zhenyu Xu |
| Resolution: | Not a Bug | Votes: | 0 |
| Labels: | None | ||
| Environment: |
clients: trevis-60vm1 & 2 before upgrade: el7.3, zfs 6.5.9, b2_10 branch, v2.10.0, b5 |
||
| Attachments: |
|
||||||||
| Issue Links: |
|
||||||||
| Severity: | 3 | ||||||||
| Rank (Obsolete): | 9223372036854775807 | ||||||||
| Description |
|
Systems were imaged to el7.3/lustre2.10.0. A zfs mount point (v6.5.9) was After systems were imaged to el7.4/2.10.52, an import of the 6.5.9 zpool was While diff was running, top showed it consuming 80-90% of memory. At some I've found two ways to avoid this: 1) Keep everything above the same except work with a newly created zfs pool 2) Instead of diffing two 2GB files, diff two 2GB sets of several smaller Note: When diff is used to compare several smaller files, it uses much less Note: This has also been seen with ldiskfs, but is easier to repro with zfs. |
| Comments |
| Comment by James Casper [ 12/Sep/17 ] |
|
My last successful clean/zfs upgrade was from 2.9.0 to 2.10.0 RC1. |
| Comment by Peter Jones [ 12/Sep/17 ] |
|
Nathaniel Could you please advise Thanks Peter |
| Comment by James Casper [ 12/Sep/17 ] |
|
Just tried my diff again on an imported 6.5.9 zpool. This time it was with 2.10.51 b3624, which also uses zfs 6.5.9 (and has an el7.3 kernel). It killed the diff process again. So this is not a zfs 7.1 issue. |
| Comment by Andreas Dilger [ 13/Sep/17 ] |
|
Could you include the stack traces from the console when the OOM was hit? That should be recorded by conman. Also, for slabtop (and to a lesser extent top), the output should be sorted by total memory usage rather than number of objects (and CPU, respectively). It looks like "too" is being charged for most of the memory usage (it shows in top as 89%), but it isn't clear what that memory is. It is definitely strange that ZFS has anything to do with this, because that is running on the OSS, and the memory used is on the client. |
| Comment by James Casper [ 13/Sep/17 ] |
|
Stack and new slabtop output attached. FYI: This is not zfs related. I finally saw the same results with ldiskfs. |
| Comment by James Casper [ 13/Sep/17 ] |
|
I was able to repro and get a crash dump. |
| Comment by James Casper [ 14/Sep/17 ] |
|
I verified the output from top. The memory usage during diff is dramatically different between reads of a couple 2GB files and reads of several smaller files (60MB or less, total read still ~4GB): two large files: ~85.0% |
| Comment by Peter Jones [ 15/Sep/17 ] |
|
Bobijam Could you please advise on this? It seems to be a CLIO issue that has been introduced since 2.10 Peter |
| Comment by James Casper [ 05/Dec/17 ] |
|
Still seeing 80-90% of memory used during a diff of large files. This is also happening on the latest b2_10 (2.10.2 RC1, b50). The message sent to the console when the memory killer kicks in is "diff: memory exhausted". |
| Comment by Andreas Dilger [ 06/Dec/17 ] |
|
Looking at the slabtop output it doesn’t seem like any slabs are taking up much space, the largest is tens of MB. If all the memory is accounts by diff, then either there is a significant memory leak in diff itself, or the file pages are being accounted against diff but cannot be released while the files are in use? |
| Comment by James Casper [ 06/Dec/17 ] |
|
I ran the diff again with the two directories on / rather than /mnt/lustre. The same behavior was seen (diff: memory exhausted), so I believe this is not a lustre issue. |