I have a 21.5" imac with one HP external display. I have getting the same gray background on the external display after waking up the screens. I placed the dock on the opposite side of the screen from the external display. (eg. my external screen is oriented on the left of the main screen, and my dock is on the right side of my main screen)
I've only been testing the fix for about 20 minutes now, but it seems to have worked.
This has been driving me nuts for ages. I decided to just create a little script to run "killall Dock" and launch it from said Dock.
Script to kill the Dock
Create a text file called Killdock
Add this to KillDock:
Save and exit
Make the file executable:
chmod 755 KillDock
Test it by running ./KillDock
You can then launch it from the dock itself by doing the following:
Either in Finder or in Terminal, rename KillDock to KillDock.command
In Finder, drag the KillDock.command file to the Dock (it will only go to the right of the separator next to the Trash bin.
Yes I know this is not a fix - same as everything here, but only an easier workaround - until Appl€ fix this very annoying bug!
Hope this helps!
Here are 10 problems I have with Lion that might be related to this thread, and what I think might be going on:
I have this problem too. It seems like it has been happening ever since Lion came out, but I feel like it got worse around December, plus or minus a month. I'm a graphic design student and I bring my 2011 Macbook Pro with me to work and plug it in at home at night. At work I don't have an external display, but at home I have a DS-263N. I connect to it with a TB to DVI adapter. That setup seemed to work fine before Lion.
Now I have a few different issues after waking from sleep.
- Gray background. Annoying.
- Full screen applications, mainly Mail (that's the main one I use though) will sometimes lose their menu bar or otherwise show up mostly off the screen, with no way to exit full screen mode.
- Windows moved around/resized long and skinny. It seems like they retain their width, but get as short as the application allows if you tried to shrink them yourself.
- Login box. Sometimes it's gone, sometimes I can see a corner of it peeking out of the top right of my screen, sometimes it will appear and then go away and the computer will suddenly sleep again.
- After logging in for about 10-15 seconds, my computer will go back to sleep. This is usually preceded by the funky login box issues mentioned above. It is very jarring and happens unexpectedly, but not very often. Maybe once or twice a week, through dozens of sleep cycles.
- Sometimes after logging in, my menu bar will be gone at the top, as well as my dock (not hidden). If I remember correctly, it seems like sometimes my desktop icons have also disappeared along with this issue. Like the one above, it is often preceded by strange login box behavior. It happens slightly more often then the above issue as well, maybe up to 3 times a week.
- Often when I have the gray background issue, the fuzzy background behind the Launchpad often disappears, showing through the regular desktop behind it, making things far less legible.
- Somtimes when having the gray background issue, the textures on the Mission Control background disappear, and sometimes the whole thing gets somewhat distorted and things don't line up properly or overlap. This distortion doesn't seem to happen as often as the missing pattern, however.
- Occasionally the Dashboard will overlay on top of what I'm currently working on. But it's not what you're thinking. I have the Dashboard setup as it's own desktop space. But the controls for editing the Dashboard Widgets will come up over what I'm working on. This seems to be the rarest of bugs. In addition, I even had mail exit full screen and land itself inside the dashboard. I could move it around inside the Dashboard and resize it, and even arranged my Widgets around it because it was kind of nice. It only lasted until I had to reboot or killed the Dock process as something else was broken. Can't remember which.
- Lastly, I've noticed that in Photoshop my document will be using the color settings for the main Macbook Pro display. They look muted and darker on my IPS screen. I've noticed it more recently as the current website I'm designing uses vibrant colors and the reds and greens were getting absolutely slaughtered. So I did a test: I opened my lid and waited for the display to wake up. I then moved my Photoshop window over to the Macbook Pro display and watched as the colors seemed to match perfectly what I would expect. But then as I move them back to the other display, it would flick over to the correct colors. Might be a Photoshop bug (I only noticed it since running the CS6 beta), but I thought it was worth a mention as it doesn't always do this, and it seems to accompany the other bugs—I think.
Many times when these issues are happening, I will notice my internal Macbook Pro's screen lighting up through the logo. It does it one or more times. I always run it in clamshell mode up on a mesh stand that keeps it nice and cool and elevated, as having the screen closed can cause an increase in temperature since the fan intakes are mainly around and in the keyboard area from what I understand.
My theory: the computer is having trouble knowing which display it should use upon waking from sleep. It flicks back and forth between them, and in the process something gets screwed up.
Per the color profile example above (#10), I would speculate that it believes it is using the Macbook Pro display, even though it is outputting to the external. Or at least it is part-way believing that it is using that display. That could explain the gray background issue.
Let me elaborate: my Macbook Pro will remember different displays I have plugged into it and set the correct background wallpaper. But what if there is no display plugged in? Well then it would not want to load the wallpaper into memory as that would be a waste. So it halfway thinks it's using the built-in display. It senses the external, matches the resolution, but that's it. It doesn't recognize an identifier? Maybe? That would tell it ok, this external uses X color profile, X wallpaper, and X whatever else. Perhaps this causes some of the other issues. Like ok, X monitor is setup as primary but it's not plugged in (or recognized by an ID), so don't put the menu bar at the top, or since it doesn't think an external is in use, it doesn't load the blurred out version of it's wallpaper for the Launchpad, or maybe the textures for Mission Control and other things go haywire because they think they are on a smaller resolution screen? My external is 1920x1200, and my MBP is 1680x1050.
So maybe upon login, some preference file is getting corrupted as it has a problem making the switch between the displays. If I were an Apple engineer (hah I wish), I would focus on that area, based on my own personal observations. I use my Macbook Pro to make a living, and to do school work (though I'm graduating soon), but this issue is still very annoying and often interrupts my workflow. As a workaround, I put the killall Dock command into Automator and saved it as an app to my desktop called "Fix My Mac" that I can click on to help get rid of some of these issues. That is, until my desktop icons disappear. Maybe I should set a keybaord shortcut for Terminal, lol.
As for debugging steps, I've tried about everything listed here already. Resetting PRAM, repairing permissions, updating everything, and even uninstalling or removing a lot of the tweaks or custom system utilities that I have installed.
I'm a huge Apple fan, but I still consider it unacceptable that this issue has been around for this long and is still not resolved. Perhaps moving to a yearly release cycle for OS X has put the pressure on the team to deliver new features instead of fixing existing bugs? I sure hope that's not the case. But perhaps the team in Cupertino could try using their Macs with some under $1000 non-Cinema displays? I've yet to hear of anyone having an issue with them. Maybe I'll put some graduation money towards one, lol. But I'm kind of wanting to hold off for a Retina Cinema Display, which would be magic for design work.
Here are some screenshots of the various bugs that I've amassed. Though I think I'm missing some.
This one was while I was working on cutting up a PDF for an email blast in Photoshop CS6. It's the Dashboard bug I mentioned earlier:
Here is an older one I found in my screenshot folder:
Here is one showing the Launchpad issue:
Here is another shot from another time:
Here is the dashboard bug:
I wish I had some screenshots of the other bugs, but I can't find them if I do. I don't think I've ever tried taking a screenshot at the login box, not sure if that would even work?
So that's my exhaustive overview of my Lion problems that are likely related to the issue in this post. Hopefully an Apple engineer will see this post and it will be helpful! Feel free to contact me, Apple engineers. I'd love to help settle this issue once and for all! This has been pretty ridiculous. I'm a fairly computer literate person. I used to build my own systems and wasted so much time troubleshooting Windows crap. I've been on OS X since 10.4 and Lion seems like a Lemon to me. 10.6 was rock solid, but I love some of the features in Lion like swiping between desktops. I just wish these bugs would get patched!
Really nice review. Thanks.
I am experiencing 90% of issues you've just mentioned except I don't work in photoshop so I have no problems related to it. So I can't confirm p10.
I am wathcnig that thread for a long time and there were couple of updates but it looks like no one in Apple even cares! And that's a kind of weird taking into consideration MPB price.
So I confirm issues p1-p9. On top of it, all that clamshell concept is a total crap.
1. User should have an option to choose when MBP will go sleep, when to stay awake even with a closed lid (overheating is not an issue as long as is is perfectly ok to work with an external monitor)
2. MPB should never try to power on internal screen when the lid is closed. It is just stupid and non sense. That's what even cheap laptops would no do...
One more related. Dock has a bug with multiple running aps icons.
There is a command open -n ...
-n Open a new instance of the application(s) even if one is already running.
I am personally using two skype instances and one skype icon often dissappears from Dock. And always will dissappear when the gray background issue happens or when the Dock was reloaded with "killall Dock"
No problem—I like to be as thorough as possible.
I've got a few more screenshots to share since then. One is a snapshot with my iPhone of the login box issue, as it refused to let me screenshot that screen.
Interesting that the login box issue correlated with these subsequent problems. All of these screenshots are from right after logging in this evening...
Login box moved to top right corner:
Detail view of login box: up against corner of monitor:
Screenshot showing missing menu bar and Photoshop magically moved over the the far right of the screen:
Here is the same screenshot but with Launchpad activated. Note it only dims the display, kind of like Dashboard used to do before Lion. No blur, no icons at all:
Here is a screenshot of Mission Control. The background isn't messed up, and the windows aren't acting weird, but it scrambled the image in Photoshop, and that was not the size of the image. When clicked on, the image was roughly 1/6 the size of the scrambled area, so I'm not sure where that came from:
I will have to post the remaining screenshots below as it doesn't seem to allow me to attach any more to this post. Perhaps I hit a limit?
Here are the remaining screenshots from the post above...
This is a screenshot of the Dashboard bug where all the widgets like to pile up in the corner:
In this bug (which I forgot about—must be the rarest of them?) the dock turned black, where mine is normally a light grayish silver:
Please note that throughout these, the gray background didn't show up, but sometimes these issues are associated with it, which is why I am posting.
Also please note in the screenshot in the above post that shows the Mission Control, the dock is missing, and it is normally visible. I forgot to note that.
I was not able to fix any of these bugs using killall Dock in terminal (using my desktop app that runs the script). The only way to fix this issue was to open the lid on the MBP and wait for the built-in display to switch on, then the menu bar, dock, and everything else went back to normal. I was able to close the lid again and not have any issues. Though curiously the black dock remains. I believe a system restart will clear it, however.
These bugs are getting out of control! I tested my system for that supposed new Mac malware that can effect your system by using a Java vulnerability, but the test results were negative—thank goodness! But part of me almost wishes this was a virus, just so I could devise a way to remove it and fix my system. No such luck.
Please, PLEASE Apple read this post and begin working on a fix ASAP. I feel like the bugs are getting worse/more frequent as time goes on. I'm considering disabling sleep on my system so things aren't all screwed up every time I come back. Or at least setting it to something ridiculous like 4 hours. It's rare that I'm away from my machine for that long—even during the night. I am a college student/design intern at an ad agency and I'm graduating in about a month. I have no life...it's all on my Mac, iPad and iPhone. At least the last two work properly most of the time. My Mac used to before Lion! But it's getting worse!!
I just made an interesting find. I noticed my line-out was unplugged and when I went to plug it back in, it pulled the Mini Display Port to DVI dongle out of my system and caused it to go to sleep.
I then went on to wake it from sleep, but it wouldn't wake becasue the cable was pulled out just slightly.
After the second time I checked the cable and it came back on the third wake from sleep. This time the screen was completely black, but I entered my password. Upon waking, my screen was set at 800x600 resolution, which is weird. But after changing it back, I noticed many of my windows that were fine (except at lower resolution) were shifted to different locations on the screen, and smaller. Here is the screen shot:
This leads me to believe that one of two things is happening here:
- There is some error in the way that the dongle from Apple is translating things to the display (proper resolution, etc). Or like I mentioned earlier, Lion is just confused about the display's info and not setting the proper settings or
- Our monitors have something about them that is causing this issue
Since this bug didn't manifest until after Lion, and I had my monitor before Lion, I'm not sure. Maybe there is some strange thing happening with our monitors and the way it communicates with Lion? Flipping through screen resolutions that are wrong, etc.
So maybe we should post our setups to narrow down possibilities.
- February 2011 Macbook Pro 15" 2.2Ghz Core i7 8GB ram Hi-Res display 8GB ram 128GB SSD
- Mini Display Port to DVI adapter from Apple going from Thunderbolt port to full size DVI cable.
- Monitor: DoubleSight DS-263N 26" H-IPS 1920x1200.
Software tricks that I've tried since my previous post:
No apps in full screen mode.
Hardware issues I've ruled out:
Problem persists with or without USB HDD, FireWire HDD, Wacom tablet, printer, or line-out audio plugged in.
Software issues I still need to try:
Making the dock visible by default (no auto-hide)
Hardware issues I still need to try:
Different monitor (this might be tricky), non Apple wired keyboard and Magic Mouse, maybe non-Apple WIFI router, but that might be pushing it. But who knows at this point!
Please Apple technicians...hear our plea!
I've also had the same annoying gray background issue (Lion, MBP i7, external monitor via miniDP->DVI).
Interestingly, the issue actually went away some time ago, and I almost forgot the whole thing. But now I had to switch to another SSD, and this new installation of Lion instantly brought back the same problem (I made a fresh install instead of restoring from a backup). Hardware is the same (apart from the SSD), and the Lion version is also now the latest, same as with the previous SSD.
Now I'm thinking that maybe there was some voodoo earlier in this thread I tried that actually helped! Have to go back and check...