Issues with blockages in the distributed Peoples database

This is an issue that has been germane for almost a year. I was unconvinced by the explanation from local Apple Support and I raise the issue here in the hope of sharing etc.

  1. I have some 55 thousand photos and 6 thousand videos all on iCloud Photos.
  2. I have these photos and videos also on my iMac with originals also stored on my iMac
  3. I have iCloud Photos with “optimize mac storage” on my iPhone and iPad. I don’t need original copies stored on these devices.
  4. I have some 101 people favorited in my Peoples Database. There are others who are identified but not favorited.
  5. Both my iPhone and iPad are plugged in at night with Photos in the background and in the case of the iPad sometimes for a few days. On Saturdays, they are plugged in and not touched for 24 hours each week with Photos running in the background. This has gone on for nearly a year.
  6. The iPhone has scanned 99% of the photos but has about 200 to go. It has had 200 to go for about 6 months and this number does not reduce.
  7. The iPad has scanned 98% of the photos and has about 600 to go. This number also is constant and will not reduce over time.
  8. I have turned off iCloud and turned it on. No change.
  9. I have factory reset my iPad and just turned on iCloud Photos and watched it populate over about a week and then get stuck again, as above.
  10. I have been through Apple Support on 2 occasions and we got to the point of installing debug profiles on my iPhone and iPad and then downloading mega large debug and log files and sending them up the chain to senior engineers for further advice and assistance. In both cases, I never heard again from anyone. When I contacted Apple Support they had no further advice. After the first attempt, we did it all again for the second attempt, and again no feedback from anybody.
  11. On my third attempt, support tried to be helpful and promised to get back to me. They did and then told me that "this behavior was normal because the technology was new and slow and greatly affected by the quality and quantity of the pictures in my Photos database. I agreed but noted that a slow process doesn’t stop over 6 months. I know “something” about these things: I taught Software Testing at the University level and have postgraduate degrees in Computer Science.
  12. I noted that there were three other telltale signs that all was not right: (a) the key photo on one or two favorited people was not the same on each device (even though the key photo was extant), (b) the number of photos and videos was not precisely the same on the iDevices (iCloud and iMac were fine), and (c) there was one person favorited on one iDevice which was not favorited on all the other devices. I argued that this was an indicator that it wasn’t just a slow machine learning process at play here, but rather, a bug or two and/or some corruption of a local database.
  13. I don’t know exactly how the Peoples database is “pseudo-shared” amongst devices. I assume that there is a local peoples database that is synced with the others and each database is stored locally and/or stored in the cloud so that if I identify someone as “Mr X” on my iPhone, that tagged identity propagates into all the other devices.
  14. I am very loathed to now also factory reset my iPhone because that process did not help my iPad’s library.

I have seen murmurings in various forums of people who have similar issues with a constipated People database that is seemingly scanning forever. Originally Apple Support thought it might be my network … and I quickly disavowed that possibility; that is not the issue at all.

Has anyone seen this problem? Has anyone been able to press a button that will cause the senior engineers to actually look at the debug and diagnostics files I uploaded and give me some informed information as opposed to the somewhat tepid (albeit friendly and professional) attempts to help me over the last year with this problem.

Thanks in advance!

Alas, this is one of those things that’s simply beyond what an ordinary user can touch. Cloud sync systems are black boxes.

One possibility is that the reporting is wrong instead of the behavior being wrong. You say the key photos aren’t always the same, but can you tell if certain photos are in a person’s set on one device but not the other?

Yes, I can tell. Someone suggested that I might have 32-bit incompatible photos in my library and/or Videos. I have looked at that and I don’t think that’s the case. I do have some large videos in my photos library eg 1Gb each, but I’d have thought that it would only look at the first frames to see if it can identify anyone in the video. Another strange behavior is that on one device it will suddenly change the key photo on its own. I thought it might be because the key photo wasn’t there, but it was.

1 Like

I checked all my files. I found some .m4v videos which were fine but didn’t play inside Photos cleanly … I recreated them in an mp4 and they are fine. This didn’t help the constipation in the Peoples database, sadly.

Some updates. There were two orthogonal things happening. I have seen both reported as problems and no solution to either. The first was a constant crash with “TrustedPeersHelper quit unexpectedly” on my Mac with Catalina. I’ve seen various attempts to eradicate this, none successful. Another was a more common crash related to the Metal library which I think was being used to decode videos in the library. I can’t recall the exact error message but it was a common complaint from people. The TrustedPeersHelper crashes perked my interest because I suspected that in comparing pictures between my Photos and my iCloud Photos there was an issue with authentication. That was further “confirmed” when I tried to fix things by turning off iCloud and then turning it back on with Photos sync off and then turning Photos sync back on. Suddenly I found that the Keychain was not turning on (it asked me lots of times for passwords and codes for my iPhone and iPad and accepted these). It would be greyed out and then just turn off. With all these issues I finally decided to bite the bullet and consider that there was some issue with my Keychain on my Mac and this was related to the TrustedPeers issues which were in turn related to Photos synchronisation. After deleting my login Keychain (that was nerve-wracking because I wasn’t sure if this would delete my Keychain passwords on Safari on my iPad and iPhone, though I had most passwords in BitWarden anyway) I was able to eventually turn on the Keychain on my Mac to syng with iCloud. Progress. I was loathe though to do a clean virgin install of Catalina, after erasing my disk in order to see whether the TrustedPeers and Metal crashes would disappear. I did do it, and lo and behold I have not seen either of those two crashes again. My Photos database has now redownloaded to my Mac. The Peoples database seems to be intact which suggests that tags identifying people I had identified were preserved in iCloud centrally. In other words, I hadn’t seemingly lost the connection between Photos and people I had identified even though I had scrubbed my Mac. To be sure, my Mac is now rescannning all the downloaded Photos (16000 done and 36000 to go). I leave my Mac on without sleep (just monitor sleep) and it grinds away with the photoanalysis daemon in overdrive if nothing else is happening. I guess the moral of the story is that if you have a system which has been upgraded from Sierra to High Sierra to Catalina to … whatever … eventually there are some nasties or corrupt or deprecated config/other files which seem to linger and cause all manner of strange effects. Every few years, a clean install of the operating system on a virgin erased disk followed by a reinstallation of apps is probably a good thing (though my Microsoft Office install asked me to login into a work account and I no longer have that work account … hmmm there must be some old files I can move across from my backup to get that working again but haven’t seen where Microsoft puts the license files but that’s a tangent). I will come back here when it’s all done and report. One other great trick I learned for my iPad was how to remove all the Photos and have them redownload. Under Photos you can’t simply “select all” and press delete on iOS. Manually selecting 55K worth of pictures/videos is not an option. The solution? Plug the iPad (or iPhone) into your Mac and open up ImageCapture on the Mac to connect to your iPad. ImageCapture still allows you to select all and delete! This was a life saver and now the Photos on my iPad have redownloaded (optimised, I don’t store them all on the iPad in original format) and it too is starting to rescan the photos to reconcile them with the Peoples database …

Your lengthy paragraph is way too long for me to even read at this time, let alone respond to, but was successful in fixing this one by following someone’s recommendations as follows:

So use these steps to fix it are:

  • use Applications/Utils/Activity Monitor to find the PID of ‘secd’.
  • Then do ‘kill -HUP pidOfsecd’ in terminal
  • Then ‘tpctl reset’ in terminal

Yes I had tried those steps prior and they didn’t work