Please read this whole message before doing anything.
This procedure is a diagnostic test. It changes nothing, and therefore will not, in itself, solve your problem.
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 procedure will help identify which such modifications you've installed, as well as certain other aspects of the configuration that may have a bearing on the problem. Don’t be alarmed by the apparent 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 possible. If you’re now running in safe mode, reboot as usual before continuing. If you can only boot in safe mode, you can still use this procedure, but not all of it will work. Be sure to mention that in your reply, if you haven't already done so.
Below are instructions to enter UNIX shell commands. The commands are safe and do nothing but produce human-readable text output, but they must be entered exactly as given in order to work. If you have doubts about the safety of the procedure suggested here, search this site for other discussions in which it’s been followed without any report of ill effects. I am not asking you to trust me. If you can't satisfy yourself that these instructions are safe, don't follow them.
The commands will line-wrap or scroll in your browser, but each one is really just a single long 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 copy it.
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. Step 1 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.
Launch the 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.
When you launch Terminal, 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” and press
return. You should then get a new line ending in a dollar sign.
Triple-click anywhere in the line of text below on this page to select it:
PB="/u*/*/Pl* -c Print"; { echo Loaded kernel extensions:; kextstat -kl | awk '!/com\.apple/{printf "%s %s\n", $6, $7}'; echo $'\nLoaded user agents:'; launchctl list | sed 1d | awk '!/0x|com\.apple|org\.(x|openbsd)|\.[0-9]+$/{print $3}'; echo $'\nInserted libraries:'; launchctl getenv DYLD_INSERT_LIBRARIES; echo $'\nUser cron tasks:'; crontab -l; echo $'\nGlobal launchd configuration:'; cat /e*/lau*; echo $'\nPer-user launchd configuration:'; cat .lau*; echo $'\nGlobal login items:'; $PB /L*/P*/loginwindow.plist | awk -F'= ' '/Path/{print $2}'; echo $'\nPer-user login items:'; $PB L*/P*/com.apple.loginitems.plist | awk -F'= ' '/Path/{print $2}'; echo $'\nSafari extensions:'; $PB L*/Saf*/*/E*.plist | awk -F'= ' '/Bundl/{print $2}' | sed 's/\..*$//;s/-[1-9]$//'; printf "\nRestricted user files: %s\n" $(find ~ $TMPDIR.. \( -flags +sappnd,schg,uappnd,uchg -o ! -user $UID -o ! -perm -600 \) | wc -l); echo $'\nExtrinsic loadable bundles:'; cd; find -L /S*/L*/E* {,/}L*/{Ad,Compon,Ex,In,Keyb,Mail/Bu,P*P,Qu,Scripti,Servi,Spo}* -type d -name Contents -prune | while read d; do /usr/libexec/PlistBuddy -c 'Print :CFBundleIdentifier' "$d/Info.plist" | egrep -qv "^com\.apple\.[^x]|Accusys|ArcMSR|ATTO|HDPro|HighPoint|driver\.stex|hp-fax|JMicron|print|SoftRAID" && echo ${d%/Contents}; done; echo $'\nUnsigned shared libraries:'; find /u*/{,*/}lib -type f -exec sh -c 'file -b $1 | grep -qw shared && ! codesign -v $1' {} {} \; -print; echo; ls -A {,/}L*/{La,Priv,Sta}* L*/Fonts; } 2> /dev/null | open -ef
Copy the selected text to the Clipboard by pressing the key combination command-C. Then click anywhere in the Terminal window and paste (command-V). I've tested these instructions only with the Safari web browser. If you use another browser, you may have to press the return key after pasting.
The command may take up to a few minutes to run, depending on how many files you have and the speed of the computer. A TextEdit window will open with the output. Post the contents of the TextEdit window (not the Terminal window) — the text, please, not a screenshot. You can then close the TextEdit window. The title of the window doesn't matter, and you don't need to post that. No typing is involved in this step.
Remember that you must be logged in as an administrator for this step. Do as in Step 1 with this line:
{ echo "Loaded system agents:"; sudo launchctl list | sed 1d | awk '!/0x|com\.(apple|openssh|vix\.cron)|org\.(amav|apac|cups|isc|ntp|postf|x)/{print $3}'; echo $'\n'"Login hook:"; sudo defaults read com.apple.loginwindow LoginHook; echo $'\n'"Root cron tasks:"; sudo crontab -l; echo $'\n'"Log check:"; syslog -k Sender kernel -k Message CReq 'GPU |hfs: Ru|I/O e|find tok|n Cause: -|NVDA\(|pagin|timed? ?o' | tail | awk '/:/{$4=""; print}'; } 2> /dev/null | open -ef
This time you'll be prompted for your login password, which you do have to type. Nothing will be displayed when you type it. Type it carefully and then press return. You may get a one-time warning to be careful. Heed that warning, but don't post it. If you see a message that your username "is not in the sudoers file," then you're not logged in as an administrator.
You can then quit Terminal.
To prevent confusion, I'll repeat: When you type your password in the Terminal window, you won't see what you're typing.
Note: If you don’t have a login password, set one before taking Step 2. If that’s not possible, skip the step.
Important: If any personal information, such as your name or email address, appears in the output of these commands, anonymize it before posting. Usually that won't be necessary.
Remember, Steps 1 and 2 are all copy-and-paste — no typing, except your password. Also remember to post the output as text, not as a screenshot.
Please post the contents of the TextEdit window, not the Terminal window.