Memory leak?? What is causing it?

Can someone help me with a Mac problem? I installed PlayOnMac but I didn't like it, so I uninstalled it but now it said that I ran out of application memory, then everything is paused... There are files that I have no idea what they are, on my SSD. I did a clean install of 10.9.1, but then it happened 20 minutes later. (I restored from a Time Machine backup... So it is definitely either a memory leak or a file I failed to delete. It says that the SystemServerUI has stopped responding (it's using 8+gb of Ram when it occurs). I currently have 16gb ram and a 256 toshiba SSD installed. I can post pictures if needed. It also says that I have 80gb of virtual memory when it freezes. I don't think I should have that much if I deleted all of the files. I get a lot of results when I search for "vm" in my finder. (Not just in the Developer folder.) After I force quit it, everything returns to normal...until it happens again, sometimes only 30 minutes later... I installed Wine, XQuarz11 and PlayOnMac I have no idea what is happening here, so if someone could please help me, that would be fantastic. Thank you very much! I'm pretty sure I forgot to delete some files when I deleted all 3 programs mentioned above... Also after my reinstall, when I try to fix any permissions, I get the following message, "acl found but not expected". It seems like it says this for every file on my Mac... (Point is that it says it a lot) please help me ASAP as I need my Mac to run perfectly for my college classes... Thanks again!

MacBook Pro, OS X Mavericks (10.9.1), 2012 non-retina MacBook Pro

Posted on Feb 14, 2014 11:24 PM

Reply
24 replies

Feb 15, 2014 8:47 AM in response to BobRz

I see that I missed some xquartz files. Not all of the apps had an uninstaller. Last night it was so bad that I had to hold down the power button to reboot it.


Hardware Information:

MacBook Pro (15-inch, Mid 2012)

MacBook Pro - model: MacBookPro9,1

1 2.6 GHz Intel Core i7 CPU: 4 cores

16 GB RAM


Video Information:

Intel HD Graphics 4000 - VRAM: 1024 MB

NVIDIA GeForce GT 650M - VRAM: 1024 MB


System Software:

OS X 10.9.1 (13B42) - Uptime: 0 days 7:23:14


Disk Information:

TOSHIBA THNSNH256GBST disk0 : (256.06 GB)

EFI (disk0s1) <not mounted>: 209.7 MB

disk0s2 (disk0s2) <not mounted>: 255.2 GB

Recovery HD (disk0s3) <not mounted>: 650 MB


HL-DT-ST DVDRW GS41N


USB Information:


Apple Inc. FaceTime HD Camera (Built-in)


Apple Inc. BRCM20702 Hub

Apple Inc. Bluetooth USB Host Controller


Apple Computer, Inc. IR Receiver


Apple Inc. Apple Internal Keyboard / Trackpad


Logitech USB Receiver


FireWire Information:


Thunderbolt Information:

Apple Inc. thunderbolt_bus


Kernel Extensions:


Problem System Launch Daemons:


Problem System Launch Agents:


Launch Daemons:

[System] com.adobe.fpsaud.plist 3rd-Party support link

[System] com.oracle.java.Helper-Tool.plist 3rd-Party support link

[System] com.oracle.java.JavaUpdateHelper.plist 3rd-Party support link

[System] com.teamviewer.teamviewer_service.plist 3rd-Party support link

[System] org.macosforge.xquartz.privileged_startx.plist 3rd-Party support link


Launch Agents:

[System] com.oracle.java.Java-Updater.plist 3rd-Party support link

[System] com.teamviewer.teamviewer.plist 3rd-Party support link

[System] com.teamviewer.teamviewer_desktop.plist 3rd-Party support link

[System] org.macosforge.xquartz.startx.plist 3rd-Party support link


User Launch Agents:


User Login Items:

iTunesHelper


Internet Plug-ins:

OfficeLiveBrowserPlugin: Version: 12.3.6 3rd-Party support link

FlashPlayer-10.6: Version: 12.0.0.44 - SDK 10.6 3rd-Party support link

Flash Player: Version: 12.0.0.44 - SDK 10.6 3rd-Party support link

QuickTime Plugin: Version: 7.7.3

JavaAppletPlugin: Version: Java 7 Update 51 3rd-Party support link

Default Browser: Version: 537 - SDK 10.9


Audio Plug-ins:

BluetoothAudioPlugIn: Version: 1.0 - SDK 10.9

AirPlay: Version: 1.9 - SDK 10.9

AppleAVBAudio: Version: 2.0.0 - SDK 10.9

iSightAudio: Version: 7.7.3 - SDK 10.9


3rd Party Preference Panes:

Flash Player 3rd-Party support link

Java 3rd-Party support link


Bad Fonts:

None


Old Applications:

/Library/Application Support/Microsoft/MERP2.0

Microsoft Error Reporting: Version: 2.2.9 - SDK 10.4 3rd-Party support link

Microsoft Ship Asserts: Version: 1.1.4 - SDK 10.4 3rd-Party support link

Microsoft AutoUpdate: Version: 2.3.6 - SDK 10.4 3rd-Party support link

/Library/Application Support/Microsoft/MAU2.0/Microsoft AutoUpdate.app


Time Machine:

Skip System Files: NO

Mobile backups: OFF

Auto backup: YES

Volumes being backed up:

Destinations:

Mac [Local] (Last used)

Total size: 931.19 GB

Total number of backups: 4

Oldest backup: 2014-02-09 02:38:23 +0000

Last backup: 2014-02-15 10:22:20 +0000

Size of backup disk: Excellent

Backup size 931.19 GB > (Disk size 0 B X 3)

Time Machine details may not be accurate.

All volumes being backed up may not be listed.


Top Processes by CPU:

3% WindowServer

2% EtreCheck

0% mds_stores

0% mds

0% loginwindow


Top Processes by Memory:

147 MB com.apple.IconServicesAgent

115 MB mds_stores

82 MB WindowServer

66 MB mds

66 MB Mail


Virtual Memory Information:

12.65 GB Free RAM

1.56 GB Active RAM

532 MB Inactive RAM

1.26 GB Wired RAM

791 MB Page-ins

0 B Page-outs

Feb 15, 2014 9:30 AM in response to tdm15mn

You can remove those two manually. This is from a Macworld article. Note that those 2 folders are in the root of your hard drive, NOT in the Home folder.


  • Items in /Library/LaunchDaemons and /System/Library/LaunchDaemons load when your Mac starts up, and run as the root user.
  • Items in /Library/LaunchAgents and /System/Library/LaunchAgents load when any user logs in, and run as that user.


Not sure if Team Viewer may be causing you a problem. I've never used it.

Feb 15, 2014 10:16 AM in response to tdm15mn

There is excessive swapping of data between physical memory (that is, the memory chips on the logic board) and virtual memory (one or more files on the startup volume.) That activity is relatively slow and causes the whole system to be less responsive. It can happen for two reasons:


  • A long-running process with a memory leak (a kind of bug)
  • Not enough memory for your usage pattern


Tracking down a memory leak can be difficult, and it may come down to a process of elimination.


These instructions are for OS X 10.9 ("Mavericks.") The procedure may be slightly different for earlier versions of OS X.

When you notice the swap activity, open the Activity Monitor application and select All Processes from the View menu, if it's not already selected. Select the Memory tab. Click the heading of the Real Mem column in the process table twice to sort the table with the highest value at the top. If you don't see that column, select

View ▹ Columns ▹ Real Memory

from the menu bar.

If one process (excluding "kernel_task") is using much more memory than all the others, that could be an indication of a leak. A better indication would be a process that continually grabs more and more real memory over time without ever releasing it. Here is an example of how it's done.


The processes named "Safari Web Content" render web pages for Safari. They use a lot of memory and may leak if certain Safari extensions or third-party web plugins are installed. Consider them prime suspects.


Another process often implicated in memory leaks is "inkjet4" or "inkjet8," which is a component of the HP printing software. If it's present, force-quit the process in Activity Monitor to solve the problem temporarily. Empty the print queues in the Printers & Scanners preference pane (which has a slightly different name in each recent version of OS X.) If you don't use an HP printer, remove the software. Otherwise, if the problem is recurrent, update the software (which may not help) or contact HP support.

"Wired" memory should be a small part of the total. That memory is not swapped, but it makes less physical memory available which may then result in swapping. If you have a lot of wired memory, that's usually an indication of a memory leak in a third-party program that modifies the operating system at a low level. Ask for guidance in that case.


If you don't have an obvious memory leak, your options are to install more memory (if possible) or to run fewer programs simultaneously.

The next suggestion is only for users familiar with the shell. For a more precise, but potentially misleading, test, run the following command:

sudo leaks -nocontext -nostacks process | grep total

where process is the name of a process you suspect of leaking memory. Almost every process will leak some memory; the question is how much, and especially how much the leak increases with time. I can’t be more specific. See theleaks(1) man page and the Apple developer documentation for details.

Feb 15, 2014 11:33 AM in response to Linc Davis

Ok... My laptop froze again, so I had to take these pics with my iPhone 5. http://www.mediafire.com/download/n952vuy0j1lt51l/Pics.zip

Hardware Information:

MacBook Pro (15-inch, Mid 2012)

MacBook Pro - model: MacBookPro9,1

1 2.6 GHz Intel Core i7 CPU: 4 cores

16 GB RAM


Video Information:

Intel HD Graphics 4000 - VRAM: 1024 MB

NVIDIA GeForce GT 650M - VRAM: 1024 MB


System Software:

OS X 10.9.1 (13B42) - Uptime: 0 days 9:52:12


Disk Information:

TOSHIBA THNSNH256GBST disk0 : (256.06 GB)

EFI (disk0s1) <not mounted>: 209.7 MB

disk0s2 (disk0s2) <not mounted>: 255.2 GB

Recovery HD (disk0s3) <not mounted>: 650 MB


HL-DT-ST DVDRW GS41N


USB Information:


Apple Inc. FaceTime HD Camera (Built-in)


Apple Inc. BRCM20702 Hub

Apple Inc. Bluetooth USB Host Controller


Apple Computer, Inc. IR Receiver


Apple Inc. Apple Internal Keyboard / Trackpad


Logitech USB Receiver


FireWire Information:


Thunderbolt Information:

Apple Inc. thunderbolt_bus


Kernel Extensions:


Problem System Launch Daemons:


Problem System Launch Agents:


Launch Daemons:

[System] com.adobe.fpsaud.plist 3rd-Party support link

[System] com.oracle.java.Helper-Tool.plist 3rd-Party support link

[System] com.oracle.java.JavaUpdateHelper.plist 3rd-Party support link

[System] com.teamviewer.teamviewer_service.plist 3rd-Party support link


Launch Agents:

[System] com.oracle.java.Java-Updater.plist 3rd-Party support link

[System] com.teamviewer.teamviewer.plist 3rd-Party support link

[System] com.teamviewer.teamviewer_desktop.plist 3rd-Party support link


User Launch Agents:


User Login Items:

iTunesHelper


Internet Plug-ins:

OfficeLiveBrowserPlugin: Version: 12.3.6 3rd-Party support link

FlashPlayer-10.6: Version: 12.0.0.44 - SDK 10.6 3rd-Party support link

Flash Player: Version: 12.0.0.44 - SDK 10.6 3rd-Party support link

QuickTime Plugin: Version: 7.7.3

JavaAppletPlugin: Version: Java 7 Update 51 3rd-Party support link

Default Browser: Version: 537 - SDK 10.9


Audio Plug-ins:

BluetoothAudioPlugIn: Version: 1.0 - SDK 10.9

AirPlay: Version: 1.9 - SDK 10.9

AppleAVBAudio: Version: 2.0.0 - SDK 10.9

iSightAudio: Version: 7.7.3 - SDK 10.9


3rd Party Preference Panes:

Flash Player 3rd-Party support link

Java 3rd-Party support link


Bad Fonts:

None


Old Applications:

/Library/Application Support/Microsoft/MERP2.0

Microsoft Error Reporting: Version: 2.2.9 - SDK 10.4 3rd-Party support link

Microsoft Ship Asserts: Version: 1.1.4 - SDK 10.4 3rd-Party support link

Microsoft AutoUpdate: Version: 2.3.6 - SDK 10.4 3rd-Party support link

/Library/Application Support/Microsoft/MAU2.0/Microsoft AutoUpdate.app


Time Machine:

Skip System Files: NO

Mobile backups: OFF

Auto backup: YES

Volumes being backed up:

Destinations:

Mac [Local] (Last used)

Total size: 931.19 GB

Total number of backups: 6

Oldest backup: 2014-02-09 02:38:23 +0000

Last backup: 2014-02-15 19:10:03 +0000

Size of backup disk: Excellent

Backup size 931.19 GB > (Disk size 0 B X 3)

Time Machine details may not be accurate.

All volumes being backed up may not be listed.


Top Processes by CPU:

95% SystemUIServer

2% WindowServer

2% EtreCheck

0% mds

0% mds_stores


Top Processes by Memory:

8.58 GB SystemUIServer

33 MB mds_stores

33 MB Finder

33 MB EtreCheck

33 MB WindowServer


Virtual Memory Information:

58 MB Free RAM

4.58 GB Active RAM

4.52 GB Inactive RAM

1.42 GB Wired RAM

974 MB Page-ins

284 KB Page-outs

Feb 15, 2014 1:52 PM in response to tdm15mn

The process leaking memory is SystemUIServer, which draws the icons on the right side of the menu bar.

Problems such as yours are sometimes caused by files that should belong to you but are locked or have wrong permissions. This procedure will check for such files. It makes no changes and therefore will not, in itself, solve your problem.

First, empty the Trash, if possible.

Triple-click anywhere in the line below on this page to select it, then copy the selected text to the Clipboard by pressing the key combination command-C:

find ~ $TMPDIR.. \( -flags +sappnd,schg,uappnd,uchg -o ! -user $UID -o ! -perm -600 \) 2>&- | wc -l | pbcopy

Launch the built-in Terminal application in any of the following ways:

☞ Enter the first few letters of its name into a Spotlight search. Select it in the results (it should be at the top.)

☞ In the Finder, select Go Utilities from the menu bar, or press the key combination shift-command-U. The application is in the folder that opens.

☞ Open LaunchPad. Click Utilities, then Terminal in the icon grid.

Paste into the Terminal window (command-V). The command may take a noticeable amount of time to run. Wait for a new line ending in a dollar sign ($) to appear.

The output of the command will be a number. It's automatically copied to the Clipboard. Please paste it into a reply.

The Terminal window doesn't show the output. Please don't copy anything from there.

Feb 15, 2014 3:17 PM in response to tdm15mn

This procedure probably won't solve the problem, but you should do it anyway and test.


Some of your user files (not system files) have incorrect permissions or are locked. This procedure will unlock all your user files, reset their ownership, and remove their access-control lists. If you've set special values for those attributes, they will be reverted. In that case, either stop here, or be prepared to recreate the settings if necessary. Do so only after verifying that those settings didn't cause the problem. If none of this is meaningful to you, you don't need to worry about it.

Back up all data.

Step 1

If you have more than one user account, and the one in question is not an administrator account, then temporarily promote it to administrator status in the Users & Groups preference pane. To do that, unlock the preference pane using the credentials of an administrator, check the box marked

Allow user to administer this computer

Then reboot. You can demote the problem account back to standard status when this step has been completed.

Enter the following command in the Terminal window in the same way as before (triple-click, copy, and paste):

{ sudo chflags -R nouchg,nouappnd ~ $TMPDIR..; sudo chown -R $UID:staff ~ $_; sudo chmod -R u+rwX ~ $_; chmod -R -N ~ $_; } 2>&-

This time you'll be prompted for your login password, which won't be displayed when you type it. You may get a one-time warning to be careful. If you don’t have a login password, you’ll need to set one before you can run the command. If you see a message that your username "is not in the sudoers file," then you're not logged in as an administrator.

The command may take several minutes to run, depending on how many files you have. Wait for a new line ending in a dollar sign ($) to appear, then quit Terminal.

Step 2 (optional)

Take this step only if you have trouble with Step 1, if you prefer not to take it, or if it doesn't solve the problem.

Boot into Recovery. When the OS X Utilities screen appears, select

Utilities Terminal

from the menu bar. A Terminal window will open. In that window, type this:

res


Press the tab key. The partial command you typed will automatically be completed to this:

resetpassword

Press return. A Reset Password window will open. You’re not going to reset a password.

Select your startup volume ("Macintosh HD," unless you gave it a different name) if not already selected.

Select your username from the menu labeled Select the user account if not already selected.

Under Reset Home Directory Permissions and ACLs, click the Reset button.

Select

Restart

from the menu bar.

This thread has been closed by the system or the community team. You may vote for any posts you find helpful, or search the Community for additional answers.

Memory leak?? What is causing it?

Welcome to Apple Support Community
A forum where Apple customers help each other with their products. Get started with your Apple Account.