Refusal to quit

When I shut down this Mac, sometimes Safari quits cleanly, but mostly it doesn't. All Safari's windows close but the app itself doesn't. Checking the Safari menu the Quit command is greyed out whereas formerly it wasn't. At this point my workaround is to Force Quit Safari.


Any ideas what's causing this?


Lion 10.7.3 on a Mac Mini and Safari 5.1.3. Safari extensions in use: Ad Block, 1Password, Click to Flash.

Mac mini, Mac OS X (10.7.3), 2.26GHz Intel Core 2 Duo, 2GB RAM

Posted on Feb 20, 2012 12:18 PM

Reply
21 replies

Feb 20, 2012 12:58 PM in response to Morley Chalmers

Please read this whole message before doing anything.


This procedure is a test, not a solution. Don’t be disappointed when you find that nothing has changed after you complete it.


Step 1


The purpose of this step is to determine whether the problem is localized to your user account.


Enable guest logins and log in as Guest. For instructions, launch the System Preferences application, select Help from the menu bar, and enter “Set up a guest account” (without the quotes) in the search box.


While logged in as Guest, you won’t have access to any of your personal files or settings. Applications will behave as if you were running them for the first time. Don’t be alarmed by this; it’s normal. If you need any passwords or other personal data in order to complete the test, memorize, print, or write them down before you begin.


As Guest, test. Same problem(s)?


After testing, log out of the guest account and, in your own account, disable it if you wish. Any files you created in the guest account will be deleted automatically when you log out of it.


Step 2


The purpose of this step is to determine whether the problem is caused by third-party system modifications that load automatically at startup or login.


Disconnect all wired peripherals except those needed for the test, and remove all aftermarket expansion cards. Boot in safe mode and log in to the account with the problem. The instructions provided by Apple are as follows:



  • Be sure your Mac is shut down.
  • Press the power button.
  • Immediately after you hear the startup tone, hold the Shift key. The Shift key should be held as soon as possible after the startup tone, but not before the tone.
  • Release the Shift key when you see the gray Apple icon and the progress indicator (looks like a spinning gear).



Safe mode is much slower to boot and run than normal, and some things won’t work at all, including wireless networking on some Macs.


The login screen appears even if you usually log in automatically. You must know your login password in order to log in. If you’ve forgotten the password, you will need to reset it before you begin.


Test while in safe mode. Same problem(s)?


After testing, reboot as usual (i.e., not in safe mode.) Post the results of steps 1 and 2.

Feb 20, 2012 2:54 PM in response to Linc Davis

Here's the result of the test. (Remember, the problem is intermittent. Happens much of the time, but sometimes Safari quits normally on shut down.)


Read your eMail all the way through and printed it. Had already been using the Mac for a few hours. Then I shut down the Mac. This time Safari quit normally.


Logged in as a guest. (Already had a Lion-style guest account and had visited it previously. A welcome addition.) On launching Safari I received a Parental Controls dialogue that listed four secure websites (none of them familiar) which Ssafari Webpage Preview Fetcher could not access. Attempted to get Mail running but couldn't remember the password. Took a screenshot. Opened it in Preview. Printed it. Then I shut down the Mac. Everything quit without fuss, including Safari.


Next launched the Mac in Safe mode. Opened my usual apps, including Safari. However Safari couldn't remember my previous Safari tabs. Shut down the Mac. Again Safari quit normally.


Now what do you suggest? Much appreciation for your attention.

Feb 20, 2012 3:01 PM in response to Morley Chalmers

Please read this whole message before doing anything.


This procedure is a diagnostic test. It won’t solve your problem. Don’t be disappointed when you find that nothing has changed after you complete it.


Third-party system modifications are a common cause of usability problems. By a “system modification,” I mean software that affects the operation of other software -- potentially for the worse. The following procedure will help identify which such modifications you've installed. Don’t be alarmed by the complexity of these instructions -- they’re easy to carry out and won’t change anything on your Mac.


These steps are to be taken while booted in “normal” mode, not in safe mode. If you’re now running in safe mode, reboot as usual before continuing.


Below are several lines of text in monospaced type, which are UNIX shell commands. They’re harmless, but they must be entered exactly as given in order to work. If you have doubts about the safety of running these commands, search this site for other discussions in which they’ve been used without any report of ill effects.


Some of the commands will line-wrap or scroll in your browser, but each one is really just a single line, all of which must be selected. You can accomplish this easily by triple-clicking anywhere in the line. The whole line will highlight, and you can then either copy or drag it. The headings “Step 1” and so on are not part of the commands.


Note: If you have more than one user account, Step 2 must be taken as an administrator. Ordinarily that would be the user created automatically when you booted the system for the first time. The other steps should be taken as the user who has the problem, if different. Most personal Macs have only one user, and in that case this paragraph doesn’t apply.


To begin, launch the Terminal application; e.g., by entering the first few letters of its name in a Spotlight search. A text window will open with a line already in it, ending either in a dollar sign (“$”) or a percent sign (“%”). If you get the percent sign, enter “sh” (without the quotes) and press return. You should then get a new line ending in a dollar sign.


Step 1


Copy or drag -- do not type -- the line below into the Terminal window, then press return:


kextstat -kl | awk '!/com\.apple/{printf "%s %s\n", $6, $7}'


Post the lines of output (if any) that appear below what you just entered (the text, please, not a screenshot.)


Step 2


Repeat with this line:


sudo launchctl list | sed 1d | awk '!/0x|com\.(apple|openssh|vix)|edu\.mit|org\.(amavis|apache|cups|isc|ntp|postfix|x)/{print $3}'


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 not to screw up. You don't need to post the warning.


Step 3


launchctl list | sed 1d | awk '!/0x|com\.apple|edu\.mit|org\.(x|openbsd)/{print $3}'


Step 4


ls -1A /e*/mach* {,/}L*/{Ad,Compon,Ex,Fram,In,Keyb,La,Mail/**,P*P,Priv,Qu,Scripti,Servi,Spo,Sta}* L*/Fonts 2> /dev/null


Important: If you synchronize with a MobileMe account, your me.com email address may appear in the output of the above command. If so, anonymize it before posting.


Step 5


osascript -e 'tell application "System Events" to get name of every login item'


Remember, steps 1-5 are all drag-and-drop or copy-and-paste, whichever you prefer -- no typing, except your password. Also remember to post the output.


You can then quit Terminal.

Feb 21, 2012 10:01 AM in response to Morley Chalmers

This forum objects with this statement, "You have included content in your post that is not permitted."


I've posted those instruction hundreds of times, but I've never seen that before. Are there any rude words in the output? I can't imagine why there would be, but I guess it's possible. If you can't get the output to post here, try this: Pastebin.


The email notifications don't come from me; they come from Apple, and you can't reply to them.

Feb 21, 2012 2:16 PM in response to Linc Davis

Step 4: Can't be posted due to a bug in the ASC application.


Step 5:


2012-02-21 12:33:25.793 osascript[562:8703] Error loading /Library/ScriptingAdditions/QXPScriptingAdditions.osax/Contents/MacOS/QXPScriptingAdditions:  dlopen(/Library/ScriptingAdditions/QXPScriptingAdditions.osax/Contents/MacOS/QXPScriptingAdditions, 262): no suitable image found.  Did find:
          /Library/ScriptingAdditions/QXPScriptingAdditions.osax/Contents/MacOS/QXPScriptingAdditions: mach-o, but wrong architecture
osascript: OpenScripting.framework - scripting addition "/Library/ScriptingAdditions/QXPScriptingAdditions.osax" declares no loadable handlers.
2012-02-21 12:33:25.857 osascript[562:8703] Error loading /Users/USER/Library/ScriptingAdditions/Satimage.osax/Contents/MacOS/Satimage:  dlopen(/Users/USER/Library/ScriptingAdditions/Satimage.osax/Contents/MacOS/Satimage, 262): no suitable image found.  Did find:
          /Users/USER/Library/ScriptingAdditions/Satimage.osax/Contents/MacOS/Satimage: no matching architecture in universal wrapper
osascript: OpenScripting.framework - scripting addition "/Users/USER/Library/ScriptingAdditions/Satimage.osax" declares no loadable handlers.
GrowlHelperApp, Snapz Pro X, Mail, Fantastical, BusyCalAlarm, BusyCal, Default Folder X Helper, Things, Alfred, Things Helper, Safari, HoudahSpotHelper, MagicPrefs, Dropbox, HP Product Research, HPEventHandler

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.

Refusal to quit

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