How to prevent OS X from launching programs from another disk?
Solution 1:
Try rebuilding the launch services database using the lsregister
command. That database provides the information for the open menu, etc as noted in How to rebuild the LaunchServices database from Macworld's Mac OS X Hints. Rebuilding the launch service database while running from the newly installed partition should fix the problem of trying to open Applications on the other drive partition.
If your "Open With" menu shows applications that are no longer installed, or shows some of them as duplicates, you can use the following Terminal command to rebuild your LaunchServices database:
For OS X 10.6 and later run:
/System/Library/Frameworks/CoreServices.framework/Versions/A/Frameworks/LaunchServices.framework/Versions/A/Support/lsregister -kill -r -domain local -domain system
For OS X 10.5 and older run:
/System/Library/Frameworks/ApplicationServices.framework/Frameworks/LaunchServices.framework/Support/lsregister -kill -r -domain local -domain system -domain user
If the problem persists after running the above command, try un mounting your original partition before running the above command again. Additionally, as noted on the hints article and when running the lsregister
command with no arguments there is some helpful output that will allow further customization to specify where to look for Applications, etc.