MacOS – How to identify application of hung menu bar icon

macosmenu bar

My Mac sometimes ends in a state with high CPU usage for SystemUIServer. This causes poor performance and decreased battery life.

I can resolve the problem by rebooting the machine but the problem inevitably reappears after some time.

I have found out that this seems to be caused by an application that has an icon in the menu bar. I tried closing all such applications by right-clicking them and selecting their Quit menu item. Now, I notice a gap in the menu line and when I hover the mouse cursor over the gap then I see the infamous spinning beach ball of death.

Screen shot of menu bar icons

How do I identify the misbehaving the underlying application – i.e. its name and/or filesystem path?

I am running Mac OS X Lion version 10.7.5

Best Answer

Use the Accessibility Inspector, accessible from Xcode → Open Developer Tool → Accessibility Inspector.

Click "Show" on the "Hierarchy" sub-section (which will show you the Application Name).

Click on the "Target Icon" at the top of the Inspector (Labeled: Start inspection follows point).

Hover over the item and the pane may show you enough information for you to determine what it is. For example, hovering the Dropbox menu bar item shows "Dropbox <version>" under AXHelp, and hovering Little Snitch shows "Little Snitch Agent" under AXTitle.