12

In Mac OS X 10.8.2, I have this curious problem. Every time I install a new updated version of one of several applications that I use, my system adds a new duplicate entry in the "Open With" contextual menu:

enter image description here

I have tried clearing caches and rebuilding disk permissions and rebooting, but the problem persists.

I have completely rebuilt the Launch Services database and completely rebuilt Pre-Binding, more than once, by using the standard command line tools and using two different commercial cleaning utilities to do the same thing.

I have also deleted and rebuilt Spotlight and then rebuilt Launch Services and cleared caches again.

Nothing has any effect.

It seems there have been similar questions posted here before, and all of them are incorrectly answered by "Rebuild the Launch Services database" but that does not help the problem.

Update 18 January 2013

After filing a bug report with Apple, I have received a notification that this is a known bug that they are already tracking and working on. It is Bug ID# 11582257, for anybody who follows these things.

Update April 2013

This bug has not been fixed in Mac OS X 10.8.3.

Update June 2013

This bug has still not been fixed in Mac OS X 10.8.4.

7
  • I don't recommend onyx - but I do like this answer and apple.stackexchange.com/a/66870/5472
    – bmike
    Jan 12, 2013 at 21:21
  • Please reopen. The "exact duplicate" is a different situation with distinctly different symptoms, applying to OS X 10.6, and the solution proposed there does not help me in OS X 10.8.2. I have completely rebuilt the Launch Services database and it has no effect on this problem.
    – user9290
    Jan 12, 2013 at 21:25
  • Other related questions: 9929, 10523, 64124, 64580, 68530. If you've done a rebuild of the database, and made sure spotlight isn't finding legitimate dupes, you could edit that into the question so that it's less like the other questions I have linked.
    – bmike
    Jan 12, 2013 at 23:07
  • 1
    There are a plethora of explanations on the other questions. In the end, you have a spotlight problem, a duplicate app problem or a launch service database problem. Working through all the answers should alert you to which situation you are experiencing.
    – bmike
    Jan 15, 2013 at 18:03
  • 2
    It's a bug in OS X actually. Remains unfixed at the time of writing this.
    – user10355
    Jan 15, 2013 at 18:18

3 Answers 3

6

I have found a Terminal command that works in Mountain Lion. It gives the correct sequence of commands for lsregister to correct this problem:

/System/Library/Frameworks/CoreServices.framework/Frameworks/LaunchServices.framework/Support/lsregister -kill -r -domain local -domain system -domain user

This was provided by one Dr. Drang on the blog at LeanCrew.com in a post called Getting rid of Open With duplicates. It was posted on February 16, 2013.

You can read the blog post at the link above for all the details.

Presumably, until Apple fixes this known bug, it may be necessary to re-run this command every time a new version of an app gets installed on my system, causing new duplicate items in the Open With menu.

I must admit that this string was suggested by bmike on January 12, 2013. But for some reason I overlooked it earlier. So thanks, bmike.

2
  • Thanks, it worked. I needed to restart Finder to get the Open With menu to update. I'm running 10.9.2. Mar 26, 2014 at 19:09
  • 1
    yes - this is a good answer but you should add killall Finder; making the complete command /System/Library/Frameworks/CoreServices.framework/Frameworks/LaunchServices.framework/Support/lsregister -kill -r -domain local -domain system -domain user; killall Finder; Mar 31, 2015 at 5:10
2

Do check Wheat's answer where he discovered the circumstances where OS X has a bug and the duplicates are caused by updating an App from the App Store.

For others where this isn't caused by a specific bug in Mountain Lion, the rebuilding has ruled out a stale launch services database, you should now rebuild your entire spotlight database.

This assumes you don't really have several copies of PDFPenPro - so you might run mdfind app_name before and after rebuilding spotlight since that is the likely cause of duplicate entries.

This might also be a good time to be sure your backups are current - random filesystem errors, incompatible utilities, or impending disk failure also could explain the database continuing to get rebuilt with duplicate entries.

5
  • As I stated in my question, I have completely rebuilt Spotlight. That did not help.
    – user9290
    Jan 15, 2013 at 21:04
  • 1
    I have also checked to make sure that I only have one copy of each app in question. But a new duplicate entry gets added to the menu of certain applications each time I install a new update of a newer revision of the application. I'm concluding it's just an unresolved bug in OS X. It's annoying because I use the "Open With" contextual menu constantly in my workflow.
    – user9290
    Jan 15, 2013 at 21:06
  • 1
    Thanks for editing that in / clarifying it. My brain was still remembering the first version of your post apparently. If you want to file a bug with apple, run mddiagnose and send it in - if you have a repeatable case, it should be easy for the engineer to get you to demonstrate the bug and then reproduce it. Better, you know exactly what triggers the addition of the new item.
    – bmike
    Jan 15, 2013 at 21:09
  • Keep us posted! And thanks for sticking with this to clarify why it wasn't like the other questions.
    – bmike
    Jan 16, 2013 at 1:17
  • @WheatWilliams If you post your Radar, I'll link to it in my bug report. This still isn't fixed on 10.8.4 (12E55) so I want to get them a perfect reproducible test case so this can be addressed in the next build if possible. My bug is rdar://14100691
    – bmike
    Jun 8, 2013 at 18:50
0

This has happened to me occasionally, but when it did, it was because there actually were two versions of the app installed. And so (in this case) the fix is to find and delete one of them.

How did I get two copies?  I consider this a bug, but some might disagree. I have a directory called /Application/Non-Apple where I put any apps that aren't built/maintained by Apple (even though they come from the App Store). Most apps update to /Applications instead of to the actual location of the app. Result: the newest version is in /Applications, both versions are in the open with menu, and the Dock still points to the old version.

It doesn't have to be this way (and it shouldn't). I know better behavior is possible because I have two apps that update to the same path as the existing (previous) version.

You must log in to answer this question.