Hacker News new | ask | show | jobs
by dschuler 1691 days ago
I've been having some sort of severe performance issue in one form or another since Mojave/Catalina or so with a 2017 MBP and a 2020 M1 Mac Mini.

The symptoms is always generally poor performance after the system has been running a while (4h to a week, varies), usually with WindowServer using CPU cycles non-stop and UI that felt choppy across all programs.

This seemed to happen frequently after "opening many files", like doing some recompiling with Xcode for a few hours, or indexing a large volume with Spotlight. Rebooting helps temporarily.

Today I realized that data read/written since boot was about 1TB in a few hours on a brand new OS install, and I traced this back to the com.apple.Safari.History process. Somehow having bookmarks and previously using Safari 15.x caused a huge amount of I/O that wouldn't stop - the solution was to remove all bookmarks and reading list items. Performance was immediately back to normal, no reboot needed.

So just logging in with your iCloud id, you could be "importing" whatever performance problem you're having on a new install.

I recommend you reboot and take a look at your disk I/O stats - maybe this will help someone!

9 comments

Do you run your laptop on non—native resolution? Or an external monitor with a non-native resolution?

I'm runnign on 2018 MBP, 16GB RAM + 4k external monitor. I experienced the same type of issues a couple of months back — high WindowServer CPU, mega choppy UI after a few days of use. Initially thought it was Safari, but it kept happening with other browsers as well. Researched it a bit and found a thread where someone suggested running both the laptop and the monitor on native resolution. Haven't had any problems since doing that. WindowServer sits at about 10% CPU and ~2GB RAM, current uptime 10 days.

I think I had the same problem as you (similar hw and setup). Do you have a discrete GPU? If so check the link below out. For me, this behavior was due to OSX flip-flopping between discrete and internal GPU. Once I set it to discrete all the time (I'm always plugged in) the problem went away.

https://support.apple.com/en-us/HT202043

Seems to me a different issue than what people are complaining about atm... but what do i know, might be one and the same.

Edit: very weird... Looks like this setting was reverted for me. I just updated from 11.? to 12.0.1, so I wonder if the installer undid some of my changes. No performance issues, but I've literally just my computer on for the first time after the upgrade.

Nope, I just have an integrated Intel GPU.

I'm also pretty much always plugged in. It's likely that the issue was manifesting before switching to a 4k monitor, but after switching the issue became unbearable. E.g I'd wait 2-3s to switch between windows or desktops. Running both screens on native resolutions and I'm switching between windows near-instantly.

¯\_(ツ)_/¯

:( Sorry to hear that... I know it must be so incredibly frustrating!

Sounds like it isn't an issue of flip/flopping between discrete and integrated GPU then... must just be the integrated GPU and its ability to deal with non-native resolutions.

IIRC, when the M1 first came out, there were a bunch of people saying their SSDs were being worn out super quickly, citing SMART statistics. Perhaps this safari process was the culprit?
> Perhaps this safari process was the culprit?

No, for many people it was Rosetta apps.

BTW, Apple totally lied when they said they "fixed it" in an update and it was only a "reporting issue". It's not fixed, and it was absolutely f'ing not a reporting issue. People's SSDs have already failed because of this, and obviously they're soldered.

> People's SSDs have already failed because of this, and obviously they're soldered.

Any links to more info about this? I’ve had my eye on a 16” Pro with an M1 Max for a couple weeks now but want to make sure it won’t have issues like this.

I haven't actually seen any reports of SSDs actually dying. Can you provide some links? SSDs dying in less than a year of typical use is a huge deal.
https://tidbits.com/2021/05/27/an-m1-mac-cant-boot-from-an-e...

I don't see any reports but there is evidence that should the soldered on SSD fail the entire device is borked short of board level repair.

I haven't seen any conclusive evidence one way or the other.
wow Safari is the IE5 of browsers now, having to do so many work arounds like we used to have to do with IE5 and now its killing hardware that you can't even replace.
Chrome is IE of browsers now. 20+ years ago nobody cared about non-IE, today nobody cares about non-Chrome.
Chrome is the IE of browsers with respect to being the dominant player approaching monopoly status.

Safari is the IE of browsers with respect to being buggy and behind on features with a slower release schedule.

IE was both and more extreme on both issues.

It’s only “behind” relative to Chrome, the dominant browser which more or less sets the standards these days. Calling Safari “behind” is judging browsers by how similar to Chrome they are.
Also Firefox and even Edge when the IE version was being developed. They've also refused to implement features which would bring web apps in line with the the capabilities of native iOS apps (things like push notifications, offline support with data that doesn't get cleared every 7 days).
IE never killed hardware. It kept legacy Enterprise technologie alive ( eg. ActiveX )
Unsure whether it's Safari related, but it was solved on a regular macOS update. I didn't recall any specific Safari update, but I might miss it.
Thanks for this tip. I’ve had a similar problem occasionally and this gives me an idea for some things to check.
Yes I've seen something similar. WindowServer taking up all the memory.

In one case I also had it crash while I was out, with every open program opened several times on the dock. I didn't do this and in fact macOS doesn't let you do this. Everything was hanging completely so I had to turn it off and on again :)

But this kind of thing does not instill a lot of confidence

> in fact macOS doesn't let you do this

See open(1), in particular the -n flag.

Yes, noticed this some time ago with WindowServer taking all my CPU usage but only twice so far for this year I think so it was okay. When it occurs every day then I will start to worry then
Have you looked at Keychain items as well? It seems to go very slow for me, and I wonder if that’s part of some similar-sounding slowdown I have.

Quitting Safari seems to resolve the slowness, but not always.

SafaribookmarkSync, Cloudd, along with Content Cache has been problematic for years. Especially if you have huge number of Tabs and Bookmarks that is being synced across devices.

Along with iCloud syncing for one reason or another have relatively higher probability of being messed up during update, and you end up with a scenario where something is to probably synced and it keeps trying it over and over again.

I know you’re humble bragging with Lunar but I’ll bite.

Thanks for such a quality app.

Im only using it to fully turn off my built-in monitor while working in clamshell mode and then manually setting the external’s brightness.

So no sync mode (and not even sunset sunrise)

But solved my problems nicely and no more reaching out to my external monitor’s buttons in Narnia

If I’ll keep using it I’ll make sure to caffeinate you ;)

Count me in as another WindowServer casualty. Can't believe it's 2021 and MacOS can't handle a 4K external monitor without grinding to a halt...